aboutsummaryrefslogtreecommitdiffstats
path: root/lib
Commit message (Collapse)AuthorAgeFilesLines
* Fix cmake build, which has a different -I thatShantonu Sen2009-09-181-1/+1
| | | | | | | causes the "../foo" to not find the file git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@82270 91177308-0d34-0410-b5e6-96231b3b80d8
* Make a new X8632_MachoTargetObjectFile TLOF implementation whose Chris Lattner2009-09-185-27/+47
| | | | | | | | | | | | | | | | | | | | | | | getSymbolForDwarfGlobalReference is smart enough to know that it needs to register the stub it references with MachineModuleInfoMachO, so that it gets emitted at the end of the file. Move stub emission from X86ATTAsmPrinter::doFinalization to the new X86ATTAsmPrinter::EmitEndOfAsmFile asmprinter hook. The important thing here is that EmitEndOfAsmFile is called *after* the ehframes are emitted, so we get all the stubs. This allows us to remove a gross hack from the asmprinter where it would "just know" that it needed to output stubs for personality functions. Now this is all driven from a consistent interface. The testcase change is just reordering the expected output now that the stubs come out after the ehframe instead of before. This also unblocks other changes that Bill wants to make. git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@82269 91177308-0d34-0410-b5e6-96231b3b80d8
* add a new hook to allow targets to splat stuff at the end of the file.Chris Lattner2009-09-181-0/+5
| | | | | | | Overriding doFinalization is pretty lame. git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@82268 91177308-0d34-0410-b5e6-96231b3b80d8
* Model the carry bit on ppc32. Without this we couldDale Johannesen2009-09-183-28/+60
| | | | | | | | | move a SUBFC (etc.) below the SUBFE (etc.) that consumed the carry bit. Add missing ADDIC8, noticed along the way. git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@82266 91177308-0d34-0410-b5e6-96231b3b80d8
* Add support for using the FLAGS result of or, xor, and and instructionsDan Gohman2009-09-184-5/+365
| | | | | | | | on x86, to avoid explicit test instructions. A few existing tests changed due to arbitrary register allocation differences. git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@82263 91177308-0d34-0410-b5e6-96231b3b80d8
* Added RCL and RCR (rotate left and right with aSean Callanan2009-09-182-0/+124
| | | | | | | | carry bit) instructions to the Intel instruction tables. git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@82260 91177308-0d34-0410-b5e6-96231b3b80d8
* Write and read metadata attachments.Devang Patel2009-09-186-6/+206
| | | | git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@82259 91177308-0d34-0410-b5e6-96231b3b80d8
* Update malloc call creation code (AllocType is now the element type of the ↵Victor Hernandez2009-09-185-89/+132
| | | | | | | | | | | | | | | | | | | | malloc, not the resulting type). In getMallocArraySize(), fix bug in the case that array size is the product of 2 constants. Extend isArrayMalloc() and getMallocArraySize() to handle case where malloc is used as char array. Ensure that ArraySize in LowerAllocations::runOnBasicBlock() is correct type. Extend Instruction::isSafeToSpeculativelyExecute() to handle malloc calls. Add verification for malloc calls. Reviewed by Dan Gohman. git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@82257 91177308-0d34-0410-b5e6-96231b3b80d8
* duncan points out the EH selector values are signed.Chris Lattner2009-09-181-1/+1
| | | | git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@82245 91177308-0d34-0410-b5e6-96231b3b80d8
* This file can need access to the X86 instruction enums when the table ↵Chris Lattner2009-09-181-0/+1
| | | | | | exceeds 32-bits. git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@82235 91177308-0d34-0410-b5e6-96231b3b80d8
* Allow symbols to start from the digit if target requests it. This allows, ↵Anton Korobeynikov2009-09-185-8/+17
| | | | | | | | | e.g. pinning variables to specified absolute address. Make use of this feature for MSP430. This unbreaks PR4776. git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@82227 91177308-0d34-0410-b5e6-96231b3b80d8
* Stop using alloca.Nick Lewycky2009-09-181-17/+14
| | | | git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@82225 91177308-0d34-0410-b5e6-96231b3b80d8
* Revert r82214. It broke 403.gcc on x86_64 / Darwin.Evan Cheng2009-09-181-12/+5
| | | | git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@82215 91177308-0d34-0410-b5e6-96231b3b80d8
* Fix a bug in sdisel switch lowering code. When it updates the phi nodes in ↵Evan Cheng2009-09-181-5/+12
| | | | | | | | | switch successor blocks, it can introduce multiple phi operands of the same value from different blocks (and may not be on the predecessor list). This can be seen on CodeGen/Generic/2006-09-06-SwitchLowering.ll. But it's not known to cause any real regression (but I have added an assertion for it now). git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@82214 91177308-0d34-0410-b5e6-96231b3b80d8
* Add newlines.Nick Lewycky2009-09-181-2/+2
| | | | git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@82206 91177308-0d34-0410-b5e6-96231b3b80d8
* tolerate llvm.eh.selector.i64 on 32-bit systems and llvm.eh.selector.i32 onChris Lattner2009-09-171-21/+24
| | | | | | | 64-bit systems. git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@82180 91177308-0d34-0410-b5e6-96231b3b80d8
* Fix parsing of optional metadata for 'load', 'store' and 'alloc' instructions.Devang Patel2009-09-172-65/+105
| | | | git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@82175 91177308-0d34-0410-b5e6-96231b3b80d8
* pass machinemoduleinfo down into getSymbolForDwarfGlobalReference, Chris Lattner2009-09-174-0/+5
| | | | | | | currently unused. git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@82157 91177308-0d34-0410-b5e6-96231b3b80d8
* Teach ScalarEvolution how to reason about no-wrap flags on loopsDan Gohman2009-09-171-15/+37
| | | | | | | | | where the induction variable has a non-unit stride, such as {0,+,2}, and there are expressions such as {1,+,2} inside the loop formed with or or add nsw operators. git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@82151 91177308-0d34-0410-b5e6-96231b3b80d8
* grammarJim Grosbach2009-09-171-1/+1
| | | | git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@82150 91177308-0d34-0410-b5e6-96231b3b80d8
* Initialize HasMetadata to zero.Benjamin Kramer2009-09-171-2/+2
| | | | git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@82145 91177308-0d34-0410-b5e6-96231b3b80d8
* Remove simple regalloc. It has bit rotted.Evan Cheng2009-09-172-262/+0
| | | | git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@82127 91177308-0d34-0410-b5e6-96231b3b80d8
* add a version of the APFloat constructor that initializes to 0.0Chris Lattner2009-09-171-0/+8
| | | | git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@82110 91177308-0d34-0410-b5e6-96231b3b80d8
* Fix PR4910: Broken logic in coalescer means when a physical register ↵Evan Cheng2009-09-171-3/+4
| | | | | | liveness is being shortened, the sub-registers were not. The symptom is the register allocator could not find a free register for this particular test. git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@82108 91177308-0d34-0410-b5e6-96231b3b80d8
* Some platforms may need malloc.h for alloca.Daniel Dunbar2009-09-171-3/+6
| | | | git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@82100 91177308-0d34-0410-b5e6-96231b3b80d8
* Update CMake.Daniel Dunbar2009-09-171-0/+1
| | | | git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@82097 91177308-0d34-0410-b5e6-96231b3b80d8
* Added the LODS (load byte into register, usuallySean Callanan2009-09-162-0/+10
| | | | | | | | as part string parsing) instructions to the Intel instruction tables. git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@82089 91177308-0d34-0410-b5e6-96231b3b80d8
* Add StringRef::{rfind, rsplit}Daniel Dunbar2009-09-162-0/+14
| | | | git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@82087 91177308-0d34-0410-b5e6-96231b3b80d8
* Added the LAR (load segment access rights)Sean Callanan2009-09-162-0/+21
| | | | | | | instructions to the Intel instruction tables. git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@82084 91177308-0d34-0410-b5e6-96231b3b80d8
* Added the LOOP family of instructions to the IntelSean Callanan2009-09-161-0/+6
| | | | | | | instruction tables. git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@82083 91177308-0d34-0410-b5e6-96231b3b80d8
* Added an alternate form of register-register CMPSean Callanan2009-09-162-0/+8
| | | | | | | to the Intel instruction tables. git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@82081 91177308-0d34-0410-b5e6-96231b3b80d8
* Fix typo.Devang Patel2009-09-161-1/+1
| | | | git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@82080 91177308-0d34-0410-b5e6-96231b3b80d8
* At iSel time, update DebugLoc based on debug info attached with an instruction.Devang Patel2009-09-161-1/+30
| | | | git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@82077 91177308-0d34-0410-b5e6-96231b3b80d8
* Add a new pass for doing late hoisting of floating-point and vectorDan Gohman2009-09-162-1/+123
| | | | | | | | | | | | constants out of loops. These aren't covered by the regular LICM pass, because in LLVM IR constants don't require separate instructions. They're not always covered by the MachineLICM pass either, because it doesn't know how to unfold folded constant-pool loads. This is somewhat experimental at this point, and off by default. git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@82076 91177308-0d34-0410-b5e6-96231b3b80d8
* Print debug info attached with an instruction.Devang Patel2009-09-162-1/+26
| | | | git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@82075 91177308-0d34-0410-b5e6-96231b3b80d8
* Expand vector floating-point conversions not supported by NEON.Bob Wilson2009-09-161-0/+6
| | | | git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@82074 91177308-0d34-0410-b5e6-96231b3b80d8
* Provide a way to extract location info from DILocation.Devang Patel2009-09-161-0/+23
| | | | git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@82064 91177308-0d34-0410-b5e6-96231b3b80d8
* Parse debug info attached with an instruction.Devang Patel2009-09-163-0/+19
| | | | git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@82063 91177308-0d34-0410-b5e6-96231b3b80d8
* Add llvm::Metadata to manage metadata used in a context. Devang Patel2009-09-164-0/+82
| | | | | | | | This interface will be used to attach metadata with an instruction. git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@82060 91177308-0d34-0410-b5e6-96231b3b80d8
* Fix incorrect assert that should be a user error for code like 'mov $0, %%eax'.Kevin Enderby2009-09-161-1/+2
| | | | git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@82054 91177308-0d34-0410-b5e6-96231b3b80d8
* Change FoldPHIArgBinOpIntoPHI to decline folding if it would introduce twoDan Gohman2009-09-161-7/+13
| | | | | | | | | phis, similar to the FoldPHIArgGEPIntoPHI change. Also, delete some comments that don't reflect the code. git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@82053 91177308-0d34-0410-b5e6-96231b3b80d8
* Don't sort the vector when it is empty. This should fix some expensive checkingBenjamin Kramer2009-09-161-1/+2
| | | | | | | failures. git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@82040 91177308-0d34-0410-b5e6-96231b3b80d8
* Reapplied r81355 with the problems fixed.Andreas Neustifter2009-09-163-18/+31
| | | | | | | | (See http://lists.cs.uiuc.edu/pipermail/llvm-commits/Week-of-Mon-20090907/086737.html and http://lists.cs.uiuc.edu/pipermail/llvm-commits/Week-of-Mon-20090907/086746.html) git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@82039 91177308-0d34-0410-b5e6-96231b3b80d8
* updated lib/CodeGen/CMakeLists.txt to unbreak cmake build after r82018Xerxes Ranby2009-09-161-0/+1
| | | | git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@82038 91177308-0d34-0410-b5e6-96231b3b80d8
* Preserve ProfileInfo during CodeGenPrepare.Andreas Neustifter2009-09-162-2/+24
| | | | git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@82034 91177308-0d34-0410-b5e6-96231b3b80d8
* move FnStubs/GVSTubs/HiddenGVStub handling out of the X86 asmprinterChris Lattner2009-09-164-43/+44
| | | | | | | | and use MachineModuleInfoMachO instead. git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@82022 91177308-0d34-0410-b5e6-96231b3b80d8
* revert a hunk of r82018 that wasn't supposed to go in yet.Chris Lattner2009-09-161-0/+5
| | | | git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@82020 91177308-0d34-0410-b5e6-96231b3b80d8
* add a new MachineModuleInfoMachO class, which is the per-moduleChris Lattner2009-09-162-5/+44
| | | | | | | | stuff common across all macho targets. git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@82018 91177308-0d34-0410-b5e6-96231b3b80d8
* the pointer MMI keeps will start out with object-file format specific stuffChris Lattner2009-09-161-2/+2
| | | | git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@82012 91177308-0d34-0410-b5e6-96231b3b80d8
* tidy upChris Lattner2009-09-161-3/+3
| | | | git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@82011 91177308-0d34-0410-b5e6-96231b3b80d8