summaryrefslogtreecommitdiffstats
path: root/clang/lib/CodeGen/CGCall.cpp
diff options
context:
space:
mode:
authorSanjay Patel <spatel@rotateright.com>2016-12-12 16:13:52 +0000
committerSanjay Patel <spatel@rotateright.com>2016-12-12 16:13:52 +0000
commite730ce87a50c1fbfc1a6a0828e472b0b2f67beab (patch)
tree4dfe3733aef71cb7b8d95cb494855856d1d66e73 /clang/lib/CodeGen/CGCall.cpp
parent040cc168355ab839053710f35fb039b4391ec5ec (diff)
downloadbcm5719-llvm-e730ce87a50c1fbfc1a6a0828e472b0b2f67beab.tar.gz
bcm5719-llvm-e730ce87a50c1fbfc1a6a0828e472b0b2f67beab.zip
[InstCombine] fix bug when offsetting case values of a switch (PR31260)
We could truncate the condition and then try to fold the add into the original condition value causing wrong case constants to be used. Move the offset transform ahead of the truncate transform and return after each transform, so there's no chance of getting confused values. Fix for: https://llvm.org/bugs/show_bug.cgi?id=31260 llvm-svn: 289442
Diffstat (limited to 'clang/lib/CodeGen/CGCall.cpp')
0 files changed, 0 insertions, 0 deletions
OpenPOWER on IntegriCloud