1
0
mirror of https://github.com/RPCS3/llvm-mirror.git synced 2024-10-20 19:42:54 +02:00
Commit Graph

27714 Commits

Author SHA1 Message Date
Chris Lattner
601a4d8c70 move a large method out of line.
llvm-svn: 67892
2009-03-28 02:08:47 +00:00
Dan Gohman
b360b0390a Fix what surely must be a copy+pasto.
llvm-svn: 67881
2009-03-27 23:55:04 +00:00
Dan Gohman
401df03e2d Initialize LiveOutInfo's APInt members to zero, as APInt's
default constructor produces an uninitialized APInt.
This fixes PR3896.

llvm-svn: 67879
2009-03-27 23:51:02 +00:00
Jim Grosbach
93b0fc3ba8 remove trailing whitespace
llvm-svn: 67874
2009-03-27 23:06:27 +00:00
Gabor Greif
b61a9d41b9 "ghostify" the ilist<Function> sentinel
llvm-svn: 67872
2009-03-27 22:28:33 +00:00
Rafael Espindola
83ee99d7b0 Avoid hardcoding that X86 addresses have 4 operands.
llvm-svn: 67848
2009-03-27 15:57:50 +00:00
Rafael Espindola
7c113e5354 Use less hard coded constants to make the code less brittle.
llvm-svn: 67846
2009-03-27 15:45:05 +00:00
Rafael Espindola
38604d9598 I am trying to add a segment to the X86 addresses matching to
improve TLS support (see http://lists.cs.uiuc.edu/pipermail/llvm-commits/Week-of-Mon-20090309/075220.html), but that code is VERY brittle.

This patch just makes it a bit more resistant.

llvm-svn: 67843
2009-03-27 15:26:30 +00:00
Duncan Sands
e13276db7f Revert r67798: it breaks llvm-gcc bootstrap on x86-64-linux, presumably due to
a miscompilation.

make[4]: Entering directory `gcc-4.2.llvm-objects/x86_64-unknown-linux-gnu/libstdc++-v3/include'
if [ ! -d "./x86_64-unknown-linux-gnu/bits/stdtr1c++.h.gch" ]; then \
          mkdir -p ./x86_64-unknown-linux-gnu/bits/stdtr1c++.h.gch; \
        fi; \
        gcc-4.2.llvm-objects/./gcc/xgcc -shared-libgcc -Bgcc-4.2.llvm-objects/./gcc -nostdinc++ 
-Lgcc-4.2.llvm-objects/x86_64-unknown-linux-gnu/libstdc++-v3/src -Lgcc-4.2.llvm-objects/x86_64-unknown-linux-gnu/libstdc++-v3/src/.libs 
-B/usr/local/gnat-llvm/x86_64-unknown-linux-gnu/bin/ -B/usr/local/gnat-llvm/x86_64-unknown-linux-gnu/lib/ -isystem 
/usr/local/gnat-llvm/x86_64-unknown-linux-gnu/include -isystem /usr/local/gnat-llvm/x86_64-unknown-linux-gnu/sys-include -Winvalid-pch -Wno-deprecated -x 
c++-header -g -O2  -D_GNU_SOURCE -Igcc-4.2.llvm-objects/x86_64-unknown-linux-gnu/libstdc++-v3/include/x86_64-unknown-linux-gnu 
-Igcc-4.2.llvm-objects/x86_64-unknown-linux-gnu/libstdc++-v3/include -Igcc-4.2.llvm/libstdc++-v3/libsupc++ -O2 -g 
gcc-4.2.llvm/libstdc++-v3/include/precompiled/stdtr1c++.h -o x86_64-unknown-linux-gnu/bits/stdtr1c++.h.gch/O2g.gch
In file included from gcc-4.2.llvm-objects/x86_64-unknown-linux-gnu/libstdc++-v3/include/tr1/repeat.h:247,
                 from gcc-4.2.llvm-objects/x86_64-unknown-linux-gnu/libstdc++-v3/include/tr1/functional:1098,
                 from gcc-4.2.llvm/libstdc++-v3/include/precompiled/stdtr1c++.h:53:
gcc-4.2.llvm-objects/x86_64-unknown-linux-gnu/libstdc++-v3/include/tr1/functional_iterate.h:417: internal compiler error: in ggc_recalculate_in_use_p, at 
ggc-page.c:1602
Please submit a full bug report,
with preprocessed source if appropriate.
See <URL:http://llvm.org/bugs/> for instructions.
make[4]: *** [x86_64-unknown-linux-gnu/bits/stdtr1c++.h.gch/O2g.gch] Error 1

llvm-svn: 67839
2009-03-27 14:56:47 +00:00
Mikhail Glushenkov
b768a08651 -write-graph now can be used with -o.
Makes it possible to set the output file name.

llvm-svn: 67835
2009-03-27 12:57:14 +00:00
John Mosby
67ffa789e8 Shrink wrapping in PEI: initial release. Finishing development, enable with --shrink-wrap.
llvm-svn: 67828
2009-03-27 06:09:40 +00:00
Dale Johannesen
9fd8bb432f One more place to skip debug info.
llvm-svn: 67811
2009-03-27 01:13:37 +00:00
Devang Patel
a2211c26d7 While hoisting an instruction, update alias info set tracker.
llvm-svn: 67798
2009-03-26 23:48:52 +00:00
Evan Cheng
ab6e38c88d -no-implicit-float means explicit fp operations are legal.
llvm-svn: 67784
2009-03-26 23:06:32 +00:00
Mikhail Glushenkov
dd06b10f0b Fix misc. small issues with debug visualization.
Detailed bug report:
http://llvm.org/bugs/show_bug.cgi?id=3873

llvm-svn: 67768
2009-03-26 21:23:48 +00:00
Evan Cheng
1343fa32dc tADDhirr is a thumb instruction. Do not allow this code to be reached in non-thumb mode.
llvm-svn: 67765
2009-03-26 19:09:01 +00:00
Owen Anderson
2312267684 Don't assign a new stack slot if the pre-alloc splitter already assigned one.
llvm-svn: 67764
2009-03-26 18:53:38 +00:00
Bill Wendling
f4247ff478 Pull transform from target-dependent code into target-independent code.
llvm-svn: 67742
2009-03-26 06:14:09 +00:00
Chris Lattner
cefed33f04 fix warning in -asserts mode.
llvm-svn: 67739
2009-03-26 05:29:34 +00:00
Chris Lattner
fd5356e4a9 fix some warnings in release-asserts mode.
llvm-svn: 67738
2009-03-26 05:28:26 +00:00
Chris Lattner
4f992250bf fix an apparently real bug exposed by a warning in -asserts mode.
llvm-svn: 67737
2009-03-26 05:28:14 +00:00
Chris Lattner
fc26089eb4 fix warning in -asserts build.
llvm-svn: 67736
2009-03-26 05:25:59 +00:00
Bill Wendling
f79eccc675 Match this pattern so that we can generate simpler code:
%a = ...
  %b = and i32 %a, 2
  %c = srl i32 %b, 1
  %d = br i32 %c, 

into

  %a = ...
  %b = and %a, 2
  %c = X86ISD::CMP %b, 0
  %d = X86ISD::BRCOND %c ...

This applies only when the AND constant value has one bit set and the SRL
constant is equal to the log2 of the AND constant. The back-end is smart enough
to convert the result into a TEST/JMP sequence.

llvm-svn: 67728
2009-03-26 01:47:50 +00:00
Bill Wendling
40ac545f38 Doxygen-ify comments.
llvm-svn: 67727
2009-03-26 01:46:56 +00:00
Dale Johannesen
03cedf1d8b Skip debug info one more place. (This one gets
called from llc, not opt, but it's an IR level
optimization nevertheless.)

llvm-svn: 67724
2009-03-26 01:15:07 +00:00
Devang Patel
8c31ea5290 Before deleting a basic block, give other loop passes a chance cleanup analysis values, related to the instructions in the basic block.
llvm-svn: 67719
2009-03-25 23:57:48 +00:00
Evan Cheng
7e4217176a Revert 67132. This is breaking some objective-c apps.
Also fixes SDISel so it *does not* force promote return value if the function is not marked signext / zeroext.

llvm-svn: 67701
2009-03-25 20:20:11 +00:00
Dale Johannesen
9fb1dcd077 When optimizing with debug info, don't keep the
stoppoint nodes around until Legalize; doing this
imposed an ordering on a sequence of loads that
came from different lines, interfering with scheduling.

llvm-svn: 67692
2009-03-25 17:36:08 +00:00
Chris Lattner
e7eed82209 Fix a bug in our autoupgrade support: in an argument list to a function
call, we should treat "i64 zext" as the start of a constant expr, but
"i64 0 zext" as an argument with an obsolete attribute on it (this form
is already tested by test/Assembler/2007-07-30-AutoUpgradeZextSext.ll).

Make the autoupgrade logic more discerning to avoid treating "i64 zext"
as an old-style attribute, causing us to reject a valid constant expr.
This fixes PR3876.

llvm-svn: 67682
2009-03-25 06:36:36 +00:00
Gabor Greif
9ac00d10ea do not rely on callee being operand 0
llvm-svn: 67681
2009-03-25 06:32:59 +00:00
Devang Patel
65314415af Do not ignore DW_TAG_class_type!
llvm-svn: 67675
2009-03-25 03:52:06 +00:00
Evan Cheng
3a7489a4cc CodeGen still defaults to non-verbose asm, but llc now overrides it and default to verbose.
llvm-svn: 67668
2009-03-25 01:47:28 +00:00
Evan Cheng
6ff8cea903 Don't print global names twice with -asm-verbose.
llvm-svn: 67667
2009-03-25 01:08:42 +00:00
Chris Lattner
c055403764 Fix PR3874 by restoring a condition I removed, but making it more
precise than it used to be.

llvm-svn: 67662
2009-03-25 00:28:58 +00:00
Devang Patel
225831fc9e Do not ignore DW_TAG_class_type!
llvm-svn: 67661
2009-03-25 00:28:40 +00:00
Chris Lattner
be6ee56fb2 oops, I intended to remove this, not comment it out. Thanks Duncan!
llvm-svn: 67657
2009-03-24 23:48:25 +00:00
Evan Cheng
758c95f07a Fix PR3845: Avoid stale MachineInstruction pointer reference.
llvm-svn: 67649
2009-03-24 20:33:17 +00:00
Gabor Greif
c988c96b3e simplify logic and get rid of the assumption that operand 0 is the callee
llvm-svn: 67642
2009-03-24 19:28:39 +00:00
Chris Lattner
aabd3eeeff canonicalize inttoptr and ptrtoint instructions which cast pointers
to/from integer types that are not intptr_t to convert to intptr_t
then do an integer conversion to the dest type.  This exposes the
cast to the optimizer.

llvm-svn: 67638
2009-03-24 18:35:40 +00:00
Dale Johannesen
17dddcd886 fix one more fp80 case (used only by Interpreter)
and streamline code here a bit.

llvm-svn: 67636
2009-03-24 18:16:17 +00:00
Chris Lattner
51a4134e1c two changes:
1. Make instcombine always canonicalize trunc x to i1 into an icmp(x&1).  This 
   exposes the AND to other instcombine xforms and is more of what the code
   generator expects.
2. Rewrite the remaining trunc pattern match to use 'match', which 
   simplifies it a lot.
   

llvm-svn: 67635
2009-03-24 18:15:30 +00:00
Dale Johannesen
68e30cdf59 Change JIT for different layout of fp80.
llvm-svn: 67629
2009-03-24 17:35:45 +00:00
Chris Lattner
135eeefe66 more tidying: name the components of PhysReg in the case when
the target constraint specifies a specific physreg.

llvm-svn: 67618
2009-03-24 15:27:37 +00:00
Chris Lattner
8793e812ef Tidy a bit more.
llvm-svn: 67617
2009-03-24 15:25:07 +00:00
Chris Lattner
a60dd19c3e simplify this code a bit now that "allocation to a vreg class" can never
fail.

llvm-svn: 67616
2009-03-24 15:22:11 +00:00
Dan Gohman
7a9e8cbf79 I was convinced that it's ok to allow a second i8 return value
to be returned in DL. LLVM's multiple-return-value support is
not ABI-conforming; front-ends that wish to have code emitted
that conforms to an ABI are currently expected to make
arrangements for this on their own rather than assuming that
multiple-return-values will automatically do the right thing.
This commit doesn't fundamentally change this situation.

llvm-svn: 67588
2009-03-24 01:04:34 +00:00
Dan Gohman
547cfc882e Minor compile-time optimization; don't bother checking
canClobberPhysRegDefs if the successor node doesn't
clobber any physical registers.

llvm-svn: 67587
2009-03-24 00:50:07 +00:00
Dan Gohman
e6d7478bc1 Add a pre-pass to the burr-list scheduler which makes adjustments to
help out the register pressure reduction heuristics in the case of
nodes with multiple uses. Currently this uses very conservative
heuristics, so it doesn't have a broad impact, but in cases where it
does help it can make a big difference.

llvm-svn: 67586
2009-03-24 00:49:12 +00:00
Evan Cheng
b3196f1298 Do not emit comments unless -asm-verbose.
llvm-svn: 67580
2009-03-24 00:17:40 +00:00
Dale Johannesen
0f8e2bcd98 Use a SmallPtrSet instead of std::set.
llvm-svn: 67578
2009-03-23 23:39:20 +00:00