Evan Cheng
f259efde47
PHI elimination should not break back edge. It can cause some significant code placement issues. rdar://8263994
...
good:
LBB0_2:
mov r2, r0
. . .
mov r1, r2
bne LBB0_2
bad:
LBB0_2:
mov r2, r0
. . .
@ BB#3:
mov r1, r2
b LBB0_2
llvm-svn: 111221
2010-08-17 01:20:36 +00:00
Eric Christopher
d84dbb5caf
Remove predicate workaround, we're going to require that predicate
...
and optional def operands are handled in the backend support.
llvm-svn: 111220
2010-08-17 01:18:37 +00:00
Eric Christopher
663f49900d
Make arm fast-isel possible to enable via command line.
...
llvm-svn: 111219
2010-08-17 00:46:57 +00:00
Benjamin Kramer
b962ca0ce5
Try to silence a overeager GCC warning.
...
llvm-svn: 111214
2010-08-17 00:33:24 +00:00
Benjamin Kramer
5f237942f5
A round of minor cleanups for ELFObjectWriter.
...
llvm-svn: 111213
2010-08-17 00:00:46 +00:00
Bob Wilson
eee4824f74
Add a testcase for svn 111208.
...
llvm-svn: 111212
2010-08-16 23:44:29 +00:00
Owen Anderson
fa7d44687f
Fix another iterator invalidation that caused a *really* nasty miscompilation in 403.gcc.
...
llvm-svn: 111210
2010-08-16 23:42:33 +00:00
Bob Wilson
c350e7a509
Ignore undef shuffle indices when checking for a VTRN shuffle. Radar 8290937.
...
llvm-svn: 111208
2010-08-16 23:37:17 +00:00
Jim Grosbach
a7c562d664
tidy up. remove unused local.
...
llvm-svn: 111206
2010-08-16 23:26:09 +00:00
Benjamin Kramer
be6cca2b7d
Silence warnings and simplify code. Eliminate a 32/64 bit portability issue.
...
llvm-svn: 111201
2010-08-16 23:00:12 +00:00
Dan Gohman
6304db3896
The plural of analysis is analyses.
...
llvm-svn: 111200
2010-08-16 22:57:28 +00:00
Dan Gohman
55cd6aadc9
Make dumpPassStructure be a PMDataManager abstraction, rather than
...
a Pass abstraction, since that's the level it's actually used at.
Rename Pass' dumpPassStructure to dumpPass.
This eliminates an awkward use of getAsPass() to convert a PMDataManager*
into a Pass* just to permit a dumpPassStructure call.
llvm-svn: 111199
2010-08-16 22:45:12 +00:00
Jim Grosbach
36d5ec383e
Better handle alignment requirements for local objects in pre-regalloc frame
...
mapping. Have the local block track its alignment requirement, and then
apply that when the block itself is allocated. Previously, offsets could
get adjusted in PEI to be different, relative to one another, than the
block allocation thought they would be, which defeats the point of doing
the allocation this way. Continuing rdar://8277890
llvm-svn: 111197
2010-08-16 22:30:41 +00:00
Bob Wilson
804f6159f1
Generalize a pattern for PKHTB: an SRL of 16-31 bits will guarantee
...
that the high halfword is zero. The shift need not be exactly 16 bits.
llvm-svn: 111196
2010-08-16 22:26:55 +00:00
Bob Wilson
3fd1e0dcda
Convert test to FileCheck.
...
llvm-svn: 111195
2010-08-16 22:21:13 +00:00
Dan Gohman
d42cc46f43
Make some of PMTopLevelManager's members non-public. In particular,
...
make its constructor protected.
llvm-svn: 111193
2010-08-16 22:03:47 +00:00
Dan Gohman
3061485624
Remove redundant inline keywords.
...
llvm-svn: 111192
2010-08-16 21:57:30 +00:00
Dan Gohman
e85c619980
Eliminate the TopLevelManagerType enum; instead, just make
...
PMTopLevelManager's constructor take a PMDataManager *, which already
provides the needed abstraction support.
llvm-svn: 111189
2010-08-16 21:38:42 +00:00
Eli Friedman
2444da0652
Comment out some broken/unused/useless instructions which mess up disassembly.
...
llvm-svn: 111185
2010-08-16 21:18:51 +00:00
Eli Friedman
1fe0d53aec
Fixes for generation of ELF relocations. Patch by Roman Divacky.
...
llvm-svn: 111183
2010-08-16 21:17:09 +00:00
Eli Friedman
51ec745509
Don't attempt to SimplifyShortMoveForm in 64-bit mode.
...
llvm-svn: 111182
2010-08-16 21:03:32 +00:00
Eli Friedman
7e2f4ce439
Until uleb/sleb are MC-ized, add a hack to make them work with ELF object
...
emission.
llvm-svn: 111177
2010-08-16 20:08:40 +00:00
Eli Friedman
b20b5249d2
Fix a few warnings in and detabify MCELFStreamer and ELFObjectWriter.
...
llvm-svn: 111175
2010-08-16 19:15:06 +00:00
Matt Fleming
6c1ad4835e
Add ELF ObjectWriter and Streamer support.
...
I forgot to add these files in commit 111172.
llvm-svn: 111174
2010-08-16 18:57:57 +00:00
Matt Fleming
f751d856f0
Hookup ELF support for X86.
...
llvm-svn: 111173
2010-08-16 18:36:14 +00:00
Matt Fleming
d83b927897
Add ELF ObjectWriter and Streamer support.
...
llvm-svn: 111172
2010-08-16 18:35:43 +00:00
Matt Fleming
9cecd63b07
Layout helper function.
...
Introduce a helper method to add a section to the end of a layout. This
will be used by the ELF ObjectWriter code to add the metadata sections
(symbol table, etc) to the end of an object file.
llvm-svn: 111171
2010-08-16 18:35:06 +00:00
Matt Fleming
c6beca522c
Record a symbol's size which is needed for ELF symbol tables.
...
llvm-svn: 111170
2010-08-16 18:34:31 +00:00
Matt Fleming
037292df7d
ELF entry size support.
...
Some ELF sections contain fixed-sized entries. Provide a way to record
the entry size of a section.
llvm-svn: 111169
2010-08-16 18:33:46 +00:00
Bob Wilson
481d7a9ab4
Rename sat_shift operand to shift_imm, in preparation for using it for other
...
instructions besides saturate instructions. No functional changes.
llvm-svn: 111168
2010-08-16 18:27:34 +00:00
Jakob Stoklund Olesen
2cd00737c0
Partially revert r111155. It looks like MSVC is calling an operator<() that
...
clang says is unused.
llvm-svn: 111167
2010-08-16 18:24:54 +00:00
Jim Grosbach
8be0196afe
track local frame size in MFI, not local to the pass, since PEI needs it.
...
llvm-svn: 111164
2010-08-16 18:06:15 +00:00
Dan Gohman
a573c41435
Revert r111031. The way LLVM defines loop invariance, the property of an
...
expression being loop invariant is not equivalent to the property of
properly dominating the loop header.
Other optimizations have also made this optimization less important.
llvm-svn: 111160
2010-08-16 17:34:25 +00:00
Jakob Stoklund Olesen
5f72a04ba7
Remove unused functions.
...
llvm-svn: 111156
2010-08-16 17:18:20 +00:00
Jakob Stoklund Olesen
b7f872197a
Remove unused functions.
...
llvm-svn: 111155
2010-08-16 17:18:18 +00:00
Bob Wilson
8303fbbcf9
Remove unused code.
...
llvm-svn: 111154
2010-08-16 17:06:03 +00:00
Bob Wilson
8f553757c4
Convert a test to use FileCheck.
...
llvm-svn: 111153
2010-08-16 17:05:27 +00:00
Dan Gohman
d0ceccd9fd
Placate overzealous compiler warnings.
...
llvm-svn: 111152
2010-08-16 17:01:55 +00:00
Dan Gohman
797a1dbb1c
To create a copy of a SmallVector with an element removed from the
...
middle, copy the elements in two groups, rather than copying all the
elements and then doing an erase on the middle of the result. These
are SmallVectors, so we shouldn't expect to hit dynamic allocation
in the common case.
llvm-svn: 111151
2010-08-16 16:57:24 +00:00
Bob Wilson
57825eea36
Install Embedded builds into usr/local. Radar 8313723.
...
llvm-svn: 111149
2010-08-16 16:39:59 +00:00
Chris Lattner
1218ed824d
silence a vc2010 warning: " result of 32-bit shift implicitly converted to
...
64 bits (was 64-bit shift intended?)", pointed out by 'nobled' on llvmdev
llvm-svn: 111148
2010-08-16 16:35:20 +00:00
Dan Gohman
0d0cc18af5
Tidy whitespace.
...
llvm-svn: 111147
2010-08-16 16:34:09 +00:00
Dan Gohman
c29eeaecec
Add a comment.
...
llvm-svn: 111145
2010-08-16 16:31:39 +00:00
Dan Gohman
7eac4961d7
Use const_iterator in a few places.
...
llvm-svn: 111144
2010-08-16 16:30:01 +00:00
Dan Gohman
74c61503b1
Use iterators instead of indices in a few more places.
...
llvm-svn: 111143
2010-08-16 16:27:53 +00:00
Dan Gohman
f29618236e
Micro-optimize SCEVConstant comparison.
...
llvm-svn: 111142
2010-08-16 16:25:35 +00:00
Dan Gohman
3688ea5c7d
Move SCEVNAryExpr's virtual member functions out of line, and convert
...
them to iterators.
llvm-svn: 111140
2010-08-16 16:21:27 +00:00
Dan Gohman
d6925bbe0d
Use iterators instead of indices in simple cases.
...
llvm-svn: 111138
2010-08-16 16:16:11 +00:00
Dan Gohman
b6c773ec2e
Avoid gratuitous inefficiency in ifndef NDEBUG code.
...
llvm-svn: 111137
2010-08-16 16:13:54 +00:00
Dan Gohman
e5fb1036e6
Make one getAddExpr call when analyzing a+b+c+d+e+... instead of one
...
for each add instruction. Ditto for Mul.
llvm-svn: 111136
2010-08-16 16:03:49 +00:00
Dan Gohman
b094b39111
Delete an unused function.
...
llvm-svn: 111135
2010-08-16 15:57:14 +00:00
Dan Gohman
89fdbaf99a
Instead of having CollectSubexpr's categorize operands as interesting or
...
uninteresting, just put all the operands on one list and make
GenerateReassociations make the decision about what's interesting.
This is simpler, and it avoids an extra ScalarEvolution::getAddExpr call.
llvm-svn: 111133
2010-08-16 15:50:00 +00:00
Dan Gohman
9b7632df26
Put add operands in ScalarEvolution-canonical order, when convenient.
...
This isn't necessary, because ScalarEvolution sorts them anyway,
but it's tidier this way.
llvm-svn: 111132
2010-08-16 15:39:27 +00:00
Dan Gohman
f99ba9671e
Specialize FoldingSetTrait<SCEV>, providing implementations of node
...
comparison and hash computation which don't require constructing
temporary ID values.
llvm-svn: 111131
2010-08-16 15:31:45 +00:00
Dan Gohman
9c9ce53b29
Add hooks to FoldingSetTrait to allow specializations to provide
...
implementations of equality comparison and hash computation. This
can be used to optimize node lookup by avoiding creating lots of
temporary ID values just for hashing and comparison purposes.
llvm-svn: 111130
2010-08-16 15:30:39 +00:00
Dan Gohman
b8640b6d73
Tidy up whitespace in comments.
...
llvm-svn: 111129
2010-08-16 15:04:39 +00:00
Dan Gohman
02341b2023
Constify FoldingSetNodeIDRef's Data.
...
llvm-svn: 111128
2010-08-16 15:03:24 +00:00
Dan Gohman
27c98e6303
Reverse the order of GetNodeProfile's arguments, for consistency
...
with FoldingSetTrait::Profile.
llvm-svn: 111127
2010-08-16 14:53:42 +00:00
Dan Gohman
1cab72a44f
Fix indentation in example code in a comment.
...
llvm-svn: 111125
2010-08-16 14:45:36 +00:00
Dan Gohman
6e964c7fb4
Avoid #include <ScalarEvolution.h> in LoopSimplify.cpp, which doesn't
...
actually use ScalarEvolution.
llvm-svn: 111124
2010-08-16 14:44:03 +00:00
Dan Gohman
250b754428
Instead, teach SimplifyCFG to trim non-address-taken blocks from
...
indirectbr destination lists.
llvm-svn: 111122
2010-08-16 14:41:14 +00:00
Dan Gohman
fb83b043eb
Revert r111058, the lint check for indirectbr successors that aren't
...
address-taken. This can occur normally, if the code which took the
address got DCEd.
llvm-svn: 111121
2010-08-16 14:39:19 +00:00
Benjamin Kramer
cbc55d9dc0
Test expects SSE, give him SSE.
...
llvm-svn: 111115
2010-08-15 23:32:03 +00:00
Oscar Fuentes
53339a737f
Updated LLVMLibDeps.cmake
...
llvm-svn: 111112
2010-08-15 22:14:42 +00:00
Oscar Fuentes
5b823e0821
CMake: Improved COMMENT on a custom command
...
llvm-svn: 111111
2010-08-15 22:14:36 +00:00
Benjamin Kramer
4566466b7f
Restore arch on these test, they fail on arm.
...
llvm-svn: 111109
2010-08-15 20:42:56 +00:00
Dale Johannesen
339423c460
Mark as XFAIL on darwin 8. PR 7886.
...
llvm-svn: 111108
2010-08-15 19:40:29 +00:00
Oscar Fuentes
8146b6ccd9
Updated the GenLibDeps -> LLVMLibDeps.cmake transformation example.
...
llvm-svn: 111104
2010-08-15 15:08:27 +00:00
Argyrios Kyrtzidis
d0fcc9a818
Revert r111082. No warnings for this common pattern.
...
llvm-svn: 111102
2010-08-15 10:27:23 +00:00
Mikhail Glushenkov
b1ec90bcf4
Update tests.
...
llvm-svn: 111096
2010-08-15 07:07:24 +00:00
Mikhail Glushenkov
6ba0ca7f40
Regenerate.
...
llvm-svn: 111095
2010-08-15 07:07:17 +00:00
Mikhail Glushenkov
938e976b90
llvmc: remove dynamic plugins.
...
llvm-svn: 111094
2010-08-15 07:07:12 +00:00
Eric Christopher
54194bd127
Rework how the non-sse2 memory barrier is lowered so that the
...
encoding is correct for the built-in assembler.
Based on a patch from Chris.
llvm-svn: 111083
2010-08-14 21:51:50 +00:00
Argyrios Kyrtzidis
7c09ddf0ae
Add ATTRIBUTE_UNUSED to methods that are not supposed to be used.
...
llvm-svn: 111082
2010-08-14 21:35:10 +00:00
Chris Lattner
2f6c3434ac
improve indentation
...
llvm-svn: 111073
2010-08-14 17:26:09 +00:00
Bob Wilson
bffc757df7
T2I_rbin_irs rr variant is for disassembly only, so don't provide a pattern.
...
llvm-svn: 111068
2010-08-14 03:18:29 +00:00
Ted Kremenek
da2eba58ed
Update CMake build.
...
llvm-svn: 111063
2010-08-14 01:55:09 +00:00
Dan Gohman
aa445c0751
LoopSimplify shouldn't split loop backedges that use indirectbr. PR7867.
...
llvm-svn: 111061
2010-08-14 00:43:09 +00:00
Dan Gohman
4a63fad976
Teach SimplifyCFG how to simplify indirectbr instructions.
...
- Eliminate redundant successors.
- Convert an indirectbr with one successor into a direct branch.
Also, generalize SimplifyCFG to be able to be run on a function entry block.
It knows quite a few simplifications which are applicable to the entry
block, and it only needs a few checks to avoid trouble with the entry block.
llvm-svn: 111060
2010-08-14 00:29:42 +00:00
Jim Grosbach
a030fa5297
Add a local stack object block allocation pass. This is still an
...
experimental pass that allocates locals relative to one another before
register allocation and then assigns them to actual stack slots as a block
later in PEI. This will eventually allow targets with limited index offset
range to allocate additional base registers (not just FP and SP) to
more efficiently reference locals, as well as handle situations where
locals cannot be referenced via SP or FP at all (dynamic stack realignment
together with variable sized objects, for example). It's currently
incomplete and almost certainly buggy. Work in progress.
Disabled by default and gated via the -enable-local-stack-alloc command
line option.
rdar://8277890
llvm-svn: 111059
2010-08-14 00:15:52 +00:00
Dan Gohman
21e6dc6aa3
Add a lint check for an indirectbr destination which has not
...
had its address taken.
llvm-svn: 111058
2010-08-13 23:56:28 +00:00
Bob Wilson
4577f37d49
Add a Thumb2 t2RSBrr instruction for disassembly only.
...
This fixes another part of PR7792.
llvm-svn: 111057
2010-08-13 23:24:25 +00:00
Jakob Stoklund Olesen
27e1f26534
Clean up the Spiller.h interface.
...
The earliestStart argument is entirely specific to linear scan allocation, and
can be easily calculated by RegAllocLinearScan.
Replace std::vector with SmallVector.
llvm-svn: 111055
2010-08-13 22:56:53 +00:00
Bob Wilson
3c9ed76ba5
Temporarily disable tail calls on ARM to work around some linker problems.
...
llvm-svn: 111050
2010-08-13 22:43:33 +00:00
Bob Wilson
15b3c3d0ac
Move the Thumb2 SSAT and USAT optional shift operator out of the
...
instruction opcode. This fixes part of PR7792.
llvm-svn: 111047
2010-08-13 21:48:10 +00:00
Dan Gohman
0c436ab356
Various optimizations. Don't compare two loops' depths
...
when they are the same loop. Don't compare two instructions'
loop depths when they are in the same block.
llvm-svn: 111045
2010-08-13 21:24:58 +00:00
Jakob Stoklund Olesen
d1191ee43c
Implement splitting inside a single block.
...
When a live range is contained a single block, we can split it around
instruction clusters. The current approach is very primitive, splitting before
and after the largest gap between uses.
llvm-svn: 111043
2010-08-13 21:18:48 +00:00
Dan Gohman
081ffcd00b
Fix LSR's ExtractImmediate and ExtractSymbol to avoid calling
...
ScalarEvolution::getAddExpr, which can be pretty expensive, when nothing
has changed, which is pretty common.
llvm-svn: 111042
2010-08-13 21:17:19 +00:00
Bruno Cardoso Lopes
160be2936b
Add comments to some pattern fragments in x86
...
llvm-svn: 111041
2010-08-13 20:39:01 +00:00
Jim Grosbach
c0b5c19547
tidy up comments
...
llvm-svn: 111040
2010-08-13 20:32:35 +00:00
Dan Gohman
63c020a210
When testing whether one loop contains another, test this directly
...
rather than testing whether the loop contains the other's header.
llvm-svn: 111039
2010-08-13 20:23:25 +00:00
Dan Gohman
3324b9ec67
Add a const.
...
llvm-svn: 111038
2010-08-13 20:17:27 +00:00
Dan Gohman
cf32f2bde1
When creating a symmetric SCEV with a constant operand, put
...
the constant operand on the left, as that's where ScalarEvolution
will end up canonicalizing to.
llvm-svn: 111037
2010-08-13 20:17:14 +00:00
Dan Gohman
ec0120a123
An add recurrence is loop-invariant in any loop inside of its
...
associated loop. This avoids potentially expensive traversals
of the add recurrence's operands.
llvm-svn: 111034
2010-08-13 20:11:39 +00:00
Jim Grosbach
5af43f04dc
tidy up 80 column and whitespace
...
llvm-svn: 111033
2010-08-13 20:08:59 +00:00
Mikhail Glushenkov
b990d970f1
Revert r111007.
...
Apparently, this is now fixed in Clang.
llvm-svn: 111032
2010-08-13 20:08:53 +00:00
Dan Gohman
874d74ef75
Implement hasComputableLoopEvolution for Add, Mul, and Trunc operators,
...
since they can support trivial implementations. This avoids potentially
expensive traversals of the operands.
llvm-svn: 111031
2010-08-13 20:03:15 +00:00
Bob Wilson
d3a828ce68
Refactor the code for disassembling Thumb2 saturate instructions along the
...
same lines as the change I made for ARM saturate instructions.
llvm-svn: 111029
2010-08-13 19:04:21 +00:00
Dale Johannesen
8d3c89e765
Revert 110491. While not wrong, it was based on a
...
misanalysis and is undesirable.
llvm-svn: 111028
2010-08-13 18:43:45 +00:00
Bruno Cardoso Lopes
081861b6b7
Fix comment to reflect code, and remove an unused argument
...
llvm-svn: 111022
2010-08-13 17:50:47 +00:00
Bruno Cardoso Lopes
1187e3f09b
Improve comment to make explicit why not to touch this could before JIT goes MC
...
llvm-svn: 111021
2010-08-13 17:44:10 +00:00
Jim Grosbach
d1f4465df0
tidy up whitespace a bit
...
llvm-svn: 111019
2010-08-13 16:55:08 +00:00
Mikhail Glushenkov
1d54a4ea1d
One more XFAIL.
...
llvm-svn: 111010
2010-08-13 07:03:56 +00:00
Mikhail Glushenkov
49fd7d3a5f
More XFAILs.
...
llvm-svn: 111008
2010-08-13 07:01:55 +00:00
Mikhail Glushenkov
8bdfce97a8
Add a workaround for building with Clang.
...
llvm-svn: 111007
2010-08-13 06:02:45 +00:00
Mikhail Glushenkov
143a33758c
Add an XFAIL.
...
llvm-svn: 111004
2010-08-13 04:15:45 +00:00
Eric Christopher
6e5b67ccc4
Revert last patch and r110954 as I meant to.
...
llvm-svn: 111001
2010-08-13 02:37:50 +00:00
Eric Christopher
5e027fe113
Revert r110954 for now, pseudo instructions can't make it through to the JIT.
...
llvm-svn: 111000
2010-08-13 02:30:00 +00:00
Mikhail Glushenkov
ee1ef8c402
Remove -fexceptions from llvmc tests.
...
llvm-svn: 110999
2010-08-13 02:29:35 +00:00
Mikhail Glushenkov
d2cc5fb971
llvmc: fix two tests, remove XFAILs.
...
Tested on Linux and Darwin; please add platform-specific XFAILs/mail me a bug
report if this still fails.
llvm-svn: 110998
2010-08-13 02:29:24 +00:00
Jakob Stoklund Olesen
3d1027e7a1
Let LiveInterval::addRange extend existing ranges, it will verify that value
...
numbers match. The old check could accidentally leave holes in openli.
Also let useIntv add all ranges for the phi-def value inserted by
enterIntvAtEnd. This works as long at the value mapping is established in
enterIntvAtEnd.
llvm-svn: 110995
2010-08-13 01:05:26 +00:00
Jakob Stoklund Olesen
840b81a19e
Remember to actually update SplitAnalysis statistics now that we have a fancy
...
function to do it.
llvm-svn: 110994
2010-08-13 01:05:23 +00:00
Benjamin Kramer
2df195eea1
Use getAllOnesValue, saves a copy and looks better.
...
llvm-svn: 110991
2010-08-13 00:29:44 +00:00
Nate Begeman
2a0ca3e937
Reapply this transformation now that it is passing the external test which it previously failed.
...
llvm-svn: 110987
2010-08-13 00:17:53 +00:00
Nate Begeman
60a31c30c3
Move some code from Verifier into SVI::isValidOperands. This allows us to catch bad shufflevector operations when they are created, rather than waiting for someone to notice later on.
...
llvm-svn: 110986
2010-08-13 00:16:46 +00:00
Dan Gohman
7b1bcaafae
Trim #includes.
...
llvm-svn: 110983
2010-08-12 23:56:03 +00:00
Dan Gohman
de6188a5d8
Tidy up whitespace.
...
llvm-svn: 110982
2010-08-12 23:50:08 +00:00
Dan Gohman
b83d1b694a
Use .empty() instead of .size().
...
llvm-svn: 110981
2010-08-12 23:46:28 +00:00
Jakob Stoklund Olesen
991e4ee860
Handle an empty dupli.
...
This can happen if the original interval has been broken into two disconnected
parts. Ideally, we should be able to detect when the graph is disconnected and
create separate intervals, but that code is not implemented yet.
Example:
Two basic blocks are both branching to a loop header. Our interval is defined in
both basic blocks, and live into the loop along both edges.
We decide to split the interval around the loop. The interval is split into an
inside part and an outside part. The outside part now has two disconnected
segments, one in each basic block.
If we later decide to split the outside interval into single blocks, we get one
interval per basic block and an empty dupli for the remainder.
llvm-svn: 110976
2010-08-12 23:02:57 +00:00
Jakob Stoklund Olesen
32c181c444
Update the SplitAnalysis statistics as uses are moved from curli to the new
...
split intervals. THis means the analysis can be used for multiple splits as long
as curli doesn't shrink.
llvm-svn: 110975
2010-08-12 23:02:55 +00:00
Chris Lattner
363226dfe8
fix PR7876: If ipsccp decides that a function's address is taken
...
before it rewrites the code, we need to use that in the post-rewrite pass.
llvm-svn: 110962
2010-08-12 22:25:23 +00:00
Bruno Cardoso Lopes
cc20fe5937
Some small clean-up: use of pseudo instructions
...
llvm-svn: 110954
2010-08-12 20:55:18 +00:00
Johnny Chen
8e8f1c133a
Cleaned up the for-disassembly-only entries in the arm instruction table so that
...
the memory barrier variants (other than 'SY' full system domain read and write)
are treated as one instruction with option operand.
llvm-svn: 110951
2010-08-12 20:46:17 +00:00
Jakob Stoklund Olesen
0910689353
Also recompute HasPHIKill flags in LiveInterval::RenumberValues.
...
If a phi-def value were removed from the interval, the phi-kill flags are no
longer valid.
llvm-svn: 110949
2010-08-12 20:38:03 +00:00
Evan Cheng
44a320dafa
Make sure ARM constant island pass does not break up an IT block. If the split point is in the middle of an IT block, it should move it up to just above the IT instruction. rdar://8302637
...
llvm-svn: 110947
2010-08-12 20:30:05 +00:00
Bruno Cardoso Lopes
7f704b31a9
- Teach SSEDomainFix to switch between different levels of AVX instructions. Here we guess that AVX will have domain issues, so just implement them for consistency and in the future we remove if it's unnecessary.
...
- Make foldMemoryOperandImpl aware of 256-bit zero vectors folding and support the 128-bit counterparts of AVX too.
- Make sure MOV[AU]PS instructions are only selected when SSE1 is enabled, and duplicate the patterns to match AVX.
- Add a testcase for a simple 128-bit zero vector creation.
llvm-svn: 110946
2010-08-12 20:20:53 +00:00
Jakob Stoklund Olesen
073cd8004a
Remove trailing whitespace.
...
llvm-svn: 110944
2010-08-12 20:01:23 +00:00
Jakob Stoklund Olesen
fa3ea11ae6
Clean up debug output.
...
llvm-svn: 110940
2010-08-12 18:50:55 +00:00
Bruno Cardoso Lopes
7e1a30c0d3
Define AVX 128-bit pattern versions of SET0PS/PD.
...
llvm-svn: 110937
2010-08-12 18:20:59 +00:00
Bob Wilson
86fa07ea05
Add a test for llvm-gcc svn 110632.
...
llvm-svn: 110935
2010-08-12 17:31:41 +00:00
Jakob Stoklund Olesen
622848b262
Implement single block splitting.
...
Before spilling a live range, we split it into a separate range for each basic
block where it is used. That way we only get one reload per basic block if the
new smaller ranges can allocate to a register.
This type of splitting is already present in the standard spiller.
llvm-svn: 110934
2010-08-12 17:07:14 +00:00
Dan Gohman
2de47777f4
Optimize ScalarEvolution::getAddExpr's operand factoring code by
...
having it finish processing all of the muliply operands before
starting the whole getAddExpr process over again, instead of
immediately after the first simplification.
llvm-svn: 110916
2010-08-12 15:00:23 +00:00
Dan Gohman
157847f5d1
Hoist some loop-invariant code out of a hot loop.
...
llvm-svn: 110915
2010-08-12 14:52:55 +00:00
Dan Gohman
e67b287451
Optimize ScalarEvolution::getAddExpr's duplicate operand detection
...
by having it finish processing the whole operand list before
starting the whole getAddExpr process over again, instead of
immediately after the first duplicate is found.
llvm-svn: 110914
2010-08-12 14:46:54 +00:00
Duncan Sands
501dff76ce
Add a 'normalize' method to the Triple class, which takes a mucked up
...
target triple and straightens it out. This does less than gcc's script
config.sub, for example it turns i386-mingw32 into i386--mingw32 not
i386-pc-mingw32, but it does a decent job of turning funky triples into
something that the rest of the Triple class can understand. The plan
is to use this to canonicalize triple's when they are first provided
by users, and have the rest of LLVM only deal with canonical triples.
Once this is done the special case workarounds in the Triple constructor
can be removed, making the class more regular and easier to use. The
comments and unittests for the Triple class are already adjusted in this
patch appropriately for this brave new world of increased uniformity.
llvm-svn: 110909
2010-08-12 11:31:39 +00:00
Eric Christopher
ac40d49c70
Temporarily revert 110737 and 110734, they were causing failures
...
in an external testsuite.
llvm-svn: 110905
2010-08-12 07:01:22 +00:00
Bruno Cardoso Lopes
1401e040eb
Fix comment order
...
llvm-svn: 110898
2010-08-12 02:08:52 +00:00
Bruno Cardoso Lopes
7306c86886
Begin to support some vector operations for AVX 256-bit intructions. The long
...
term goal here is to be able to match enough of vector_shuffle and build_vector
so all avx intrinsics which aren't mapped to their own built-ins but to
shufflevector calls can be codegen'd. This is the first (baby) step, support
building zeroed vectors.
llvm-svn: 110897
2010-08-12 02:06:36 +00:00
Johnny Chen
74491bb52c
The autogened decoder was confusing the ARM STRBT for ARM USAT, because the .td
...
entry for ARM STRBT is actually a super-instruction for A8.6.199 STRBT A1 & A2.
Recover by looking for ARM:USAT encoding pattern before delegating to the auto-
gened decoder.
Added a "usat" test case to arm-tests.txt.
llvm-svn: 110894
2010-08-12 01:40:54 +00:00
Daniel Dunbar
7d7b4d1b0f
MC/X86/AsmParser: Give an explicit error message when we reject an instruction
...
because it could have an ambiguous suffix.
llvm-svn: 110890
2010-08-12 00:55:42 +00:00
Daniel Dunbar
2ecc3bb4f7
MC/AsmParser: Push the burdon of emitting diagnostics about unmatched
...
instructions onto the target specific parser, which can do a better job.
llvm-svn: 110889
2010-08-12 00:55:38 +00:00
Daniel Dunbar
167b9d7f30
tblgen/AsmMatcher: Always emit the match function as 'MatchInstructionImpl',
...
target specific parsers can adapt the TargetAsmParser to this.
llvm-svn: 110888
2010-08-12 00:55:32 +00:00
Devang Patel
48595bf2bc
This is x86 only test.
...
llvm-svn: 110887
2010-08-12 00:17:38 +00:00
Daniel Dunbar
b524afbae3
configure: Add detection of the linker version string.
...
- Review appreciated, as long as you understand that I understand that this is
a horrible hack.
llvm-svn: 110883
2010-08-11 23:53:59 +00:00
Johnny Chen
d59c73f998
Changed the format of DMBsy, DSBsy, and friends from Pseudo to MiscFrm.
...
Added two test cases to arm-tests.txt.
llvm-svn: 110880
2010-08-11 23:35:12 +00:00
Devang Patel
4d597e8268
Even if a variable has constant value all the time, it is still a variable in gdb's eyes.
...
Tested by scope.exp in gdb testsuite.
llvm-svn: 110876
2010-08-11 23:17:54 +00:00
Bob Wilson
add513112a
Move the ARM SSAT and USAT optional shift amount operand out of the
...
instruction opcode. This also fixes part of PR7792.
llvm-svn: 110875
2010-08-11 23:10:46 +00:00
Jakob Stoklund Olesen
9c473e46f3
Fix <rdar://problem/8282498> even if it doesn't reproduce on trunk.
...
When a register is defined by a partial load:
%reg1234:sub_32 = MOV32mr <fi#-1>; GR64:%reg1234
That load cannot be folded into an instruction using the full 64-bit register.
It would become a 64-bit load.
This is related to the recent change to have isLoadFromStackSlot return false on
a sub-register load.
llvm-svn: 110874
2010-08-11 23:08:22 +00:00
Owen Anderson
7b974a45db
Fix a subtle use-after-free issue.
...
llvm-svn: 110863
2010-08-11 22:36:04 +00:00
Nick Lewycky
d385c22cf3
Clean up ConstantRange a bit:
...
- remove ashr which never worked.
- fix lshr and shl and add tests.
- remove dead function "intersect1Wrapped".
- add a new sub method to subtract ranges, with test.
llvm-svn: 110861
2010-08-11 22:04:36 +00:00