Nick Lewycky [Sat, 1 Mar 2008 17:20:55 +0000 (17:20 +0000)]
Print the name, not a pointer.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@47796
91177308-0d34-0410-b5e6-
96231b3b80d8
Andrew Lenharth [Sat, 1 Mar 2008 13:37:02 +0000 (13:37 +0000)]
Add lock prefix support to x86. Also add the instructions necessary for the atomic ops. They are still marked pseudo, since I cannot figure out what format to use, but they are the correct opcode.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@47795
91177308-0d34-0410-b5e6-
96231b3b80d8
Tanya Lattner [Sat, 1 Mar 2008 09:15:35 +0000 (09:15 +0000)]
Remove llvm-upgrade and update test cases.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@47793
91177308-0d34-0410-b5e6-
96231b3b80d8
Chris Lattner [Sat, 1 Mar 2008 09:01:57 +0000 (09:01 +0000)]
Fix PR2113 by verifying allocations.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@47792
91177308-0d34-0410-b5e6-
96231b3b80d8
Chris Lattner [Sat, 1 Mar 2008 09:00:21 +0000 (09:00 +0000)]
Fix this test.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@47791
91177308-0d34-0410-b5e6-
96231b3b80d8
Chris Lattner [Sat, 1 Mar 2008 08:09:51 +0000 (08:09 +0000)]
allow specified inline threshold to be negative, as the value is
itself sometimes negative.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@47786
91177308-0d34-0410-b5e6-
96231b3b80d8
Tanya Lattner [Sat, 1 Mar 2008 07:38:40 +0000 (07:38 +0000)]
Remove llvm-upgrade and update tests.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@47784
91177308-0d34-0410-b5e6-
96231b3b80d8
Tanya Lattner [Sat, 1 Mar 2008 07:36:30 +0000 (07:36 +0000)]
Disable lto because its broken on tiger.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@47783
91177308-0d34-0410-b5e6-
96231b3b80d8
Dale Johannesen [Sat, 1 Mar 2008 03:40:57 +0000 (03:40 +0000)]
Add MVT::is128BitVector and is64BitVector. Shrink
unaligned load/store code using them. Per review
of unaligned load/store vector patch.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@47782
91177308-0d34-0410-b5e6-
96231b3b80d8
Evan Cheng [Sat, 1 Mar 2008 00:39:47 +0000 (00:39 +0000)]
Refactor / clean up code; remove td list scheduler special tie breaker (no real benefit).
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@47779
91177308-0d34-0410-b5e6-
96231b3b80d8
Devang Patel [Fri, 29 Feb 2008 23:41:13 +0000 (23:41 +0000)]
Fix cut-n-pasto.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@47777
91177308-0d34-0410-b5e6-
96231b3b80d8
Devang Patel [Fri, 29 Feb 2008 23:34:08 +0000 (23:34 +0000)]
Add pass to promote sret.
This pass transforms
%struct._Point = type { i32, i32, i32, i32, i32, i32 }
define internal void @foo(%struct._Point* sret %agg.result)
into
%struct._Point = type { i32, i32, i32, i32, i32, i32 }
define internal %struct._Point @foo()
This pass updates foo() clients appropriately to use
getresult instruction to extract return values.
This pass is not yet ready for prime time.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@47776
91177308-0d34-0410-b5e6-
96231b3b80d8
Anton Korobeynikov [Fri, 29 Feb 2008 22:09:08 +0000 (22:09 +0000)]
Use enumeration for preffered EH dwarf encoding reason
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@47770
91177308-0d34-0410-b5e6-
96231b3b80d8
Evan Cheng [Fri, 29 Feb 2008 19:36:59 +0000 (19:36 +0000)]
Don't fill eh frames even though these are text sections.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@47765
91177308-0d34-0410-b5e6-
96231b3b80d8
Nick Kledzik [Fri, 29 Feb 2008 19:34:52 +0000 (19:34 +0000)]
update to document new lto API
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@47764
91177308-0d34-0410-b5e6-
96231b3b80d8
Nick Kledzik [Fri, 29 Feb 2008 19:32:13 +0000 (19:32 +0000)]
install new lto dylib. pass down LLVM_SUBMIT_VERSION
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@47763
91177308-0d34-0410-b5e6-
96231b3b80d8
Nick Kledzik [Fri, 29 Feb 2008 19:31:29 +0000 (19:31 +0000)]
stop building lto on all platforms. Start building lto2 on Darwin
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@47762
91177308-0d34-0410-b5e6-
96231b3b80d8
Nick Kledzik [Fri, 29 Feb 2008 19:30:23 +0000 (19:30 +0000)]
fix default RC_ProjectSourceSubversion to be zero
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@47761
91177308-0d34-0410-b5e6-
96231b3b80d8
Bill Wendling [Fri, 29 Feb 2008 19:28:11 +0000 (19:28 +0000)]
DCE'ed this testcase.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@47760
91177308-0d34-0410-b5e6-
96231b3b80d8
Bill Wendling [Fri, 29 Feb 2008 18:52:01 +0000 (18:52 +0000)]
If we reload a virtual register that's already been assigned, we want to mark
that instruction as its "last use". This fixes PR1925.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@47758
91177308-0d34-0410-b5e6-
96231b3b80d8
Evan Cheng [Fri, 29 Feb 2008 17:52:15 +0000 (17:52 +0000)]
Fix PR2112: don't run loop aligner if target doesn't have a TargetLowering object.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@47755
91177308-0d34-0410-b5e6-
96231b3b80d8
Chris Lattner [Fri, 29 Feb 2008 07:12:06 +0000 (07:12 +0000)]
fix a bug Anders ran into where scalarrepl would crash when promoting
a union containing a vector and an array whose elements were smaller than
the vector elements. this means we need to compile the load of the
array elements into an extract element plus a truncate.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@47752
91177308-0d34-0410-b5e6-
96231b3b80d8
Chris Lattner [Fri, 29 Feb 2008 07:03:13 +0000 (07:03 +0000)]
Refactor some code out of ConvertUsesToScalar into their own methods, no
functionality change.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@47751
91177308-0d34-0410-b5e6-
96231b3b80d8
Chris Lattner [Fri, 29 Feb 2008 06:09:11 +0000 (06:09 +0000)]
Folding or(fcmp,fcmp) only works if the operands of the fcmps are the same fp type.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@47750
91177308-0d34-0410-b5e6-
96231b3b80d8
Evan Cheng [Fri, 29 Feb 2008 02:50:03 +0000 (02:50 +0000)]
No need for coalescer to update kills. Only copies are coalesced and those instructions will be deleted. Doh.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@47749
91177308-0d34-0410-b5e6-
96231b3b80d8
Evan Cheng [Fri, 29 Feb 2008 02:49:15 +0000 (02:49 +0000)]
Remove redundant #include.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@47748
91177308-0d34-0410-b5e6-
96231b3b80d8
Nick Kledzik [Fri, 29 Feb 2008 02:01:34 +0000 (02:01 +0000)]
also pass -compatibility_version when linking shared object for Darwin
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@47747
91177308-0d34-0410-b5e6-
96231b3b80d8
Dan Gohman [Fri, 29 Feb 2008 01:47:35 +0000 (01:47 +0000)]
More APInt-ification.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@47746
91177308-0d34-0410-b5e6-
96231b3b80d8
Dan Gohman [Fri, 29 Feb 2008 01:44:25 +0000 (01:44 +0000)]
Use the new convertFromAPInt instead of convertFromZeroExtendedInteger,
which allows more of the surrounding arithmetic to be done with APInt
instead of uint64_t.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@47745
91177308-0d34-0410-b5e6-
96231b3b80d8
Dan Gohman [Fri, 29 Feb 2008 01:42:52 +0000 (01:42 +0000)]
Use the new convertFromAPInt instead of convertFromZeroExtendedInteger.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@47744
91177308-0d34-0410-b5e6-
96231b3b80d8
Dan Gohman [Fri, 29 Feb 2008 01:41:59 +0000 (01:41 +0000)]
Use the new APInt-enabled form of getConstant instead of converting
an APInt into a uint64_t to call getConstant.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@47742
91177308-0d34-0410-b5e6-
96231b3b80d8
Dan Gohman [Fri, 29 Feb 2008 01:40:47 +0000 (01:40 +0000)]
Add support to APInt for shift and rotate operations with APInt
instead of uint32_t for the shift/rotate count operand type.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@47741
91177308-0d34-0410-b5e6-
96231b3b80d8
Anders Carlsson [Fri, 29 Feb 2008 01:35:12 +0000 (01:35 +0000)]
Use the correct instruction encodings for the 64-bit MMX movd.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@47740
91177308-0d34-0410-b5e6-
96231b3b80d8
Dan Gohman [Fri, 29 Feb 2008 01:27:13 +0000 (01:27 +0000)]
Simplify code using convertFromZeroExtendedInteger with an APInt
by using the new convertFromAPInt directly.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@47739
91177308-0d34-0410-b5e6-
96231b3b80d8
Dan Gohman [Fri, 29 Feb 2008 01:26:11 +0000 (01:26 +0000)]
Add a method to APFloat to convert directly from APInt.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@47738
91177308-0d34-0410-b5e6-
96231b3b80d8
Evan Cheng [Thu, 28 Feb 2008 23:29:57 +0000 (23:29 +0000)]
Added option -align-loops=<true/false> to disable loop aligner pass.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@47736
91177308-0d34-0410-b5e6-
96231b3b80d8
Lauro Ramos Venancio [Thu, 28 Feb 2008 23:13:15 +0000 (23:13 +0000)]
Update testcase.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@47735
91177308-0d34-0410-b5e6-
96231b3b80d8
Dale Johannesen [Thu, 28 Feb 2008 22:31:51 +0000 (22:31 +0000)]
Interface of getByValTypeAlignment differed between
generic & x86 versions; change generic to follow x86
and improve comments. Add PPC version (not right
for non-Darwin.)
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@47734
91177308-0d34-0410-b5e6-
96231b3b80d8
Andrew Lenharth [Thu, 28 Feb 2008 22:24:48 +0000 (22:24 +0000)]
Make llvm-ar behave like ar, if you create an empty archive, ar creates an empty archive. llvm-ar would not generate an output file in this case
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@47733
91177308-0d34-0410-b5e6-
96231b3b80d8
Lauro Ramos Venancio [Thu, 28 Feb 2008 22:14:09 +0000 (22:14 +0000)]
Initialize TextAlignFillValue. Fix revision 47703.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@47732
91177308-0d34-0410-b5e6-
96231b3b80d8
Lauro Ramos Venancio [Thu, 28 Feb 2008 20:26:04 +0000 (20:26 +0000)]
Avoid collisions in value names.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@47725
91177308-0d34-0410-b5e6-
96231b3b80d8
Gabor Greif [Thu, 28 Feb 2008 18:46:56 +0000 (18:46 +0000)]
Run 'svn info' in the C locale. Also appropriately escape spaces and ? for gawk in darwin.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@47723
91177308-0d34-0410-b5e6-
96231b3b80d8
Dale Johannesen [Thu, 28 Feb 2008 18:36:51 +0000 (18:36 +0000)]
Fix an assertion message.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@47722
91177308-0d34-0410-b5e6-
96231b3b80d8
Chris Lattner [Thu, 28 Feb 2008 17:21:27 +0000 (17:21 +0000)]
add a note
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@47720
91177308-0d34-0410-b5e6-
96231b3b80d8
Duncan Sands [Thu, 28 Feb 2008 17:12:11 +0000 (17:12 +0000)]
Document that the shuffle mask may contain undef
values.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@47719
91177308-0d34-0410-b5e6-
96231b3b80d8
Gabor Greif [Thu, 28 Feb 2008 14:58:14 +0000 (14:58 +0000)]
Simplify and clean up "update" target. Also
add an SVN-UPDATE-OPTIONS variable that controls
the update behaviour. This allows to go to a common
older revision of all svn directories:
gmake update SVN-UPDATE-OPTIONS=-r47717
would rewind both llvm and clang to a common
revision (if clang is checked out into the llvm
tree).
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@47717
91177308-0d34-0410-b5e6-
96231b3b80d8
Gabor Greif [Thu, 28 Feb 2008 13:06:50 +0000 (13:06 +0000)]
Now that targets are serialized, introduce
two new convenience targets:
- update: svn update toplevel and try hard
to locate updatable subdirectories
using cunning tricks
- happiness: update then build and test
so what one wants to do now is:
nice gmake --jobs happiness
Have fun!
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@47716
91177308-0d34-0410-b5e6-
96231b3b80d8
Gabor Greif [Thu, 28 Feb 2008 11:48:14 +0000 (11:48 +0000)]
Treat all targets serially at the toplevel. This allows
to specify
nice gmake --jobs all check
and go to lunch, while a multiprocessor machine
will build everything using spare resources
and check the result thereafter.
Since concurrency of make is not restricted
in subdirectories, this should be a nearly
optimal way to do it.
Also teach the user about a configure switch.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@47715
91177308-0d34-0410-b5e6-
96231b3b80d8
Gabor Greif [Thu, 28 Feb 2008 08:38:45 +0000 (08:38 +0000)]
Fix llvm.org/bugs/show_bug.cgi?id=2104 by ordering lexicographically what gets printed. Be const-correct in PrintResults and uninline it too
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@47712
91177308-0d34-0410-b5e6-
96231b3b80d8
Evan Cheng [Thu, 28 Feb 2008 07:46:38 +0000 (07:46 +0000)]
Set to default: x86 no longer fold and into test if it has more than one use.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@47711
91177308-0d34-0410-b5e6-
96231b3b80d8
Evan Cheng [Thu, 28 Feb 2008 07:40:24 +0000 (07:40 +0000)]
Keep track how many commutes are performed by the scheduler.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@47710
91177308-0d34-0410-b5e6-
96231b3b80d8
Chris Lattner [Thu, 28 Feb 2008 05:54:25 +0000 (05:54 +0000)]
Sparc backend doesn't support debug info yet, mark the nodes as expand. This fixes a crash on
test/DebugInfo/funccall.ll
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@47709
91177308-0d34-0410-b5e6-
96231b3b80d8
Chris Lattner [Thu, 28 Feb 2008 05:53:40 +0000 (05:53 +0000)]
implement expand for ISD::DECLARE by just deleting it.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@47708
91177308-0d34-0410-b5e6-
96231b3b80d8
Chris Lattner [Thu, 28 Feb 2008 05:48:04 +0000 (05:48 +0000)]
Fix CodeGen/Generic/storetrunc-fp.ll on sparc, PR2105
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@47707
91177308-0d34-0410-b5e6-
96231b3b80d8
Chris Lattner [Thu, 28 Feb 2008 05:44:20 +0000 (05:44 +0000)]
fix CodeGen/Generic/2008-01-25-dag-combine-mul.ll on sparc, PR2105
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@47706
91177308-0d34-0410-b5e6-
96231b3b80d8
Chris Lattner [Thu, 28 Feb 2008 05:34:27 +0000 (05:34 +0000)]
target-indep codegen memcpy lowering issue.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@47705
91177308-0d34-0410-b5e6-
96231b3b80d8
Chris Lattner [Thu, 28 Feb 2008 04:52:59 +0000 (04:52 +0000)]
Add a random not very important note
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@47704
91177308-0d34-0410-b5e6-
96231b3b80d8
Evan Cheng [Thu, 28 Feb 2008 00:43:03 +0000 (00:43 +0000)]
Add a quick and dirty "loop aligner pass". x86 uses it to align its loops to 16-byte boundaries.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@47703
91177308-0d34-0410-b5e6-
96231b3b80d8
Eli Friedman [Thu, 28 Feb 2008 00:21:43 +0000 (00:21 +0000)]
A few more small things I've run into.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@47702
91177308-0d34-0410-b5e6-
96231b3b80d8
Anton Korobeynikov [Wed, 27 Feb 2008 23:49:15 +0000 (23:49 +0000)]
EHPreferredDataFormat hook for PPC targets. Looks like Darwin
uses the same encoding everywhere. Linux FIXME'ed.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@47701
91177308-0d34-0410-b5e6-
96231b3b80d8
Devang Patel [Wed, 27 Feb 2008 23:33:51 +0000 (23:33 +0000)]
Remove dead code.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@47700
91177308-0d34-0410-b5e6-
96231b3b80d8
Anton Korobeynikov [Wed, 27 Feb 2008 23:33:50 +0000 (23:33 +0000)]
Preparation step for some cleanup/generalization in EH information emission:
provide TAI hook for selection of EH data emission format. Currently unused.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@47699
91177308-0d34-0410-b5e6-
96231b3b80d8
Dale Johannesen [Wed, 27 Feb 2008 23:14:50 +0000 (23:14 +0000)]
New test for misaligned Altivec laod/store.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@47698
91177308-0d34-0410-b5e6-
96231b3b80d8
Anton Korobeynikov [Wed, 27 Feb 2008 22:37:28 +0000 (22:37 +0000)]
Assert on invalid PHINode::addIncoming() arguments. Patch by Erick Tryzelaar!
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@47697
91177308-0d34-0410-b5e6-
96231b3b80d8
Dale Johannesen [Wed, 27 Feb 2008 22:36:00 +0000 (22:36 +0000)]
Handle load/store of misaligned vectors that are the
same size as an int type by doing a bitconvert of
load/store of the int type (same algorithm as floating point).
This makes them work for ppc Altivec. There was some
code that purported to handle loads of (some) vectors
by splitting them into two smaller vectors, but getExtLoad
rejects subvector loads, so this could never have worked;
the patch removes it.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@47696
91177308-0d34-0410-b5e6-
96231b3b80d8
Nick Kledzik [Wed, 27 Feb 2008 22:25:36 +0000 (22:25 +0000)]
fixes from review of first commit
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@47695
91177308-0d34-0410-b5e6-
96231b3b80d8
Nick Kledzik [Wed, 27 Feb 2008 22:23:46 +0000 (22:23 +0000)]
use PROJ_SRC_DIR so this builds with Apple style builds
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@47694
91177308-0d34-0410-b5e6-
96231b3b80d8
Dan Gohman [Wed, 27 Feb 2008 21:12:32 +0000 (21:12 +0000)]
Don't hard-code the mask size to be 32, which is incorrect on ppc64
and was causing aborts with the new APInt changes. This may also be
fixing an obscure ppc64 bug.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@47692
91177308-0d34-0410-b5e6-
96231b3b80d8
Evan Cheng [Wed, 27 Feb 2008 20:26:32 +0000 (20:26 +0000)]
This is done.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@47688
91177308-0d34-0410-b5e6-
96231b3b80d8
Evan Cheng [Wed, 27 Feb 2008 19:57:11 +0000 (19:57 +0000)]
Fix a bug in dead spill slot elimination.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@47687
91177308-0d34-0410-b5e6-
96231b3b80d8
Dan Gohman [Wed, 27 Feb 2008 19:44:57 +0000 (19:44 +0000)]
Remove the `else', at Evan's insistence.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@47686
91177308-0d34-0410-b5e6-
96231b3b80d8
Dan Gohman [Wed, 27 Feb 2008 18:38:29 +0000 (18:38 +0000)]
Add -analyze support to postdomtree.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@47680
91177308-0d34-0410-b5e6-
96231b3b80d8
Chris Lattner [Wed, 27 Feb 2008 17:46:54 +0000 (17:46 +0000)]
actually run llc, thanks Dan :)
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@47677
91177308-0d34-0410-b5e6-
96231b3b80d8
Duncan Sands [Wed, 27 Feb 2008 17:39:13 +0000 (17:39 +0000)]
Add a FIXME about the VECTOR_SHUFFLE evil hack.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@47676
91177308-0d34-0410-b5e6-
96231b3b80d8
Lauro Ramos Venancio [Wed, 27 Feb 2008 17:20:32 +0000 (17:20 +0000)]
Emit an error when a library is not found. It is the GNU ld behavior and it is expected by the configure scripts.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@47674
91177308-0d34-0410-b5e6-
96231b3b80d8
Duncan Sands [Wed, 27 Feb 2008 13:34:40 +0000 (13:34 +0000)]
LegalizeTypes support for EXTRACT_VECTOR_ELT. The
approach taken is different to that in LegalizeDAG
when it is a question of expanding or promoting the
result type: for example, if extracting an i64 from
a <2 x i64>, when i64 needs expanding, it bitcasts
the vector to <4 x i32>, extracts the appropriate
two i32's, and uses those for the Lo and Hi parts.
Likewise, when extracting an i16 from a <4 x i16>,
and i16 needs promoting, it bitcasts the vector to
<2 x i32>, extracts the appropriate i32, twiddles
the bits if necessary, and uses that as the promoted
value. This puts more pressure on bitcast legalization,
and I've added the appropriate cases. They needed to
be added anyway since users can generate such bitcasts
too if they want to. Also, when considering various
cases (Legal, Promote, Expand, Scalarize, Split) it is
a pain that expand can correspond to Expand, Scalarize
or Split, so I've changed the LegalizeTypes enum so it
lists those different cases - now Expand only means
splitting a scalar in two.
The code produced is the same as by LegalizeDAG for
all relevant testcases, except for
2007-10-31-extractelement-i64.ll, where the code seems
to have improved (see below; can an expert please tell
me if it is better or not).
Before < vs after >.
< subl $92, %esp
< movaps %xmm0, 64(%esp)
< movaps %xmm0, (%esp)
< movl 4(%esp), %eax
< movl %eax, 28(%esp)
< movl (%esp), %eax
< movl %eax, 24(%esp)
< movq 24(%esp), %mm0
< movq %mm0, 56(%esp)
---
> subl $44, %esp
> movaps %xmm0, 16(%esp)
> pshufd $1, %xmm0, %xmm1
> movd %xmm1, 4(%esp)
> movd %xmm0, (%esp)
> movq (%esp), %mm0
> movq %mm0, 8(%esp)
< subl $92, %esp
< movaps %xmm0, 64(%esp)
< movaps %xmm0, (%esp)
< movl 12(%esp), %eax
< movl %eax, 28(%esp)
< movl 8(%esp), %eax
< movl %eax, 24(%esp)
< movq 24(%esp), %mm0
< movq %mm0, 56(%esp)
---
> subl $44, %esp
> movaps %xmm0, 16(%esp)
> pshufd $3, %xmm0, %xmm1
> movd %xmm1, 4(%esp)
> movhlps %xmm0, %xmm0
> movd %xmm0, (%esp)
> movq (%esp), %mm0
> movq %mm0, 8(%esp)
< subl $92, %esp
< movaps %xmm0, 64(%esp)
---
> subl $44, %esp
< movl 16(%esp), %eax
< movl %eax, 48(%esp)
< movl 20(%esp), %eax
< movl %eax, 52(%esp)
< movaps %xmm0, (%esp)
< movl 4(%esp), %eax
< movl %eax, 60(%esp)
< movl (%esp), %eax
< movl %eax, 56(%esp)
---
> pshufd $1, %xmm0, %xmm1
> movd %xmm1, 4(%esp)
> movd %xmm0, (%esp)
> movd %xmm1, 12(%esp)
> movd %xmm0, 8(%esp)
< subl $92, %esp
< movaps %xmm0, 64(%esp)
---
> subl $44, %esp
< movl 24(%esp), %eax
< movl %eax, 48(%esp)
< movl 28(%esp), %eax
< movl %eax, 52(%esp)
< movaps %xmm0, (%esp)
< movl 12(%esp), %eax
< movl %eax, 60(%esp)
< movl 8(%esp), %eax
< movl %eax, 56(%esp)
---
> pshufd $3, %xmm0, %xmm1
> movd %xmm1, 4(%esp)
> movhlps %xmm0, %xmm0
> movd %xmm0, (%esp)
> movd %xmm1, 12(%esp)
> movd %xmm0, 8(%esp)
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@47672
91177308-0d34-0410-b5e6-
96231b3b80d8
Gabor Greif [Wed, 27 Feb 2008 13:34:15 +0000 (13:34 +0000)]
Remove inappropriate whitespace, change CVS to SVN where it makes sense.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@47671
91177308-0d34-0410-b5e6-
96231b3b80d8
Duncan Sands [Wed, 27 Feb 2008 13:03:44 +0000 (13:03 +0000)]
LegalizeTypes support for legalizing the mask
operand of a VECTOR_SHUFFLE. The mask is a
vector of constant integers. The code in
LegalizeDAG doesn't bother to legalize the
mask, since it's basically just storage for
a bunch of constants, however LegalizeTypes
is more picky. The problem is that there may
not exist any legal vector-of-integers type
with a legal element type, so it is impossible
to create a legal mask! Unless of course you
cheat by creating a BUILD_VECTOR where the
operands have a different type to the element
type of the vector being built... This is
pretty ugly but works - all relevant tests in
the testsuite pass, and produce the same
assembler with and without LegalizeTypes.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@47670
91177308-0d34-0410-b5e6-
96231b3b80d8
Duncan Sands [Wed, 27 Feb 2008 10:18:23 +0000 (10:18 +0000)]
LegalizeTypes support for INSERT_VECTOR_ELT.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@47669
91177308-0d34-0410-b5e6-
96231b3b80d8
Evan Cheng [Wed, 27 Feb 2008 10:04:56 +0000 (10:04 +0000)]
Don't track max alignment during stack object allocations since they can be deleted later. Let PEI compute it.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@47668
91177308-0d34-0410-b5e6-
96231b3b80d8
Duncan Sands [Wed, 27 Feb 2008 08:53:44 +0000 (08:53 +0000)]
Support for legalizing MEMBARRIER.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@47667
91177308-0d34-0410-b5e6-
96231b3b80d8
Bill Wendling [Wed, 27 Feb 2008 06:33:05 +0000 (06:33 +0000)]
Final de-tabification.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@47663
91177308-0d34-0410-b5e6-
96231b3b80d8
Chris Lattner [Wed, 27 Feb 2008 06:17:10 +0000 (06:17 +0000)]
Add path separator support, patch by Sam Bishop.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@47662
91177308-0d34-0410-b5e6-
96231b3b80d8
Chris Lattner [Wed, 27 Feb 2008 05:57:41 +0000 (05:57 +0000)]
Make X86TargetLowering::LowerSINT_TO_FP return without creating a dead
stack slot and store if the SINT_TO_FP is actually legal. This allows
us to compile:
double a(double b) {return (unsigned)b;}
to:
_a:
cvttsd2siq %xmm0, %rax
movl %eax, %eax
cvtsi2sdq %rax, %xmm0
ret
instead of:
_a:
subq $8, %rsp
cvttsd2siq %xmm0, %rax
movl %eax, %eax
cvtsi2sdq %rax, %xmm0
addq $8, %rsp
ret
crazy.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@47660
91177308-0d34-0410-b5e6-
96231b3b80d8
Chris Lattner [Wed, 27 Feb 2008 05:48:44 +0000 (05:48 +0000)]
this code is correct but strange looking ;-)
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@47659
91177308-0d34-0410-b5e6-
96231b3b80d8
Chris Lattner [Wed, 27 Feb 2008 05:47:54 +0000 (05:47 +0000)]
Compile x86-64-and-mask.ll into:
_test:
movl %edi, %eax
ret
instead of:
_test:
movl $
4294967295, %ecx
movq %rdi, %rax
andq %rcx, %rax
ret
It would be great to write this as a Pat pattern that used subregs
instead of a 'pseudo' instruction, but I don't know how to do that
in td files.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@47658
91177308-0d34-0410-b5e6-
96231b3b80d8
Evan Cheng [Wed, 27 Feb 2008 03:04:06 +0000 (03:04 +0000)]
Spiller now remove unused spill slots.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@47657
91177308-0d34-0410-b5e6-
96231b3b80d8
Dan Gohman [Wed, 27 Feb 2008 01:52:30 +0000 (01:52 +0000)]
Teach Legalize how to expand an EXTRACT_ELEMENT.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@47656
91177308-0d34-0410-b5e6-
96231b3b80d8
Dan Gohman [Wed, 27 Feb 2008 01:23:58 +0000 (01:23 +0000)]
Convert the last remaining users of the non-APInt form of
ComputeMaskedBits to use the APInt form, and remove the
non-APInt form.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@47654
91177308-0d34-0410-b5e6-
96231b3b80d8
Devang Patel [Wed, 27 Feb 2008 01:20:54 +0000 (01:20 +0000)]
Add comment.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@47653
91177308-0d34-0410-b5e6-
96231b3b80d8
Chris Lattner [Wed, 27 Feb 2008 01:17:20 +0000 (01:17 +0000)]
add a note
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@47652
91177308-0d34-0410-b5e6-
96231b3b80d8
Dan Gohman [Wed, 27 Feb 2008 00:25:32 +0000 (00:25 +0000)]
Convert SimplifyDemandedMask and ShrinkDemandedConstant to use APInt.
Change several cases in SimplifyDemandedMask that don't ever do any
simplifying to reuse the logic in ComputeMaskedBits instead of
duplicating it.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@47648
91177308-0d34-0410-b5e6-
96231b3b80d8
Bill Wendling [Tue, 26 Feb 2008 23:22:40 +0000 (23:22 +0000)]
Upgrade testcase.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@47644
91177308-0d34-0410-b5e6-
96231b3b80d8
Devang Patel [Tue, 26 Feb 2008 23:19:08 +0000 (23:19 +0000)]
regenerate.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@47642
91177308-0d34-0410-b5e6-
96231b3b80d8
Devang Patel [Tue, 26 Feb 2008 23:17:50 +0000 (23:17 +0000)]
Add assert.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@47641
91177308-0d34-0410-b5e6-
96231b3b80d8
Owen Anderson [Tue, 26 Feb 2008 23:16:11 +0000 (23:16 +0000)]
Add PR number to testcase.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@47640
91177308-0d34-0410-b5e6-
96231b3b80d8
Owen Anderson [Tue, 26 Feb 2008 23:06:17 +0000 (23:06 +0000)]
Fix an issue where GVN had the sizes of the two memcpy's reverse, resulting
in an invalid transformation.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@47639
91177308-0d34-0410-b5e6-
96231b3b80d8
Devang Patel [Tue, 26 Feb 2008 22:55:21 +0000 (22:55 +0000)]
Add assert to check return type.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@47637
91177308-0d34-0410-b5e6-
96231b3b80d8
Arnold Schwaighofer [Tue, 26 Feb 2008 22:21:54 +0000 (22:21 +0000)]
Refactor according to Evan's and Anton's suggestions.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@47635
91177308-0d34-0410-b5e6-
96231b3b80d8
Devang Patel [Tue, 26 Feb 2008 22:17:48 +0000 (22:17 +0000)]
regenerate
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@47634
91177308-0d34-0410-b5e6-
96231b3b80d8