llvm-6502/include/llvm
Victor Hernandez 9d0b704e3e Re-commit r86077 now that r86290 fixes the 179.art and 175.vpr ARM regressions.
Here is the original commit message:

This commit updates malloc optimizations to operate on malloc calls that have constant int size arguments.

Update CreateMalloc so that its callers specify the size to allocate:
MallocInst-autoupgrade users use non-TargetData-computed allocation sizes.
Optimization uses use TargetData to compute the allocation size.

Now that malloc calls can have constant sizes, update isArrayMallocHelper() to use TargetData to determine the size of the malloced type and the size of malloced arrays.
Extend getMallocType() to support malloc calls that have non-bitcast uses.

Update OptimizeGlobalAddressOfMalloc() to optimize malloc calls that have non-bitcast uses.  The bitcast use of a malloc call has to be treated specially here because the uses of the bitcast need to be replaced and the bitcast needs to be erased (just like the malloc call) for OptimizeGlobalAddressOfMalloc() to work correctly.

Update PerformHeapAllocSRoA() to optimize malloc calls that have non-bitcast uses.  The bitcast use of the malloc is not handled specially here because ReplaceUsesOfMallocWithGlobal replaces through the bitcast use.

Update OptimizeOnceStoredGlobal() to not care about the malloc calls' bitcast use.

Update all globalopt malloc tests to not rely on autoupgraded-MallocInsts, but instead use explicit malloc calls with correct allocation sizes.



git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@86311 91177308-0d34-0410-b5e6-96231b3b80d8
2009-11-07 00:16:28 +00:00
..
ADT Pass StringRef by value. 2009-11-06 10:58:06 +00:00
Analysis Re-commit r86077 now that r86290 fixes the 179.art and 175.vpr ARM regressions. 2009-11-07 00:16:28 +00:00
Assembly Use MemoryBuffer::getBufferIdentifier() in the AsmPrinter instead 2009-09-08 22:20:35 +00:00
Bitcode Pass StringRef by value. 2009-11-06 10:58:06 +00:00
CodeGen Make printImplicitDef and printKill non-virtual, since they don't 2009-11-06 00:04:05 +00:00
CompilerDriver Forgot a declaration. 2009-10-22 04:15:24 +00:00
Config CMake: Detect dotty. 2009-11-05 19:03:26 +00:00
ExecutionEngine add interpreter support for indirect goto / blockaddress. The interpreter 2009-10-29 05:26:09 +00:00
MC Pass StringRef by value. 2009-11-06 10:58:06 +00:00
Support Pass StringRef by value. 2009-11-06 10:58:06 +00:00
System Move DataTypes.h to include/llvm/System, update all users. This breaks the last 2009-10-26 01:35:46 +00:00
Target Pass StringRef by value. 2009-11-06 10:58:06 +00:00
Transforms Make a few more LLVM headers parsable as standalone headers. 2009-11-05 23:01:30 +00:00
AbstractTypeUser.h When a constant's type is refined, update the constant in place 2009-09-15 15:58:07 +00:00
Argument.h Initial update to VMCore to use Twines for string arguments. 2009-07-25 04:41:11 +00:00
Attributes.h Add an 'inline hint' attribute to represent source 2009-08-26 01:08:21 +00:00
AutoUpgrade.h Reapply 79977. 2009-08-28 23:24:31 +00:00
BasicBlock.h the verifier shouldn't modify the IR. 2009-11-01 18:11:50 +00:00
CallGraphSCCPass.h Fix some nasty callgraph dangling pointer problems in 2009-08-31 00:19:58 +00:00
CallingConv.h Address review comments: add 3 ARM calling conventions. 2009-06-16 18:50:49 +00:00
CMakeLists.txt CMake: Have generated Xcode projects also contain the LLVM header files. 2009-04-01 15:40:21 +00:00
Constant.h the verifier shouldn't modify the IR. 2009-11-01 18:11:50 +00:00
Constants.h Pass StringRef by value. 2009-11-06 10:58:06 +00:00
DerivedTypes.h Actually privatize a IntegerTypes, and fix a few bugs exposed by this. 2009-08-13 23:27:32 +00:00
Function.h Retype from unsigned to CallingConv::ID accordingly. Approved by Bob Wilson. 2009-09-02 08:44:58 +00:00
GlobalAlias.h Public and private corrections, warned about by icc (#304). 2009-09-06 08:55:57 +00:00
GlobalValue.h Pass StringRef by value. 2009-11-06 10:58:06 +00:00
GlobalVariable.h remove a bunch of extraneous LLVMContext arguments 2009-11-06 04:27:31 +00:00
InlineAsm.h Pass StringRef by value. 2009-11-06 10:58:06 +00:00
InstrTypes.h Factor out redundancy from clone() implementations. 2009-10-27 22:16:29 +00:00
Instruction.def rename indbr -> indirectbr to appease the residents of #llvm. 2009-10-28 00:19:10 +00:00
Instruction.h Factor out redundancy from clone() implementations. 2009-10-27 22:16:29 +00:00
Instructions.h Re-commit r86077 now that r86290 fixes the 179.art and 175.vpr ARM regressions. 2009-11-07 00:16:28 +00:00
IntrinsicInst.h Don't put in these EH changes. 2009-10-29 00:37:35 +00:00
Intrinsics.h Make LLVMContext and LLVMContextImpl classes instead of structs. 2009-08-11 17:45:13 +00:00
Intrinsics.td Add objectsize intrinsic and hook it up through codegen. Doesn't 2009-10-27 00:52:25 +00:00
IntrinsicsAlpha.td Modify the intrinsics pattern to separate out the "return" types from the 2008-11-13 09:08:33 +00:00
IntrinsicsARM.td Add new intrinsics for Neon vldN_lane and vstN_lane operations. 2009-08-22 02:28:46 +00:00
IntrinsicsCellSPU.td Modify the intrinsics pattern to separate out the "return" types from the 2008-11-13 09:08:33 +00:00
IntrinsicsPowerPC.td Modify the intrinsics pattern to separate out the "return" types from the 2008-11-13 09:08:33 +00:00
IntrinsicsX86.td Fix PR5315, original patch by Nicolas Capens! 2009-11-06 00:11:57 +00:00
IntrinsicsXCore.td Add XCore intrinsics for getid (returns thread id) and bitrev (reverses 2008-11-14 10:12:16 +00:00
LinkAllPasses.h Remove CodeGenLICM. It's largely obsoleted by MachineLICM's new ability 2009-10-31 14:35:41 +00:00
LinkAllVMCore.h Push LLVMContexts through the IntegerType APIs. 2009-08-13 21:58:54 +00:00
Linker.h Pass StringRef by value. 2009-11-06 10:58:06 +00:00
LLVMContext.h Derive metadata hierarchy from Value instead of User. 2009-10-21 23:57:35 +00:00
Metadata.h Silence implicit conversion warnings. 2009-11-04 03:08:57 +00:00
Module.h Pass StringRef by value. 2009-11-06 10:58:06 +00:00
ModuleProvider.h Remove warnings about unused parameters and shadowed variables. 2008-05-19 20:15:12 +00:00
OperandTraits.h Public and private corrections, warned about by icc (#304). 2009-09-06 08:55:57 +00:00
Operator.h Remove a bunch of unused arguments from functions, silencing a 2009-10-14 20:28:33 +00:00
Pass.h Pass StringRef by value. 2009-11-06 10:58:06 +00:00
PassAnalysisSupport.h Pass StringRef by value. 2009-11-06 10:58:06 +00:00
PassManager.h Reverting 85714, 85715, 85716, which are breaking the build 2009-11-01 16:42:53 +00:00
PassManagers.h Pass StringRef by value. 2009-11-06 10:58:06 +00:00
PassSupport.h Add required #includes for freestanding .h files. 2009-10-17 03:28:07 +00:00
SymbolTableListTraits.h Forward-declare ValueSymbolTable so that SymbolTableListTraits.h can be parsed by itself 2009-09-30 00:08:25 +00:00
Type.h Type.h doesn't need to #include LLVMContext.h 2009-10-27 17:08:31 +00:00
TypeSymbolTable.h Pass StringRef by value. 2009-11-06 10:58:06 +00:00
Use.h eliminate all 80-col violations that I have introduced in my recent checkins (and some others more) 2009-08-27 23:44:33 +00:00
User.h Remove some dead functions, patch by Ryan Flynn! 2009-07-14 18:58:35 +00:00
Value.h IR support for the new BlockAddress constant kind. This is 2009-10-28 00:01:44 +00:00
ValueSymbolTable.h Pass StringRef by value. 2009-11-06 10:58:06 +00:00