1
0
mirror of https://github.com/RPCS3/llvm-mirror.git synced 2024-11-25 12:12:47 +01:00
Commit Graph

20209 Commits

Author SHA1 Message Date
Chris Lattner
ec85d13393 Change these methods to take RC's
llvm-svn: 23535
2005-09-30 01:28:14 +00:00
Chris Lattner
2b22bc735c Use the 32-bit version for now
llvm-svn: 23534
2005-09-30 00:05:05 +00:00
Chris Lattner
06cf72a8e5 Add a bunch of patterns for F64 FP ops, add some more integer ops
llvm-svn: 23533
2005-09-29 23:34:24 +00:00
Chris Lattner
47999915ad Remove code for patterns that are autogenerated
llvm-svn: 23532
2005-09-29 23:33:31 +00:00
Andrew Lenharth
070a2605dd begining alpha subtarget support
llvm-svn: 23531
2005-09-29 22:54:56 +00:00
Chris Lattner
e16fc704bd tblgen autogens this pattern now
llvm-svn: 23530
2005-09-29 22:37:24 +00:00
Chris Lattner
10a8d57590 Teach tablegen to reassociate operators when possible. This allows it to
find all of teh pattern matches for EQV from one definition

llvm-svn: 23529
2005-09-29 22:36:54 +00:00
Andrew Lenharth
b5d08bba45 copy and paste error
llvm-svn: 23528
2005-09-29 21:11:57 +00:00
Chris Lattner
7c8efa3b9b now that tblgen is smarter, this pattern is not needed. Also, tblgen
now inverts commuted versions of ANDC/ORC with the current .td file.

llvm-svn: 23527
2005-09-29 19:29:15 +00:00
Chris Lattner
31a9d318a3 Teach tblgen to build permutations of instructions, so that the target author
doesn't have to specify them manually.  It currently handles associativity,
e.g. knowing that (X*Y)+Z  also matches  X+(Y*Z)  and will be extended in
the future.

It is smart enough to not introduce duplicate patterns or patterns that can
never match.

llvm-svn: 23526
2005-09-29 19:28:10 +00:00
Chris Lattner
633db4c298 Insert stores after phi nodes in the normal dest. This fixes
LowerInvoke/2005-08-03-InvokeWithPHI.ll

llvm-svn: 23525
2005-09-29 17:44:20 +00:00
Chris Lattner
cb42f7df68 consistency with other cases, no functionality change
llvm-svn: 23524
2005-09-29 17:38:52 +00:00
Chris Lattner
cb09b023d3 Make the JIT default to the DAG isel instead of the pattern isel, like LLC.
The Pattern isel has some strange memory corruption issues going on. :(

This should have been converted over anyway, but it got forgotten somehow
when switching to the dag isel.

llvm-svn: 23523
2005-09-29 17:31:03 +00:00
Chris Lattner
9fbe5b6a51 Fix two bugs in my patch earlier today that broke int->fp conversion on X86.
llvm-svn: 23522
2005-09-29 06:44:39 +00:00
Chris Lattner
c800214144 Fold isascii into a simple comparison. This speeds up 197.parser by 7.4%,
bringing the LLC time down to the CBE time.

llvm-svn: 23521
2005-09-29 06:17:27 +00:00
Chris Lattner
698283c3c3 new testcase for isascii
llvm-svn: 23520
2005-09-29 06:16:37 +00:00
Chris Lattner
3aa9edd482 remove a bunch of unneeded stuff, or self evident comments
llvm-svn: 23519
2005-09-29 06:16:11 +00:00
Chris Lattner
a2cff39dcd add a new testcase
llvm-svn: 23518
2005-09-29 06:11:34 +00:00
Chris Lattner
0cf56701ef Implement a couple of memcmp folds from the todo list
llvm-svn: 23517
2005-09-29 04:54:20 +00:00
Jeff Cohen
e070c04df0 Silence VC++ redeclaration warnings.
llvm-svn: 23516
2005-09-29 01:59:49 +00:00
Chris Lattner
3c9cb55f13 Never rely on ReplaceAllUsesWith when selecting, use CodeGenMap instead.
ReplaceAllUsesWith does not replace scalars SDOperand floating around on
the stack, permitting things to be selected multiple times.

llvm-svn: 23515
2005-09-29 00:59:32 +00:00
Chris Lattner
0c905d0186 Codegen ADD X, IMM -> addis/addi if needed.
This implements PowerPC/fold-li.ll

llvm-svn: 23514
2005-09-28 23:07:13 +00:00
Chris Lattner
7ae5d2a51d add a testcase for a feature we regressed on because noone wrote the test! :(
llvm-svn: 23513
2005-09-28 23:03:11 +00:00
Chris Lattner
04dae1b9ce Autogen MUL, move FP cases together
llvm-svn: 23512
2005-09-28 22:53:16 +00:00
Chris Lattner
6f2adbd5b0 disentangle FP from INT versions of div/mul
llvm-svn: 23511
2005-09-28 22:50:24 +00:00
Chris Lattner
95601538e4 Use the autogenerated matcher for ADD/SUB
llvm-svn: 23510
2005-09-28 22:47:28 +00:00
Chris Lattner
57694930e5 add a patter for SUBFIC
llvm-svn: 23509
2005-09-28 22:47:06 +00:00
Chris Lattner
e3d0ea8e0f Mark int binops as int-only, add FP binops. Mark FADD/FMUL as commutative but
not associative.  Add [SU]REM.

llvm-svn: 23508
2005-09-28 22:38:27 +00:00
Chris Lattner
8503ee5b01 wrap a long line
llvm-svn: 23507
2005-09-28 22:30:58 +00:00
Chris Lattner
9a2fb006e4 Add FP versions of the binary operators, keeping the int and fp worlds seperate.
llvm-svn: 23506
2005-09-28 22:29:58 +00:00
Chris Lattner
d3b3d07c41 Add FP versions of the binary operators, keeping the int and fp worlds seperate.
Though I have done extensive testing, it is possible that this will break
things in configs I can't test.  Please let me know if this causes a problem
and I'll fix it ASAP.

llvm-svn: 23505
2005-09-28 22:29:17 +00:00
Chris Lattner
61f3785147 Add FP versions of the binary operators, keeping the int and fp worlds seperate.
Though I have done extensive testing, it is possible that this will break
things in configs I can't test.  Please let me know if this causes a problem
and I'll fix it ASAP.

llvm-svn: 23504
2005-09-28 22:28:18 +00:00
Chris Lattner
97cd256caf Mark associative nodes as associative
llvm-svn: 23503
2005-09-28 20:58:39 +00:00
Chris Lattner
86a339dc34 add support for an associative marker
llvm-svn: 23502
2005-09-28 20:58:06 +00:00
Chris Lattner
0231f57a46 Emit an error if instructions or patterns are defined but can never match.
Currently we check that immediate values live on the RHS of commutative
operators.  Defining ORI like this, for example:

def ORI   : DForm_4<24, (ops GPRC:$dst, GPRC:$src1, u16imm:$src2),
                    "ori $dst, $src1, $src2",
                    [(set GPRC:$dst, (or immZExt16:$src2, GPRC:$src1))]>;

results in:

tblgen: In ORI: Instruction can never match: Immediate values must be on the RHS of commutative operators!
llvm-svn: 23501
2005-09-28 19:27:25 +00:00
Chris Lattner
2c54044630 Nate pointed out that mulh[us] are commutative as well. Thanks!
llvm-svn: 23500
2005-09-28 19:01:44 +00:00
Chris Lattner
18ccb532b5 collect commutativity information
llvm-svn: 23499
2005-09-28 18:28:29 +00:00
Chris Lattner
f9cb3cd512 expose commutativity information
llvm-svn: 23498
2005-09-28 18:27:58 +00:00
Chris Lattner
64a7b30379 All (xor *) cases are autogenerated now
llvm-svn: 23497
2005-09-28 18:12:37 +00:00
Chris Lattner
90179cf384 add support for missed eqv tests
llvm-svn: 23496
2005-09-28 18:10:51 +00:00
Chris Lattner
eb8d9090c3 add testcase for nand
llvm-svn: 23495
2005-09-28 18:08:58 +00:00
Chris Lattner
82eb231e2f Implement PowerPC/eqv-andc-orc-nor.ll:EQV3
llvm-svn: 23494
2005-09-28 18:04:52 +00:00
Chris Lattner
816f712c69 Consolidate the eqv.ll and nor.ll files together.
Add a missed eqv case.

llvm-svn: 23493
2005-09-28 18:04:22 +00:00
Chris Lattner
5dae8ab260 Prefer cheaper patterns to more expensive ones. Print the costs to the generated
file

llvm-svn: 23492
2005-09-28 17:57:56 +00:00
Chris Lattner
26c05140ee simple tests for nor generation
llvm-svn: 23491
2005-09-28 17:55:10 +00:00
Chris Lattner
2d240ce480 learn to codegen not as NOR instead of xoris/xori
llvm-svn: 23490
2005-09-28 17:13:15 +00:00
Chris Lattner
dad2994a3a These nodes are all autogenerated
llvm-svn: 23489
2005-09-28 17:07:09 +00:00
Chris Lattner
eeead91a84 Select Constant nodes to TargetConstant nodes
llvm-svn: 23488
2005-09-28 16:58:06 +00:00
Chris Lattner
6ce1d7dabb Constant fold llvm.sqrt
llvm-svn: 23487
2005-09-28 01:34:32 +00:00
Chris Lattner
cd79ed877a add a note about a way to improve this code further, that I won't be getting
to right now.

llvm-svn: 23485
2005-09-27 22:44:59 +00:00