Mikhail Glushenkov
4c358b3125
Add support for response files to the CommandLine library.
...
llvm-svn: 50355
2008-04-28 16:44:25 +00:00
Chris Lattner
27fa922841
Remove the SmallVector ctor that converts from a SmallVectorImpl. This
...
conversion open the door for many nasty implicit conversion issues, and
can be easily solved by initializing with (V.begin(), V.end()) when
needed.
This patch includes many small cleanups for sdisel also.
llvm-svn: 50340
2008-04-28 06:44:42 +00:00
Chris Lattner
89339f3a90
restore the copy ctor in SmallVector. This fixes serious
...
errors I introduced in my last patch.
llvm-svn: 50338
2008-04-28 06:32:08 +00:00
Chris Lattner
a03159bc35
generalize SmallVector copy ctor, there is no requirement for
...
the initialization vector to have the same fixed size, just the
same element type.
llvm-svn: 50334
2008-04-28 06:01:06 +00:00
Chris Lattner
39a4281deb
Implement a signficant optimization for inline asm:
...
When choosing between constraints with multiple options,
like "ir", test to see if we can use the 'i' constraint and
go with that if possible. This produces more optimal ASM in
all cases (sparing a register and an instruction to load it),
and fixes inline asm like this:
void test () {
asm volatile (" %c0 %1 " : : "imr" (42), "imr"(14));
}
Previously we would dump "42" into a memory location (which
is ok for the 'm' constraint) which would cause a problem
because the 'c' modifier is not valid on memory operands.
Isn't it great how inline asm turns 'missed optimization'
into 'compile failed'??
Incidentally, this was the todo in
PowerPC/2007-04-24-InlineAsm-I-Modifier.ll
Please do NOT pull this into Tak.
llvm-svn: 50315
2008-04-27 00:37:18 +00:00
Chris Lattner
b83aaaa855
Move a bunch of inline asm code out of line.
...
llvm-svn: 50313
2008-04-27 00:09:47 +00:00
Chris Lattner
b5bd654163
A few inline asm cleanups:
...
- Make targetlowering.h fit in 80 cols.
- Make LowerAsmOperandForConstraint const.
- Make lowerXConstraint -> LowerXConstraint
- Make LowerXConstraint return a const char* instead of taking a string byref.
llvm-svn: 50312
2008-04-26 23:02:14 +00:00
Nick Lewycky
1f831c0f57
Remove 'unwinds to' support from mainline. This patch undoes r47802 r47989
...
r48047 r48084 r48085 r48086 r48088 r48096 r48099 r48109 and r48123.
llvm-svn: 50265
2008-04-25 16:53:59 +00:00
Gordon Henriksen
cd80583c68
PR2245: Misleading parameter name in llvm-c/Core.h:LLVMConstArray
...
Applying fix by Frits van Bommel.
llvm-svn: 50250
2008-04-25 03:21:19 +00:00
Ted Kremenek
247bdc8ec7
Implement != for DenseSet iterators.
...
llvm-svn: 50236
2008-04-24 23:49:45 +00:00
Ted Kremenek
100956926c
Added iterator support for DenseSet.
...
llvm-svn: 50235
2008-04-24 23:48:12 +00:00
Evan Cheng
1a97cb159e
- Check if a register is livein before removing it. It may have already been removed.
...
- Do not iterate over SmallPtrSet, the order of iteration is not deterministic.
llvm-svn: 50209
2008-04-24 09:06:33 +00:00
Anton Korobeynikov
b1ad6979dc
Add facility for pre-RA passes
...
llvm-svn: 50165
2008-04-23 18:22:28 +00:00
Anton Korobeynikov
73935826d4
Make stack alignment options global for all targets
...
llvm-svn: 50157
2008-04-23 18:18:10 +00:00
Dan Gohman
3c6f2b3a6f
Fix some whitespace.
...
llvm-svn: 50151
2008-04-23 17:50:15 +00:00
Chris Lattner
39e4b2e5d2
Enforce that multiple return values have to have at least one result.
...
llvm-svn: 50137
2008-04-23 05:36:34 +00:00
Nick Lewycky
97179cb16f
Whoops! Undo r50087, unbreak the build.
...
llvm-svn: 50088
2008-04-22 05:20:06 +00:00
Nick Lewycky
e708ae5ffd
Reverse r47989. Part of removing 'unwinds to' support.
...
llvm-svn: 50087
2008-04-22 05:16:51 +00:00
Chris Lattner
57e11a167d
Move SplitBlockPredecessors out of loopsimplify into BasicBlockUtils.h
...
as a global helper function. At the same type, switch it from taking
a vector of predecessors to an arbitrary sequential input. This allows
us to switch LoopSimplify to use a SmallVector for various temporary
vectors that it passed into SplitBlockPredecessors.
llvm-svn: 50020
2008-04-21 01:28:02 +00:00
Chris Lattner
368e2b28bf
add a handy helper method to instruction, useful for determining
...
whether it is used outside of some block. This can be used to see
if there are any non-local references, for example.
llvm-svn: 50004
2008-04-20 22:11:30 +00:00
Chris Lattner
c8c74f39db
Add a new Jump Threading pass, which will handle cases
...
such as those in PR2235. Right now the pass is not very
effective. :)
llvm-svn: 50000
2008-04-20 20:35:01 +00:00
Dale Johannesen
15969b664d
Check we aren't trying to convert PPC long double.
...
This fixes the testsuite failure on ppcf128-4.ll.
llvm-svn: 49994
2008-04-20 18:23:46 +00:00
Nicolas Geoffray
c80229e1c7
Cosmetic changes, as suggested by Evan. No functionality changes.
...
llvm-svn: 49993
2008-04-20 17:44:19 +00:00
Chris Lattner
d299f7b8cf
Allow argpromote to promote struct arguments with a specified number
...
of elements. Patch by Matthijs Kooijman!
llvm-svn: 49962
2008-04-19 19:50:01 +00:00
Nicolas Geoffray
f005e6fa3b
Enable jitting with a known memory size.
...
llvm-svn: 49924
2008-04-18 20:59:31 +00:00
Dan Gohman
cfdb39da9c
Remove the implicit conversion from SDOperandPtr to SDOperand*; this
...
may fix a build error on Visual Studio.
llvm-svn: 49876
2008-04-17 23:02:12 +00:00
Argyrios Kyrtzidis
2f4e52ee48
Bring in uint32_t, uint64_t, and int64_t types for MSVC.
...
llvm-svn: 49854
2008-04-17 13:56:31 +00:00
Roman Levenstein
2a2a386127
Minor clean-up based on Dan's comments.
...
llvm-svn: 49844
2008-04-17 09:29:48 +00:00
Scott Michel
4b37c88f48
Workaround for PR2207, in which pred_iterator assert gets triggered due to a
...
wee problem in Xcode 2.[45]/gcc 4.0.1.
llvm-svn: 49831
2008-04-16 23:46:39 +00:00
Dan Gohman
14ff970e58
Fix a copy+paste error in a comment.
...
llvm-svn: 49820
2008-04-16 21:57:29 +00:00
Nicolas Geoffray
1f3211af01
Correlate stubs with functions in JIT: when emitting a stub, the JIT tells the memory manager which function
...
the stub will resolve.
llvm-svn: 49814
2008-04-16 20:46:05 +00:00
Eric Christopher
3630cecfe4
Fix comment.
...
llvm-svn: 49813
2008-04-16 20:45:31 +00:00
Nicolas Geoffray
82baa2d2c6
Infrastructure for getting the machine code size of a function and an instruction. X86, PowerPC and ARM are implemented
...
llvm-svn: 49809
2008-04-16 20:10:13 +00:00
Bill Wendling
45432e8339
Add "empty()" method to sys::Path and remove unnecessary whitespace.
...
Patch by Mikhail Glushenkov!
llvm-svn: 49803
2008-04-16 18:27:02 +00:00
Roman Levenstein
728d59166f
Ongoing work on improving the instruction selection infrastructure:
...
Rename SDOperandImpl back to SDOperand.
Introduce the SDUse class that represents a use of the SDNode referred by
an SDOperand. Now it is more similar to Use/Value classes.
Patch is approved by Dan Gohman.
llvm-svn: 49795
2008-04-16 16:15:27 +00:00
Gabor Greif
32b4942a0a
merge of r49785 (from branches/ggreif/use-diet): pass V to dyn_cast by const reference, this avoids copy-constructing and destructing all the time. especially important if these constructors are not accessible
...
llvm-svn: 49787
2008-04-16 11:43:47 +00:00
Evan Cheng
6d05ce493b
Rewrite LiveVariable liveness computation. The new implementation is much simplified. It eliminated the nasty recursive routines and removed the partial def / use bookkeeping. There is also potential for performance improvement by replacing the conservative handling of partial physical register definitions. The code is currently disabled until live interval analysis is taught of the name scheme.
...
This patch also fixed a couple of nasty corner cases.
llvm-svn: 49784
2008-04-16 09:46:40 +00:00
Owen Anderson
030428b435
Major repairs to the post-dominators implementation. Patch from Florian Brandner!
...
llvm-svn: 49768
2008-04-16 04:21:16 +00:00
Chris Lattner
3d52eb61ca
fix off by one error.
...
llvm-svn: 49766
2008-04-16 04:10:37 +00:00
Chris Lattner
f24665de72
give smallstring some methods to do 'itoa'.
...
llvm-svn: 49765
2008-04-16 04:05:02 +00:00
Dale Johannesen
f45cadf9d2
Make 64-to-32 bit truncations explicit (prevent warnings).
...
All values here fit in 32 bits.
llvm-svn: 49736
2008-04-15 18:44:59 +00:00
Nicolas Geoffray
7e0110f724
Change Divided flag to Split, as suggested by Evan
...
llvm-svn: 49715
2008-04-15 08:08:50 +00:00
Evan Cheng
cff9295e43
Sort sub-registers and super-registers lists according to super-sub register relations. e.g. X86::RAX sub-register list is EAX, AX, AL, AH (order of last two are not guaranteed).
...
llvm-svn: 49714
2008-04-15 07:56:03 +00:00
Dan Gohman
3b99b3c807
Treat EntryToken nodes as "passive" so that they aren't added to the
...
ScheduleDAG; they don't correspond to any actual instructions so they
don't need to be scheduled.
This fixes a bug where the EntryToken was being scheduled multiple
times in some cases, though it ended up not causing any trouble because
EntryToken doesn't expand into anything. With this fixed the schedulers
reliably schedule the expected number of units, so we can check this
with an assertion.
This requires a tweak to test/CodeGen/X86/loop-hoist.ll because it
ends up getting scheduled differently in a trivial way, though it was
enough to fool the prcontext+grep that the test does.
llvm-svn: 49701
2008-04-15 01:22:18 +00:00
Dan Gohman
dfa422fe9e
In -view-sunit-dags, display "special" chain dependencies as cyan
...
instead of blue to distinguish them from regular dependencies.
llvm-svn: 49696
2008-04-14 23:15:07 +00:00
Dan Gohman
14dce3e51c
Teach AliasSetTracker about VAArgInst.
...
llvm-svn: 49674
2008-04-14 18:34:50 +00:00
Dan Gohman
8d46278998
Fix const-correctness issues with the SrcValue handling in the
...
memory intrinsic expansion code.
llvm-svn: 49666
2008-04-14 17:55:48 +00:00
Dale Johannesen
edcba1161f
Reverse sense of unwind-tables option. This means
...
stack tracebacks on Darwin x86-64 won't work by default;
nevertheless, everybody but me thinks this is a good idea.
llvm-svn: 49663
2008-04-14 17:54:17 +00:00
Dan Gohman
237a69b49c
Clean up some comments.
...
llvm-svn: 49661
2008-04-14 17:45:20 +00:00
Chris Lattner
f63bdaf0b5
add a new CallGraphNode::removeCallEdgeFor method, tidy some comments.
...
llvm-svn: 49617
2008-04-13 19:41:25 +00:00