commit | 602650c98822371d4a34b00353ec71051621b7fb | [log] [tgz] |
---|---|---|
author | Chandler Carruth <chandlerc@gmail.com> | Mon Oct 17 01:11:57 2011 +0000 |
committer | Chandler Carruth <chandlerc@gmail.com> | Mon Oct 17 01:11:57 2011 +0000 |
tree | d6b4d7c82ce7ba5d787d6f22a6c5c2b339793663 | |
parent | 1416dc29d8573e58c8b2d7fe0715f3e289d03ab8 [diff] |
Add a routine to swap branch instruction operands, and update any profile metadata at the same time. Use it to preserve metadata attached to a branch when re-writing it in InstCombine. Add metadata to the canonicalize_branch InstCombine test, and check that it is tranformed correctly. Reviewed by Nick Lewycky! git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@142168 91177308-0d34-0410-b5e6-96231b3b80d8