1
0
mirror of https://github.com/RPCS3/llvm-mirror.git synced 2024-10-21 03:53:04 +02:00
Commit Graph

51196 Commits

Author SHA1 Message Date
Chris Lattner
f32c2d890c eliminate some uses of prcontext. Any help here would be appreciated :)
llvm-svn: 80520
2009-08-30 21:45:23 +00:00
Chris Lattner
4c06cf3a4f rename test so that name reflects what it is testing for.
llvm-svn: 80519
2009-08-30 21:36:39 +00:00
Chris Lattner
0ad4b1ca5e convert to filecheck format.
llvm-svn: 80518
2009-08-30 21:36:06 +00:00
Chris Lattner
1c81f120e2 suck a bunch more gep tests into getelementptr.ll and filecheckize them all.
llvm-svn: 80517
2009-08-30 21:31:34 +00:00
Daniel Dunbar
30b720266e Tweak comment.
llvm-svn: 80516
2009-08-30 21:14:05 +00:00
Daniel Dunbar
89f43b31cc Fix some possible-use-of-uninitialized warnings.
llvm-svn: 80515
2009-08-30 21:13:58 +00:00
Chris Lattner
1c8bd32732 consolodate various GEP tests into getelementptr.ll using filecheck.
llvm-svn: 80514
2009-08-30 21:02:36 +00:00
Chris Lattner
ac17c19a06 another huge testcase, this time from 'gs' in llvm-test.
llvm-svn: 80513
2009-08-30 21:02:02 +00:00
Chris Lattner
6c6cd82568 remove another poorly-reduced testcase which came from ldecod in llvm-test.
llvm-svn: 80512
2009-08-30 21:01:14 +00:00
Chris Lattner
94ea2fb674 this testcase is 500 lines long and is distilled from bzip2, just
remove it.

llvm-svn: 80511
2009-08-30 21:00:11 +00:00
Chris Lattner
22c8be162d convert to filecheck
llvm-svn: 80510
2009-08-30 20:48:15 +00:00
Chris Lattner
d21a94f8d6 Fix PR4748: don't fold gep(bitcast(x)) into bitcast(gep) when x
is itself a bitcast.  Since we have gep(bitcast(bitcast(y))) in this
case, just wait for the two bitcasts to get zapped.  This prevents
instcombine from confusing some aliasing stuff, and allows it to
directly eliminate the load in the testcase.

llvm-svn: 80508
2009-08-30 20:38:21 +00:00
Chris Lattner
474990915a misc cleanup
llvm-svn: 80507
2009-08-30 20:36:46 +00:00
Chris Lattner
784e8d9177 add getPointerAddressSpace() to GEP instruction, use the method
in a few scalar xforms to simplify things.

llvm-svn: 80506
2009-08-30 20:06:40 +00:00
Chris Lattner
dc6b5be632 eliminate InsertCastBefore, use the builder instead.
llvm-svn: 80505
2009-08-30 20:01:10 +00:00
Chris Lattner
2a3af9b743 eliminate InsertBitCastBefore, just use the builder instead.
llvm-svn: 80504
2009-08-30 19:47:22 +00:00
Chris Lattner
81c37331cf add a "getPointerAddressSpace" helper method to LoadInst and StoreInst.
llvm-svn: 80503
2009-08-30 19:45:21 +00:00
Anton Korobeynikov
17529667db Add missed pattern
llvm-svn: 80502
2009-08-30 19:06:39 +00:00
Chris Lattner
bbfe14087f convert a bunch more calls to InsertNewInstBefore to use
the new Instcombine builder.

llvm-svn: 80501
2009-08-30 18:50:58 +00:00
Chris Lattner
444e6e0118 fix typo
llvm-svn: 80500
2009-08-30 17:53:59 +00:00
Chris Lattner
5bb0ee8c70 hopefully unbreak the build by making this-> explicit for dependent
base class lookup.

llvm-svn: 80499
2009-08-30 17:44:10 +00:00
Anton Korobeynikov
a261afbf14 EXTRACT_VECTOR_ELEMENT can have result type different from element type.
Remove the assertion and generalize the code for ARM NEON stuff.

llvm-svn: 80498
2009-08-30 17:14:54 +00:00
Torok Edwin
21897521c1 Add regular expression matching support, based on OpenBSD regexec()/regcomp()
implementation.

llvm-svn: 80493
2009-08-30 08:24:09 +00:00
Chris Lattner
dd71643cf1 give instcombine a custom IRBuilder that adds new instructions to the
workslist and is set to insert new instructions before the current one.
Convert a bunch of stuff that used to call InsertNewInstBefore over to
use it, greatly simplifying code and making it more natural.

There is still a lot more to go, but this is a good start.

llvm-svn: 80492
2009-08-30 07:44:24 +00:00
Daniel Dunbar
8cbbfb58e7 Update test.
llvm-svn: 80490
2009-08-30 07:01:09 +00:00
Chris Lattner
d53d314bd6 add a new InstCombineWorklist::AddValue method that works even
if the operand is not an instruction.

Simplify most uses of AddOperandsToWorkList to use AddValue and
inline it into the one remaining callsite.

llvm-svn: 80488
2009-08-30 06:27:41 +00:00
Chris Lattner
7dfc9cc68f move AddUsersToWorkList to the worklist processing class, make the
argument stronger typed.

llvm-svn: 80487
2009-08-30 06:22:51 +00:00
Chris Lattner
13202514e1 rename AddUsesToWorkList -> AddOperandsToWorkList. The
former looks too much like AddUsersToWorkList and keeps
confusing me.

Remove AddSoonDeadInstToWorklist and change its two callers
to do the same thing in a simpler way.

llvm-svn: 80486
2009-08-30 06:20:05 +00:00
Daniel Dunbar
21f3ac490c llvm-mc/X86: Encode constant MCValue's correctly.
llvm-svn: 80485
2009-08-30 06:17:49 +00:00
Daniel Dunbar
bc61205626 llvm-mc: MCStreamer cleanups. - Remove EmitLocalSymbol, this is unsupported for now.
- Switch Emit{CommonSymbol,Zerofill} to take alignment in bytes (for consistency).

llvm-svn: 80484
2009-08-30 06:17:16 +00:00
Chris Lattner
1f8e8caacb inline the trivial AddToWorkList/RemoveFromWorkList methods
into their callers.  simplify ReplaceInstUsesWith.  Make
EraseInstFromFunction only add operands to the worklist if
there aren't too many of them (this was a scalability win
for crazy programs that was only infrequently enforced).
Switch more code to using EraseInstFromFunction instead of
duplicating it inline.  Change some fcmp/icmp optimizations
to modify fcmp/icmp in place instead of creating a new one
and deleting the old one just to change the predicate.

llvm-svn: 80483
2009-08-30 06:13:40 +00:00
Chris Lattner
97d6443c26 fix a bug I introduced in r80478 found by the build bot.
llvm-svn: 80482
2009-08-30 05:56:44 +00:00
Chris Lattner
ca6875bf57 refactor instcombine's worklist processing stuff out to its own class.
llvm-svn: 80481
2009-08-30 05:55:36 +00:00
Chris Lattner
0ba5632cf6 make DenseMap::clear() early exit if there is nothing to do.
llvm-svn: 80480
2009-08-30 05:55:04 +00:00
Chris Lattner
c3deceaf81 some minor cleanups to IRBuilder, factor the insertion
hook out of the main IRBuilder class to allow clients to
override it.

llvm-svn: 80479
2009-08-30 05:42:59 +00:00
Chris Lattner
741fcee014 more cleanups: remove some redundant code, and simplify some
other places.

llvm-svn: 80478
2009-08-30 05:30:55 +00:00
Chris Lattner
aecf0100db eliminate the temporary SrcGEPOperands smallvector.
llvm-svn: 80477
2009-08-30 05:08:50 +00:00
Chris Lattner
2051889d14 simplify/detangle some control flow.
llvm-svn: 80476
2009-08-30 05:00:50 +00:00
Chris Lattner
e5c5ff8f49 simplify and cleanup some code, remove some code that just
does constant folding of gep's: this is already handled in
a more general way.

No functionality change.

llvm-svn: 80475
2009-08-30 04:49:01 +00:00
Chris Lattner
df2191a33d default count-aa to -print-all. The whole reason to use count-aa is
to see what queries are being made by a transformation, we might as well
default to printing them.

llvm-svn: 80474
2009-08-30 04:25:40 +00:00
Bill Wendling
ccb2d3a3b8 Nuke moribund "std::string" version of EOL(..., Encoding).
llvm-svn: 80466
2009-08-30 00:28:57 +00:00
Dan Gohman
cc35ffe3df Remove an unnecessary Context argument.
llvm-svn: 80454
2009-08-29 23:39:38 +00:00
Dan Gohman
4fef698b89 Minor logic simplification.
llvm-svn: 80453
2009-08-29 23:37:49 +00:00
Dan Gohman
c9dbe1610e Add some comments.
llvm-svn: 80452
2009-08-29 23:36:57 +00:00
Dan Gohman
e0697de4c6 Cleanup whitespace and indentation.
llvm-svn: 80451
2009-08-29 23:35:16 +00:00
Dan Gohman
e5f1c4a5c2 Remove some unused fields.
llvm-svn: 80450
2009-08-29 23:34:14 +00:00
Dan Gohman
f7b76078bb CMOV_GR8 clobbers EFLAGS when its expansion involves an xor to set
a register to 0. This fixes PR4814.

llvm-svn: 80445
2009-08-29 22:19:15 +00:00
Benjamin Kramer
34020d0ab5 Inline empty destructor.
llvm-svn: 80431
2009-08-29 13:38:21 +00:00
Bill Wendling
095b3c55e8 Fix warning about non-virtual destructor.
llvm-svn: 80429
2009-08-29 12:31:38 +00:00
Bill Wendling
9dddea2ec3 - Add target lowering methods to get the preferred format for the FDE and LSDA
encodings.
- Make some of the values emitted by the FDEs dependent upon the pointer
  size. This is in line with how GCC does things. And it has the benefit of
  working for Darwin in 64-bit mode now.

llvm-svn: 80428
2009-08-29 12:20:54 +00:00