1
0
mirror of https://github.com/RPCS3/llvm-mirror.git synced 2024-10-27 22:12:47 +01:00
llvm-mirror/lib
Arnaud A. de Grandmaison fdfed29d10 Fix tail recursion elimination
When the BasicBlock containing the return instrution has a PHI with 2
incoming values, FoldReturnIntoUncondBranch will remove the no longer
used incoming value and remove the no longer needed phi as well. This
leaves us with a BB that no longer has a PHI, but the subsequent call
to FoldReturnIntoUncondBranch from FoldReturnAndProcessPred will not
remove the return instruction (which still uses the result of the call
instruction). This prevents EliminateRecursiveTailCall to remove
the value, as it is still being used in a basicblock which has no
predecessors.

The basicblock can not be erased on the spot, because its iterator is
still being used in runTRE.

This issue was exposed when removing the threshold on size for lifetime
marker insertion for named temporaries in clang. The testcase is a much
reduced version of peelOffOuterExpr(const Expr*, const ExplodedNode *)
from clang/lib/StaticAnalyzer/Core/BugReporterVisitors.cpp.

llvm-svn: 222354
2014-11-19 13:32:51 +00:00
..
Analysis AliasSetTracker: UnknownInsts should contribute to the refcount 2014-11-19 09:41:05 +00:00
AsmParser Update SetVector to rely on the underlying set's insert to return a pair<iterator, bool> 2014-11-19 07:49:26 +00:00
Bitcode Pass a reference to ValueEnumerator. 2014-11-17 20:06:27 +00:00
CodeGen [X86][SSE] pslldq/psrldq byte shifts/rotation for SSE2 2014-11-19 10:06:49 +00:00
DebugInfo [dwarfdump] Handle relocations in Dwarf accelerator tables 2014-11-14 19:30:08 +00:00
ExecutionEngine Fix covered switch warning 2014-11-18 01:26:46 +00:00
IR Update SetVector to rely on the underlying set's insert to return a pair<iterator, bool> 2014-11-19 07:49:26 +00:00
IRReader Remove unused variable. NFC. 2014-11-06 23:16:57 +00:00
LineEditor
Linker Update SetVector to rely on the underlying set's insert to return a pair<iterator, bool> 2014-11-19 07:49:26 +00:00
LTO Remove StringMap::GetOrCreateValue in favor of StringMap::insert 2014-11-19 05:49:42 +00:00
MC Remove StringMap::GetOrCreateValue in favor of StringMap::insert 2014-11-19 05:49:42 +00:00
Object llvm-readobj: fix off-by-one error in COFFDumper 2014-11-19 02:07:10 +00:00
Option Add an overload of getLastArgNoClaim taking two OptSpecifiers. 2014-09-12 19:42:53 +00:00
ProfileData llvm-cov: Sink some reporting logic into CoverageMapping 2014-11-14 01:50:32 +00:00
Support Update SetVector to rely on the underlying set's insert to return a pair<iterator, bool> 2014-11-19 07:49:26 +00:00
TableGen Eliminate some deep std::vector copies. NFC. 2014-10-03 18:33:16 +00:00
Target [mips][microMIPS] Implement CodeGen support for 16-bit instruction ADDIUR2. 2014-11-19 13:23:58 +00:00
Transforms Fix tail recursion elimination 2014-11-19 13:32:51 +00:00
CMakeLists.txt
LLVMBuild.txt
Makefile