Bill Wendling [Tue, 25 May 2010 22:02:22 +0000 (22:02 +0000)]
Constify function.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@104646
91177308-0d34-0410-b5e6-
96231b3b80d8
Dan Gohman [Tue, 25 May 2010 21:59:42 +0000 (21:59 +0000)]
Do one map lookup instead of two.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@104645
91177308-0d34-0410-b5e6-
96231b3b80d8
Dan Gohman [Tue, 25 May 2010 21:50:35 +0000 (21:50 +0000)]
Fix a missing newline in debug output.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@104644
91177308-0d34-0410-b5e6-
96231b3b80d8
Eric Christopher [Tue, 25 May 2010 21:49:43 +0000 (21:49 +0000)]
Move the verbose asm output up a bit so it can be used in the special cases
as well.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@104642
91177308-0d34-0410-b5e6-
96231b3b80d8
Bill Wendling [Tue, 25 May 2010 21:44:26 +0000 (21:44 +0000)]
Okay, bear with me here...
If you have a setjmp/longjmp situation, it's possible for stack slot coloring to
reuse a stack slot before it's really dead. For instance, if we have something
like this:
1: y = g;
x = sigsetjmp(env, 0);
switch (x) {
case 1:
/* ... */
goto run;
case 0:
run:
do_run(); /* marked as "no return" */
break;
case 3:
if (...) {
/* ... */
goto run;
}
/* ... */
break;
}
2: g = y;
"y" may be put onto the stack, so the expression "g = y" is relying upon the
fact that the stack slot containing "y" isn't modified between (1) and (2). But
it can be, because of the "no return" calls in there. A longjmp might come back
with 3, modify the stack slot, and then go to case 0. And it's perfectly
acceptable to reuse the stack slot there because there's no CFG flow from case 3
to (2).
The fix is to disable certain optimizations in these situations. Ideally, we'd
disable them for all "returns twice" functions. But we don't support that
attribute. Check for "setjmp" and "sigsetjmp" instead.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@104640
91177308-0d34-0410-b5e6-
96231b3b80d8
Eric Christopher [Tue, 25 May 2010 21:28:50 +0000 (21:28 +0000)]
Add support for initialized global data for darwin tls. Update comments
and testcases accordingly.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@104635
91177308-0d34-0410-b5e6-
96231b3b80d8
Kevin Enderby [Tue, 25 May 2010 20:52:34 +0000 (20:52 +0000)]
Changed the encoding of X86 floating point stack operations where both operands
are st(0). These can be encoded using an opcode for storing in st(0) or using
an opcode for storing in st(i), where i can also be 0. To allow testing with
the darwin assembler and get a matching binary the opcode for storing in st(0)
is now used. To do this the same logical trick is use from the darwin assembler
in converting things like this:
fmul %st(0), %st
into this:
fmul %st(0)
by looking for the second operand being X86::ST0 for specific floating point
mnemonics then removing the second X86::ST0 operand. This also has the add
benefit to allow things like:
fmul %st(1), %st
that llvm-mc did not assemble.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@104634
91177308-0d34-0410-b5e6-
96231b3b80d8
Dale Johannesen [Tue, 25 May 2010 20:40:10 +0000 (20:40 +0000)]
Removing test; Chris thinks it's better to have the
bug go untested than have a testcase this large. So be it.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@104632
91177308-0d34-0410-b5e6-
96231b3b80d8
Jakob Stoklund Olesen [Tue, 25 May 2010 19:49:40 +0000 (19:49 +0000)]
Separate unrelated cases that once shared a numeric value
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@104629
91177308-0d34-0410-b5e6-
96231b3b80d8
Jakob Stoklund Olesen [Tue, 25 May 2010 19:49:38 +0000 (19:49 +0000)]
Print symbolic SubRegIndex names on machine operands.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@104628
91177308-0d34-0410-b5e6-
96231b3b80d8
Jakob Stoklund Olesen [Tue, 25 May 2010 19:49:33 +0000 (19:49 +0000)]
Remove NumberHack entirely.
SubRegIndex instances are now numbered uniquely the same way Register instances
are - in lexicographical order by name.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@104627
91177308-0d34-0410-b5e6-
96231b3b80d8
Daniel Dunbar [Tue, 25 May 2010 19:49:32 +0000 (19:49 +0000)]
MC/X86: Add a hack to allow recognizing 'cmpltps' and friends.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@104626
91177308-0d34-0410-b5e6-
96231b3b80d8
Dale Johannesen [Tue, 25 May 2010 18:47:23 +0000 (18:47 +0000)]
Fix another variant of PR 7191. Also add a testcase
Mon Ping provided; unfortunately bugpoint failed to
reduce it, but I think it's important to have a test for
this in the suite.
8023512.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@104624
91177308-0d34-0410-b5e6-
96231b3b80d8
Daniel Dunbar [Tue, 25 May 2010 18:40:53 +0000 (18:40 +0000)]
MC/X86: Define explicit immediate forms of cmp{ss,sd,ps,pd}.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@104622
91177308-0d34-0410-b5e6-
96231b3b80d8
Kevin Enderby [Tue, 25 May 2010 18:16:58 +0000 (18:16 +0000)]
The BT64ri8 record in X86Instr64bit.td was missing a REX_W which is required
for the 64-bit version of the Bit Test instruction.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@104621
91177308-0d34-0410-b5e6-
96231b3b80d8
Dale Johannesen [Tue, 25 May 2010 17:50:03 +0000 (17:50 +0000)]
Fix PR 7191. I have been unable to create a .ll file that fails, sorry.
(oye, a word which should be better known to people writing tree
traversals, means grandchild.)
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@104619
91177308-0d34-0410-b5e6-
96231b3b80d8
Eric Christopher [Tue, 25 May 2010 17:33:22 +0000 (17:33 +0000)]
Make sure aeskeygenassist uses an unsigned immediate field.
Fixes rdar://
8017638
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@104617
91177308-0d34-0410-b5e6-
96231b3b80d8
Jakob Stoklund Olesen [Tue, 25 May 2010 17:21:04 +0000 (17:21 +0000)]
Ignore NumberHack and give each SubRegIndex instance a unique enum value instead.
This passes lit tests, but I'll give it a go through the buildbots to smoke out
any remaining places that depend on the old SubRegIndex numbering.
Then I'll remove NumberHack entirely.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@104615
91177308-0d34-0410-b5e6-
96231b3b80d8
Jakob Stoklund Olesen [Tue, 25 May 2010 17:04:18 +0000 (17:04 +0000)]
Use enums instead of literals for SystemZ subregisters
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@104612
91177308-0d34-0410-b5e6-
96231b3b80d8
Jakob Stoklund Olesen [Tue, 25 May 2010 17:04:16 +0000 (17:04 +0000)]
Use enums instead of literals for X86 subregisters.
The cases in getMatchingSuperRegClass cannot be broken up until the enums have
unique values.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@104611
91177308-0d34-0410-b5e6-
96231b3b80d8
Zonr Chang [Tue, 25 May 2010 10:23:52 +0000 (10:23 +0000)]
Add missing implementation to the materialization of VFP misc. instructions (vmrs, vmsr and vmov (immediate))
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@104588
91177308-0d34-0410-b5e6-
96231b3b80d8
Zonr Chang [Tue, 25 May 2010 08:42:45 +0000 (08:42 +0000)]
Add support to MOVimm32 using movt/movw for ARM JIT
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@104587
91177308-0d34-0410-b5e6-
96231b3b80d8
Bob Wilson [Tue, 25 May 2010 04:51:47 +0000 (04:51 +0000)]
Allow t2MOVsrl_flag and t2MOVsra_flag instructions to be predicated.
I don't know of any particular reason why that would be important, but
neither can I see any reason to disallow it.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@104583
91177308-0d34-0410-b5e6-
96231b3b80d8
Bob Wilson [Tue, 25 May 2010 04:43:08 +0000 (04:43 +0000)]
Fix up instruction classes for Thumb2 RSB instructions to be consistent with
Thumb2 ADD and SUB instructions: allow RSB instructions be changed to set the
condition codes, and allow RSBS instructions to be predicated.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@104582
91177308-0d34-0410-b5e6-
96231b3b80d8
Bob Wilson [Tue, 25 May 2010 03:36:52 +0000 (03:36 +0000)]
Clean up indentation.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@104580
91177308-0d34-0410-b5e6-
96231b3b80d8
Jakob Stoklund Olesen [Tue, 25 May 2010 00:15:18 +0000 (00:15 +0000)]
Disable invalid coalescer assertion.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@104574
91177308-0d34-0410-b5e6-
96231b3b80d8
Jakob Stoklund Olesen [Tue, 25 May 2010 00:15:15 +0000 (00:15 +0000)]
Use enums instead of literals in the ARM backend.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@104573
91177308-0d34-0410-b5e6-
96231b3b80d8
Bill Wendling [Mon, 24 May 2010 23:16:04 +0000 (23:16 +0000)]
Print out the name of the function during SSC.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@104572
91177308-0d34-0410-b5e6-
96231b3b80d8
Jakob Stoklund Olesen [Mon, 24 May 2010 23:03:18 +0000 (23:03 +0000)]
Switch SubRegSet to using symbolic SubRegIndices
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@104571
91177308-0d34-0410-b5e6-
96231b3b80d8
Bob Wilson [Mon, 24 May 2010 22:41:19 +0000 (22:41 +0000)]
Allow Thumb2 MVN instructions to set condition codes. The immediate operand
version of t2MVN already allowed that, but not the register versions.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@104570
91177308-0d34-0410-b5e6-
96231b3b80d8
Chris Lattner [Mon, 24 May 2010 21:55:47 +0000 (21:55 +0000)]
diaggroup categories should take precedence over diag-specific groups.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@104567
91177308-0d34-0410-b5e6-
96231b3b80d8
Jakob Stoklund Olesen [Mon, 24 May 2010 21:47:01 +0000 (21:47 +0000)]
Lose the dummies
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@104564
91177308-0d34-0410-b5e6-
96231b3b80d8
Jakob Stoklund Olesen [Mon, 24 May 2010 21:46:58 +0000 (21:46 +0000)]
Replace the tablegen RegisterClass field SubRegClassList with an alist-like data
structure that represents a mapping without any dependencies on SubRegIndex
numbering.
This brings us closer to being able to remove the explicit SubRegIndex
numbering, and it is now possible to specify any mapping without inventing
*_INVALID register classes.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@104563
91177308-0d34-0410-b5e6-
96231b3b80d8
Evan Cheng [Mon, 24 May 2010 21:33:37 +0000 (21:33 +0000)]
Avoid adding duplicate function live-in's.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@104560
91177308-0d34-0410-b5e6-
96231b3b80d8
Dan Gohman [Mon, 24 May 2010 20:51:08 +0000 (20:51 +0000)]
Fix an mmx movd encoding.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@104552
91177308-0d34-0410-b5e6-
96231b3b80d8
Kevin Enderby [Mon, 24 May 2010 20:32:23 +0000 (20:32 +0000)]
MC/X86: Add aliases for CMOVcc variants.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@104549
91177308-0d34-0410-b5e6-
96231b3b80d8
Bob Wilson [Mon, 24 May 2010 20:08:34 +0000 (20:08 +0000)]
Clean up some extra whitespace.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@104544
91177308-0d34-0410-b5e6-
96231b3b80d8
Bob Wilson [Mon, 24 May 2010 18:44:06 +0000 (18:44 +0000)]
Thumb2 RSBS instructions were being printed without the 'S' suffix.
Fix it by changing the T2I_rbin_s_is multiclass to handle the CPSR
output and 'S' suffix in the same way as T2I_bin_s_irs.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@104531
91177308-0d34-0410-b5e6-
96231b3b80d8
Devang Patel [Mon, 24 May 2010 18:26:49 +0000 (18:26 +0000)]
Do not emit line number entries for unknown debug values.
This fixes recent regression in store.exp from gdb testsuite.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@104524
91177308-0d34-0410-b5e6-
96231b3b80d8
Evan Cheng [Mon, 24 May 2010 18:00:18 +0000 (18:00 +0000)]
LR is in GPR, not tGPR even in Thumb1 mode.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@104518
91177308-0d34-0410-b5e6-
96231b3b80d8
Jakob Stoklund Olesen [Mon, 24 May 2010 17:55:38 +0000 (17:55 +0000)]
Add SubRegIndex defs to PowerPC. It looks like the CR subregister indices are
never used.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@104517
91177308-0d34-0410-b5e6-
96231b3b80d8
Jakob Stoklund Olesen [Mon, 24 May 2010 17:43:01 +0000 (17:43 +0000)]
Use SubRegIndex in SystemZ.
Anton, please review the change to SystemZAsmPrinter.cpp. It could be a bug.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@104515
91177308-0d34-0410-b5e6-
96231b3b80d8
Jakob Stoklund Olesen [Mon, 24 May 2010 17:42:58 +0000 (17:42 +0000)]
SubRegIndex'ize Mips
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@104514
91177308-0d34-0410-b5e6-
96231b3b80d8
Jakob Stoklund Olesen [Mon, 24 May 2010 17:42:55 +0000 (17:42 +0000)]
SubRegIndex'ize MSP430
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@104513
91177308-0d34-0410-b5e6-
96231b3b80d8
Jakob Stoklund Olesen [Mon, 24 May 2010 17:13:28 +0000 (17:13 +0000)]
Fix a few places that depended on the numeric value of subreg indices.
Add assertions in places that depend on consecutive indices.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@104510
91177308-0d34-0410-b5e6-
96231b3b80d8
Jakob Stoklund Olesen [Mon, 24 May 2010 16:54:32 +0000 (16:54 +0000)]
Switch ARMRegisterInfo.td to use SubRegIndex and eliminate the parallel enums
from ARMRegisterInfo.h
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@104508
91177308-0d34-0410-b5e6-
96231b3b80d8
Jakob Stoklund Olesen [Mon, 24 May 2010 14:48:17 +0000 (14:48 +0000)]
Rename X86 subregister indices to something shorter.
Use the tablegen-produced enums.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@104493
91177308-0d34-0410-b5e6-
96231b3b80d8
Jakob Stoklund Olesen [Mon, 24 May 2010 14:48:12 +0000 (14:48 +0000)]
Add the SubRegIndex TableGen class.
This is the beginning of purely symbolic subregister indices, but we need a bit
of jiggling before the explicit numeric indices can be completely removed.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@104492
91177308-0d34-0410-b5e6-
96231b3b80d8
Nicolas Geoffray [Mon, 24 May 2010 12:24:11 +0000 (12:24 +0000)]
Encode the Caml frametable by following what the comment says: the number of descriptors
is first emitted, and StackOffsets are emitted in 16 bits.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@104488
91177308-0d34-0410-b5e6-
96231b3b80d8
Duncan Sands [Mon, 24 May 2010 07:49:55 +0000 (07:49 +0000)]
Apply timeouts and memory limits in more places. In particular, when
bugpoint does "Running the code generator to test for a crash" this
gets you a crash if llc goes into an infinite loop or uses up vast
amounts of memory.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@104485
91177308-0d34-0410-b5e6-
96231b3b80d8
Daniel Dunbar [Sun, 23 May 2010 18:36:38 +0000 (18:36 +0000)]
llvm-mc: Use EmitIntValue where possible, which makes the API calls from the AsmParser and CodeGen line up better.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@104467
91177308-0d34-0410-b5e6-
96231b3b80d8
Daniel Dunbar [Sun, 23 May 2010 18:36:34 +0000 (18:36 +0000)]
llvm-mc: Use AddBlankLine in asm parser. This makes transliteration match the input much more closely, and also makes the API calls from the AsmParser and CodeGen line up better.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@104466
91177308-0d34-0410-b5e6-
96231b3b80d8
Daniel Dunbar [Sun, 23 May 2010 17:44:06 +0000 (17:44 +0000)]
MC: Add an MCLoggingStreamer, for use in debugging integrated-as mismatches.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@104463
91177308-0d34-0410-b5e6-
96231b3b80d8
Bob Wilson [Sun, 23 May 2010 05:42:31 +0000 (05:42 +0000)]
VDUP doesn't support vectors with 64-bit elements.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@104455
91177308-0d34-0410-b5e6-
96231b3b80d8
Daniel Dunbar [Sat, 22 May 2010 21:02:33 +0000 (21:02 +0000)]
MC/X86: Subdivide immediates a bit more, so that we properly recognize immediates based on the width of the target instruction. For example:
addw $0xFFFF, %ax
should match the same as
addw $-1, %ax
but we used to match it to the longer encoding.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@104453
91177308-0d34-0410-b5e6-
96231b3b80d8
Daniel Dunbar [Sat, 22 May 2010 21:02:29 +0000 (21:02 +0000)]
tblgen/AsmMatcher: Change AsmOperandClass to allow a list of superclasses instead of just one.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@104452
91177308-0d34-0410-b5e6-
96231b3b80d8
Daniel Dunbar [Sat, 22 May 2010 06:37:33 +0000 (06:37 +0000)]
MC/X86: Add alias for setz, setnz, jz, jnz.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@104435
91177308-0d34-0410-b5e6-
96231b3b80d8
John Mosby [Sat, 22 May 2010 05:13:17 +0000 (05:13 +0000)]
Trivial change to dump() function for SparseBitVector
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@104433
91177308-0d34-0410-b5e6-
96231b3b80d8
Evan Cheng [Sat, 22 May 2010 01:47:14 +0000 (01:47 +0000)]
Implement @llvm.returnaddress. rdar://
8015977.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@104421
91177308-0d34-0410-b5e6-
96231b3b80d8
Jim Grosbach [Sat, 22 May 2010 01:06:18 +0000 (01:06 +0000)]
Implement eh.sjlj.longjmp for ARM. Clean up the intrinsic a bit.
Followups: docs patch for the builtin and eh.sjlj.setjmp cleanup to match
longjmp.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@104419
91177308-0d34-0410-b5e6-
96231b3b80d8
Eric Christopher [Sat, 22 May 2010 00:55:55 +0000 (00:55 +0000)]
This test is darwin only. Make it so(tm).
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@104418
91177308-0d34-0410-b5e6-
96231b3b80d8
Bob Wilson [Sat, 22 May 2010 00:23:12 +0000 (00:23 +0000)]
Recognize more BUILD_VECTORs and VECTOR_SHUFFLEs that can be implemented by
copying VFP subregs. This exposed a bunch of dead code in the *spill-q.ll
tests, so I tweaked those tests to keep that code from being optimized away.
Radar
7872877.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@104415
91177308-0d34-0410-b5e6-
96231b3b80d8
Eric Christopher [Sat, 22 May 2010 00:10:22 +0000 (00:10 +0000)]
Add full bss data support for darwin tls variables.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@104414
91177308-0d34-0410-b5e6-
96231b3b80d8
Devang Patel [Sat, 22 May 2010 00:04:14 +0000 (00:04 +0000)]
Collect variable information during endFunction() instead of beginFunction().
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@104412
91177308-0d34-0410-b5e6-
96231b3b80d8
Eric Christopher [Sat, 22 May 2010 00:00:58 +0000 (00:00 +0000)]
Add a new section and accessor for TLS data.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@104411
91177308-0d34-0410-b5e6-
96231b3b80d8
Bob Wilson [Fri, 21 May 2010 23:53:55 +0000 (23:53 +0000)]
Clean up extra whitespace.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@104410
91177308-0d34-0410-b5e6-
96231b3b80d8
Eric Christopher [Fri, 21 May 2010 23:40:03 +0000 (23:40 +0000)]
Make this LookAheadLimit, not the uninitialized LookAheadLeft.
Evan please verify!
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@104408
91177308-0d34-0410-b5e6-
96231b3b80d8
Chris Lattner [Fri, 21 May 2010 23:16:21 +0000 (23:16 +0000)]
add a note
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@104404
91177308-0d34-0410-b5e6-
96231b3b80d8
Eric Christopher [Fri, 21 May 2010 23:03:53 +0000 (23:03 +0000)]
Expand on comment.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@104396
91177308-0d34-0410-b5e6-
96231b3b80d8
Kevin Enderby [Fri, 21 May 2010 23:01:38 +0000 (23:01 +0000)]
Added retl for 32-bit x86 and added retq for 64-bit x86.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@104394
91177308-0d34-0410-b5e6-
96231b3b80d8
Eric Christopher [Fri, 21 May 2010 22:39:11 +0000 (22:39 +0000)]
Fix comment and whitespace.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@104392
91177308-0d34-0410-b5e6-
96231b3b80d8
Chris Lattner [Fri, 21 May 2010 22:20:54 +0000 (22:20 +0000)]
expand on the llvm ir bitcode dox. Patch by Peter Housel!
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@104391
91177308-0d34-0410-b5e6-
96231b3b80d8
Evan Cheng [Fri, 21 May 2010 21:22:19 +0000 (21:22 +0000)]
Allow machine cse to cse instructions which define physical registers. Controlled by option -machine-cse-phys-defs.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@104385
91177308-0d34-0410-b5e6-
96231b3b80d8
Eric Christopher [Fri, 21 May 2010 21:08:52 +0000 (21:08 +0000)]
Fix section attribute name.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@104381
91177308-0d34-0410-b5e6-
96231b3b80d8
Bob Wilson [Fri, 21 May 2010 21:05:32 +0000 (21:05 +0000)]
Change CodeGen/ARM/2009-11-02-NegativeLane.ll to use 16-bit vector elements
so that it will continue to test what it was meant to test when I commit a
separate change for better support of BUILD_VECTOR and VECTOR_SHUFFLE for Neon.
Fix a DAG combiner crash exposed by this test change.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@104380
91177308-0d34-0410-b5e6-
96231b3b80d8
Evan Cheng [Fri, 21 May 2010 20:53:24 +0000 (20:53 +0000)]
- Change MachineInstr::findRegisterDefOperandIdx so it can also look for defs
that are aliases of the specified register.
- Rename modifiesRegister to definesRegister since it's looking a def of the
specific register or one of its super-registers. It's not looking for def of a
sub-register or alias that could change the specified register.
- Added modifiesRegister to look for defs of aliases.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@104377
91177308-0d34-0410-b5e6-
96231b3b80d8
Jakob Stoklund Olesen [Fri, 21 May 2010 20:02:01 +0000 (20:02 +0000)]
Add MachineInstr::readsWritesVirtualRegister() to determine if an instruction
reads or writes a register.
This takes partial redefines and undef uses into account.
Don't actually use it yet. That caused miscompiles.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@104372
91177308-0d34-0410-b5e6-
96231b3b80d8
Devang Patel [Fri, 21 May 2010 18:49:09 +0000 (18:49 +0000)]
Simplify
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@104338
91177308-0d34-0410-b5e6-
96231b3b80d8
Dale Johannesen [Fri, 21 May 2010 18:44:47 +0000 (18:44 +0000)]
Previous commit message should refer to 104308.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@104337
91177308-0d34-0410-b5e6-
96231b3b80d8
Dale Johannesen [Fri, 21 May 2010 18:40:15 +0000 (18:40 +0000)]
Fix two bugs in 104348:
Case where MMX is disabled wasn't handled right.
MMX->MMX bitconverts are Legal.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@104336
91177308-0d34-0410-b5e6-
96231b3b80d8
Nathan Jeffords [Fri, 21 May 2010 18:23:56 +0000 (18:23 +0000)]
added an assertion to MCObjectWriter::WriteBytes to catch misuse of the ZeroFillSize parameter
If the size of the string is greater than the zero fill size, the function will attempt to write a very large string of zeros to the object file (~4GB on 32 bit platforms). This assertion will catch the scenario and crash the program before the write occurs.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@104334
91177308-0d34-0410-b5e6-
96231b3b80d8
Chris Lattner [Fri, 21 May 2010 18:17:54 +0000 (18:17 +0000)]
now that fp reg kill insertion stuff happens as a separate
pass after isel instead of being interlaced with it, we can
trust that all the code for a function has been isel'd before
it is run.
The practical impact of this is that we can scan for machine
instr phis instead of doing a fuzzy match on the LLVM BB for
phi nodes. Doing the fuzzy match required knowing when isel
would produce an fp reg stack phi which was gross. It was
also wrong in cases where select got lowered to a branch
tree because cmovs aren't available (PR6828).
Just do the scan on machine phis which is simpler, faster
and more correct. This fixes PR6828.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@104333
91177308-0d34-0410-b5e6-
96231b3b80d8
Chris Lattner [Fri, 21 May 2010 18:02:42 +0000 (18:02 +0000)]
Use less evil form of switch stmt.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@104331
91177308-0d34-0410-b5e6-
96231b3b80d8
Chris Lattner [Fri, 21 May 2010 18:01:24 +0000 (18:01 +0000)]
use continue to reduce nesting.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@104330
91177308-0d34-0410-b5e6-
96231b3b80d8
Chris Lattner [Fri, 21 May 2010 17:57:03 +0000 (17:57 +0000)]
pull a nested loop of this pass out to its own function,
eliminating the gymnastics around the ContainsFPCode var.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@104328
91177308-0d34-0410-b5e6-
96231b3b80d8
Chris Lattner [Fri, 21 May 2010 17:49:07 +0000 (17:49 +0000)]
modernize this pass a bit, fit in 80 columns.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@104326
91177308-0d34-0410-b5e6-
96231b3b80d8
Chris Lattner [Fri, 21 May 2010 17:47:50 +0000 (17:47 +0000)]
constify accessor.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@104325
91177308-0d34-0410-b5e6-
96231b3b80d8
Jakob Stoklund Olesen [Fri, 21 May 2010 17:36:32 +0000 (17:36 +0000)]
Revert "Use MachineInstr::readsWritesVirtualRegister to determine if a register is read."
This reverts r104322. I think it was causing miscompilations.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@104323
91177308-0d34-0410-b5e6-
96231b3b80d8
Jakob Stoklund Olesen [Fri, 21 May 2010 16:42:30 +0000 (16:42 +0000)]
Use MachineInstr::readsWritesVirtualRegister to determine if a register is read.
This correctly handles partial redefines and undef uses.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@104322
91177308-0d34-0410-b5e6-
96231b3b80d8
Jakob Stoklund Olesen [Fri, 21 May 2010 16:36:13 +0000 (16:36 +0000)]
Teach VirtRegRewriter to handle spilling in instructions that have multiple
definitions of the virtual register.
This happens when spilling the registers produced by REG_SEQUENCE:
%reg1047:5<def>, %reg1047:6<def>, %reg1047:7<def> = VLD3d8 %reg1033, 0, pred:14, pred:%reg0
The rewriter would spill the register multiple times, dead store elimination
tried to keep up, but ended up cutting the branch it was sitting on.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@104321
91177308-0d34-0410-b5e6-
96231b3b80d8
Jakob Stoklund Olesen [Fri, 21 May 2010 16:32:16 +0000 (16:32 +0000)]
If the first definition of a virtual register is a partial redef, add an
<imp-def> operand for the full register. This ensures that the full physical
register is marked live after register allocation.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@104320
91177308-0d34-0410-b5e6-
96231b3b80d8
Matt Fleming [Fri, 21 May 2010 12:54:43 +0000 (12:54 +0000)]
Currently, createMachOStreamer() is invoked directly in llvm-mc which
isn't ideal if we want to be able to use another object file format.
Add a createObjectStreamer() factory method so that the correct object
file streamer can be instantiated for a given target triple.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@104318
91177308-0d34-0410-b5e6-
96231b3b80d8
Matt Fleming [Fri, 21 May 2010 11:39:07 +0000 (11:39 +0000)]
Split out the x86_32 an x86_64 ELF backends as they handle ELF
differently. This will make adding ELF support easier in the long run.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@104317
91177308-0d34-0410-b5e6-
96231b3b80d8
Matt Fleming [Fri, 21 May 2010 11:36:59 +0000 (11:36 +0000)]
Add support for parsing the ELF .type assembler directive.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@104316
91177308-0d34-0410-b5e6-
96231b3b80d8
Lang Hames [Fri, 21 May 2010 03:04:04 +0000 (03:04 +0000)]
Removed scaleNumbering method declaration from LiveInterval (not defined, not used).
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@104311
91177308-0d34-0410-b5e6-
96231b3b80d8
Dale Johannesen [Fri, 21 May 2010 00:52:33 +0000 (00:52 +0000)]
Fix i64->f64 conversion, x86-64, -no-sse. A bit
tricky since there's a 3rd 64-bit type, MMX vectors.
PR 7135.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@104308
91177308-0d34-0410-b5e6-
96231b3b80d8
Evan Cheng [Fri, 21 May 2010 00:43:17 +0000 (00:43 +0000)]
Change ARM scheduling default to list-hybrid if the target supports floating point instructions (and is not using soft float).
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@104307
91177308-0d34-0410-b5e6-
96231b3b80d8
Evan Cheng [Fri, 21 May 2010 00:42:32 +0000 (00:42 +0000)]
Rename -pre-RA-sched=hybrid to -pre-RA-sched=list-hybrid.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@104306
91177308-0d34-0410-b5e6-
96231b3b80d8
Daniel Dunbar [Fri, 21 May 2010 00:27:55 +0000 (00:27 +0000)]
Remove dead option.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@104303
91177308-0d34-0410-b5e6-
96231b3b80d8
Devang Patel [Fri, 21 May 2010 00:10:20 +0000 (00:10 +0000)]
Simplify.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@104302
91177308-0d34-0410-b5e6-
96231b3b80d8