aboutsummaryrefslogtreecommitdiff
path: root/lib/Support/Unix/Unix.h
diff options
context:
space:
mode:
authorHans Wennborg <hans@hanshq.net>2012-10-31 13:42:45 +0000
committerHans Wennborg <hans@hanshq.net>2012-10-31 13:42:45 +0000
commite03d9e4ec7037526b94ce91985e7ff82ebc069fa (patch)
tree9ea5f59b7ef92e8909ae6e2aedab077cc1bee2f8 /lib/Support/Unix/Unix.h
parente803d05bd87d1181c971fb719fef5638dd44ce99 (diff)
Do simple constant propagation in lookup table formation for switches
By propagating the value for the switch condition, LLVM can now build lookup tables for code such as: switch (x) { case 1: return 5; case 2: return 42; case 3: case 4: case 5: return x - 123; default: return 123; } Given that x is known for each case, "x - 123" becomes a constant for cases 3, 4, and 5. git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@167115 91177308-0d34-0410-b5e6-96231b3b80d8
Diffstat (limited to 'lib/Support/Unix/Unix.h')
0 files changed, 0 insertions, 0 deletions