1
0
mirror of https://github.com/RPCS3/llvm-mirror.git synced 2024-10-20 19:42:54 +02:00
Commit Graph

50 Commits

Author SHA1 Message Date
Bill Wendling
0b2e131798 Update some tests to the new EH scheme.
llvm-svn: 138925
2011-09-01 00:58:03 +00:00
Eli Friedman
baf0f69f9a Move "atomic" and "volatile" designations on instructions after the opcode
of the instruction.

Note that this change affects the existing non-atomic load and store
instructions; the parser now accepts both forms, and the change is noted
in the release notes.

llvm-svn: 137527
2011-08-12 22:50:01 +00:00
Chris Lattner
a106725fc5 Land the long talked about "type system rewrite" patch. This
patch brings numerous advantages to LLVM.  One way to look at it
is through diffstat:
 109 files changed, 3005 insertions(+), 5906 deletions(-)

Removing almost 3K lines of code is a good thing.  Other advantages
include:

1. Value::getType() is a simple load that can be CSE'd, not a mutating
   union-find operation.
2. Types a uniqued and never move once created, defining away PATypeHolder.
3. Structs can be "named" now, and their name is part of the identity that
   uniques them.  This means that the compiler doesn't merge them structurally
   which makes the IR much less confusing.
4. Now that there is no way to get a cycle in a type graph without a named
   struct type, "upreferences" go away.
5. Type refinement is completely gone, which should make LTO much MUCH faster
   in some common cases with C++ code.
6. Types are now generally immutable, so we can use "Type *" instead 
   "const Type *" everywhere.

Downsides of this patch are that it removes some functions from the C API,
so people using those will have to upgrade to (not yet added) new API.  
"LLVM 3.0" is the right time to do this.

There are still some cleanups pending after this, this patch is large enough
as-is.

llvm-svn: 134829
2011-07-09 17:41:24 +00:00
Chris Lattner
9ec82f54d4 manually upgrade a bunch of tests to modern syntax, and remove some that
are either unreduced or only test old syntax.

llvm-svn: 133228
2011-06-17 03:14:27 +00:00
Nick Lewycky
7cc4d86ea6 Fix grammar in test.
llvm-svn: 131831
2011-05-22 01:16:00 +00:00
Eli Friedman
c00dc3f262 Add an obvious missing safety check to DAE::RemoveDeadArgumentsFromCallers.
llvm-svn: 126720
2011-03-01 00:33:47 +00:00
Anders Carlsson
c9781e5764 Teach DAE to look for functions whose arguments are unused, and change all callers to pass in an undefvalue instead.
llvm-svn: 123596
2011-01-16 21:25:33 +00:00
Devang Patel
8146cb492f Preserve debug info attached with call instruction while eliminating dead argument.
Radar 7927803

llvm-svn: 102760
2010-04-30 20:23:54 +00:00
Nick Lewycky
cc67a7f57e Revert r101213.
llvm-svn: 101231
2010-04-14 04:51:58 +00:00
Nick Lewycky
49c5407ceb Commit testcase for r101213.
llvm-svn: 101214
2010-04-14 03:46:42 +00:00
Chris Lattner
23334439e9 add newlines at the end of files.
llvm-svn: 100705
2010-04-07 22:53:17 +00:00
Nick Lewycky
f9a681fb61 Speculatively revert r94322 to see if it fixes darwin selfhost buildbot.
llvm-svn: 94331
2010-01-23 20:32:12 +00:00
Nick Lewycky
8bbb754c7c Teach DAE that even though it can't modify the function signature of an
externally visible function, it can still find all callers of it and replace
the parameters to a dead argument with undef.

llvm-svn: 94322
2010-01-23 19:19:34 +00:00
Dan Gohman
5fa04f2707 Delete useless trailing semicolons.
llvm-svn: 92740
2010-01-05 17:55:26 +00:00
Dan Gohman
205b641954 Change tests from "opt %s" to "opt < %s" so that opt doesn't see the
input filename so that opt doesn't print the input filename in the
output so that grep lines in the tests don't unintentionally match
strings in the input filename.

llvm-svn: 81537
2009-09-11 18:01:28 +00:00
Dan Gohman
c95df8b6d8 Use opt -S instead of piping bitcode output through llvm-dis.
llvm-svn: 81257
2009-09-08 22:34:10 +00:00
Dan Gohman
8d84372836 Change these tests to feed the assembly files to opt directly, instead
of using llvm-as, now that opt supports this.

llvm-svn: 81226
2009-09-08 16:50:01 +00:00
Chris Lattner
6dce8d4135 aha, DAE does have to think about PHI nodes. Many thanks to "Dr Evil" (aka Duncan)
for pointing this out :)

llvm-svn: 67212
2009-03-18 16:48:45 +00:00
Chris Lattner
7bef74e92f Fix PR3807 by inserting 'insertelement' instructions in the normal dest of
an invoke instead of after the invoke (in its block), which is invalid.

llvm-svn: 67139
2009-03-18 00:31:45 +00:00
Chris Lattner
3680a9598e adjust test to make it more robust
llvm-svn: 65739
2009-03-01 00:24:40 +00:00
Devang Patel
7536edca09 Support inreg, zext and sext as return value attributes.
llvm-svn: 56801
2008-09-29 20:49:50 +00:00
Matthijs Kooijman
0625e0fda6 Un-XFAIL multdeadretval, since instcombine now properly handles the mess deadargelim leaves behind :-)
llvm-svn: 53674
2008-07-16 12:56:52 +00:00
Matthijs Kooijman
45140a0497 XFAIL the multdeadretval test for now, I will be fixing instcombine to make it work again tomorrow.
llvm-svn: 53614
2008-07-15 16:05:09 +00:00
Matthijs Kooijman
48fd953b49 Remove a few tests which no longer hold for deadargelim (since it is now
allowed to canonicalize return values).

Add a test that checks if return value and function attributes are not removed.

llvm-svn: 53612
2008-07-15 14:57:01 +00:00
Matthijs Kooijman
21162f1db9 Add a testcase for the canonicalizations now performed by deadargelim.
llvm-svn: 53611
2008-07-15 14:42:58 +00:00
Matthijs Kooijman
f940585c1c Make deadargelim a bit less smart, so it doesn't choke on nested structs as
return values that are still (partially) live. Instead of updating all uses of
a call instruction after removing some elements, it now just rebuilds the
original struct (With undef gaps where the unused values were) and leaves it to
instcombine to clean this up.

The added testcase still fails currently, but this is due to instcombine which
isn't good enough yet. I will fix that part next.

llvm-svn: 53608
2008-07-15 14:03:10 +00:00
Matthijs Kooijman
02ffbaf305 Fix typo.
llvm-svn: 53605
2008-07-15 13:15:10 +00:00
Matthijs Kooijman
ca5124a630 Restructure dead argument elimination, try #3 :-)
Rewrite the DeadArgumentElimination pass, to use a more explicit tracking of
dependencies between return values and/or arguments. Also make the handling of
arguments and return values the same.

The pass now looks properly inside returned structs, but only at the first
level (ie, not inside nested structs).

This version fixed a few more bugs and was cleaned up a bit. It now passes all
of LLVM's testing, and should still pass SPEC2006. There is still a minor bug
with regard to returning nested structs. Since there is currently nothing that
emits such IR, I will fix that in a seperate commit (partly because it requires
a non-trivial fix).

llvm-svn: 53400
2008-07-10 10:24:08 +00:00
Evan Cheng
407d3b820b XFAIL for now.
llvm-svn: 52795
2008-06-26 22:09:29 +00:00
Matthijs Kooijman
ff03ea8aeb Commit the new DeadArgElim pass again, this time with the gcc bootstrap failures fixed.
Also add a testcase to reproduce the gcc bootstrap failure in very much reduced form.

llvm-svn: 52677
2008-06-24 16:30:26 +00:00
Duncan Sands
dd3b6236c8 This file is empty.
llvm-svn: 52596
2008-06-21 20:26:50 +00:00
Evan Cheng
b65bceda9c Back out Matthijs' DAE patches. It's miscompiling gcc driver.
llvm-svn: 52570
2008-06-21 00:31:44 +00:00
Matthijs Kooijman
564fe9092f Add testcase that checks that DeadArgElim doesn't touch stuff it shouldn't touch.
llvm-svn: 52540
2008-06-20 15:38:22 +00:00
Matthijs Kooijman
a3222e3730 Recommit r52459, rewriting of the dead argument elimination pass.
This is a fixed version that no longer uses multimap::equal_range, which
resulted in a pointer invalidation problem.

Also, DAE::InspectedFunctions was not really necessary, so it got removed.

Lastly, this version no longer applies the extra arg hack on functions who did
not have any arguments to start with.

llvm-svn: 52532
2008-06-20 09:36:16 +00:00
Owen Anderson
597b40ed60 Remove this test until the corresponding patch is reapplied because it's causing make check to crash for some people.
llvm-svn: 52473
2008-06-18 22:37:31 +00:00
Matthijs Kooijman
b7e2818227 Rewrite the DeadArgumentElimination pass, to use a more explicit tracking of
dependencies between return values and/or arguments. Also make the handling of
arguments and return values the same.

The pass now looks properly inside returned structs, but only at the first                                                                                     
level (ie, not inside nested structs).

Also add a testcase for testing various variations of (multiple) dead rerturn
values.

llvm-svn: 52459
2008-06-18 11:12:53 +00:00
Matthijs Kooijman
e01197eaa9 Store the result of multiple identical run lines in a temporary file.
llvm-svn: 52314
2008-06-16 12:21:25 +00:00
Gabor Greif
807c2df887 sabre brings to my attention that the 'tr' suffix is also obsolete
llvm-svn: 51349
2008-05-20 21:00:03 +00:00
Gabor Greif
d8a4dbb5da Rename the last test with .llx extension to .ll, resolve duplicate test by renaming to isnan2. Now that no test has llx ending there is no need to search for them from dg.exp too.
llvm-svn: 51328
2008-05-20 19:52:04 +00:00
Tanya Lattner
c072619922 Remove llvm-upgrade and update test cases.
llvm-svn: 47793
2008-03-01 09:15:35 +00:00
Evan Cheng
ca434b34ff Test case for varargs parameter attribute issue I just fixed.
llvm-svn: 46127
2008-01-17 07:26:31 +00:00
Duncan Sands
6f49217a5e When DAE drops the varargs part of a function, ensure any
attributes on the vararg call arguments are also dropped.

llvm-svn: 45892
2008-01-11 23:13:45 +00:00
Duncan Sands
85ca85c070 Make DAE not wipe out attributes on calls, and not drop
return attributes on the floor.  In the case of a call
to a varargs function where the varargs arguments are
being removed, any call attributes on those arguments
need to be dropped.  I didn't do this because I plan to
make it illegal to have such attributes (see next patch).
With this change, compiling the gcc filter2 eh test at -O0
and then running opt -std-compile-opts on it results in
a correctly working program (compiling at -O1 or higher
results in the test failing due to a problem with how we
output eh info into the IR).

llvm-svn: 45285
2007-12-21 19:16:16 +00:00
Chris Lattner
efaf4ba65d Fix PR1735 and Transforms/DeadArgElim/2007-10-18-VarargsReturn.ll by
fixing some obviously broken code :(

llvm-svn: 43141
2007-10-18 18:49:29 +00:00
John Criswell
57e5ed4b5a Convert .cvsignore files
llvm-svn: 37801
2007-06-29 16:35:07 +00:00
Reid Spencer
df17fa8ef9 For PR1319:
Remove && from the end of the lines to prevent tests from throwing run
lines into the background. Also, clean up places where the same command
is run multiple times by using a temporary file.

llvm-svn: 36142
2007-04-16 17:36:08 +00:00
Reid Spencer
d1d4897d3f For PR1319:
Upgrade to use new Tcl exec based test harness.

llvm-svn: 36062
2007-04-15 08:30:33 +00:00
Reid Spencer
56b310ae49 Make the llvm-runtest function much more amenable by eliminating all the
global variables that needed to be passed in. This makes it possible to
add new global variables with only a couple changes (Makefile and llvm-dg.exp)
instead of touching every single dg.exp file.

llvm-svn: 35918
2007-04-11 19:56:59 +00:00
Chris Lattner
1c153a1e17 Testcase for a bug responsible for GCC bootstrap failure, fallout from PR411.
llvm-svn: 34004
2007-02-07 19:28:52 +00:00
Reid Spencer
4572ce85b0 Regression is gone, don't try to find it on clean target.
llvm-svn: 33296
2007-01-17 07:59:14 +00:00