aboutsummaryrefslogtreecommitdiff
path: root/clang/lib/Frontend/CompilerInvocation.cpp
diff options
context:
space:
mode:
authorChandler Carruth <chandlerc@gmail.com>2014-09-01 10:09:18 +0000
committerChandler Carruth <chandlerc@gmail.com>2014-09-01 10:09:18 +0000
commit18cee1defcc67c3379e613352a87bb2b33ae3d89 (patch)
treec238fc643363f456d398004287b603a5d23e7689 /clang/lib/Frontend/CompilerInvocation.cpp
parent86a6c3f2694fa9e68af00e72a40a653a491d19da (diff)
downloadllvm-18cee1defcc67c3379e613352a87bb2b33ae3d89.zip
llvm-18cee1defcc67c3379e613352a87bb2b33ae3d89.tar.gz
llvm-18cee1defcc67c3379e613352a87bb2b33ae3d89.tar.bz2
Fix a really bad miscompile introduced in r216865 - the else-if logic
chain became completely broken here as *all* intrinsic users ended up being skipped, and the ones that seemed to be singled out were actually the exact wrong set. This is a great example of why long else-if chains can be easily confusing. Switch the entire code to use early exits and early continues to have simpler (and more importantly, correct) logic here, as well as fixing the reversed logic for detecting and continuing on lifetime intrinsics. I've also significantly cleaned up the test case and added another test case demonstrating an example where the optimization is not (trivially) safe to perform. llvm-svn: 216871
Diffstat (limited to 'clang/lib/Frontend/CompilerInvocation.cpp')
0 files changed, 0 insertions, 0 deletions