{"action":"created","issue":{"url":"https://api.github.com/repos/sbbm/llvm/issues/3","labels_url":"https://api.github.com/repos/sbbm/llvm/issues/3/labels{/name}","comments_url":"https://api.github.com/repos/sbbm/llvm/issues/3/comments","events_url":"https://api.github.com/repos/sbbm/llvm/issues/3/events","html_url":"https://github.com/sbbm/llvm/issues/3","id":81697459,"number":3,"title":"Improve predication","user":{"login":"chris-chambers","id":6810256,"avatar_url":"https://avatars.githubusercontent.com/u/6810256?v=3","gravatar_id":"","url":"https://api.github.com/users/chris-chambers","html_url":"https://github.com/chris-chambers","followers_url":"https://api.github.com/users/chris-chambers/followers","following_url":"https://api.github.com/users/chris-chambers/following{/other_user}","gists_url":"https://api.github.com/users/chris-chambers/gists{/gist_id}","starred_url":"https://api.github.com/users/chris-chambers/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/chris-chambers/subscriptions","organizations_url":"https://api.github.com/users/chris-chambers/orgs","repos_url":"https://api.github.com/users/chris-chambers/repos","events_url":"https://api.github.com/users/chris-chambers/events{/privacy}","received_events_url":"https://api.github.com/users/chris-chambers/received_events","type":"User","site_admin":false},"labels":[{"url":"https://api.github.com/repos/sbbm/llvm/labels/enhancement","name":"enhancement","color":"84b6eb"}],"state":"open","locked":false,"assignee":null,"milestone":null,"comments":1,"created_at":"2015-05-28T01:04:16Z","updated_at":"2015-05-29T03:05:49Z","closed_at":null,"body":"The `IfConverter` pass that is built in to LLVM is unable to take full advantage of the essentially-unbounded predication available in SBBM.  Currently the most predication that ever really occurs as a result of if conversion is a single level.  And then the presence of that level causes the if converter to ignore all further optimization possibilities.  An improved pass should be developed that will take advantage of predicate nesting.\r\n\r\nNotes:\r\n- Predication occurs after register allocation, which means the cleanness of virtual registers has been lost.  The nesting will need to either be recovered at this stage, or preserved from an earlier stage.\r\n- LLVM's register scheduling may or may not be fully aware of predicate registers.  The current code sidesteps any potential clobbering, but a real solution may be needed.\r\n- It would also be a very good idea to support, at least, the predication of trivial loops.  Complex ones may be difficult to deal with, but at least `while true` or `while $boolean` ought to be achievable."},"comment":{"url":"https://api.github.com/repos/sbbm/llvm/issues/comments/106668153","html_url":"https://github.com/sbbm/llvm/issues/3#issuecomment-106668153","issue_url":"https://api.github.com/repos/sbbm/llvm/issues/3","id":106668153,"user":{"login":"chris-chambers","id":6810256,"avatar_url":"https://avatars.githubusercontent.com/u/6810256?v=3","gravatar_id":"","url":"https://api.github.com/users/chris-chambers","html_url":"https://github.com/chris-chambers","followers_url":"https://api.github.com/users/chris-chambers/followers","following_url":"https://api.github.com/users/chris-chambers/following{/other_user}","gists_url":"https://api.github.com/users/chris-chambers/gists{/gist_id}","starred_url":"https://api.github.com/users/chris-chambers/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/chris-chambers/subscriptions","organizations_url":"https://api.github.com/users/chris-chambers/orgs","repos_url":"https://api.github.com/users/chris-chambers/repos","events_url":"https://api.github.com/users/chris-chambers/events{/privacy}","received_events_url":"https://api.github.com/users/chris-chambers/received_events","type":"User","site_admin":false},"created_at":"2015-05-29T03:05:49Z","updated_at":"2015-05-29T03:05:49Z","body":"Waiting on #6."}}