summaryrefslogtreecommitdiffstats
path: root/clang/lib/Sema
diff options
context:
space:
mode:
authorDan Gohman <gohman@apple.com>2009-06-27 21:30:38 +0000
committerDan Gohman <gohman@apple.com>2009-06-27 21:30:38 +0000
commitc8ca49659ac479b5be0349528d42179f40fc553b (patch)
treed2b4977eceb634483498ec06414fac689972c2c7 /clang/lib/Sema
parent8918b481bfdb79a5bd354e9cb38577e3fb55f104 (diff)
downloadbcm5719-llvm-c8ca49659ac479b5be0349528d42179f40fc553b.tar.gz
bcm5719-llvm-c8ca49659ac479b5be0349528d42179f40fc553b.zip
Teach LoopSimplify how to merge multiple loop exits into a single exit,
when one of them can be converted to a trivial icmp and conditional branch. This addresses what is essentially a phase ordering problem. SimplifyCFG knows how to do this transformation, but it doesn't do so if the primary block has any instructions in it other than an icmp and a branch. In the given testcase, the block contains other instructions, however they are loop-invariant and can be hoisted. SimplifyCFG doesn't have LoopInfo though, so it can't hoist them. And, it's important that the blocks be merged before LoopRotation, as it doesn't support multiple-exit loops. llvm-svn: 74396
Diffstat (limited to 'clang/lib/Sema')
0 files changed, 0 insertions, 0 deletions
OpenPOWER on IntegriCloud