Commit Graph

4958 Commits

Author SHA1 Message Date
Evan Cheng
e90da97f3e LHS = X86ISD::CMOVcc LHS, RHS means LHS = RHS if cc. So the operands must be
flipped around.


git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@25290 91177308-0d34-0410-b5e6-96231b3b80d8
2006-01-13 19:51:46 +00:00
Andrew Lenharth
512c77e532 make DAG isel the default
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@25282 91177308-0d34-0410-b5e6-96231b3b80d8
2006-01-13 18:49:47 +00:00
Chris Lattner
9edba7605e Enable X86 support for savestack/restorestack
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@25278 91177308-0d34-0410-b5e6-96231b3b80d8
2006-01-13 18:00:54 +00:00
Chris Lattner
cadd7420f9 implement stacksave/stackrestore on PPC
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@25277 91177308-0d34-0410-b5e6-96231b3b80d8
2006-01-13 17:52:03 +00:00
Duraid Madina
544cbbd479 don't be a doofus - this fixes storing bools
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@25274 91177308-0d34-0410-b5e6-96231b3b80d8
2006-01-13 10:28:25 +00:00
Chris Lattner
b99329e8a0 expand unsupported stacksave/stackrestore nodes
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@25272 91177308-0d34-0410-b5e6-96231b3b80d8
2006-01-13 02:42:53 +00:00
Chris Lattner
33f79df40c new nodes
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@25271 91177308-0d34-0410-b5e6-96231b3b80d8
2006-01-13 02:40:58 +00:00
Evan Cheng
e08c270623 Minor update.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@25263 91177308-0d34-0410-b5e6-96231b3b80d8
2006-01-13 01:20:42 +00:00
Evan Cheng
80ebe38118 More typo's. I need new eye glasses...
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@25261 91177308-0d34-0410-b5e6-96231b3b80d8
2006-01-13 01:17:24 +00:00
Evan Cheng
189d01e8cc Oops. Typo.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@25260 91177308-0d34-0410-b5e6-96231b3b80d8
2006-01-13 01:06:49 +00:00
Evan Cheng
1bcee3602e Fix a SETCC / BRCOND folding bug.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@25259 91177308-0d34-0410-b5e6-96231b3b80d8
2006-01-13 01:03:02 +00:00
Evan Cheng
a3195e8643 Fix sint_to_fp (fild*) support.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@25257 91177308-0d34-0410-b5e6-96231b3b80d8
2006-01-12 22:54:21 +00:00
Evan Cheng
77e9043b84 Specify transformation from GlobalAddress to TargetGlobalAddress and
ExternalSymbol to TargetExternalSymbol.


git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@25253 91177308-0d34-0410-b5e6-96231b3b80d8
2006-01-12 19:36:31 +00:00
Chris Lattner
4bb91024ac Fix branches on FP compares
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@25249 91177308-0d34-0410-b5e6-96231b3b80d8
2006-01-12 17:05:32 +00:00
Evan Cheng
5ee4ccce5b X86ISD::SETCC (e.g. SETEr) produces a flag (so multiple SETCC can be
linked together).


git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@25247 91177308-0d34-0410-b5e6-96231b3b80d8
2006-01-12 08:27:59 +00:00
Evan Cheng
002fe9baf2 * Materialize GlobalAddress and ExternalSym with MOV32ri rather than
LEA32r.
* Do not lower GlobalAddress to TargetGlobalAddress. Let isel does it.


git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@25246 91177308-0d34-0410-b5e6-96231b3b80d8
2006-01-12 07:56:47 +00:00
Chris Lattner
138d322e96 fix a bug in my previous checkin
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@25244 91177308-0d34-0410-b5e6-96231b3b80d8
2006-01-12 07:38:04 +00:00
Chris Lattner
72878a463b Give V8ISD nodes symbolic names in dumps
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@25243 91177308-0d34-0410-b5e6-96231b3b80d8
2006-01-12 07:31:15 +00:00
Duraid Madina
a5959bfdfa sabre's (correct) fix means these guys need to be flagged as well (else
the scheduler will complain)


git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@25241 91177308-0d34-0410-b5e6-96231b3b80d8
2006-01-12 03:28:40 +00:00
Chris Lattner
a613d267ea ahem :)
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@25239 91177308-0d34-0410-b5e6-96231b3b80d8
2006-01-12 02:05:36 +00:00
Chris Lattner
e699ef5618 these cases are autogenerated
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@25238 91177308-0d34-0410-b5e6-96231b3b80d8
2006-01-12 02:01:45 +00:00
Chris Lattner
17e82d2858 remove dead code
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@25237 91177308-0d34-0410-b5e6-96231b3b80d8
2006-01-12 01:54:15 +00:00
Chris Lattner
05f1fe8d44 Goodbye PPC pattern isel. You have served us well, but it is now time for
you to ride off into the sunset.


git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@25236 91177308-0d34-0410-b5e6-96231b3b80d8
2006-01-12 01:46:07 +00:00
Chris Lattner
271426a99a Fix an itanium call lowering bug for duraid
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@25235 91177308-0d34-0410-b5e6-96231b3b80d8
2006-01-12 01:33:08 +00:00
Chris Lattner
b3c77152c8 invert the sense of this switch and its name
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@25234 91177308-0d34-0410-b5e6-96231b3b80d8
2006-01-12 01:28:56 +00:00
Nate Begeman
c3f8c2eaac Missed a spot.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@25233 91177308-0d34-0410-b5e6-96231b3b80d8
2006-01-11 23:20:28 +00:00
Evan Cheng
eb422a7234 Added ROTL and ROTR.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@25232 91177308-0d34-0410-b5e6-96231b3b80d8
2006-01-11 23:20:05 +00:00
Chris Lattner
ba625726a1 Fix an off-by-one error that Nate's eagle eyes caught
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@25231 91177308-0d34-0410-b5e6-96231b3b80d8
2006-01-11 23:16:29 +00:00
Chris Lattner
c6d48d36a3 Use the auto-insert BuildMI constructor to avoid an explicit insert. No
functionality change, just code cleanup.


git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@25230 91177308-0d34-0410-b5e6-96231b3b80d8
2006-01-11 23:07:57 +00:00
Chris Lattner
64da172b14 If a function has a non-zero sized frame, use an add to adjust the stack
pointer in the epilog, not a load.


git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@25229 91177308-0d34-0410-b5e6-96231b3b80d8
2006-01-11 23:03:54 +00:00
Evan Cheng
67f92a7649 Support for MEMCPY and MEMSET.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@25226 91177308-0d34-0410-b5e6-96231b3b80d8
2006-01-11 22:15:48 +00:00
Evan Cheng
38262cad0a Select DYNAMIC_STACKALLOC
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@25225 91177308-0d34-0410-b5e6-96231b3b80d8
2006-01-11 22:15:18 +00:00
Nate Begeman
35ef913ec2 Add bswap, rotl, and rotr nodes
Add dag combiner code to recognize rotl, rotr
Add ppc code to match rotl

Targets should add rotl/rotr patterns if they have them


git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@25222 91177308-0d34-0410-b5e6-96231b3b80d8
2006-01-11 21:21:00 +00:00
Chris Lattner
a243db8c41 Fix calls that need to store values in stack slots, to not copy the stack
pointer.  This allows us to emit stuff like this:

        li r10, 0
        stw r10, 56(r1)
        or r3, r10, r10
        or r4, r10, r10
        or r5, r10, r10
        or r6, r10, r10
        or r7, r10, r10
        or r8, r10, r10
        or r9, r10, r10
        bl L_bar$stub

instead of this:

        or r2, r1, r1     ;; Extraneous copy.
        li r10, 0
        stw r10, 56(r2)
        or r3, r10, r10
        or r4, r10, r10
        or r5, r10, r10
        or r6, r10, r10
        or r7, r10, r10
        or r8, r10, r10
        or r9, r10, r10
        bl L_bar$stub

wowness.


git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@25221 91177308-0d34-0410-b5e6-96231b3b80d8
2006-01-11 19:55:07 +00:00
Chris Lattner
6232d7d1f4 tblgen does this now
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@25220 91177308-0d34-0410-b5e6-96231b3b80d8
2006-01-11 19:53:22 +00:00
Chris Lattner
7ec6a6e96e This is no longer needed
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@25219 91177308-0d34-0410-b5e6-96231b3b80d8
2006-01-11 19:52:46 +00:00
Chris Lattner
413b979fe4 Dead FP arguments still use an incoming FP reg. This fixes
Regression/CodeGen/PowerPC/2006-01-11-darwin-fp-argument.ll, which was
distilled from a miscompilation in 252.eon.


git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@25217 91177308-0d34-0410-b5e6-96231b3b80d8
2006-01-11 18:21:25 +00:00
Chris Lattner
b9169ceb23 Use Evan's outflag stuff to implement V8cmpicc. This allows us to write a
pattern for SUBCCrr, and makes it trivial to add support for SUBCCri, eliminating
an instruction in the common "setcc X, imm" case.


git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@25212 91177308-0d34-0410-b5e6-96231b3b80d8
2006-01-11 07:49:38 +00:00
Chris Lattner
3fbb726141 Fix a bug in i32->f64 conversion lowering
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@25211 91177308-0d34-0410-b5e6-96231b3b80d8
2006-01-11 07:27:40 +00:00
Chris Lattner
1b8af84a84 Unbreak ret void :-/
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@25210 91177308-0d34-0410-b5e6-96231b3b80d8
2006-01-11 07:15:43 +00:00
Chris Lattner
bda559e115 Write this pattern in canonical form, allowing more patterns to match.
This implements Regression/CodeGen/SparcV8/xnor.ll


git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@25209 91177308-0d34-0410-b5e6-96231b3b80d8
2006-01-11 07:14:01 +00:00
Evan Cheng
8700e14ba1 * Add special entry code main() (to set x87 to 64-bit precision).
* Allow a register node as SelectAddr() base.
* ExternalSymbol -> TargetExternalSymbol as direct function callee.
* Use X86::ESP register rather than CopyFromReg(X86::ESP) as stack ptr for
  call parmater passing.


git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@25207 91177308-0d34-0410-b5e6-96231b3b80d8
2006-01-11 06:09:51 +00:00
Duraid Madina
bf0945877e cleanup GETFD
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@25198 91177308-0d34-0410-b5e6-96231b3b80d8
2006-01-11 03:50:40 +00:00
Andrew Lenharth
3b628f8388 this pattern was bogus
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@25197 91177308-0d34-0410-b5e6-96231b3b80d8
2006-01-11 03:33:06 +00:00
Duraid Madina
eac2a1bdbf this just might work
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@25195 91177308-0d34-0410-b5e6-96231b3b80d8
2006-01-11 01:38:07 +00:00
Duraid Madina
07ac89f30a add support for selecting bools
FIXME: this is commented out because it makes tblgen go a bit fruity


git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@25193 91177308-0d34-0410-b5e6-96231b3b80d8
2006-01-11 01:21:12 +00:00
Chris Lattner
92cb0af675 implement FP_REG_KILL insertion for the dag-dag instruction selector
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@25192 91177308-0d34-0410-b5e6-96231b3b80d8
2006-01-11 01:15:34 +00:00
Chris Lattner
a2b694ce35 Fit into 80 cols
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@25191 91177308-0d34-0410-b5e6-96231b3b80d8
2006-01-11 00:46:55 +00:00
Evan Cheng
4a46080fe0 SSE cmov support.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@25190 91177308-0d34-0410-b5e6-96231b3b80d8
2006-01-11 00:33:36 +00:00
Evan Cheng
f710062bfb * fp to sint patterns.
* fiadd, fisub, etc.


git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@25189 91177308-0d34-0410-b5e6-96231b3b80d8
2006-01-10 22:22:02 +00:00