Commit Graph

60281 Commits

Author SHA1 Message Date
Dan Gohman
71cee76d26 Temporarily disable SelectionDAG kill flags, which are causing trouble.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@102680 91177308-0d34-0410-b5e6-96231b3b80d8
2010-04-30 00:32:51 +00:00
Jeffrey Yasskin
8c818fc35c Fix the OProfileJITEventListener build after r101844 removed
MachineFunction::DefaultDebugLoc.  We now use the same technique as
DwarfDebug::beginFunction to find the starting line number for a
function.



git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@102679 91177308-0d34-0410-b5e6-96231b3b80d8
2010-04-30 00:16:10 +00:00
Dan Gohman
47bd03b277 Set register kill flags on the SelectionDAG path, at least in the
easy cases.


git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@102678 91177308-0d34-0410-b5e6-96231b3b80d8
2010-04-30 00:08:21 +00:00
Jakob Stoklund Olesen
f07fc974d3 Reject really weird coalescer case when trying to merge identical subregisters
of different register classes. e.g.

  %reg1048:3<def> = EXTRACT_SUBREG %RAX<kill>, 3

Where %reg1048 is a GR32 register. This is not impossible to handle, but it is
pretty hard and very rare.

This should unbreak the dragonegg builder.

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@102672 91177308-0d34-0410-b5e6-96231b3b80d8
2010-04-29 23:47:46 +00:00
Nick Lewycky
8d0e1bcc92 The llc -f flag was removed.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@102670 91177308-0d34-0410-b5e6-96231b3b80d8
2010-04-29 23:37:44 +00:00
Dan Gohman
ffce6f1343 Don't leave Base.FrameIndex uninitialized, so that it doesn't
print randomly in debug output.


git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@102668 91177308-0d34-0410-b5e6-96231b3b80d8
2010-04-29 23:30:41 +00:00
Chris Lattner
c799c55a33 add some more (void)'s to prototypes for PR6961
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@102667 91177308-0d34-0410-b5e6-96231b3b80d8
2010-04-29 23:27:32 +00:00
Dan Gohman
a555ac9d15 Fix typos in assertion strings.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@102666 91177308-0d34-0410-b5e6-96231b3b80d8
2010-04-29 23:25:34 +00:00
Jakob Stoklund Olesen
02104df05f Slightly verboser debug spew from coalescer
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@102663 91177308-0d34-0410-b5e6-96231b3b80d8
2010-04-29 22:21:48 +00:00
Devang Patel
22070e88f2 Missed earlier. This is part of previous check-in. (r102661 - refactor.)
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@102662 91177308-0d34-0410-b5e6-96231b3b80d8
2010-04-29 20:48:12 +00:00
Devang Patel
719f6a9d9c Refactor.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@102661 91177308-0d34-0410-b5e6-96231b3b80d8
2010-04-29 20:40:36 +00:00
Dale Johannesen
8c5358c936 Make naked functions work on PPC.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@102657 91177308-0d34-0410-b5e6-96231b3b80d8
2010-04-29 19:32:19 +00:00
Devang Patel
67a444ca36 Print variable scope name in DEBUG_VALUE comment. Useful in some cases. e.g.
##DEBUG_VALUE: runOnMachineFunction:this <- RDI+0
	##DEBUG_VALUE: runOnMachineFunction:fn <- RSI+0
	##DEBUG_VALUE: DeadDefs <- undef ## SimpleRegisterCoalescing.cpp:2706
	##DEBUG_VALUE: getRegInfo:this <- [%rsp+$56]+$0
	##DEBUG_VALUE: getTarget:this <- [%rsp+$56]+$0



git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@102655 91177308-0d34-0410-b5e6-96231b3b80d8
2010-04-29 18:52:10 +00:00
Evan Cheng
bd6cb4ba1f Remove DBG_VALUE which reference dead stack slots.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@102654 91177308-0d34-0410-b5e6-96231b3b80d8
2010-04-29 18:51:00 +00:00
Devang Patel
a83ce98d5f DO not push DBG_VALUE machine instructions for inlined fuction arguments in entry block.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@102653 91177308-0d34-0410-b5e6-96231b3b80d8
2010-04-29 18:50:36 +00:00
Evan Cheng
3e6fe5ec17 Add DenseMapInfo for int.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@102652 91177308-0d34-0410-b5e6-96231b3b80d8
2010-04-29 18:50:35 +00:00
Dan Gohman
281ead4da6 llc no longer requires the -f option to overwrite files.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@102651 91177308-0d34-0410-b5e6-96231b3b80d8
2010-04-29 18:46:52 +00:00
Bob Wilson
619d03fa04 Don't remove libLTO.dylib if it's not being installed in Developer/usr/lib;
just leave it in Developer/usr/local/lib.


git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@102646 91177308-0d34-0410-b5e6-96231b3b80d8
2010-04-29 18:04:29 +00:00
Dan Gohman
5768ea9ca1 Elaborate on a comment.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@102637 91177308-0d34-0410-b5e6-96231b3b80d8
2010-04-29 16:57:54 +00:00
Daniel Dunbar
8ae93e77e8 Remove dead option.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@102621 91177308-0d34-0410-b5e6-96231b3b80d8
2010-04-29 16:29:02 +00:00
Duncan Sands
e704d9d89c Verify metadata harder. In particular, check that module
level metadata does not have any function local operands.
This would have caught the problem found in PR6112.


git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@102620 91177308-0d34-0410-b5e6-96231b3b80d8
2010-04-29 16:10:30 +00:00
Duncan Sands
e57f048b91 Fix comment typo.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@102612 91177308-0d34-0410-b5e6-96231b3b80d8
2010-04-29 12:32:45 +00:00
Evan Cheng
8fed76115e Add comment.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@102606 91177308-0d34-0410-b5e6-96231b3b80d8
2010-04-29 06:58:53 +00:00
Torok Edwin
e8ab3bd3a5 Fix PR6910.
Limit alignment in SmallVector 8, otherwise GCC assumes 16 byte alignment.
opetaror new, and malloc only return 8-byte aligned memory on 32-bit Linux,
which cause a crash if code is compiled with -O3 (or -ftree-vectorize) and some
SmallVector code is vectorized.


git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@102604 91177308-0d34-0410-b5e6-96231b3b80d8
2010-04-29 06:43:12 +00:00
Evan Cheng
a36acad67d Re-enable 102565 with fixes.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@102602 91177308-0d34-0410-b5e6-96231b3b80d8
2010-04-29 06:33:38 +00:00
Nick Lewycky
28edeb765b Fix typo.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@102599 91177308-0d34-0410-b5e6-96231b3b80d8
2010-04-29 05:54:29 +00:00
Evan Cheng
3f54c64a98 Load folding tail call should not use ebp / rbp after it's popped. PEI
should use esp / rsp to reference frame instead.


git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@102596 91177308-0d34-0410-b5e6-96231b3b80d8
2010-04-29 05:08:22 +00:00
Mon P Wang
b9a01bcf48 Add support for assemblers that don't support periods in a name
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@102594 91177308-0d34-0410-b5e6-96231b3b80d8
2010-04-29 04:00:56 +00:00
Evan Cheng
16e4ace951 Temporarily disable my changes to unbreak the build.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@102590 91177308-0d34-0410-b5e6-96231b3b80d8
2010-04-29 03:34:19 +00:00
Evan Cheng
9e8a2b9346 Do not generate duplicate dbg_value instructions for function arguments.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@102585 91177308-0d34-0410-b5e6-96231b3b80d8
2010-04-29 01:40:30 +00:00
Dan Gohman
c924556dd5 Fix missing #include.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@102584 91177308-0d34-0410-b5e6-96231b3b80d8
2010-04-29 01:39:13 +00:00
Evan Cheng
ee1d91a830 Avoid emitting a dbg_value machineinstr that's not going to be inserted into entry block.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@102581 91177308-0d34-0410-b5e6-96231b3b80d8
2010-04-29 01:23:55 +00:00
Evan Cheng
8601a3d4de Frame index can be negative.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@102577 91177308-0d34-0410-b5e6-96231b3b80d8
2010-04-29 01:13:30 +00:00
Evan Cheng
1deef27b0a Check Reg against zero.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@102573 91177308-0d34-0410-b5e6-96231b3b80d8
2010-04-29 00:59:34 +00:00
Evan Cheng
6691a8935c - Really preserve dbg_value instructions when the register is spilled.
- Also, update dbg_value is the value is being re-matted from a frame slot, e.g. fixed slots for arguments.


git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@102565 91177308-0d34-0410-b5e6-96231b3b80d8
2010-04-28 23:52:26 +00:00
Devang Patel
f38c6c89f1 tidy up.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@102558 91177308-0d34-0410-b5e6-96231b3b80d8
2010-04-28 23:24:13 +00:00
Kevin Enderby
9ac7282117 Fixed the word sized Bit Scan Forward/Reverse instructions, they needed the
Operand size override prefix to be part of their records.


git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@102556 91177308-0d34-0410-b5e6-96231b3b80d8
2010-04-28 23:20:40 +00:00
Evan Cheng
2ad0fcf794 Replace r102368 with code that's less fragile. This creates DBG_VALUE instructions for function arguments early and insert them after instruction selection is done.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@102554 91177308-0d34-0410-b5e6-96231b3b80d8
2010-04-28 23:08:54 +00:00
Chris Lattner
c1c4595d1f fix this to work with objdir != srcdir
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@102547 91177308-0d34-0410-b5e6-96231b3b80d8
2010-04-28 22:34:35 +00:00
Dale Johannesen
de5996e33a Fix comment.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@102545 91177308-0d34-0410-b5e6-96231b3b80d8
2010-04-28 22:23:46 +00:00
Dale Johannesen
21a9bd91e9 Test for llvm-gcc checkin 102543.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@102544 91177308-0d34-0410-b5e6-96231b3b80d8
2010-04-28 22:17:33 +00:00
Bob Wilson
b8485d69c1 Add an option to the Apple-style build to control whether libLTO.dylib should
be installed.  Disable it by default.


git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@102531 91177308-0d34-0410-b5e6-96231b3b80d8
2010-04-28 21:08:01 +00:00
Jim Grosbach
d100755bab Add sizes non-floating point versions for the eh sjlj intrinsic expansions.
rdar://7895451



git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@102526 91177308-0d34-0410-b5e6-96231b3b80d8
2010-04-28 20:33:09 +00:00
Devang Patel
518e21ae8a Update tests. Now DBG_VALUE instruction is created only if alloca corresponding to llvm.dbg.declare is missing.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@102524 91177308-0d34-0410-b5e6-96231b3b80d8
2010-04-28 20:27:48 +00:00
Chris Lattner
ff33d83322 declare targets with (void) instead of () since this is a C header.
Patch by Lars R in PR6961.


git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@102523 91177308-0d34-0410-b5e6-96231b3b80d8
2010-04-28 20:24:45 +00:00
Chris Lattner
f3f325b82f fix PR6112 - When globalopt (or any other pass) does RAUW(@G, %G),
metadata references in non-function-local MDNodes should drop to 
null.



git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@102519 91177308-0d34-0410-b5e6-96231b3b80d8
2010-04-28 20:16:12 +00:00
Evan Cheng
59b3655564 Pretty print DBG_VALUE machine instructions.
Before:
DBG_VALUE %RSI, 0, !-1; dbg:SimpleRegisterCoalescing.cpp:2707
Now:
DBG_VALUE %RSI, 0, !"this"; dbg:SimpleRegisterCoalescing.cpp:2707


git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@102518 91177308-0d34-0410-b5e6-96231b3b80d8
2010-04-28 20:03:13 +00:00
Chris Lattner
e87f7bb50e Rework global alignment computation again. Now we do round up
alignment of globals to the preferred alignment, but only when
there is no section specified on the global (by far the common
case).


git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@102515 91177308-0d34-0410-b5e6-96231b3b80d8
2010-04-28 19:58:07 +00:00
Devang Patel
54fc4d6a48 While lowering dbg_declare, emit DBG_VALUE machine instruction if alloca matching llvm.dbg.declare intrinsic is missing.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@102513 91177308-0d34-0410-b5e6-96231b3b80d8
2010-04-28 19:27:33 +00:00
Jakob Stoklund Olesen
0fd109963a Recompute kill flags from live intervals after coalescing instead of trying to
update them. Computing kill flags is notoriously difficult, and the coalescer
would get it wrong sometimes, and it would completely skip physical registers.

Now we simply remove kill flags based on the live intervals after coalescing.
This is a few percent slower, but now we get correct kill flags for physical
registers after coalescing.

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@102510 91177308-0d34-0410-b5e6-96231b3b80d8
2010-04-28 18:28:39 +00:00