Nick Lewycky [Wed, 20 Sep 2006 23:02:24 +0000 (23:02 +0000)]
Once we're down to "setcc type constant1, constant2", at least come up
with the right answer.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@30550
91177308-0d34-0410-b5e6-
96231b3b80d8
Anton Korobeynikov [Wed, 20 Sep 2006 22:03:51 +0000 (22:03 +0000)]
Adding codegeneration for StdCall & FastCall calling conventions
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@30549
91177308-0d34-0410-b5e6-
96231b3b80d8
Andrew Lenharth [Wed, 20 Sep 2006 20:08:52 +0000 (20:08 +0000)]
Account for pseudo-ops correctly
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@30548
91177308-0d34-0410-b5e6-
96231b3b80d8
Chris Lattner [Wed, 20 Sep 2006 17:12:19 +0000 (17:12 +0000)]
The DarwinAsmPrinter need not check for isDarwin. createPPCAsmPrinterPass
should create the right asmprinter subclass.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@30542
91177308-0d34-0410-b5e6-
96231b3b80d8
Chris Lattner [Wed, 20 Sep 2006 17:07:15 +0000 (17:07 +0000)]
Wrap some darwin'isms with isDarwin checks.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@30541
91177308-0d34-0410-b5e6-
96231b3b80d8
Nick Lewycky [Wed, 20 Sep 2006 17:04:01 +0000 (17:04 +0000)]
Use a total ordering to compare instructions.
Fixes infinite loop in resolve().
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@30540
91177308-0d34-0410-b5e6-
96231b3b80d8
Andrew Lenharth [Wed, 20 Sep 2006 15:37:57 +0000 (15:37 +0000)]
simplify
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@30535
91177308-0d34-0410-b5e6-
96231b3b80d8
Andrew Lenharth [Wed, 20 Sep 2006 15:05:49 +0000 (15:05 +0000)]
catch constants more often
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@30534
91177308-0d34-0410-b5e6-
96231b3b80d8
Andrew Lenharth [Wed, 20 Sep 2006 15:04:55 +0000 (15:04 +0000)]
catch another constant
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@30533
91177308-0d34-0410-b5e6-
96231b3b80d8
Andrew Lenharth [Wed, 20 Sep 2006 14:48:00 +0000 (14:48 +0000)]
clarify with test case
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@30531
91177308-0d34-0410-b5e6-
96231b3b80d8
Andrew Lenharth [Wed, 20 Sep 2006 14:40:01 +0000 (14:40 +0000)]
Add Note
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@30530
91177308-0d34-0410-b5e6-
96231b3b80d8
Jim Laskey [Wed, 20 Sep 2006 09:20:22 +0000 (09:20 +0000)]
Trim the home directory from the dejagnu test
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@30519
91177308-0d34-0410-b5e6-
96231b3b80d8
Chris Lattner [Wed, 20 Sep 2006 06:41:56 +0000 (06:41 +0000)]
item done
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@30518
91177308-0d34-0410-b5e6-
96231b3b80d8
Chris Lattner [Wed, 20 Sep 2006 06:41:35 +0000 (06:41 +0000)]
Compile:
int test3(int a, int b) { return (a < 0) ? a : 0; }
to:
_test3:
srawi r2, r3, 31
and r3, r2, r3
blr
instead of:
_test3:
cmpwi cr0, r3, 1
li r2, 0
blt cr0, LBB2_2 ;entry
LBB2_1: ;entry
mr r3, r2
LBB2_2: ;entry
blr
This implements: PowerPC/select_lt0.ll:seli32_a_a
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@30517
91177308-0d34-0410-b5e6-
96231b3b80d8
Chris Lattner [Wed, 20 Sep 2006 06:40:37 +0000 (06:40 +0000)]
new testcase
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@30516
91177308-0d34-0410-b5e6-
96231b3b80d8
Chris Lattner [Wed, 20 Sep 2006 06:32:10 +0000 (06:32 +0000)]
add a note
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@30515
91177308-0d34-0410-b5e6-
96231b3b80d8
Chris Lattner [Wed, 20 Sep 2006 06:29:17 +0000 (06:29 +0000)]
Fold the full generality of (any_extend (truncate x))
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@30514
91177308-0d34-0410-b5e6-
96231b3b80d8
Chris Lattner [Wed, 20 Sep 2006 06:19:26 +0000 (06:19 +0000)]
Two things:
1. teach SimplifySetCC that '(srl (ctlz x), 5) == 0' is really x != 0.
2. Teach visitSELECT_CC to use SimplifySetCC instead of calling it and
ignoring the result. This allows us to compile:
bool %test(ulong %x) {
%tmp = setlt ulong %x,
4294967296
ret bool %tmp
}
to:
_test:
cntlzw r2, r3
cmplwi cr0, r3, 1
srwi r2, r2, 5
li r3, 0
beq cr0, LBB1_2 ;
LBB1_1: ;
mr r3, r2
LBB1_2: ;
blr
instead of:
_test:
addi r2, r3, -1
cntlzw r2, r2
cntlzw r3, r3
srwi r2, r2, 5
cmplwi cr0, r2, 0
srwi r2, r3, 5
li r3, 0
bne cr0, LBB1_2 ;
LBB1_1: ;
mr r3, r2
LBB1_2: ;
blr
This isn't wonderful, but it's an improvement.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@30513
91177308-0d34-0410-b5e6-
96231b3b80d8
Chris Lattner [Wed, 20 Sep 2006 04:59:33 +0000 (04:59 +0000)]
This is already done
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@30512
91177308-0d34-0410-b5e6-
96231b3b80d8
Chris Lattner [Wed, 20 Sep 2006 04:44:59 +0000 (04:44 +0000)]
We went through all that trouble to compute whether it was safe to transform
this comparison, but never checked it. Whoops, no wonder we miscompiled
177.mesa!
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@30511
91177308-0d34-0410-b5e6-
96231b3b80d8
Chris Lattner [Wed, 20 Sep 2006 04:33:27 +0000 (04:33 +0000)]
Improve PPC64 equality comparisons like PPC32 comparisons.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@30510
91177308-0d34-0410-b5e6-
96231b3b80d8
Chris Lattner [Wed, 20 Sep 2006 04:25:47 +0000 (04:25 +0000)]
Two improvements:
1. Codegen this comparison:
if (X == 0x8000)
as:
cmplwi cr0, r3, 32768
bne cr0, LBB1_2 ;cond_next
instead of:
lis r2, 0
ori r2, r2, 32768
cmpw cr0, r3, r2
bne cr0, LBB1_2 ;cond_next
2. Codegen this comparison:
if (X == 0x12345678)
as:
xoris r2, r3, 4660
cmplwi cr0, r2, 22136
bne cr0, LBB1_2 ;cond_next
instead of:
lis r2, 4660
ori r2, r2, 22136
cmpw cr0, r3, r2
bne cr0, LBB1_2 ;cond_next
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@30509
91177308-0d34-0410-b5e6-
96231b3b80d8
Chris Lattner [Wed, 20 Sep 2006 03:59:25 +0000 (03:59 +0000)]
Add a note that we should match rlwnm better
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@30508
91177308-0d34-0410-b5e6-
96231b3b80d8
Chris Lattner [Wed, 20 Sep 2006 03:47:40 +0000 (03:47 +0000)]
Legalize is no longer limited to cleverness with just constant shift amounts.
Allow it to be clever when possible and fall back to the gross code when needed.
This allows us to compile:
long long foo1(long long X, int C) {
return X << (C|32);
}
long long foo2(long long X, int C) {
return X << (C&~32);
}
to:
_foo1:
rlwinm r2, r5, 0, 27, 31
slw r3, r4, r2
li r4, 0
blr
.globl _foo2
.align 4
_foo2:
rlwinm r2, r5, 0, 27, 25
subfic r5, r2, 32
slw r3, r3, r2
srw r5, r4, r5
or r3, r3, r5
slw r4, r4, r2
blr
instead of:
_foo1:
ori r2, r5, 32
subfic r5, r2, 32
addi r6, r2, -32
srw r5, r4, r5
slw r3, r3, r2
slw r6, r4, r6
or r3, r3, r5
slw r4, r4, r2
or r3, r3, r6
blr
.globl _foo2
.align 4
_foo2:
rlwinm r2, r5, 0, 27, 25
subfic r5, r2, 32
addi r6, r2, -32
srw r5, r4, r5
slw r3, r3, r2
slw r6, r4, r6
or r3, r3, r5
slw r4, r4, r2
or r3, r3, r6
blr
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@30507
91177308-0d34-0410-b5e6-
96231b3b80d8
Chris Lattner [Wed, 20 Sep 2006 03:38:48 +0000 (03:38 +0000)]
Expand 64-bit shifts more optimally if we know that the high bit of the
shift amount is one or zero. For example, for:
long long foo1(long long X, int C) {
return X << (C|32);
}
long long foo2(long long X, int C) {
return X << (C&~32);
}
we get:
_foo1:
movb $31, %cl
movl 4(%esp), %edx
andb 12(%esp), %cl
shll %cl, %edx
xorl %eax, %eax
ret
_foo2:
movb $223, %cl
movl 4(%esp), %eax
movl 8(%esp), %edx
andb 12(%esp), %cl
shldl %cl, %eax, %edx
shll %cl, %eax
ret
instead of:
_foo1:
subl $4, %esp
movl %ebx, (%esp)
movb $32, %bl
movl 8(%esp), %eax
movl 12(%esp), %edx
movb %bl, %cl
orb 16(%esp), %cl
shldl %cl, %eax, %edx
shll %cl, %eax
xorl %ecx, %ecx
testb %bl, %bl
cmovne %eax, %edx
cmovne %ecx, %eax
movl (%esp), %ebx
addl $4, %esp
ret
_foo2:
subl $4, %esp
movl %ebx, (%esp)
movb $223, %cl
movl 8(%esp), %eax
movl 12(%esp), %edx
andb 16(%esp), %cl
shldl %cl, %eax, %edx
shll %cl, %eax
xorl %ecx, %ecx
xorb %bl, %bl
testb %bl, %bl
cmovne %eax, %edx
cmovne %ecx, %eax
movl (%esp), %ebx
addl $4, %esp
ret
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@30506
91177308-0d34-0410-b5e6-
96231b3b80d8
Evan Cheng [Wed, 20 Sep 2006 01:39:40 +0000 (01:39 +0000)]
Back out Chris' last set of changes. This breaks 177.mesa and povray somehow.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@30505
91177308-0d34-0410-b5e6-
96231b3b80d8
Evan Cheng [Wed, 20 Sep 2006 01:10:02 +0000 (01:10 +0000)]
80 col.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@30504
91177308-0d34-0410-b5e6-
96231b3b80d8
Evan Cheng [Tue, 19 Sep 2006 19:08:04 +0000 (19:08 +0000)]
Allow PatFrag to be a leaf node.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@30498
91177308-0d34-0410-b5e6-
96231b3b80d8
Evan Cheng [Tue, 19 Sep 2006 18:40:15 +0000 (18:40 +0000)]
Add result of a Xform to isel queue.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@30497
91177308-0d34-0410-b5e6-
96231b3b80d8
Andrew Lenharth [Tue, 19 Sep 2006 18:24:51 +0000 (18:24 +0000)]
If we have an add, do it in the pointer realm, not the int realm. This is critical in the linux kernel for pointer analysis correctness
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@30496
91177308-0d34-0410-b5e6-
96231b3b80d8
Andrew Lenharth [Tue, 19 Sep 2006 18:23:39 +0000 (18:23 +0000)]
Inspired by the linux kernel, the more we keep adds in the pointer realm, the better pointer analysis works.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@30495
91177308-0d34-0410-b5e6-
96231b3b80d8
Chris Lattner [Tue, 19 Sep 2006 18:02:01 +0000 (18:02 +0000)]
Fix UnitTests/2005-05-12-Int64ToFP.c with llc-beta. In particular, do not
allow it to go into an infinite loop, filling up the disk!
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@30494
91177308-0d34-0410-b5e6-
96231b3b80d8
Rafael Espindola [Tue, 19 Sep 2006 16:41:40 +0000 (16:41 +0000)]
fix header
add comments
untabify
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@30486
91177308-0d34-0410-b5e6-
96231b3b80d8
Rafael Espindola [Tue, 19 Sep 2006 15:49:25 +0000 (15:49 +0000)]
Implement a MachineFunctionPass to fix the mul instruction
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@30485
91177308-0d34-0410-b5e6-
96231b3b80d8
Chris Lattner [Tue, 19 Sep 2006 06:19:19 +0000 (06:19 +0000)]
number test right
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@30484
91177308-0d34-0410-b5e6-
96231b3b80d8
Chris Lattner [Tue, 19 Sep 2006 06:19:03 +0000 (06:19 +0000)]
item done
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@30483
91177308-0d34-0410-b5e6-
96231b3b80d8
Chris Lattner [Tue, 19 Sep 2006 06:18:21 +0000 (06:18 +0000)]
implement select.ll:test19-22
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@30482
91177308-0d34-0410-b5e6-
96231b3b80d8
Chris Lattner [Tue, 19 Sep 2006 06:17:55 +0000 (06:17 +0000)]
make this harder
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@30481
91177308-0d34-0410-b5e6-
96231b3b80d8
Chris Lattner [Tue, 19 Sep 2006 06:16:46 +0000 (06:16 +0000)]
new testcases
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@30480
91177308-0d34-0410-b5e6-
96231b3b80d8
Chris Lattner [Tue, 19 Sep 2006 05:22:59 +0000 (05:22 +0000)]
Fold the PPCISD shifts when presented with 0 inputs. This occurs for code
like:
long long test(long long X, int Y) {
return 1ULL << Y;
}
long long test2(long long X, int Y) {
return -1LL << Y;
}
which we used to compile to:
_test:
li r2, 1
subfic r3, r5, 32
li r4, 0
addi r6, r5, -32
srw r3, r2, r3
slw r4, r4, r5
slw r6, r2, r6
or r3, r4, r3
slw r4, r2, r5
or r3, r3, r6
blr
_test2:
li r2, -1
subfic r3, r5, 32
addi r6, r5, -32
srw r3, r2, r3
slw r4, r2, r5
slw r2, r2, r6
or r3, r4, r3
or r3, r3, r2
blr
Now we produce:
_test:
li r2, 1
addi r3, r5, -32
subfic r4, r5, 32
slw r3, r2, r3
srw r4, r2, r4
or r3, r4, r3
slw r4, r2, r5
blr
_test2:
li r2, -1
subfic r3, r5, 32
addi r6, r5, -32
srw r3, r2, r3
slw r4, r2, r5
slw r2, r2, r6
or r3, r4, r3
or r3, r3, r2
blr
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@30479
91177308-0d34-0410-b5e6-
96231b3b80d8
Chris Lattner [Tue, 19 Sep 2006 05:02:39 +0000 (05:02 +0000)]
Fold extract_element(cst) to cst
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@30478
91177308-0d34-0410-b5e6-
96231b3b80d8
Chris Lattner [Tue, 19 Sep 2006 04:51:23 +0000 (04:51 +0000)]
Minor speedup for legalize by avoiding some malloc traffic
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@30477
91177308-0d34-0410-b5e6-
96231b3b80d8
Chris Lattner [Tue, 19 Sep 2006 00:41:36 +0000 (00:41 +0000)]
If multiple predicates are listed, they must all pass
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@30476
91177308-0d34-0410-b5e6-
96231b3b80d8
Nick Lewycky [Tue, 19 Sep 2006 00:31:54 +0000 (00:31 +0000)]
Enable dejagnu tests for predicate simplifier.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@30475
91177308-0d34-0410-b5e6-
96231b3b80d8
Evan Cheng [Mon, 18 Sep 2006 23:28:33 +0000 (23:28 +0000)]
Fix a typo.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@30474
91177308-0d34-0410-b5e6-
96231b3b80d8
Chris Lattner [Mon, 18 Sep 2006 22:41:07 +0000 (22:41 +0000)]
There!
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@30473
91177308-0d34-0410-b5e6-
96231b3b80d8
Chris Lattner [Mon, 18 Sep 2006 22:28:27 +0000 (22:28 +0000)]
Fix Regression/TableGen/2006-09-18-LargeInt.td
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@30472
91177308-0d34-0410-b5e6-
96231b3b80d8
Chris Lattner [Mon, 18 Sep 2006 22:28:07 +0000 (22:28 +0000)]
new testcase
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@30471
91177308-0d34-0410-b5e6-
96231b3b80d8
Evan Cheng [Mon, 18 Sep 2006 21:49:04 +0000 (21:49 +0000)]
Allow i32 UDIV, SDIV, UREM, SREM to be expanded into libcalls.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@30470
91177308-0d34-0410-b5e6-
96231b3b80d8
Nick Lewycky [Mon, 18 Sep 2006 21:09:35 +0000 (21:09 +0000)]
Walk down the dominator tree instead of the control flow graph. That means
that we can't modify the CFG any more, at least not until it's possible
to update the dominator tree (PR217).
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@30469
91177308-0d34-0410-b5e6-
96231b3b80d8
Nick Lewycky [Mon, 18 Sep 2006 20:44:37 +0000 (20:44 +0000)]
Fix findCaseDest to return null when BB is both the default dest and one
of the numeric cases.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@30468
91177308-0d34-0410-b5e6-
96231b3b80d8
Andrew Lenharth [Mon, 18 Sep 2006 19:44:29 +0000 (19:44 +0000)]
A pass to remove the worst of the replay trap offenders, and as a bonus, align basic blocks when it is free to do so
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@30467
91177308-0d34-0410-b5e6-
96231b3b80d8
Nick Lewycky [Mon, 18 Sep 2006 19:03:59 +0000 (19:03 +0000)]
Add a new helper method to SwitchInst. Useful when you've got a BB from
somewhere (like the dominator graph) and would like to know which case it
came from.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@30466
91177308-0d34-0410-b5e6-
96231b3b80d8
Chris Lattner [Mon, 18 Sep 2006 18:27:05 +0000 (18:27 +0000)]
Fix an infinite loop building the CFE
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@30465
91177308-0d34-0410-b5e6-
96231b3b80d8
Chris Lattner [Mon, 18 Sep 2006 18:07:51 +0000 (18:07 +0000)]
new testcase
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@30464
91177308-0d34-0410-b5e6-
96231b3b80d8
Andrew Lenharth [Mon, 18 Sep 2006 18:01:03 +0000 (18:01 +0000)]
Jump tables on Alpha
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@30463
91177308-0d34-0410-b5e6-
96231b3b80d8
Andrew Lenharth [Mon, 18 Sep 2006 18:00:18 +0000 (18:00 +0000)]
oops
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@30462
91177308-0d34-0410-b5e6-
96231b3b80d8
Andrew Lenharth [Mon, 18 Sep 2006 17:59:35 +0000 (17:59 +0000)]
absolute addresses must match pointer size
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@30461
91177308-0d34-0410-b5e6-
96231b3b80d8
Jim Laskey [Mon, 18 Sep 2006 14:47:26 +0000 (14:47 +0000)]
Sort out mangled names for globals
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@30460
91177308-0d34-0410-b5e6-
96231b3b80d8
Chris Lattner [Mon, 18 Sep 2006 07:02:31 +0000 (07:02 +0000)]
Implement a trivial optzn: of vastart is never called in a function that takes
... args, remove the '...'.
This is Transforms/DeadArgElim/dead_vaargs.ll
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@30459
91177308-0d34-0410-b5e6-
96231b3b80d8
Chris Lattner [Mon, 18 Sep 2006 07:01:39 +0000 (07:01 +0000)]
new testcase
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@30458
91177308-0d34-0410-b5e6-
96231b3b80d8
Chris Lattner [Mon, 18 Sep 2006 05:36:54 +0000 (05:36 +0000)]
add a note. Our 64-bit shifts are ~30% slower than gcc's
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@30457
91177308-0d34-0410-b5e6-
96231b3b80d8
Chris Lattner [Mon, 18 Sep 2006 05:27:43 +0000 (05:27 +0000)]
Implement InstCombine/cast.ll:test31. This speeds up 462.libquantum by 26%.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@30456
91177308-0d34-0410-b5e6-
96231b3b80d8
Chris Lattner [Mon, 18 Sep 2006 05:25:10 +0000 (05:25 +0000)]
new testcase
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@30455
91177308-0d34-0410-b5e6-
96231b3b80d8
Chris Lattner [Mon, 18 Sep 2006 05:17:11 +0000 (05:17 +0000)]
Add support for pattern matching cast operations
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@30454
91177308-0d34-0410-b5e6-
96231b3b80d8
Chris Lattner [Mon, 18 Sep 2006 04:58:06 +0000 (04:58 +0000)]
fix typo
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@30453
91177308-0d34-0410-b5e6-
96231b3b80d8
Chris Lattner [Mon, 18 Sep 2006 04:54:57 +0000 (04:54 +0000)]
add a helper method
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@30452
91177308-0d34-0410-b5e6-
96231b3b80d8
Chris Lattner [Mon, 18 Sep 2006 04:54:35 +0000 (04:54 +0000)]
This is closer to what we really want.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@30451
91177308-0d34-0410-b5e6-
96231b3b80d8
Chris Lattner [Mon, 18 Sep 2006 04:31:40 +0000 (04:31 +0000)]
Implement Transforms/InstCombine/shift-sra.ll:test0
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@30450
91177308-0d34-0410-b5e6-
96231b3b80d8
Chris Lattner [Mon, 18 Sep 2006 04:31:18 +0000 (04:31 +0000)]
New testcase, can be an srl instead of sra
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@30449
91177308-0d34-0410-b5e6-
96231b3b80d8
Chris Lattner [Mon, 18 Sep 2006 04:22:48 +0000 (04:22 +0000)]
Rewrite shift/and/compare sequences to promote better licm of the RHS.
Use isLogicalShift/isArithmeticShift to simplify code.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@30448
91177308-0d34-0410-b5e6-
96231b3b80d8
Reid Spencer [Sun, 17 Sep 2006 23:05:15 +0000 (23:05 +0000)]
Make the LLVM Publications link point to /pubs/ since this has moved to
its own page on the LLVM web site.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@30447
91177308-0d34-0410-b5e6-
96231b3b80d8
Anton Korobeynikov [Sun, 17 Sep 2006 20:25:45 +0000 (20:25 +0000)]
Added some eye-candy for Subtarget type checking
Added X86 StdCall & FastCall calling conventions. Codegen will follow.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@30446
91177308-0d34-0410-b5e6-
96231b3b80d8
Chris Lattner [Sun, 17 Sep 2006 19:29:56 +0000 (19:29 +0000)]
Add ShiftInst::isLogical/ArithmeticShift methods.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@30445
91177308-0d34-0410-b5e6-
96231b3b80d8
Chris Lattner [Sun, 17 Sep 2006 19:14:47 +0000 (19:14 +0000)]
Add new SetCondInst::isRelational/isEquality methods. Rename
Instruction::isRelational to Instruction::isComparison.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@30444
91177308-0d34-0410-b5e6-
96231b3b80d8
Nick Lewycky [Sun, 17 Sep 2006 17:51:00 +0000 (17:51 +0000)]
Explain change with a comment.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@30443
91177308-0d34-0410-b5e6-
96231b3b80d8
Nick Lewycky [Sun, 17 Sep 2006 16:23:36 +0000 (16:23 +0000)]
Fix PR912. The input to erase() must not be a reference to the data
being erased.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@30442
91177308-0d34-0410-b5e6-
96231b3b80d8
Anton Korobeynikov [Sun, 17 Sep 2006 13:06:18 +0000 (13:06 +0000)]
Small fixes for supporting dll* linkage types
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@30441
91177308-0d34-0410-b5e6-
96231b3b80d8
Chris Lattner [Sat, 16 Sep 2006 23:57:51 +0000 (23:57 +0000)]
add a note noticed through source inspection
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@30418
91177308-0d34-0410-b5e6-
96231b3b80d8
Chris Lattner [Sat, 16 Sep 2006 05:08:34 +0000 (05:08 +0000)]
Oh yeah, this is needed too
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@30407
91177308-0d34-0410-b5e6-
96231b3b80d8
Chris Lattner [Sat, 16 Sep 2006 03:30:19 +0000 (03:30 +0000)]
add a note
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@30406
91177308-0d34-0410-b5e6-
96231b3b80d8
Chris Lattner [Sat, 16 Sep 2006 03:14:10 +0000 (03:14 +0000)]
Fix Transforms/InstCombine/2006-09-15-CastToBool.ll and PR913
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@30405
91177308-0d34-0410-b5e6-
96231b3b80d8
Chris Lattner [Sat, 16 Sep 2006 03:13:22 +0000 (03:13 +0000)]
Testcase for PR913
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@30404
91177308-0d34-0410-b5e6-
96231b3b80d8
Chris Lattner [Sat, 16 Sep 2006 00:21:44 +0000 (00:21 +0000)]
simplify control flow, no functionality change
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@30403
91177308-0d34-0410-b5e6-
96231b3b80d8
Chris Lattner [Sat, 16 Sep 2006 00:09:24 +0000 (00:09 +0000)]
Allow custom expand of mul
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@30402
91177308-0d34-0410-b5e6-
96231b3b80d8
Chris Lattner [Fri, 15 Sep 2006 23:01:10 +0000 (23:01 +0000)]
comment out debug code
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@30401
91177308-0d34-0410-b5e6-
96231b3b80d8
Chris Lattner [Fri, 15 Sep 2006 21:29:15 +0000 (21:29 +0000)]
Add a new -cbe-bug mode, which works just like -run-llc, except that it uses
LLC as the reference compiler to reduce testcases for bugs in GCC.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@30400
91177308-0d34-0410-b5e6-
96231b3b80d8
Chris Lattner [Fri, 15 Sep 2006 20:31:36 +0000 (20:31 +0000)]
add a nate note
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@30399
91177308-0d34-0410-b5e6-
96231b3b80d8
Chris Lattner [Fri, 15 Sep 2006 17:25:22 +0000 (17:25 +0000)]
xfail this for now
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@30398
91177308-0d34-0410-b5e6-
96231b3b80d8
Chris Lattner [Fri, 15 Sep 2006 17:24:45 +0000 (17:24 +0000)]
revert previous two patches. They cause miscompilation of MultiSource/Applications/Burg
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@30397
91177308-0d34-0410-b5e6-
96231b3b80d8
Jim Laskey [Fri, 15 Sep 2006 17:03:36 +0000 (17:03 +0000)]
Switching to NewNightlyTest.php
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@30394
91177308-0d34-0410-b5e6-
96231b3b80d8
Chris Lattner [Fri, 15 Sep 2006 16:53:11 +0000 (16:53 +0000)]
The inliner strips dead allocas now. Add a use to allow this test to
test the right thing.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@30393
91177308-0d34-0410-b5e6-
96231b3b80d8
Owen Anderson [Fri, 15 Sep 2006 05:22:51 +0000 (05:22 +0000)]
Revert my previous work on ArgumentPromotion. Further investigation has revealed these
changes to be incorrect. They just weren't showing up in any of our current testcases.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@30385
91177308-0d34-0410-b5e6-
96231b3b80d8
Chris Lattner [Fri, 15 Sep 2006 04:56:11 +0000 (04:56 +0000)]
Unbreak the JIT
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@30384
91177308-0d34-0410-b5e6-
96231b3b80d8
Chris Lattner [Fri, 15 Sep 2006 03:57:23 +0000 (03:57 +0000)]
Keep track of the start of MBB's in a separate map from instructions. This
is faster and is needed for future improvements.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@30383
91177308-0d34-0410-b5e6-
96231b3b80d8
Evan Cheng [Thu, 14 Sep 2006 23:55:02 +0000 (23:55 +0000)]
Remove a unnecessary check.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@30382
91177308-0d34-0410-b5e6-
96231b3b80d8
Chris Lattner [Thu, 14 Sep 2006 23:54:24 +0000 (23:54 +0000)]
Relax this check.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@30381
91177308-0d34-0410-b5e6-
96231b3b80d8
Devang Patel [Thu, 14 Sep 2006 21:43:24 +0000 (21:43 +0000)]
Undo previous check-in.
Reintroduce recursive assignDFSNumber().
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@30380
91177308-0d34-0410-b5e6-
96231b3b80d8
Chris Lattner [Thu, 14 Sep 2006 21:11:37 +0000 (21:11 +0000)]
Fold (X & C1) | (Y & C2) -> (X|Y) & C3 when possible.
This implements CodeGen/X86/and-or-fold.ll
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@30379
91177308-0d34-0410-b5e6-
96231b3b80d8
Chris Lattner [Thu, 14 Sep 2006 21:10:06 +0000 (21:10 +0000)]
New testcase
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@30378
91177308-0d34-0410-b5e6-
96231b3b80d8