llvm-project/llvm/lib/Transforms
Xin Tong 42ef2177af [SCCP] Remove manual folding of terminator instructions.
Summary:
BranchInst, SwitchInst (with non-default case) with Undef as input is not
possible at this point. As we always default-fold terminator to one target in
ResolvedUndefsIn and set the input accordingly.

So we should only have constantint/blockaddress here.

If ConstantFoldTerminator fails, that could mean 2 things.

1. ConstantFoldTerminator is doing something unexpected, i.e. not folding on constantint
or blockaddress and not making blocks that should be dead dead.
2. This is not a terminator on constantint or blockaddress. Its on a constant or
overdefined, then this block should not be dead.

In both cases, we should assert.

Reviewers: davide, efriedma, sanjoy

Subscribers: llvm-commits

Differential Revision: https://reviews.llvm.org/D30381

llvm-svn: 296281
2017-02-26 02:11:24 +00:00
..
Coroutines [Coroutines] Add header guard to header that's missing one. 2017-01-30 16:32:20 +00:00
Hello Add auto-exporting of symbols from tools so that plugins work on Windows 2016-05-26 11:16:43 +00:00
IPO [OptDiag] Hide legacy remark ctors 2017-02-23 23:11:11 +00:00
InstCombine [InstCombine] Fix bug in pointer replacement 2017-02-24 20:27:25 +00:00
Instrumentation [msan] Fix instrumentation of array allocas. 2017-02-24 00:13:17 +00:00
ObjCARC Remove redundant code. NFC. 2017-02-25 00:59:49 +00:00
Scalar [SCCP] Remove manual folding of terminator instructions. 2017-02-26 02:11:24 +00:00
Utils PredicateInfo: Support switch statements 2017-02-22 22:20:58 +00:00
Vectorize [LV] Merge floating-point and integer induction widening code 2017-02-24 18:20:12 +00:00
CMakeLists.txt [coroutines] Part 3 of N: Adding Boilerplate for Coroutine Passes 2016-07-28 21:04:31 +00:00
LLVMBuild.txt [coroutines] Part 3 of N: Adding Boilerplate for Coroutine Passes 2016-07-28 21:04:31 +00:00