llvm-6502/include/llvm
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
..
ADT Remove copy ctors that did the same thing as the default one. 2014-03-11 11:32:49 +00:00
Analysis Remove copy ctors that did the same thing as the default one. 2014-03-11 11:32:49 +00:00
AsmParser Move the LLVM IR asm writer header files into the IR directory, as they 2014-01-07 12:34:26 +00:00
Bitcode Replace OwningPtr<T> with std::unique_ptr<T>. 2014-03-06 05:51:42 +00:00
CodeGen Replace '#include ValueTypes.h' with forward declarations. 2014-03-12 08:00:24 +00:00
Config Add patch level to llvm version in CMake and Autoconf 2014-03-03 15:22:00 +00:00
DebugInfo Revert "Clean up SmallString a bit" 2014-03-09 06:22:58 +00:00
ExecutionEngine [C++11] Add 'override' keyword to virtual methods that override their base class. 2014-03-08 07:51:20 +00:00
IR Remove copy ctors that did the same thing as the default one. 2014-03-11 11:32:49 +00:00
IRReader Split out the IRReader header and the utility functions it provides into 2013-03-26 02:25:37 +00:00
LineEditor Replace OwningPtr<T> with std::unique_ptr<T>. 2014-03-06 05:51:42 +00:00
Linker [Layering] Sink Linker.h into a Linker subdirectory to make it 2014-03-06 03:42:23 +00:00
LTO Replace OwningPtr<T> with std::unique_ptr<T>. 2014-03-06 05:51:42 +00:00
MC Simplify a really complicated check for Arch == X86_64. 2014-03-11 21:22:57 +00:00
Object Remove copy ctors that did the same thing as the default one. 2014-03-11 11:32:49 +00:00
Option [C++11] Add 'override' keyword to virtual methods that override their base class. 2014-03-05 07:52:44 +00:00
Support support: add a utility function to normalise path separators 2014-03-11 22:05:42 +00:00
TableGen [C++11] Add 'override' keywords to tablegen code. 2014-03-05 05:17:42 +00:00
Target Replace '#include ValueTypes.h' with forward declarations. 2014-03-12 08:00:24 +00:00
Transforms Move duplicated code into a helper function (exposed through overload). 2014-03-12 16:12:36 +00:00
CMakeLists.txt The llvm_headers_do_not_build project needs to be excluded from the default build, otherwise it gets built (at least in Visual Studio 2013). 2014-01-28 16:07:10 +00:00
InitializePasses.h Pass to emit DWARF path discriminators. 2014-03-03 20:06:11 +00:00
LinkAllIR.h [cleanup] Move the Dominators.h and Verifier.h headers into the IR 2014-01-13 09:26:24 +00:00
LinkAllPasses.h Revert "Revert "Add Constant Hoisting Pass" (r200034)" 2014-01-25 02:02:55 +00:00
Pass.h [C++11] Add 'override' keyword to IR library. 2014-03-05 06:35:38 +00:00
PassAnalysisSupport.h Fix include guards so they exactly match file names. 2013-01-10 00:45:19 +00:00
PassManager.h Move the old pass manager infrastructure into a legacy namespace and 2013-11-09 12:26:54 +00:00
PassRegistry.h Re-sort all of the includes with ./utils/sort_includes.py so that 2014-01-07 11:48:04 +00:00
PassSupport.h Revert "[C++11] Replace LLVM atomics with std::atomic." 2014-03-03 18:02:34 +00:00