Commit Graph

51464 Commits

Author SHA1 Message Date
Evan Cheng 904199547b Revert r80926. It causes loop unswitch assertion and slow down some JIT tests significantly.
llvm-svn: 81101
2009-09-06 02:26:10 +00:00
Daniel Dunbar 10ea8bb8e0 Revert "Include optional subclass flags, such as inbounds, nsw, etc., ...", this
breaks MiniSAT on x86_64.

llvm-svn: 81098
2009-09-06 00:11:24 +00:00
Daniel Dunbar db5d4521f5 Fix spacing.
llvm-svn: 81097
2009-09-06 00:00:13 +00:00
Nick Lewycky d592399beb Now that googletest can print ConstantRange, use EXPECT_EQ when testing for
equality. Prefer EXPECT_EQ(foo, Full) over EXPECT_TRUE(foo.isFullSet()) because
the former will print out the contents of the constant range that failed.

llvm-svn: 81094
2009-09-05 18:27:40 +00:00
Jeffrey Yasskin b797fdc365 Teach googletest to use raw_ostream instead of just std::ostream.
This can break when there are implicit conversions from types raw_ostream
understands but std::ostream doesn't, but it increases the number of cases that
Just Work.

llvm-svn: 81093
2009-09-05 18:16:17 +00:00
Daniel Dunbar 25900fc909 Quote another '%S' in a test.
llvm-svn: 81088
2009-09-05 12:38:44 +00:00
Daniel Dunbar faa0fa5c83 Rename %S metavar to %M (clang uses %S for the basename of the test file).
llvm-svn: 81087
2009-09-05 12:38:35 +00:00
Daniel Dunbar 5e606cb503 Temporary test files should use %t.
llvm-svn: 81086
2009-09-05 12:38:26 +00:00
Daniel Dunbar b9a562b7c4 Don't depend on arch specific global prefix.
llvm-svn: 81084
2009-09-05 11:53:06 +00:00
Daniel Dunbar b9ea94c990 Eliminate uses of %prcontext.
- I'd appreciate it if someone else eyeballs my changes to make sure I captured
   the intent of the test.

llvm-svn: 81083
2009-09-05 11:35:16 +00:00
Daniel Dunbar 6b3153bb53 opt: Add -S option to print output as LLVM assembly.
llvm-svn: 81082
2009-09-05 11:34:53 +00:00
Daniel Dunbar 77e2f2583b Eliminate some Tclisms.
llvm-svn: 81081
2009-09-05 11:34:46 +00:00
Benjamin Kramer 8691eecb91 Delete unused #include.
llvm-svn: 81076
2009-09-05 08:50:14 +00:00
Bob Wilson 7f20002993 Stabilize the order of live intervals in the priority_queue used by the
linear scan reg alloc.  This fixes a problem I ran into where extracting
a function from a larger file caused the generated code to change (masking
the problem I was trying to debug) because the allocator behaved differently.

This changes the results for two X86 regression checks.  stack-color-with-reg
is improved, with one less instruction, but pr3495 is worse, with one more
copy.  As far as I can tell, these tests were just getting lucky or unlucky,
so I've changed the expected results.

llvm-svn: 81060
2009-09-05 01:19:16 +00:00
Devang Patel f03667e20e Detect VLAs.
Do not use DenseMap operator[] because it inserts new entry if lookup fails. Use find() to check an entry in a DenseMap first.

llvm-svn: 81058
2009-09-05 00:34:14 +00:00
Devang Patel f5d5360065 Ignore malformed global variable debug info.
llvm-svn: 81055
2009-09-04 23:59:07 +00:00
Benjamin Kramer 21d15aa591 Prune #includes.
llvm-svn: 81052
2009-09-04 22:45:23 +00:00
Benjamin Kramer 865f7deab5 Remove an unneeded call to c_str().
llvm-svn: 81051
2009-09-04 22:44:03 +00:00
Kevin Enderby 9c0f7fc746 Added AsmToken enum constants to MCAsmLexer.h for '[', ']', '{', and '}' in
preparation of supporting other targets. Then changed the lexer to parse these
as tokens.

llvm-svn: 81050
2009-09-04 22:40:31 +00:00
Kevin Enderby f92f9909c4 Added the AsmToken::Hash enum constant to MCAsmLexer.h in preparation of
supporting other targets.  Changed the code to pass MCAsmInfo to the parser
and the lexer.  Then changed the lexer to use CommentString from MCAsmInfo
instead of a literal '#' character.

llvm-svn: 81046
2009-09-04 21:45:34 +00:00
Devang Patel a33c5a922d While replacing an MDNode elment, properly update MDNode's operand list.
MDNode's operand list does not include all elements.

llvm-svn: 81045
2009-09-04 21:32:05 +00:00
Andreas Neustifter b7d704dac3 Prevent warnings on compilers for which its not clear that assert won't return.
llvm-svn: 81044
2009-09-04 21:22:04 +00:00
Lang Hames 7af06f63bf Removed yet another std::ostream reference.
llvm-svn: 81042
2009-09-04 21:03:07 +00:00
Lang Hames bba76db033 Removed some junk and a std::ostream operator that was hanging around.
llvm-svn: 81041
2009-09-04 20:54:51 +00:00
Lang Hames 3fffe62177 Replaces uses of unsigned for indexes in LiveInterval and VNInfo with
a new class, MachineInstrIndex, which hides arithmetic details from
most clients. This is a step towards allowing the register allocator
to update/insert code during allocation.

llvm-svn: 81040
2009-09-04 20:41:11 +00:00
Dale Johannesen d14b67e931 Test for llvm-gcc commit 81037.
llvm-svn: 81038
2009-09-04 20:19:09 +00:00
Andreas Neustifter 5673c0aace Updated tests to use ProfileVerifer to test ProfileLoader and ProfileEstimator.
(Keep disabled test disabled until selfhosted build issue is resolved.)

llvm-svn: 81008
2009-09-04 17:21:59 +00:00
Andreas Neustifter 8f166f6a36 Cleaned up ProfileVerifierPass.
(See http://lists.cs.uiuc.edu/pipermail/llvm-commits/Week-of-Mon-20090831/086219.html)

llvm-svn: 81007
2009-09-04 17:15:10 +00:00
Andreas Neustifter 18156bd75c Converted MaximumSpanningTree algorithm to a generic template, this could go
into llvm/ADT.

llvm-svn: 81001
2009-09-04 12:34:44 +00:00
Dan Gohman 0c2477c26b Include optional subclass flags, such as inbounds, nsw, etc., in the
Constant uniquing tables. This allows distinct ConstantExpr objects
with the same operation and different flags.

Even though a ConstantExpr "a + b" is either always overflowing or
never overflowing (due to being a ConstantExpr), it's still necessary
to be able to represent it both with and without overflow flags at
the same time within the IR, because the safety of the flag may
depend on the context of the use. If the constant really does overflow,
it wouldn't ever be safe to use with the flag set, however the use
may be in code that is never actually executed.

This also makes it possible to merge all the flags tests into a single test.

llvm-svn: 80998
2009-09-04 12:08:11 +00:00
Duncan Sands bc74cae983 Use delete[] to match new[] (found by valgrind).
llvm-svn: 80997
2009-09-04 11:59:43 +00:00
Evan Cheng 3d2fce01aa Run branch folding if if-converter make some transformations.
llvm-svn: 80994
2009-09-04 07:47:40 +00:00
Evan Cheng fc4eef183b Fix comment for consistency sake.
llvm-svn: 80993
2009-09-04 07:46:30 +00:00
Daniel Dunbar 30e30587eb Remove stale greps.
llvm-svn: 80986
2009-09-04 05:07:52 +00:00
Daniel Dunbar 59eb5ef136 Update lib deps.
llvm-svn: 80985
2009-09-04 05:07:44 +00:00
Bob Wilson 36d8c75eca Convert tests to FileCheck.
llvm-svn: 80983
2009-09-04 04:07:19 +00:00
Jim Grosbach 1eaa90b901 Whitespace cleanup
llvm-svn: 80978
2009-09-04 01:38:51 +00:00
Eric Christopher a3438c8bc2 If there's a calling convention attach it to the rewind function call.
llvm-svn: 80976
2009-09-04 01:14:14 +00:00
Bob Wilson e072f8eedb Convert a test to FileCheck.
llvm-svn: 80975
2009-09-04 00:32:31 +00:00
Evan Cheng 1f6e5eb07b Funky indentation.
llvm-svn: 80971
2009-09-03 23:54:22 +00:00
Daniel Dunbar a48a2f6055 Revert "--- Reverse-merging r80908 into '.':", I already "fixed" this.
llvm-svn: 80970
2009-09-03 23:40:10 +00:00
Dan Gohman e4ca02da1b Revert 80959. It isn't sufficient to solve the full problem. And it
introduced regressions in the Ocaml bindings tests.

llvm-svn: 80969
2009-09-03 23:34:49 +00:00
Erick Tryzelaar 19e1eec248 Replace ocamlc tests with ocamlopt tests since they're less noisy.
There's a bug with ocamlc that uses "char*" instead of "const char*" for
global string variables. This causes g++ to be very noisy when linking
ocamlc programs. That's why the ocaml test used to cat to /dev/null.
ocamlopt doesn't have this problem, so we can get rid of the >/dev/null,
which may obscure some problems.

llvm-svn: 80968
2009-09-03 23:27:31 +00:00
Bill Wendling 92291f6ad0 --- Reverse-merging r80908 into '.':
D    test/Analysis/Profiling

--- Reverse-merging r80907 into '.':
U    lib/Analysis/ProfileInfoLoaderPass.cpp

Attempt to remove failure in the self-hosting build bot.

llvm-svn: 80966
2009-09-03 23:13:46 +00:00
Daniel Dunbar bc52e4fe73 Add test for PR4873, which works for me.
llvm-svn: 80965
2009-09-03 22:57:02 +00:00
Dan Gohman aa92dc1e61 LLVM currently represents floating-point negation as -0.0 - x. Fix
FastISel to recognize this pattern and emit a floating-point
negation using xor.

llvm-svn: 80963
2009-09-03 22:53:57 +00:00
David Goodwin 1d5d245453 Don't crash when target has no itineraries.
llvm-svn: 80962
2009-09-03 22:48:51 +00:00
Bill Wendling ea0185fe91 If we've pushed registers onto the stack, but aren't adjusting the stack pointer
(i.e., there are no local variables and stuff), we still need to output FDE
information for the pushed registers.

llvm-svn: 80960
2009-09-03 22:19:22 +00:00
Dan Gohman 2a53b30f6d Remove the API for creating ConstantExprs with the nsw, nuw, inbounds,
and exact flags. Because ConstantExprs are uniqued, creating an
expression with this flag causes all expressions with the same operands
to have the same flag, which may not be safe. Add, sub, mul, and sdiv
ConstantExprs are usually folded anyway, so the main interesting flag
here is inbounds, and the constant folder already knows how to set the
inbounds flag automatically in most cases, so there isn't an urgent need
for the API support.

This can be reconsidered in the future, but for now just removing these
API bits eliminates a source of potential trouble with little downside.

llvm-svn: 80959
2009-09-03 22:17:40 +00:00
David Goodwin 6c08cfcfa0 Create our own block initializer for kill fixups as the scheduling one wasn't doing the right thing.
llvm-svn: 80958
2009-09-03 22:15:25 +00:00