Commit Graph

20740 Commits

Author SHA1 Message Date
Duncan Sands
f6bd0ce4c9 Add terminating newline.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@43933 91177308-0d34-0410-b5e6-96231b3b80d8
2007-11-09 08:30:21 +00:00
Evan Cheng
cc41586b9d Much improved pic jumptable codegen:
Then:
        call    "L1$pb"
"L1$pb":
        popl    %eax
		...
LBB1_1: # entry
        imull   $4, %ecx, %ecx
        leal    LJTI1_0-"L1$pb"(%eax), %edx
        addl    LJTI1_0-"L1$pb"(%ecx,%eax), %edx
        jmpl    *%edx

        .align  2
        .set L1_0_set_3,LBB1_3-LJTI1_0
        .set L1_0_set_2,LBB1_2-LJTI1_0
        .set L1_0_set_5,LBB1_5-LJTI1_0
        .set L1_0_set_4,LBB1_4-LJTI1_0
LJTI1_0:
        .long    L1_0_set_3
        .long    L1_0_set_2

Now:
        call    "L1$pb"
"L1$pb":
        popl    %eax
		...
LBB1_1: # entry
        addl    LJTI1_0-"L1$pb"(%eax,%ecx,4), %eax
        jmpl    *%eax

		.align  2
		.set L1_0_set_3,LBB1_3-"L1$pb"
		.set L1_0_set_2,LBB1_2-"L1$pb"
		.set L1_0_set_5,LBB1_5-"L1$pb"
		.set L1_0_set_4,LBB1_4-"L1$pb"
LJTI1_0:
        .long    L1_0_set_3
        .long    L1_0_set_2


git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@43924 91177308-0d34-0410-b5e6-96231b3b80d8
2007-11-09 01:32:10 +00:00
Evan Cheng
2dfdefd282 Didn't mean to check these in.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@43923 91177308-0d34-0410-b5e6-96231b3b80d8
2007-11-09 01:28:33 +00:00
Evan Cheng
7da8f399bf Bug fix. Passive nodes are not in SUnitMap.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@43922 91177308-0d34-0410-b5e6-96231b3b80d8
2007-11-09 01:27:11 +00:00
Dale Johannesen
3556bc1a9d Rewrite Dwarf number handling per review comments.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@43918 91177308-0d34-0410-b5e6-96231b3b80d8
2007-11-09 00:47:10 +00:00
Ted Kremenek
48a396948f Updated Deserializer class to provide more information about the current
block that is being visited in the bitstream.  The client can also now
skip blocks before reading them, and query the current abbreviation number
as seen from the perspective of the Deserializer.  This allows the client
to be more interactive in the deserialization process (if they so choose).


git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@43916 91177308-0d34-0410-b5e6-96231b3b80d8
2007-11-09 00:43:51 +00:00
Owen Anderson
0823cea34a This preserves critical edge breaking.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@43911 91177308-0d34-0410-b5e6-96231b3b80d8
2007-11-08 22:23:57 +00:00
Owen Anderson
d195ce1fb6 Make BreakCriticalMachineEdges available as a pass that can be depended on.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@43910 91177308-0d34-0410-b5e6-96231b3b80d8
2007-11-08 22:20:23 +00:00
Ted Kremenek
ec8cd06555 Added typedef "SerializedPtrID" to represent the pointer handle written to disk
instead of just using "unsigned".  This gives us more flexibility in changing
the definition of the handle later, and is more self-documenting.

Added tracking of block stack in the Deserializer.  Now clients can query
if they are still within a block using the methods GetCurrentBlockLocation()
and FinishedBlock().


git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@43903 91177308-0d34-0410-b5e6-96231b3b80d8
2007-11-08 19:50:46 +00:00
Andrew Lenharth
b410df995c Better check
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@43897 91177308-0d34-0410-b5e6-96231b3b80d8
2007-11-08 18:45:15 +00:00
Andrew Lenharth
ab9338eb9f Fix PR1780
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@43893 91177308-0d34-0410-b5e6-96231b3b80d8
2007-11-08 17:39:28 +00:00
Lauro Ramos Venancio
e0cb36b9fb [ARM] Implement __builtin_thread_pointer.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@43892 91177308-0d34-0410-b5e6-96231b3b80d8
2007-11-08 17:20:05 +00:00
Evan Cheng
4471194d69 If both parts of smul_lohi, etc. are used, don't simplify. If only one part is used, try simplify it.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@43888 91177308-0d34-0410-b5e6-96231b3b80d8
2007-11-08 09:25:29 +00:00
Owen Anderson
01f43a4d55 Add the majority of machine-level critical edge breaking pass. Most of this was written by Fernando, cleanup and updating to TOT by me.
This still needs a bit of work, particularly to handle jump tables properly.


git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@43885 91177308-0d34-0410-b5e6-96231b3b80d8
2007-11-08 07:55:43 +00:00
Owen Anderson
14b3fb7805 Take another stab at getting isLiveIn() and isLiveOut() right.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@43869 91177308-0d34-0410-b5e6-96231b3b80d8
2007-11-08 01:32:45 +00:00
Owen Anderson
a018540807 Bring UsedBlocks back. StrongPHIElimination needs this information.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@43866 91177308-0d34-0410-b5e6-96231b3b80d8
2007-11-08 01:20:48 +00:00
Dale Johannesen
4542edcaa7 Complete conditionalization of Dwarf reg numbers.
Would somebody not on Darwin please make sure this
doesn't break anything.  Exception handling failures
would be the most likely symptom.



git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@43844 91177308-0d34-0410-b5e6-96231b3b80d8
2007-11-07 21:48:35 +00:00
Ted Kremenek
c47dfdde24 Implemented generic serialization of APFloat.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@43829 91177308-0d34-0410-b5e6-96231b3b80d8
2007-11-07 18:39:22 +00:00
Ted Kremenek
2e6452ca0c Implemented serialization of signed integers.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@43828 91177308-0d34-0410-b5e6-96231b3b80d8
2007-11-07 18:24:34 +00:00
Evan Cheng
29121848b9 Simplify my (il)logic.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@43819 91177308-0d34-0410-b5e6-96231b3b80d8
2007-11-07 08:08:25 +00:00
Owen Anderson
60a877d713 Add some more of StrongPHIElim.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@43805 91177308-0d34-0410-b5e6-96231b3b80d8
2007-11-07 05:17:15 +00:00
Dale Johannesen
483ec21d90 Interchange Dwarf numbers of ESP and EBP on x86 Darwin.
Much improvement in exception handling.


git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@43794 91177308-0d34-0410-b5e6-96231b3b80d8
2007-11-07 00:25:05 +00:00
Ted Kremenek
68dd3fbe5b Serializer no longer automatically emits a root-level block in the bitstream.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@43784 91177308-0d34-0410-b5e6-96231b3b80d8
2007-11-06 22:22:25 +00:00
Ted Kremenek
b12a82dbf4 Augmented ReadPtr and ReadOwnedPtr to control whether or not a pointer is allowed to be backpatched
or can be registered with the deserializer to backpatch other pointers.


git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@43783 91177308-0d34-0410-b5e6-96231b3b80d8
2007-11-06 22:21:14 +00:00
Chris Lattner
373a733be0 make smallptrset more const and type correct, which caught a few
minor bugs.


git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@43782 91177308-0d34-0410-b5e6-96231b3b80d8
2007-11-06 22:12:43 +00:00
Dan Gohman
0d97426b7b Remainder operations must be either integer or floating-point.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@43781 91177308-0d34-0410-b5e6-96231b3b80d8
2007-11-06 22:11:54 +00:00
Chris Lattner
f67f73a519 fix const correctness, BB is const, so its predecessors are too
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@43780 91177308-0d34-0410-b5e6-96231b3b80d8
2007-11-06 22:07:40 +00:00
Chris Lattner
6390ae0a4a don't put erase or query for non-allocainst pointers in an set of allocainsts*'s
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@43779 91177308-0d34-0410-b5e6-96231b3b80d8
2007-11-06 22:07:22 +00:00
Chris Lattner
cf5008a792 Implement PR1777 by detecting dependent phis that
all compute the same value.


git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@43777 91177308-0d34-0410-b5e6-96231b3b80d8
2007-11-06 21:52:06 +00:00
Evan Cheng
be6781b5d0 When the allocator rewrite a spill register with new virtual register, it replaces other operands of the same register. Watch out for situations where
only some of the operands are sub-register uses.


git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@43776 91177308-0d34-0410-b5e6-96231b3b80d8
2007-11-06 21:12:10 +00:00
Duncan Sands
91508a490b At the point of calculating the shift amount, the
type of SV has changed from what it originally was.
However we need the store width of the original.


git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@43775 91177308-0d34-0410-b5e6-96231b3b80d8
2007-11-06 20:39:11 +00:00
Ted Kremenek
730c273d42 Renamed "Flush()" to "FlushRecord()".
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@43772 91177308-0d34-0410-b5e6-96231b3b80d8
2007-11-06 19:49:50 +00:00
Ted Kremenek
26e25b3bf0 Added support for processing abbreviations in the Deserializer.
Added some #ifdef-controlled messages for debugging backpatching.


git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@43771 91177308-0d34-0410-b5e6-96231b3b80d8
2007-11-06 19:49:16 +00:00
Evan Cheng
8fc9a10221 First step towards moving the coalescer to priority_queue based machinery.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@43764 91177308-0d34-0410-b5e6-96231b3b80d8
2007-11-06 08:52:21 +00:00
Evan Cheng
ab84724297 Fix a bug where a def use operand isn't being detected as a sub-register use.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@43763 91177308-0d34-0410-b5e6-96231b3b80d8
2007-11-06 08:50:44 +00:00
Evan Cheng
1fd15ba961 Add pseudo dependency to force two-address instruction to be scheduled after
other uses. There was a overly restricted check that prevented some obvious
cases.


git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@43762 91177308-0d34-0410-b5e6-96231b3b80d8
2007-11-06 08:44:59 +00:00
Chris Lattner
9907cb12ae Fix PR1774 and BasicAA/2007-11-05-SizeCrash.ll
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@43756 91177308-0d34-0410-b5e6-96231b3b80d8
2007-11-06 05:58:42 +00:00
Owen Anderson
8b96b9fce0 Add a few comments.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@43755 91177308-0d34-0410-b5e6-96231b3b80d8
2007-11-06 05:26:02 +00:00
Owen Anderson
ee49b5385b DomForest is a forest of registers, not instructions.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@43754 91177308-0d34-0410-b5e6-96231b3b80d8
2007-11-06 05:22:43 +00:00
Owen Anderson
a4ad2e740a StrongPHIElimination requires LiveVariables.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@43751 91177308-0d34-0410-b5e6-96231b3b80d8
2007-11-06 04:49:43 +00:00
Bruno Cardoso Lopes
000604afd4 Better processor definition
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@43749 91177308-0d34-0410-b5e6-96231b3b80d8
2007-11-06 03:15:20 +00:00
Chris Lattner
bde90f0fc1 wrap long lines
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@43745 91177308-0d34-0410-b5e6-96231b3b80d8
2007-11-06 01:15:27 +00:00
Dan Gohman
80176319f3 Add support for vector remainder operations.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@43744 91177308-0d34-0410-b5e6-96231b3b80d8
2007-11-05 23:35:22 +00:00
Dan Gohman
cff550995b Fix an abort in instcombine when folding creates a vector rem instruction.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@43743 91177308-0d34-0410-b5e6-96231b3b80d8
2007-11-05 23:16:33 +00:00
Rafael Espindola
f1ba1cad38 Move the LowerMEMCPY and LowerMEMCPYCall to a common place.
Thanks for the suggestions Bill :-)



git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@43742 91177308-0d34-0410-b5e6-96231b3b80d8
2007-11-05 23:12:20 +00:00
Ted Kremenek
0a6d98e10e Added support in serializer and deserializer to create arbitrary blocks.
Added detection of end-of-stream in deserializer.


git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@43736 91177308-0d34-0410-b5e6-96231b3b80d8
2007-11-05 21:36:35 +00:00
Dale Johannesen
eb57ea7ea2 Make labels work in asm blocks; allow labels as
parameters.  Rename ValueRefList to ParamList
in AsmParser, since its only use is for parameters.



git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@43734 91177308-0d34-0410-b5e6-96231b3b80d8
2007-11-05 21:20:28 +00:00
Ted Kremenek
14ac17e2df Added default creation of root-level block by bitstream serializer.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@43732 91177308-0d34-0410-b5e6-96231b3b80d8
2007-11-05 20:47:27 +00:00
Devang Patel
5d01aa484f If a value is incoming from outside the loop then the value does not need remapping and the value is never tracked through LastValueMap.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@43728 91177308-0d34-0410-b5e6-96231b3b80d8
2007-11-05 19:32:30 +00:00
Lauro Ramos Venancio
8699a97a2e [ARM] Fix code generation for:
static __thread struct {
    int a;
    int b;
} teste = {0, 0};



git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@43722 91177308-0d34-0410-b5e6-96231b3b80d8
2007-11-05 18:33:37 +00:00