Commit Graph

54348 Commits

Author SHA1 Message Date
Mikhail Glushenkov 5551c207cd Move the handling of CommaSeparated options into ProvideOption.
Makes '--comma-separated val1,val2' mean the same thing as
'--comma-separated=val1,val2' (that is, 'val1' and 'val2' are not lumped
together as 'val1,val2'). Also declutters the main loop a bit.

llvm-svn: 89463
2009-11-20 17:23:17 +00:00
Duncan Sands 9e26aac773 Fix PR5563, an expensive checks failure when running on
tests/Transforms/InstCombine/shufflemask-undef.ll.  If
anyone cares, the use of 2*e here (and the equivalent
all over the place in instcombine) seems wrong, though
harmless: it should really be twice the length of the
input vector.  I think shufflevector used to require
that the mask have the same length as the input, but I
don't think that's true any more.  I don't care enough
about vectors to do anything about this...

llvm-svn: 89456
2009-11-20 13:19:51 +00:00
Duncan Sands cc0a0cb4b7 Fix PR5558, which was caused by a wrong fix for PR3393 (see commit 63048),
which was an expensive checks failure due to a bug in the checking.  This
patch in essence reverts the original fix for PR3393, and refixes it by a
tweak to the way expensive checking is done.

llvm-svn: 89454
2009-11-20 10:45:10 +00:00
Benjamin Kramer e986c44a9b Try to work around grep's "Binary file (standard input) matches" complaints seen
on ppc buildbot.

llvm-svn: 89452
2009-11-20 09:53:25 +00:00
Daniel Dunbar fa559f46c4 Fix -march= name for x86-64.
llvm-svn: 89445
2009-11-20 02:52:08 +00:00
Dan Gohman 20c8ab655e Fix fast-isel to avoid selecting the return instruction if a
tail call has been encountered.

llvm-svn: 89444
2009-11-20 02:51:26 +00:00
Jim Grosbach fc81352e3f Remove verifySizes() since it's not adding much value.
llvm-svn: 89443
2009-11-20 02:32:06 +00:00
Evan Cheng bbd50b0f78 Also CSE non-pic load from constant pools.
llvm-svn: 89440
2009-11-20 02:10:27 +00:00
Dan Gohman f4fe57ad90 Add an experimental option to run gep-splitting and no-load GVN
just before codegen.

llvm-svn: 89439
2009-11-20 02:03:44 +00:00
Dan Gohman 6d919f1613 Simplify this code; it's not necessary to check isIdentifiedObject here
because if the results from getUnderlyingObject match, the values must
be from the same underlying object, even if we don't know what that
object is.

llvm-svn: 89434
2009-11-20 01:34:03 +00:00
Jakob Stoklund Olesen 2bbeaa8774 Add MachineBasicBlock::getName, and use it in place of getBasicBlock()->getName.
Fix debug code that assumes getBasicBlock never returns NULL.

llvm-svn: 89428
2009-11-20 01:17:03 +00:00
Dan Gohman 62167b9516 Teach getSmallConstantTripMultiple about Shl operators.
llvm-svn: 89426
2009-11-20 01:09:34 +00:00
Evan Cheng 81a2851bcb Fix codegen of conditional move of immediates. We were not making use of the immediate forms of cmov instructions at all.
llvm-svn: 89423
2009-11-20 00:54:03 +00:00
Lang Hames c6e434573c Removed references to LiveStacks from Spiller.* . They're no longer needed.
llvm-svn: 89422
2009-11-20 00:53:30 +00:00
Dan Gohman 91449224e8 Refine the capture tracking rules for comparisons to be more
careful about crazy methods of capturing pointers using comparisons.
Comparisons of identified objects with null in the default address
space are not captures. And, comparisons of two pointers within the
same identified object are not captures.

llvm-svn: 89421
2009-11-20 00:50:47 +00:00
Dan Gohman 01956f5a6b Use isVoidTy().
llvm-svn: 89419
2009-11-20 00:43:11 +00:00
Bill Wendling c0cc2ae45b Specify proper arch and triple for 64-bit.
llvm-svn: 89418
2009-11-20 00:40:21 +00:00
Bill Wendling 7dc8d2d025 Testcase for r89415.
llvm-svn: 89417
2009-11-20 00:32:16 +00:00
Eric Christopher a6380af658 Update comment to reflect instruction.
llvm-svn: 89414
2009-11-20 00:21:55 +00:00
Dan Gohman 772f922acb Refine this to only apply to null in the default address space.
llvm-svn: 89411
2009-11-19 23:53:49 +00:00
Jeffrey Yasskin 34fb6838bc Try to fix JITTest.FarCallToKnownFunction on ARM and PPC.
llvm-svn: 89410
2009-11-19 23:42:58 +00:00
Oscar Fuentes 36dd7d5f5c Use CMAKE_DL_LIBS instead of raw library name. Fixes bug 5536.
Patch by Tobias Grosser!

llvm-svn: 89406
2009-11-19 23:21:43 +00:00
David Goodwin dd1c6198d4 Fix a couple of problems with maintaining liveness information for antidep breaking.
llvm-svn: 89404
2009-11-19 23:12:37 +00:00
Jim Grosbach b73918c42d When placing constant islands and adjusting for alignment padding, inline
assembly can confuse things utterly, as it's assumed that instructions in
inline assembly are 4 bytes wide. For Thumb mode, that's often not true,
so the calculations for when alignment padding will be present get thrown off,
ultimately leading to out of range constant pool entry references. Making
more conservative assumptions that padding may be necessary when inline asm
is present avoids this situation.

llvm-svn: 89403
2009-11-19 23:10:28 +00:00
Dan Gohman 94e617627d Extend CaptureTracking to indicate when a value is never stored, even
if it is not ultimately captured. Teach BasicAliasAnalysis that a 
local object address which does not escape and is never stored does
not alias with a value resulting from a load.

llvm-svn: 89398
2009-11-19 21:57:48 +00:00
Evan Cheng b6c7704a8d Refactor cmov selection code out to a separate function. No functionality change.
llvm-svn: 89396
2009-11-19 21:45:22 +00:00
Dan Gohman 0a2ba1068e Comparing a pointer with null is not a capture.
llvm-svn: 89389
2009-11-19 21:34:07 +00:00
Duncan Sands c8cee4f64f Only run this mutex test if threading is enabled. This
fixes PR5395.

llvm-svn: 89385
2009-11-19 20:48:14 +00:00
Jakob Stoklund Olesen 331e6880a5 Place new basic blocks immediately after their predecessor when splitting
critical edges in PHIElimination.

This has a huge impact on regalloc performance, and we recover almost all of
the 10% compile time regression that edge splitting introduced.

llvm-svn: 89381
2009-11-19 19:42:16 +00:00
Bill Wendling 31c74dbb10 Reverting the EH table patches.
$ svn merge -c -89279 https://llvm.org/svn/llvm-project/llvm/trunk
--- Reverse-merging r89279 into '.':
U    lib/CodeGen/AsmPrinter/DwarfException.cpp
U    lib/Target/TargetLoweringObjectFile.cpp
$ svn merge -c -89270 https://llvm.org/svn/llvm-project/llvm/trunk
--- Reverse-merging r89270 into '.':
G    lib/CodeGen/AsmPrinter/DwarfException.cpp
G    lib/Target/TargetLoweringObjectFile.cpp

llvm-svn: 89379
2009-11-19 19:21:09 +00:00
Johnny Chen b3b8209d77 Added NLdStLN which is similar to NLdSt with the exception that op7_4 is not
fully specified at this level.  Subclasses of NLdStLN can specify selective
bit(s) for Inst{7-4}, as is done for VLD[234]LN* and VST[234]LN* inside
ARMInstrNEON.td.

llvm-svn: 89377
2009-11-19 19:20:17 +00:00
David Greene 50909c0595 Fix a small bug.
Fix one case we missed to make sure we reserve registers from
allocation.

llvm-svn: 89376
2009-11-19 19:09:39 +00:00
Dan Gohman cbc6ebb6fd Enable hoisting of loads from constant memory by default. In cases where
they are lowered to instruction sequences more complex than a simple
load, such that CodeGen cannot rematerialize them, a reload from a
spill slot is likely to be cheaper than the complex sequence.

llvm-svn: 89374
2009-11-19 19:00:10 +00:00
Daniel Dunbar 956c1581fa Use StringRef::min instead of std::min.
llvm-svn: 89372
2009-11-19 18:53:18 +00:00
Jim Grosbach 36a5bf82bf fix typo
llvm-svn: 89369
2009-11-19 18:23:19 +00:00
Daniel Dunbar 73cb65f704 TableGen/OptParser: When ordering options, make "sentinel" options appear before
everything else.

llvm-svn: 89368
2009-11-19 18:22:16 +00:00
Mikhail Glushenkov 1d9f1fe7cc Trailing whitespace.
llvm-svn: 89364
2009-11-19 17:29:36 +00:00
Mikhail Glushenkov 3faece9462 Make example/Hello compile again.
llvm-svn: 89363
2009-11-19 17:29:25 +00:00
Dan Gohman 91431b008b Fix a typo in a comment.
llvm-svn: 89360
2009-11-19 16:35:11 +00:00
Benjamin Kramer 1dfe1bead6 cstdlib is not automatically included with StringRef anymore.
llvm-svn: 89359
2009-11-19 16:08:04 +00:00
Benjamin Kramer 99b5bd9074 Reenable Split2 StringRef test with Apple gcc.
llvm-svn: 89357
2009-11-19 16:04:41 +00:00
David Greene f37756d609 Add support for spreading register allocation.
Add a -linearscan-skip-count argument (default to 0) that tells the
allocator to remember the last N registers it allocated and skip them
when looking for a register candidate.  This tends to spread out
register usage and free up post-allocation scheduling at the cost of
slightly more register pressure.  The primary benefit is the ability
to backschedule reloads.

This is turned off by default.

llvm-svn: 89356
2009-11-19 15:55:49 +00:00
Benjamin Kramer 879f8c1382 Remove the now obsolete algorithm include from StringRef.h.
llvm-svn: 89354
2009-11-19 15:48:14 +00:00
Torok Edwin 5400cd9b8c Workaround PR5482, because all the gcc versions that I had were miscompiling StringRef:
4.2.4, 4.3.4, 4.4.2.
The workaround is to use a local min/max implementation that takes an integer
param, and not a reference to integer param (like std::min does).

llvm-svn: 89352
2009-11-19 15:39:50 +00:00
Benjamin Kramer 3846506466 Unbreak x64 MSVC build. Patch by Nicolas Capens!
llvm-svn: 89341
2009-11-19 12:17:31 +00:00
Edward O'Callaghan ba993b8add Add PS3 Triple class, Credit to John Thompson.
llvm-svn: 89339
2009-11-19 11:59:00 +00:00
Evan Cheng 82adca8373 80 col violation.
llvm-svn: 89337
2009-11-19 08:16:50 +00:00
Daniel Dunbar 0b2099ad5f Unbreak test, Bruno please check.
llvm-svn: 89329
2009-11-19 07:18:49 +00:00
Evan Cheng b18525937c More consistent thumb1 asm printing.
llvm-svn: 89328
2009-11-19 06:57:41 +00:00
Evan Cheng 2a6c92fcb6 Shrink ldr / str [sp, imm0-1024] to 16-bit instructions.
llvm-svn: 89326
2009-11-19 06:32:27 +00:00