{"action":"opened","number":733,"pull_request":{"url":"https://api.github.com/repos/ucb-bar/chisel/pulls/733","id":85173046,"html_url":"https://github.com/ucb-bar/chisel/pull/733","diff_url":"https://github.com/ucb-bar/chisel/pull/733.diff","patch_url":"https://github.com/ucb-bar/chisel/pull/733.patch","issue_url":"https://api.github.com/repos/ucb-bar/chisel/issues/733","number":733,"state":"open","locked":false,"title":"Invalid verilog generated with constant idx into ROM","user":{"login":"da-steve101","id":3221447,"avatar_url":"https://avatars.githubusercontent.com/u/3221447?v=3","gravatar_id":"","url":"https://api.github.com/users/da-steve101","html_url":"https://github.com/da-steve101","followers_url":"https://api.github.com/users/da-steve101/followers","following_url":"https://api.github.com/users/da-steve101/following{/other_user}","gists_url":"https://api.github.com/users/da-steve101/gists{/gist_id}","starred_url":"https://api.github.com/users/da-steve101/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/da-steve101/subscriptions","organizations_url":"https://api.github.com/users/da-steve101/orgs","repos_url":"https://api.github.com/users/da-steve101/repos","events_url":"https://api.github.com/users/da-steve101/events{/privacy}","received_events_url":"https://api.github.com/users/da-steve101/received_events","type":"User","site_admin":false},"body":"With the following verilog, the always @(*) is interpreted as trigger on all input changes. However as there are no inputs, this never triggers. Hence it has the value xxx. This pr is a bit hacky but gets round it by changing the declaration to set the reg to an initial value.\r\n\r\n```verilog\r\nreg [3:0] T0;\r\n always @(*) case (2'h2)\r\n    0: T0 = 4'h3;\r\n    1: T0 = 4'h1;\r\n    2: T0 = 4'h5;\r\n    3: T0 = 4'h8;\r\n    default: begin\r\n      T0 = 4'bx;\r\n`ifndef SYNTHESIS\r\n// synthesis translate_off\r\n      T0 = {1{$random}};\r\n// synthesis translate_on\r\n`endif\r\n    end\r\n  endcase\r\n```\r\n\r\ninstead have\r\n```verilog\r\nreg [3:0] T0 = 4'h5;\r\n```","created_at":"2016-09-14T06:27:45Z","updated_at":"2016-09-14T06:27:45Z","closed_at":null,"merged_at":null,"merge_commit_sha":null,"assignee":null,"assignees":[],"milestone":null,"commits_url":"https://api.github.com/repos/ucb-bar/chisel/pulls/733/commits","review_comments_url":"https://api.github.com/repos/ucb-bar/chisel/pulls/733/comments","review_comment_url":"https://api.github.com/repos/ucb-bar/chisel/pulls/comments{/number}","comments_url":"https://api.github.com/repos/ucb-bar/chisel/issues/733/comments","statuses_url":"https://api.github.com/repos/ucb-bar/chisel/statuses/8b142ad22bfe7d6db1903098ca0d6a38cbf0c48a","head":{"label":"da-steve101:constVecInvalid","ref":"constVecInvalid","sha":"8b142ad22bfe7d6db1903098ca0d6a38cbf0c48a","user":{"login":"da-steve101","id":3221447,"avatar_url":"https://avatars.githubusercontent.com/u/3221447?v=3","gravatar_id":"","url":"https://api.github.com/users/da-steve101","html_url":"https://github.com/da-steve101","followers_url":"https://api.github.com/users/da-steve101/followers","following_url":"https://api.github.com/users/da-steve101/following{/other_user}","gists_url":"https://api.github.com/users/da-steve101/gists{/gist_id}","starred_url":"https://api.github.com/users/da-steve101/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/da-steve101/subscriptions","organizations_url":"https://api.github.com/users/da-steve101/orgs","repos_url":"https://api.github.com/users/da-steve101/repos","events_url":"https://api.github.com/users/da-steve101/events{/privacy}","received_events_url":"https://api.github.com/users/da-steve101/received_events","type":"User","site_admin":false},"repo":{"id":37750896,"name":"chisel","full_name":"da-steve101/chisel","owner":{"login":"da-steve101","id":3221447,"avatar_url":"https://avatars.githubusercontent.com/u/3221447?v=3","gravatar_id":"","url":"https://api.github.com/users/da-steve101","html_url":"https://github.com/da-steve101","followers_url":"https://api.github.com/users/da-steve101/followers","following_url":"https://api.github.com/users/da-steve101/following{/other_user}","gists_url":"https://api.github.com/users/da-steve101/gists{/gist_id}","starred_url":"https://api.github.com/users/da-steve101/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/da-steve101/subscriptions","organizations_url":"https://api.github.com/users/da-steve101/orgs","repos_url":"https://api.github.com/users/da-steve101/repos","events_url":"https://api.github.com/users/da-steve101/events{/privacy}","received_events_url":"https://api.github.com/users/da-steve101/received_events","type":"User","site_admin":false},"private":false,"html_url":"https://github.com/da-steve101/chisel","description":"","fork":true,"url":"https://api.github.com/repos/da-steve101/chisel","forks_url":"https://api.github.com/repos/da-steve101/chisel/forks","keys_url":"https://api.github.com/repos/da-steve101/chisel/keys{/key_id}","collaborators_url":"https://api.github.com/repos/da-steve101/chisel/collaborators{/collaborator}","teams_url":"https://api.github.com/repos/da-steve101/chisel/teams","hooks_url":"https://api.github.com/repos/da-steve101/chisel/hooks","issue_events_url":"https://api.github.com/repos/da-steve101/chisel/issues/events{/number}","events_url":"https://api.github.com/repos/da-steve101/chisel/events","assignees_url":"https://api.github.com/repos/da-steve101/chisel/assignees{/user}","branches_url":"https://api.github.com/repos/da-steve101/chisel/branches{/branch}","tags_url":"https://api.github.com/repos/da-steve101/chisel/tags","blobs_url":"https://api.github.com/repos/da-steve101/chisel/git/blobs{/sha}","git_tags_url":"https://api.github.com/repos/da-steve101/chisel/git/tags{/sha}","git_refs_url":"https://api.github.com/repos/da-steve101/chisel/git/refs{/sha}","trees_url":"https://api.github.com/repos/da-steve101/chisel/git/trees{/sha}","statuses_url":"https://api.github.com/repos/da-steve101/chisel/statuses/{sha}","languages_url":"https://api.github.com/repos/da-steve101/chisel/languages","stargazers_url":"https://api.github.com/repos/da-steve101/chisel/stargazers","contributors_url":"https://api.github.com/repos/da-steve101/chisel/contributors","subscribers_url":"https://api.github.com/repos/da-steve101/chisel/subscribers","subscription_url":"https://api.github.com/repos/da-steve101/chisel/subscription","commits_url":"https://api.github.com/repos/da-steve101/chisel/commits{/sha}","git_commits_url":"https://api.github.com/repos/da-steve101/chisel/git/commits{/sha}","comments_url":"https://api.github.com/repos/da-steve101/chisel/comments{/number}","issue_comment_url":"https://api.github.com/repos/da-steve101/chisel/issues/comments{/number}","contents_url":"https://api.github.com/repos/da-steve101/chisel/contents/{+path}","compare_url":"https://api.github.com/repos/da-steve101/chisel/compare/{base}...{head}","merges_url":"https://api.github.com/repos/da-steve101/chisel/merges","archive_url":"https://api.github.com/repos/da-steve101/chisel/{archive_format}{/ref}","downloads_url":"https://api.github.com/repos/da-steve101/chisel/downloads","issues_url":"https://api.github.com/repos/da-steve101/chisel/issues{/number}","pulls_url":"https://api.github.com/repos/da-steve101/chisel/pulls{/number}","milestones_url":"https://api.github.com/repos/da-steve101/chisel/milestones{/number}","notifications_url":"https://api.github.com/repos/da-steve101/chisel/notifications{?since,all,participating}","labels_url":"https://api.github.com/repos/da-steve101/chisel/labels{/name}","releases_url":"https://api.github.com/repos/da-steve101/chisel/releases{/id}","deployments_url":"https://api.github.com/repos/da-steve101/chisel/deployments","created_at":"2015-06-19T23:37:00Z","updated_at":"2016-01-15T07:59:31Z","pushed_at":"2016-09-14T06:26:04Z","git_url":"git://github.com/da-steve101/chisel.git","ssh_url":"git@github.com:da-steve101/chisel.git","clone_url":"https://github.com/da-steve101/chisel.git","svn_url":"https://github.com/da-steve101/chisel","homepage":"chisel.eecs.berkeley.edu","size":58499,"stargazers_count":1,"watchers_count":1,"language":"Scala","has_issues":false,"has_downloads":true,"has_wiki":true,"has_pages":false,"forks_count":0,"mirror_url":null,"open_issues_count":0,"forks":0,"open_issues":0,"watchers":1,"default_branch":"master"}},"base":{"label":"ucb-bar:master","ref":"master","sha":"217cfbb10d5578a4b14a262ed662ba4f341b032d","user":{"login":"ucb-bar","id":998197,"avatar_url":"https://avatars.githubusercontent.com/u/998197?v=3","gravatar_id":"","url":"https://api.github.com/users/ucb-bar","html_url":"https://github.com/ucb-bar","followers_url":"https://api.github.com/users/ucb-bar/followers","following_url":"https://api.github.com/users/ucb-bar/following{/other_user}","gists_url":"https://api.github.com/users/ucb-bar/gists{/gist_id}","starred_url":"https://api.github.com/users/ucb-bar/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/ucb-bar/subscriptions","organizations_url":"https://api.github.com/users/ucb-bar/orgs","repos_url":"https://api.github.com/users/ucb-bar/repos","events_url":"https://api.github.com/users/ucb-bar/events{/privacy}","received_events_url":"https://api.github.com/users/ucb-bar/received_events","type":"Organization","site_admin":false},"repo":{"id":3392244,"name":"chisel","full_name":"ucb-bar/chisel","owner":{"login":"ucb-bar","id":998197,"avatar_url":"https://avatars.githubusercontent.com/u/998197?v=3","gravatar_id":"","url":"https://api.github.com/users/ucb-bar","html_url":"https://github.com/ucb-bar","followers_url":"https://api.github.com/users/ucb-bar/followers","following_url":"https://api.github.com/users/ucb-bar/following{/other_user}","gists_url":"https://api.github.com/users/ucb-bar/gists{/gist_id}","starred_url":"https://api.github.com/users/ucb-bar/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/ucb-bar/subscriptions","organizations_url":"https://api.github.com/users/ucb-bar/orgs","repos_url":"https://api.github.com/users/ucb-bar/repos","events_url":"https://api.github.com/users/ucb-bar/events{/privacy}","received_events_url":"https://api.github.com/users/ucb-bar/received_events","type":"Organization","site_admin":false},"private":false,"html_url":"https://github.com/ucb-bar/chisel","description":"","fork":false,"url":"https://api.github.com/repos/ucb-bar/chisel","forks_url":"https://api.github.com/repos/ucb-bar/chisel/forks","keys_url":"https://api.github.com/repos/ucb-bar/chisel/keys{/key_id}","collaborators_url":"https://api.github.com/repos/ucb-bar/chisel/collaborators{/collaborator}","teams_url":"https://api.github.com/repos/ucb-bar/chisel/teams","hooks_url":"https://api.github.com/repos/ucb-bar/chisel/hooks","issue_events_url":"https://api.github.com/repos/ucb-bar/chisel/issues/events{/number}","events_url":"https://api.github.com/repos/ucb-bar/chisel/events","assignees_url":"https://api.github.com/repos/ucb-bar/chisel/assignees{/user}","branches_url":"https://api.github.com/repos/ucb-bar/chisel/branches{/branch}","tags_url":"https://api.github.com/repos/ucb-bar/chisel/tags","blobs_url":"https://api.github.com/repos/ucb-bar/chisel/git/blobs{/sha}","git_tags_url":"https://api.github.com/repos/ucb-bar/chisel/git/tags{/sha}","git_refs_url":"https://api.github.com/repos/ucb-bar/chisel/git/refs{/sha}","trees_url":"https://api.github.com/repos/ucb-bar/chisel/git/trees{/sha}","statuses_url":"https://api.github.com/repos/ucb-bar/chisel/statuses/{sha}","languages_url":"https://api.github.com/repos/ucb-bar/chisel/languages","stargazers_url":"https://api.github.com/repos/ucb-bar/chisel/stargazers","contributors_url":"https://api.github.com/repos/ucb-bar/chisel/contributors","subscribers_url":"https://api.github.com/repos/ucb-bar/chisel/subscribers","subscription_url":"https://api.github.com/repos/ucb-bar/chisel/subscription","commits_url":"https://api.github.com/repos/ucb-bar/chisel/commits{/sha}","git_commits_url":"https://api.github.com/repos/ucb-bar/chisel/git/commits{/sha}","comments_url":"https://api.github.com/repos/ucb-bar/chisel/comments{/number}","issue_comment_url":"https://api.github.com/repos/ucb-bar/chisel/issues/comments{/number}","contents_url":"https://api.github.com/repos/ucb-bar/chisel/contents/{+path}","compare_url":"https://api.github.com/repos/ucb-bar/chisel/compare/{base}...{head}","merges_url":"https://api.github.com/repos/ucb-bar/chisel/merges","archive_url":"https://api.github.com/repos/ucb-bar/chisel/{archive_format}{/ref}","downloads_url":"https://api.github.com/repos/ucb-bar/chisel/downloads","issues_url":"https://api.github.com/repos/ucb-bar/chisel/issues{/number}","pulls_url":"https://api.github.com/repos/ucb-bar/chisel/pulls{/number}","milestones_url":"https://api.github.com/repos/ucb-bar/chisel/milestones{/number}","notifications_url":"https://api.github.com/repos/ucb-bar/chisel/notifications{?since,all,participating}","labels_url":"https://api.github.com/repos/ucb-bar/chisel/labels{/name}","releases_url":"https://api.github.com/repos/ucb-bar/chisel/releases{/id}","deployments_url":"https://api.github.com/repos/ucb-bar/chisel/deployments","created_at":"2012-02-08T22:47:57Z","updated_at":"2016-09-14T05:25:04Z","pushed_at":"2016-09-14T06:27:46Z","git_url":"git://github.com/ucb-bar/chisel.git","ssh_url":"git@github.com:ucb-bar/chisel.git","clone_url":"https://github.com/ucb-bar/chisel.git","svn_url":"https://github.com/ucb-bar/chisel","homepage":"chisel.eecs.berkeley.edu","size":62279,"stargazers_count":361,"watchers_count":361,"language":"Scala","has_issues":true,"has_downloads":true,"has_wiki":true,"has_pages":false,"forks_count":94,"mirror_url":null,"open_issues_count":124,"forks":94,"open_issues":124,"watchers":361,"default_branch":"master"}},"_links":{"self":{"href":"https://api.github.com/repos/ucb-bar/chisel/pulls/733"},"html":{"href":"https://github.com/ucb-bar/chisel/pull/733"},"issue":{"href":"https://api.github.com/repos/ucb-bar/chisel/issues/733"},"comments":{"href":"https://api.github.com/repos/ucb-bar/chisel/issues/733/comments"},"review_comments":{"href":"https://api.github.com/repos/ucb-bar/chisel/pulls/733/comments"},"review_comment":{"href":"https://api.github.com/repos/ucb-bar/chisel/pulls/comments{/number}"},"commits":{"href":"https://api.github.com/repos/ucb-bar/chisel/pulls/733/commits"},"statuses":{"href":"https://api.github.com/repos/ucb-bar/chisel/statuses/8b142ad22bfe7d6db1903098ca0d6a38cbf0c48a"}},"merged":false,"mergeable":null,"mergeable_state":"unknown","merged_by":null,"comments":0,"review_comments":0,"commits":1,"additions":62,"deletions":2,"changed_files":3}}
{"actor":{"display_login":"da-steve101"}}