1
0
mirror of https://github.com/RPCS3/llvm-mirror.git synced 2024-11-25 04:02:41 +01:00
llvm-mirror/lib/Transforms/Utils
Benjamin Kramer dc1c57af91 SimplifyCFG: If we have a PHI node that can evaluate to NULL and do a load or store to the address returned by the PHI node then we can consider this incoming value as dead and remove the edge pointing there, unless there are instructions that can affect control flow executed in between.
In theory this could be extended to other instructions, eg. division by zero, but it's likely that it will "miscompile" some code because people depend on div by zero not trapping. NULL pointer dereference usually leads to a crash so we should be on the safe side.

This shrinks the size of a Release clang by 16k on x86_64.

llvm-svn: 138618
2011-08-26 01:22:29 +00:00
..
AddrModeMatcher.cpp land David Blaikie's patch to de-constify Type, with a few tweaks. 2011-07-18 04:54:35 +00:00
BasicBlockUtils.cpp Fix a crashing bug in SplitBlock when it is called on a block with no 2011-08-24 18:07:01 +00:00
BasicInliner.cpp
BreakCriticalEdges.cpp Assert that we aren't trying to split the critical edge of a landing pad. Doing 2011-08-17 21:04:05 +00:00
BuildLibCalls.cpp land David Blaikie's patch to de-constify Type, with a few tweaks. 2011-07-18 04:54:35 +00:00
CloneFunction.cpp Use ArrayRef in ConstantFoldInstOperands and ConstantFoldCall. 2011-07-19 13:32:40 +00:00
CloneModule.cpp Fix llvm::CloneModule to correctly clone globals. Patch per bug report by Simon Moll on llvmdev. 2011-08-15 21:05:06 +00:00
CMakeLists.txt Update CMake build. 2011-08-10 03:51:58 +00:00
CodeExtractor.cpp Convert GetElementPtrInst to use ArrayRef. 2011-07-25 09:48:08 +00:00
DemoteRegToStack.cpp
InlineFunction.cpp Add inlining for the new EH scheme. 2011-08-14 08:01:36 +00:00
InstructionNamer.cpp
LCSSA.cpp There is no need to force DebugLoc on a PHI at this point. 2011-05-16 22:05:03 +00:00
Local.cpp The "landingpad" instruction will never be "trivially" dead. 2011-08-15 20:10:51 +00:00
LoopSimplify.cpp Intelligently split the landing pad block. 2011-08-19 00:09:22 +00:00
LoopUnroll.cpp Comments. Thanks for the spell check Nick! 2011-08-10 18:07:05 +00:00
LowerExpectIntrinsic.cpp land David Blaikie's patch to de-constify Type, with a few tweaks. 2011-07-18 04:54:35 +00:00
LowerInvoke.cpp When inserting new instructions, use getFirstInsertionPt instead of 2011-08-25 01:08:34 +00:00
LowerSwitch.cpp Fix a ton of comment typos found by codespell. Patch by 2011-04-15 05:18:47 +00:00
Makefile
Mem2Reg.cpp
PromoteMemoryToRegister.cpp Add comments and test for atomic load/store and mem2reg. 2011-08-15 23:55:52 +00:00
SimplifyCFG.cpp SimplifyCFG: If we have a PHI node that can evaluate to NULL and do a load or store to the address returned by the PHI node then we can consider this incoming value as dead and remove the edge pointing there, unless there are instructions that can affect control flow executed in between. 2011-08-26 01:22:29 +00:00
SimplifyIndVar.cpp Comments. Thanks for the spell check Nick! 2011-08-10 18:07:05 +00:00
SimplifyInstructions.cpp
SSAUpdater.cpp land David Blaikie's patch to de-constify Type, with a few tweaks. 2011-07-18 04:54:35 +00:00
UnifyFunctionExitNodes.cpp Remove PHINode::reserveOperandSpace(). Instead, add a parameter to 2011-03-30 11:28:46 +00:00
Utils.cpp
ValueMapper.cpp We need to map DebugLoc. It leads to Fuction * (through subprogram entry node) which should be appropriately mapped. 2011-08-04 20:02:18 +00:00