aboutsummaryrefslogtreecommitdiffstats
Commit message (Collapse)AuthorAgeFilesLines
...
* MC: When running with -mc-relax-all, we can eagerly relax instructions and ↵Daniel Dunbar2010-05-262-21/+20
| | | | | | avoid creating unnecessary MCInstFragments. git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@104736 91177308-0d34-0410-b5e6-96231b3b80d8
* MC/Mach-O: Factor out EmitInstTo{Fragment,Data} for emitting MCInst's as ↵Daniel Dunbar2010-05-261-34/+46
| | | | | | MCInstFragments or appending onto an MCDataFragment. git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@104735 91177308-0d34-0410-b5e6-96231b3b80d8
* Adjust eh.sjlj.setjmp to properly have a chain and to have an opcode entry inJim Grosbach2010-05-267-11/+32
| | | | | | | | ISD::. No functional change. git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@104734 91177308-0d34-0410-b5e6-96231b3b80d8
* Update debug info when live-in reg is copied into a vreg.Devang Patel2010-05-262-0/+88
| | | | git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@104732 91177308-0d34-0410-b5e6-96231b3b80d8
* Fix the x86 move to/from segment register instructions.Kevin Enderby2010-05-263-4/+54
| | | | git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@104731 91177308-0d34-0410-b5e6-96231b3b80d8
* Move the check for "calls setjmp" to SelectionDAGISel so that it can be used byBill Wendling2010-05-263-33/+50
| | | | | | | more than just the stack slot coloring algorithm. git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@104722 91177308-0d34-0410-b5e6-96231b3b80d8
* Identify instructions, that needs a label to mark debug info entity, in ↵Devang Patel2010-05-262-37/+68
| | | | | | advance. This simplifies beginScope(). git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@104720 91177308-0d34-0410-b5e6-96231b3b80d8
* Eliminate the use of PriorityQueue and just use a std::vector,Dan Gohman2010-05-263-21/+46
| | | | | | | | | implementing pop with a linear search for a "best" element. The priority queue was a neat idea, but in practice the comparison functions depend on dynamic information. git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@104718 91177308-0d34-0410-b5e6-96231b3b80d8
* Fix indentation.Dan Gohman2010-05-261-2/+2
| | | | git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@104717 91177308-0d34-0410-b5e6-96231b3b80d8
* Delete an unused function.Dan Gohman2010-05-261-2/+0
| | | | git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@104716 91177308-0d34-0410-b5e6-96231b3b80d8
* MC: Change RelaxInstruction to only take the input and output instructions.Daniel Dunbar2010-05-263-12/+13
| | | | git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@104713 91177308-0d34-0410-b5e6-96231b3b80d8
* Fix a typo in a comment that Gabor noticed.Dan Gohman2010-05-261-3/+3
| | | | git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@104711 91177308-0d34-0410-b5e6-96231b3b80d8
* Testcase for 104624/104619/PR7191/8023512.Dale Johannesen2010-05-261-0/+16
| | | | | | | | Reduced from one provided by Duncan Sands, thanks! git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@104710 91177308-0d34-0410-b5e6-96231b3b80d8
* MC: Eliminate an unnecessary copy.Daniel Dunbar2010-05-261-9/+4
| | | | git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@104709 91177308-0d34-0410-b5e6-96231b3b80d8
* MC: Simplify MayNeedRelaxation to not provide the fixups, so we can query itDaniel Dunbar2010-05-264-32/+13
| | | | | | before encoding. git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@104707 91177308-0d34-0410-b5e6-96231b3b80d8
* Remove dead code.Devang Patel2010-05-262-11/+1
| | | | git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@104706 91177308-0d34-0410-b5e6-96231b3b80d8
* Do not construct location list backword!Devang Patel2010-05-261-13/+17
| | | | git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@104705 91177308-0d34-0410-b5e6-96231b3b80d8
* Replace the SubRegSet tablegen class with a less error-prone mechanism.Jakob Stoklund Olesen2010-05-2611-326/+187
| | | | | | | | | | | | | | | | A Register with subregisters must also provide SubRegIndices for adressing the subregisters. TableGen automatically inherits indices for sub-subregisters to minimize typing. CompositeIndices may be specified for the weirder cases such as the XMM sub_sd index that returns the same register, and ARM NEON Q registers where both D subregs have ssub_0 and ssub_1 sub-subregs. It is now required that all subregisters are named by an index, and a future patch will also require inherited subregisters to be named. This is necessary to allow composite subregister indices to be reduced to a single index. git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@104704 91177308-0d34-0410-b5e6-96231b3b80d8
* Add entry for llvm.eh.sjlj.longjmp. PR4999.Jim Grosbach2010-05-261-0/+20
| | | | git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@104703 91177308-0d34-0410-b5e6-96231b3b80d8
* MC: Eliminate MCAsmFixup, replace with MCFixup.Daniel Dunbar2010-05-268-75/+44
| | | | git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@104699 91177308-0d34-0410-b5e6-96231b3b80d8
* MC: Simplify MCFixup and increase the available offset size.Daniel Dunbar2010-05-261-29/+14
| | | | git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@104698 91177308-0d34-0410-b5e6-96231b3b80d8
* MC: Use accessors for access to MCAsmFixup.Daniel Dunbar2010-05-265-27/+38
| | | | git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@104697 91177308-0d34-0410-b5e6-96231b3b80d8
* MC: Change MCInst::dump_pretty to not include a trailing newline.Daniel Dunbar2010-05-263-3/+6
| | | | git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@104696 91177308-0d34-0410-b5e6-96231b3b80d8
* Kill unneeded SExt.Benjamin Kramer2010-05-261-1/+1
| | | | git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@104692 91177308-0d34-0410-b5e6-96231b3b80d8
* SRetReturnReg was set in LowerFormalArguments(). So only assert it here.Zhongxing Xu2010-05-261-4/+2
| | | | git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@104691 91177308-0d34-0410-b5e6-96231b3b80d8
* MC: Eliminate MCFragment vtable, which was unnecessary.Daniel Dunbar2010-05-262-81/+63
| | | | git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@104689 91177308-0d34-0410-b5e6-96231b3b80d8
* Coding style change (Adding 1 missing space.)Shih-wei Liao2010-05-261-1/+1
| | | | git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@104670 91177308-0d34-0410-b5e6-96231b3b80d8
* Adding the missing implementation for ARM::SBFX and ARM::UBFX.Shih-wei Liao2010-05-261-1/+13
| | | | | | | Fixing http://llvm.org/bugs/show_bug.cgi?id=7225. git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@104667 91177308-0d34-0410-b5e6-96231b3b80d8
* Temporarily revert r104655 as it's breaking the bots.Eric Christopher2010-05-263-53/+38
| | | | git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@104664 91177308-0d34-0410-b5e6-96231b3b80d8
* fix off by 1 (insn) error in eh.sjlj.setjmp thumb code sequence.Jim Grosbach2010-05-262-3/+3
| | | | git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@104661 91177308-0d34-0410-b5e6-96231b3b80d8
* Revert "Replace the SubRegSet tablegen class with a less error-prone mechanism."Jakob Stoklund Olesen2010-05-2611-187/+326
| | | | | | This reverts commit 104654. git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@104660 91177308-0d34-0410-b5e6-96231b3b80d8
* Change push_all to a non-virtual function and implement it in theDan Gohman2010-05-264-16/+8
| | | | | | | base class, since all the implementations are the same. git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@104659 91177308-0d34-0410-b5e6-96231b3b80d8
* Delete an unused function.Dan Gohman2010-05-262-3/+0
| | | | git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@104658 91177308-0d34-0410-b5e6-96231b3b80d8
* Trim #include.Dan Gohman2010-05-261-1/+0
| | | | git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@104657 91177308-0d34-0410-b5e6-96231b3b80d8
* Dale and Evan suggested putting the "check for setjmp" much earlier in theBill Wendling2010-05-263-38/+53
| | | | | | | machine code generation. That's a good idea, so I made it so. git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@104655 91177308-0d34-0410-b5e6-96231b3b80d8
* Replace the SubRegSet tablegen class with a less error-prone mechanism.Jakob Stoklund Olesen2010-05-2611-326/+187
| | | | | | | | | | | | | | | | A Register with subregisters must also provide SubRegIndices for adressing the subregisters. TableGen automatically inherits indices for sub-subregisters to minimize typing. CompositeIndices may be specified for the weirder cases such as the XMM sub_sd index that returns the same register, and ARM NEON Q registers where both D subregs have ssub_0 and ssub_1 sub-subregs. It is now required that all subregisters are named by an index, and a future patch will also require inherited subregisters to be named. This is necessary to allow composite subregister indices to be reduced to a single index. git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@104654 91177308-0d34-0410-b5e6-96231b3b80d8
* Adding the missing implementation of Bitfield's "clear" and "insert".Shih-wei Liao2010-05-261-4/+9
| | | | | | | Fixing http://llvm.org/bugs/show_bug.cgi?id=7222. git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@104653 91177308-0d34-0410-b5e6-96231b3b80d8
* To handle s* registers in emitVFPLoadStoreMultipleInstruction().Shih-wei Liao2010-05-261-7/+12
| | | | | | | Fixing http://llvm.org/bugs/show_bug.cgi?id=7221. git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@104652 91177308-0d34-0410-b5e6-96231b3b80d8
* Start adding mach-o tls reloc support.Eric Christopher2010-05-263-3/+12
| | | | git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@104651 91177308-0d34-0410-b5e6-96231b3b80d8
* Drop the SuperregHashTable. It is essentially the same as SubregHashTable.Jakob Stoklund Olesen2010-05-253-103/+6
| | | | git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@104650 91177308-0d34-0410-b5e6-96231b3b80d8
* First cut at supporting .debug_loc section. Devang Patel2010-05-254-87/+492
| | | | | | | This is used to track variable information. git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@104649 91177308-0d34-0410-b5e6-96231b3b80d8
* Properly promote operands when optimizing a single-character memcmp.Benjamin Kramer2010-05-252-4/+19
| | | | git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@104648 91177308-0d34-0410-b5e6-96231b3b80d8
* Constify function.Bill Wendling2010-05-251-2/+2
| | | | git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@104646 91177308-0d34-0410-b5e6-96231b3b80d8
* Do one map lookup instead of two.Dan Gohman2010-05-251-2/+3
| | | | git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@104645 91177308-0d34-0410-b5e6-96231b3b80d8
* Fix a missing newline in debug output.Dan Gohman2010-05-251-1/+1
| | | | git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@104644 91177308-0d34-0410-b5e6-96231b3b80d8
* Move the verbose asm output up a bit so it can be used in the special casesEric Christopher2010-05-251-5/+6
| | | | | | | as well. git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@104642 91177308-0d34-0410-b5e6-96231b3b80d8
* Okay, bear with me here...Bill Wendling2010-05-251-0/+41
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | If you have a setjmp/longjmp situation, it's possible for stack slot coloring to reuse a stack slot before it's really dead. For instance, if we have something like this: 1: y = g; x = sigsetjmp(env, 0); switch (x) { case 1: /* ... */ goto run; case 0: run: do_run(); /* marked as "no return" */ break; case 3: if (...) { /* ... */ goto run; } /* ... */ break; } 2: g = y; "y" may be put onto the stack, so the expression "g = y" is relying upon the fact that the stack slot containing "y" isn't modified between (1) and (2). But it can be, because of the "no return" calls in there. A longjmp might come back with 3, modify the stack slot, and then go to case 0. And it's perfectly acceptable to reuse the stack slot there because there's no CFG flow from case 3 to (2). The fix is to disable certain optimizations in these situations. Ideally, we'd disable them for all "returns twice" functions. But we don't support that attribute. Check for "setjmp" and "sigsetjmp" instead. git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@104640 91177308-0d34-0410-b5e6-96231b3b80d8
* Add support for initialized global data for darwin tls. Update commentsEric Christopher2010-05-253-94/+144
| | | | | | | and testcases accordingly. git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@104635 91177308-0d34-0410-b5e6-96231b3b80d8
* Changed the encoding of X86 floating point stack operations where both operandsKevin Enderby2010-05-252-0/+36
| | | | | | | | | | | | | | | | | | | | | | | | | are st(0). These can be encoded using an opcode for storing in st(0) or using an opcode for storing in st(i), where i can also be 0. To allow testing with the darwin assembler and get a matching binary the opcode for storing in st(0) is now used. To do this the same logical trick is use from the darwin assembler in converting things like this: fmul %st(0), %st into this: fmul %st(0) by looking for the second operand being X86::ST0 for specific floating point mnemonics then removing the second X86::ST0 operand. This also has the add benefit to allow things like: fmul %st(1), %st that llvm-mc did not assemble. git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@104634 91177308-0d34-0410-b5e6-96231b3b80d8
* Removing test; Chris thinks it's better to have theDale Johannesen2010-05-251-2718/+0
| | | | | | | | bug go untested than have a testcase this large. So be it. git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@104632 91177308-0d34-0410-b5e6-96231b3b80d8