llvm-6502/lib
Eli Bendersky ce306f9f99 Move duplicated code into a helper function (exposed through overload).
There's a bit of duplicated "magic" code in opt.cpp and Clang's CodeGen that
computes the inliner threshold from opt level and size opt level.

This patch moves the code to a function that lives alongside the inliner itself,
providing a convenient overload to the inliner creation.

A separate patch can be committed to Clang to use this once it's committed to
LLVM. Standalone tools that use the inlining pass can also avoid duplicating
this code and fearing it will go out of sync.

Note: this patch also restructures the conditinal logic of the computation to
be cleaner.



git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@203669 91177308-0d34-0410-b5e6-96231b3b80d8
2014-03-12 16:12:36 +00:00
..
Analysis IR: add a second ordering operand to cmpxhg for failure 2014-03-11 10:48:52 +00:00
AsmParser IR: add a second ordering operand to cmpxhg for failure 2014-03-11 10:48:52 +00:00
Bitcode IR: add a second ordering operand to cmpxhg for failure 2014-03-11 10:48:52 +00:00
CodeGen Replace '#include ValueTypes.h' with forward declarations. 2014-03-12 08:00:24 +00:00
DebugInfo Replace OwningPtr<T> with std::unique_ptr<T>. 2014-03-06 05:51:42 +00:00
ExecutionEngine [ppc64] Patch in TOC restore code after all external function calls 2014-03-11 15:26:27 +00:00
IR Remove copy ctors that did the same thing as the default one. 2014-03-11 11:32:49 +00:00
IRReader Replace OwningPtr<T> with std::unique_ptr<T>. 2014-03-06 05:51:42 +00:00
LineEditor [CMake] Use LINK_LIBS instead of target_link_libraries(). 2014-02-26 06:41:29 +00:00
Linker [Layering] Sink Linker.h into a Linker subdirectory to make it 2014-03-06 03:42:23 +00:00
LTO [C++11] Add 'override' keyword to virtual methods that override their base class. 2014-03-08 07:51:20 +00:00
MC Simplify a really complicated check for Arch == X86_64. 2014-03-11 21:22:57 +00:00
Object Object: rename ARMV7 to ARMNT 2014-03-11 03:08:37 +00:00
Option Avoid buffer copies when a Twine already is a StringRef. 2013-12-03 18:18:28 +00:00
Support support: add a utility function to normalise path separators 2014-03-11 22:05:42 +00:00
TableGen Replace OwningPtr<T> with std::unique_ptr<T>. 2014-03-06 05:51:42 +00:00
Target Update the datalayout string for ppc64LE. 2014-03-12 14:59:17 +00:00
Transforms Move duplicated code into a helper function (exposed through overload). 2014-03-12 16:12:36 +00:00
CMakeLists.txt Introduce line editor library. 2014-01-31 23:46:14 +00:00
LLVMBuild.txt Introduce line editor library. 2014-01-31 23:46:14 +00:00
Makefile Introduce line editor library. 2014-01-31 23:46:14 +00:00