llvm-6502/lib
Philip Reames 64b906419e Teach InlineCost to account for a null check which can be folded away
If we have a caller that knows a particular argument can never be null, we can exploit this fact while simplifying values in the inline cost analysis. This has the effect of reducing the cost for inlining when a null check is present in the callee, but the value is known non null in the caller. In particular, any dependent control flow can be discounted from the cost estimate.

Note that we use the parameter attributes at the call site to memoize the analysis within the caller's code.  The setting of this attribute is done in InstCombine, the inline cost analysis just consumes it.  This is intentional and important because we want the inline cost analysis results to be easily cachable themselves.  We're not currently doing so, but initial results on LTO indicate this will quickly become important.

Differential Revision: http://reviews.llvm.org/D9129



git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@240828 91177308-0d34-0410-b5e6-96231b3b80d8
2015-06-26 20:51:17 +00:00
..
Analysis Teach InlineCost to account for a null check which can be folded away 2015-06-26 20:51:17 +00:00
AsmParser ADT: Add a string APSInt constructor. 2015-06-23 18:22:10 +00:00
Bitcode Use foreach loop over constant operands. NFC. 2015-06-25 20:51:38 +00:00
CodeGen Convert a bunch of loops to foreach. NFC. 2015-06-26 19:37:02 +00:00
DebugInfo Revert r240137 (Fixed/added namespace ending comments using clang-tidy. NFC) 2015-06-23 09:49:53 +00:00
ExecutionEngine Expose getFlags via ELFSectionRef. 2015-06-26 12:44:10 +00:00
Fuzzer
IR Devirtualize Instruction::clone_impl 2015-06-24 20:22:23 +00:00
IRReader
LibDriver Revert r240137 (Fixed/added namespace ending comments using clang-tidy. NFC) 2015-06-23 09:49:53 +00:00
LineEditor
Linker Revert r240137 (Fixed/added namespace ending comments using clang-tidy. NFC) 2015-06-23 09:49:53 +00:00
LTO Simplify the Mangler interface now that DataLayout is mandatory. 2015-06-23 13:59:29 +00:00
MC IAS: Use the root macro instanciation for location 2015-06-25 21:57:33 +00:00
Object Simplify getSymbolType. 2015-06-26 12:18:49 +00:00
Option [Option] Plug a leak when move-assigning an InputArgList. 2015-06-23 15:28:10 +00:00
Passes
ProfileData Revert r240137 (Fixed/added namespace ending comments using clang-tidy. NFC) 2015-06-23 09:49:53 +00:00
Support ADT: Add a string APSInt constructor. 2015-06-23 18:22:10 +00:00
TableGen [TableGen] Restore the use of the TheInit field in Record to cache the Record's DefInit. I broke this when I fixed memory leaks recently. Remove the DenseMap that mapped Record's to DefInit. 2015-06-24 06:19:19 +00:00
Target AMDGPU: really don't commute REV opcodes if the target variant doesn't exist 2015-06-26 20:29:10 +00:00
Transforms Move VectorUtils from Transforms to Analysis to correct layering violation 2015-06-26 18:02:52 +00:00
CMakeLists.txt
LLVMBuild.txt
Makefile LibDriver, llvm-lib: introduce. 2015-06-09 21:50:22 +00:00