Dan Gohman
b6e8617481
Revert r136156, which broke several buildbots.
...
llvm-svn: 136206
2011-07-27 01:10:27 +00:00
Dan Gohman
709e6c8722
Delete unnecessarily cautious LastCALLSEQ code.
...
llvm-svn: 136156
2011-07-26 22:00:59 +00:00
Chris Lattner
e1fe7061ce
land David Blaikie's patch to de-constify Type, with a few tweaks.
...
llvm-svn: 135375
2011-07-18 04:54:35 +00:00
Dan Gohman
8e056f4a49
LegalizeDAG doesn't need its own copy of this enum.
...
llvm-svn: 135320
2011-07-15 22:51:43 +00:00
Dan Gohman
a44add3a49
Delete LegalizeDAG's own version of isTypeLegal and getTypeAction
...
and just use the ones from TargetLowering directly.
llvm-svn: 135318
2011-07-15 22:39:09 +00:00
Dan Gohman
f41cbc8222
Delete an unused variable and a redundant assert.
...
llvm-svn: 135311
2011-07-15 22:19:02 +00:00
Dan Gohman
038295aff9
Modernize comments.
...
llvm-svn: 135305
2011-07-15 21:42:20 +00:00
Cameron Zwarich
c23366d357
Add an intrinsic and codegen support for fused multiply-accumulate. The intent
...
is to use this for architectures that have a native FMA instruction.
llvm-svn: 134742
2011-07-08 21:39:21 +00:00
Nadav Rotem
1b92c3d96c
Add a testcase for checking the integer-promotion of many different vector
...
types (with power of two types such as 8,16,32 .. 512).
Fix a bug in the integer promotion of bitcast nodes. Enable integer expanding
only if the target of the conversion is an integer (when the type action is
scalarize).
Add handling to the legalization of vector load/store in cases where the saved
vector is integer-promoted.
llvm-svn: 132985
2011-06-14 08:11:52 +00:00
Nadav Rotem
531aa71d22
Refactor getActionType and getTypeToTransformTo ; place all of the 'decision'
...
code in one place. Re-apply 131534 and fix the multi-step promotion of integers.
llvm-svn: 132217
2011-05-27 21:03:13 +00:00
Duncan Sands
d3292b9f1e
Revert commit 131534 since it seems to have broken several buildbots.
...
Original log entry:
Refactor getActionType and getTypeToTransformTo ; place all of the 'decision'
code in one place.
llvm-svn: 131536
2011-05-18 14:57:56 +00:00
Nadav Rotem
b7d689c706
Refactor getActionType and getTypeToTransformTo ; place all of the 'decision'
...
code in one place.
llvm-svn: 131534
2011-05-18 12:26:38 +00:00
Dan Gohman
834a63625d
Misc. code cleanups.
...
llvm-svn: 131497
2011-05-17 22:22:52 +00:00
Dan Gohman
9a55240376
Delete unused variables.
...
llvm-svn: 131430
2011-05-16 22:19:54 +00:00
Dan Gohman
9ea3bcc685
Trim #includes.
...
llvm-svn: 131429
2011-05-16 22:14:50 +00:00
Dan Gohman
2d7dc7849f
Fix whitespace and 80-column violations.
...
llvm-svn: 131428
2011-05-16 22:09:53 +00:00
Stuart Hastings
5fb280fd39
Since I can't reproduce the failures from 131261, re-trying with a
...
simplified version. <rdar://problem/9298790>
llvm-svn: 131274
2011-05-13 00:51:54 +00:00
Stuart Hastings
b362a9bcc6
Revert 131266 and 131261 due to buildbot complaints.
...
rdar://problem/9298790
llvm-svn: 131269
2011-05-13 00:15:17 +00:00
Stuart Hastings
d106d72681
Non-fast-isel followup to 129634; correctly handle branches controlled
...
by non-CMP expressions. The executable test case (129821) would test
this as well, if we had an "-O0 -disable-arm-fast-isel" LLVM-GCC
tester. Alas, the ARM assembly would be very difficult to check with
FileCheck.
The thumb2-cbnz.ll test is affected; it generates larger code (tst.w
vs. cmp #0 ), but I believe the new version is correct.
rdar://problem/9298790
llvm-svn: 131261
2011-05-12 23:36:41 +00:00
Stuart Hastings
e589a29764
Correctly walk through nested and adjacent CALLSEQ_START nodes. No
...
test case; I've only seen this on a release branch, and I can't get it
to reproduce on trunk. rdar://problem/7662569
llvm-svn: 131152
2011-05-10 21:20:03 +00:00
Eric Christopher
4c3c7c8211
Rewrite the expander for umulo/smulo to remember to sign extend the input
...
manually and pass all (now) 4 arguments to the mul libcall. Add a new
ExpandLibCall for just this (copied gratuitously from type legalization).
Fixes rdar://9292577
llvm-svn: 129842
2011-04-20 01:19:45 +00:00
Stuart Hastings
89cb281cf8
Delete unnecessary variable. <rdar://problem/7662569>
...
llvm-svn: 129796
2011-04-19 20:09:38 +00:00
Stuart Hastings
f838ea4959
Support nested CALLSEQ_BEGIN/END; necessary for ARM byval support. <rdar://problem/7662569>
...
llvm-svn: 129761
2011-04-19 16:16:58 +00:00
Evan Cheng
b720f37282
Fix divmod libcall lowering. Convert to {S|U}DIVREM first and then expand the node to a libcall. rdar://9280991
...
llvm-svn: 129633
2011-04-16 03:08:26 +00:00
Chris Lattner
0304b82f80
Fix a ton of comment typos found by codespell. Patch by
...
Luis Felipe Strano Moraes!
llvm-svn: 129558
2011-04-15 05:18:47 +00:00
Stuart Hastings
1635b37415
Revert 123704; it broke threaded LLVM.
...
llvm-svn: 128868
2011-04-05 00:37:28 +00:00
Evan Cheng
39574b2766
Issue libcalls __udivmod*i4 / __divmod*i4 for div / rem pairs.
...
rdar://8911343
llvm-svn: 128696
2011-04-01 00:42:02 +00:00
Owen Anderson
11a49e845a
Use the correct LHS type when determining the legalization of a shift's RHS type.
...
llvm-svn: 127163
2011-03-07 18:29:47 +00:00
Owen Anderson
bd26993873
Allow targets to specify a the type of the RHS of a shift parameterized on the type of the LHS.
...
llvm-svn: 126518
2011-02-25 21:41:48 +00:00
Devang Patel
d63bce18da
Do not lose debug info of an inlined function argument even if the argument is only used through GEPs.
...
This time with a fix that avoids using invalidated DenseMap iterator.
llvm-svn: 125984
2011-02-18 22:43:42 +00:00
Cameron Zwarich
f6fa19a03f
Roll out r125794 to help diagnose the llvm-gcc-i386-linux-selfhost failure.
...
llvm-svn: 125830
2011-02-18 04:58:10 +00:00
Devang Patel
b6f55191b3
Do not lose debug info of an inlined function argument even if the argument is only used through GEPs.
...
llvm-svn: 125794
2011-02-17 23:33:27 +00:00
Stuart Hastings
47e45a32a8
Swap VT and DebugLoc operands of getExtLoad() for consistency with
...
other getNode() methods. Radar 9002173.
llvm-svn: 125665
2011-02-16 16:23:55 +00:00
Devang Patel
14eb3db47f
Speculatively revert r124380.
...
llvm-svn: 124397
2011-01-27 19:15:01 +00:00
Devang Patel
6c3de04fdd
While legalizing SDValues do not drop SDDbgValues, trasfer them to new legal nodes.
...
Take 2. This includes fix for dragonegg crash.
llvm-svn: 124380
2011-01-27 17:43:53 +00:00
Bill Wendling
51d9acc25b
Initialize variable to get rid of clang warning.
...
llvm-svn: 124331
2011-01-26 22:21:35 +00:00
Devang Patel
ac5d878d16
Revert r124302
...
llvm-svn: 124320
2011-01-26 21:12:32 +00:00
David Greene
5c173a307b
[AVX] Add INSERT_SUBVECTOR and support it on x86. This provides a
...
default implementation for x86, going through the stack in a similr
fashion to how the codegen implements BUILD_VECTOR. Eventually this
will get matched to VINSERTF128 if AVX is available.
llvm-svn: 124307
2011-01-26 19:13:22 +00:00
Devang Patel
3f443cbd7b
While legalizing SDValues do not drop SDDbgValues, trasfer them to new legal nodes.
...
llvm-svn: 124302
2011-01-26 18:55:05 +00:00
Eric Christopher
58f8058502
Use only one API at a time.
...
llvm-svn: 123866
2011-01-20 01:29:23 +00:00
Eric Christopher
1b0e5debb4
If we can, lower the multiply part of a umulo/smulo call to a libcall
...
with an invalid type then split the result and perform the overflow check
normally.
Fixes the 32-bit parts of rdar://8622122 and rdar://8774702.
llvm-svn: 123864
2011-01-20 00:29:24 +00:00
Stuart Hastings
f5f8318eb6
Remove checking that prevented overlapping CALLSEQ_START/CALLSEQ_END
...
ranges, add legalizer support for nested calls. Necessary for ARM
byval support. Radar 7662569.
llvm-svn: 123704
2011-01-18 00:09:27 +00:00
Benjamin Kramer
2e7ead5bb5
Add an assert so we don't silently miscompile ctpop for bit widths > 128.
...
llvm-svn: 123549
2011-01-15 21:19:37 +00:00
Benjamin Kramer
b48a048de6
Reimplement CTPOP legalization with the "best" algorithm from
...
http://graphics.stanford.edu/~seander/bithacks.html#CountBitsSetParallel
In a silly microbenchmark on a 65 nm core2 this is 1.5x faster than the old
code in 32 bit mode and about 2x faster in 64 bit mode. It's also a lot shorter,
especially when counting 64 bit population on a 32 bit target.
I hope this is fast enough to replace Kernighan-style counting loops even when
the input is rather sparse.
llvm-svn: 123547
2011-01-15 20:30:30 +00:00
Dan Gohman
f4ec824435
Fix r123346 to handle scalar types too.
...
llvm-svn: 123352
2011-01-13 01:06:51 +00:00
Dan Gohman
5bbd766a7b
Apply the patch from PR8958, which allows llc to get slightly
...
further on the associated testcase before aborting.
llvm-svn: 123346
2011-01-12 23:56:26 +00:00
Anton Korobeynikov
cf5967630b
Rename TargetFrameInfo into TargetFrameLowering. Also, put couple of FIXMEs and fixes here and there.
...
llvm-svn: 123170
2011-01-10 12:39:04 +00:00
Eric Christopher
be2382f9a6
Remove TODO, these appear to be implemented.
...
llvm-svn: 122849
2011-01-04 22:31:50 +00:00
Stuart Hastings
fedc21e594
Fix indentation, add comment.
...
llvm-svn: 122345
2010-12-21 17:16:58 +00:00
Stuart Hastings
a1f786efa9
Missing logic for nested CALLSEQ_START/END.
...
llvm-svn: 122342
2010-12-21 17:07:24 +00:00