Dan Gohman
f113e5466c
In guaranteed tailcall mode, don't decline the tailcall optimization
...
for blocks ending in "unreachable".
llvm-svn: 95565
2010-02-08 20:34:14 +00:00
Dan Gohman
f45b7c6795
Rename the PerformTailCallOpt variable to GuaranteedTailCallOpt to reflect
...
its current purpose.
llvm-svn: 95564
2010-02-08 20:27:50 +00:00
Johnny Chen
7092ebb040
Add VCMP (VFP floating-point compare without 'E' bit set) for disassembly purpose.
...
llvm-svn: 95560
2010-02-08 19:41:48 +00:00
Chris Lattner
b3fe7597f5
add scaffolding for target-specific MCExprs.
...
llvm-svn: 95559
2010-02-08 19:41:07 +00:00
Duncan Sands
983b171d40
Flesh out the list of predicates, for those who like this style. I was
...
looking for isPointer, and added the rest for uniformity.
llvm-svn: 95557
2010-02-08 19:36:51 +00:00
Daniel Dunbar
e56fb57d08
ImmutableIntervalMap: Fix for unqualified lookup into dependent base class, done
...
by clang's -fixit! :)
llvm-svn: 95551
2010-02-08 18:08:46 +00:00
Johnny Chen
92ec9f2887
Added VMOVRRS/VMOVSRR to ARMInstrVFP.td for disassembly purpose.
...
A8.6.331 VMOV (between two ARM core registers and two single-precision registers)
llvm-svn: 95548
2010-02-08 17:26:09 +00:00
Duncan Sands
70a24159d2
Fix some typos.
...
llvm-svn: 95542
2010-02-08 11:03:31 +00:00
Torok Edwin
01b6959fb6
Fix x86 JIT stub on MSVC.
...
Thanks to Kristaps Straupe for noticing the bug.
llvm-svn: 95537
2010-02-08 08:37:27 +00:00
Sanjiv Gupta
4a56e894a7
Fixed build error for redefinition.
...
llvm-svn: 95532
2010-02-08 06:08:32 +00:00
Sanjiv Gupta
09a80bb7d9
Add uppercase and lowercase part defines in driver.
...
Use a temp dir with a unique name in the current dir itself.
Use forward_value instead of unpack_values.
llvm-svn: 95530
2010-02-08 05:56:37 +00:00
Nick Lewycky
866c48ae12
Make the destructor for TypeMapBase protected. Spotted by Duncan Sands with
...
cppcheck!
llvm-svn: 95527
2010-02-07 21:13:46 +00:00
Duncan Sands
ea225349b0
Give DwarfPrinter a protected (but not virtual) destructor. Cppcheck
...
warns about this base class not having a virtual destructor, but since
this class has no virtual methods and neither it or the types derived
from it has a destructor, a protected trivial destructor will do (and
shuts cppcheck up) the trick without the cost of introducing a vtable.
llvm-svn: 95526
2010-02-07 21:09:22 +00:00
Bruno Cardoso Lopes
014f8fc7b1
Add suport for VASTART on Mips.
...
llvm-svn: 95506
2010-02-06 21:00:02 +00:00
Bruno Cardoso Lopes
2f4294068f
First step towards varargs support in Mips:
...
- o32 cc must pass all arguments in A0...A3 and stack regardless
if its type (but respect the alignment).
- Store all variable arguments back to the caller stack.
llvm-svn: 95500
2010-02-06 19:20:49 +00:00
Evan Cheng
5541068ad3
Run codegen dce pass for all targets at all optimization levels. Previously it's
...
only run for x86 with fastisel. I've found it being very effective in
eliminating some obvious dead code as result of formal parameter lowering
especially when tail call optimization eliminated the need for some of the loads
from fixed frame objects. It also shrinks a number of the tests. A couple of
tests no longer make sense and are now eliminated.
llvm-svn: 95493
2010-02-06 09:07:11 +00:00
Evan Cheng
c3cfda4e7e
Remove a large test case that (soon will) no longer make sense.
...
llvm-svn: 95492
2010-02-06 09:00:30 +00:00
Bob Wilson
61a15581e7
Fix an uninitialized value. Radar 7609421.
...
llvm-svn: 95488
2010-02-06 05:55:20 +00:00
Rafael Espindola
b0bb1ddfe3
Fix alignment on ppc linux. This fixes the build of crtend.o
...
llvm-svn: 95477
2010-02-06 03:32:21 +00:00
Evan Cheng
de1a4726e6
Do not emit callseq instructions around sibcalls. This eliminated some unnecessary stack adjustments.
...
llvm-svn: 95475
2010-02-06 03:28:46 +00:00
Dale Johannesen
05cffb66ae
Add a Debug bit to MachineOperand, for uses that
...
are from debug info. Add an iterator to MachineRegisterInfo
to skip Debug operands when walking the use list. No
functional change yet.
llvm-svn: 95473
2010-02-06 02:28:32 +00:00
Dale Johannesen
83f31d3511
After Victor's latest commits I am seeing null
...
addresses in dbg.declare; ignore this for the
moment to prevent things from breaking.
llvm-svn: 95471
2010-02-06 02:26:02 +00:00
Victor Hernandez
157da4b794
Linker should not remap null operands of metadata
...
llvm-svn: 95468
2010-02-06 01:31:55 +00:00
Victor Hernandez
e65222a748
Function-local metadata whose operands had been optimized to no longer refer to function-local IR were not getting written by BitcodeWriter; solution is for these metadata to be enumerated just like global metadata.
...
llvm-svn: 95467
2010-02-06 01:21:09 +00:00
Jakob Stoklund Olesen
83ebc265b3
Reintroduce the InlineHint function attribute.
...
This time it's for real! I am going to hook this up in the frontends as well.
The inliner has some experimental heuristics for dealing with the inline hint.
When given a -respect-inlinehint option, functions marked with the inline
keyword are given a threshold just above the default for -O3.
We need some experiments to determine if that is the right thing to do.
llvm-svn: 95466
2010-02-06 01:16:28 +00:00
Bob Wilson
60fb5a2446
Add a test for my change to disable reassociation for i1 types.
...
llvm-svn: 95465
2010-02-06 01:16:25 +00:00
Devang Patel
102b8a3103
Set DW_AT_artificial only if argument is marked as artificial.
...
llvm-svn: 95461
2010-02-06 01:02:37 +00:00
Bob Wilson
1a324958d6
Handle AddrMode6 (for NEON load/stores) in Thumb2's rewriteT2FrameIndex.
...
Radar 7614112.
llvm-svn: 95456
2010-02-06 00:24:38 +00:00
Jakob Stoklund Olesen
7b4c60adae
Don't unroll loops containing function calls.
...
llvm-svn: 95454
2010-02-05 23:21:31 +00:00
Jakob Stoklund Olesen
039cd8ab3a
Update CodeMetrics to count 'big' function calls explicitly.
...
llvm-svn: 95453
2010-02-05 23:21:18 +00:00
Devang Patel
9eb9bb03c9
Do not generate specification DIE for nested functions.
...
llvm-svn: 95452
2010-02-05 23:09:20 +00:00
Chris Lattner
e1b8c529a4
fix incorrect encoding of SBB8mi that Kevin noticed.
...
llvm-svn: 95448
2010-02-05 22:56:11 +00:00
Chris Lattner
9d4e878b6a
fix a case where we'd mis-encode fisttp because of an incorrect (and
...
redundant with a correct one) pattern that was added for the disassembler.
llvm-svn: 95446
2010-02-05 22:49:06 +00:00
Chris Lattner
261d9ac280
add note.
...
llvm-svn: 95445
2010-02-05 22:48:33 +00:00
Chris Lattner
bec530a499
remove fixme
...
llvm-svn: 95444
2010-02-05 22:46:46 +00:00
Chris Lattner
b79cdb101f
print encodings like this:
...
pslld 69, %mm3 ## encoding: [0x0f,0xf2,0x1c,0x25,0x45,0x00,0x00,0x00]
instead of like this:
pslld 69, %mm3 ## encoding: [0x0f,0xf2,0x1c,0x25,0x45,0000,0000,0000]
this only affects 0.
llvm-svn: 95441
2010-02-05 22:20:08 +00:00
Chris Lattner
8db3500688
port X86InstrInfo::determineREX over to the new encoder.
...
llvm-svn: 95440
2010-02-05 22:10:22 +00:00
Jakob Stoklund Olesen
670458b3be
Teach SimplifyCFG about magic pointer constants.
...
Weird code sometimes uses pointer constants other than null. This patch
teaches SimplifyCFG to build switch instructions in those cases.
Code like this:
void f(const char *x) {
if (!x)
puts("null");
else if ((uintptr_t)x == 1)
puts("one");
else if (x == (char*)2 || x == (char*)3)
puts("two");
else if ((intptr_t)x == 4)
puts("four");
else
puts(x);
}
Now becomes a switch:
define void @f(i8* %x) nounwind ssp {
entry:
%magicptr23 = ptrtoint i8* %x to i64 ; <i64> [#uses=1]
switch i64 %magicptr23, label %if.else16 [
i64 0, label %if.then
i64 1, label %if.then2
i64 2, label %if.then9
i64 3, label %if.then9
i64 4, label %if.then14
]
Note that LLVM's own DenseMap uses magic pointers.
llvm-svn: 95439
2010-02-05 22:03:18 +00:00
Chris Lattner
15817c2239
wire up 64-bit MCCodeEmitter.
...
llvm-svn: 95438
2010-02-05 21:51:35 +00:00
Chris Lattner
22151cbec5
really kill off the last MRMInitReg inst, remove logic from encoder.
...
llvm-svn: 95437
2010-02-05 21:34:18 +00:00
Chris Lattner
071fe62af6
lower the last of the MRMInitReg instructions in MCInstLower.
...
llvm-svn: 95435
2010-02-05 21:30:49 +00:00
Chris Lattner
9b3cf069dc
teach X86MCInstLower to lower the MOV32r0 and MOV8r0
...
pseudo instructions.
llvm-svn: 95433
2010-02-05 21:21:06 +00:00
Chris Lattner
f77eadcfbb
genericize helpers, use them for MOV16r0/MOV64r0
...
llvm-svn: 95432
2010-02-05 21:15:57 +00:00
Chris Lattner
32f09202d6
factor code better in X86MCInstLower::Lower, teach it to
...
lower the SETB* instructions.
llvm-svn: 95431
2010-02-05 21:13:48 +00:00
Chris Lattner
44965f1107
fix logical-select to invoke filecheck right, and fix hte instcombine
...
xform it is checking to actually pass. There is no need to match
m_SelectCst<0, -1> since instcombine canonicalizes that into not(sext).
Add matches for sext(not(x)) in addition to not(sext(x)).
llvm-svn: 95420
2010-02-05 19:53:02 +00:00
Chris Lattner
3590276566
implement the rest of the encoding types.
...
llvm-svn: 95414
2010-02-05 19:37:31 +00:00
Chris Lattner
a6d9d45f42
move functions for decoding X86II values into the X86II namespace.
...
llvm-svn: 95410
2010-02-05 19:24:13 +00:00
Dan Gohman
96cad72d2d
Implement releaseMemory in CodeGenPrepare and free the BackEdges
...
container data. This prevents it from holding onto dangling
pointers and potentially behaving unpredictably.
llvm-svn: 95409
2010-02-05 19:24:11 +00:00
Chris Lattner
326cf88352
constant propagate a method away.
...
llvm-svn: 95408
2010-02-05 19:20:30 +00:00
Dan Gohman
8142ba6bbb
Use a SmallSetVector instead of a SetVector; this code showed up as a
...
malloc caller in a profile.
llvm-svn: 95407
2010-02-05 19:20:15 +00:00