Mon P Wang [Mon, 20 Dec 2010 00:54:26 +0000 (00:54 +0000)]
Add comment for testcase for 122206
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@122210
91177308-0d34-0410-b5e6-
96231b3b80d8
Chris Lattner [Mon, 20 Dec 2010 00:51:56 +0000 (00:51 +0000)]
the result of CheckForLiveRegDef is dead, remove it.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@122209
91177308-0d34-0410-b5e6-
96231b3b80d8
Chris Lattner [Mon, 20 Dec 2010 00:50:16 +0000 (00:50 +0000)]
reduce indentation, no functionality change.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@122208
91177308-0d34-0410-b5e6-
96231b3b80d8
Cameron Zwarich [Mon, 20 Dec 2010 00:08:10 +0000 (00:08 +0000)]
Ignore debug values when performing MachineVerifier liveness checks. Fixes
PR8822.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@122207
91177308-0d34-0410-b5e6-
96231b3b80d8
Mon P Wang [Sun, 19 Dec 2010 23:55:53 +0000 (23:55 +0000)]
Prevents PerformShuffleCombine from creating a node with an illegal type after legalize types
has run, e.g., prevent creating an i64 node from a v2i64 when i64 is not a legal type.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@122206
91177308-0d34-0410-b5e6-
96231b3b80d8
Cameron Zwarich [Sun, 19 Dec 2010 23:50:53 +0000 (23:50 +0000)]
Early clobber operands are allowed to be defined at use indices. This fixes one
half of PR8813.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@122205
91177308-0d34-0410-b5e6-
96231b3b80d8
Chris Lattner [Sun, 19 Dec 2010 23:24:04 +0000 (23:24 +0000)]
fix an oversight caught by Frits!
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@122204
91177308-0d34-0410-b5e6-
96231b3b80d8
Bruno Cardoso Lopes [Sun, 19 Dec 2010 22:41:43 +0000 (22:41 +0000)]
Update the Target Feature Matrix for Mips
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@122203
91177308-0d34-0410-b5e6-
96231b3b80d8
Cameron Zwarich [Sun, 19 Dec 2010 22:12:45 +0000 (22:12 +0000)]
Fix PR8815 by checking for an explicit clobber def tied to a use operand in
ConnectedVNInfoEqClasses::Classify().
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@122202
91177308-0d34-0410-b5e6-
96231b3b80d8
Chris Lattner [Sun, 19 Dec 2010 22:08:31 +0000 (22:08 +0000)]
improve the setcc -> setcc_carry optimization to happen more
consistently by moving it out of lowering into dag combine.
Add some missing patterns for matching away extended versions of setcc_c.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@122201
91177308-0d34-0410-b5e6-
96231b3b80d8
Cameron Zwarich [Sun, 19 Dec 2010 21:37:23 +0000 (21:37 +0000)]
Fix PR8811 by teaching MachineVerifier about optional defs.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@122199
91177308-0d34-0410-b5e6-
96231b3b80d8
Cameron Zwarich [Sun, 19 Dec 2010 21:32:29 +0000 (21:32 +0000)]
StrongPHIElimination will never run before TwoAddressInstructionPass.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@122197
91177308-0d34-0410-b5e6-
96231b3b80d8
Chris Lattner [Sun, 19 Dec 2010 21:23:48 +0000 (21:23 +0000)]
simplify some code to just reuse a setcc if we can instead of
going through the CSE maps to get it.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@122196
91177308-0d34-0410-b5e6-
96231b3b80d8
Nick Lewycky [Sun, 19 Dec 2010 20:57:14 +0000 (20:57 +0000)]
Use the new way of silencing this warning.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@122195
91177308-0d34-0410-b5e6-
96231b3b80d8
Nick Lewycky [Sun, 19 Dec 2010 20:43:38 +0000 (20:43 +0000)]
Add missing standard headers. Patch by Joerg Sonnenberger!
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@122193
91177308-0d34-0410-b5e6-
96231b3b80d8
Nick Lewycky [Sun, 19 Dec 2010 20:42:43 +0000 (20:42 +0000)]
Add missing std:: prefixes to some calls. C++ doesn't require that <cfoo>
headers provide symbols outside namespace std and the LLVM coding standards
state that we should prefix all of them.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@122192
91177308-0d34-0410-b5e6-
96231b3b80d8
Chris Lattner [Sun, 19 Dec 2010 20:38:28 +0000 (20:38 +0000)]
teach MaskedValueIsZero how to analyze ADDE. This is
enough to teach it that ADDE(0,0) is known 0 except the
low bit, for example.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@122191
91177308-0d34-0410-b5e6-
96231b3b80d8
Chris Lattner [Sun, 19 Dec 2010 20:24:28 +0000 (20:24 +0000)]
tidy up
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@122190
91177308-0d34-0410-b5e6-
96231b3b80d8
Chris Lattner [Sun, 19 Dec 2010 20:19:20 +0000 (20:19 +0000)]
now that generic vector types aren't selected onto MMX operations,
we don't need -disable-mmx anymore.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@122189
91177308-0d34-0410-b5e6-
96231b3b80d8
Chris Lattner [Sun, 19 Dec 2010 20:12:58 +0000 (20:12 +0000)]
now that generic vector types aren't selected onto MMX registers, these
tests don't need -disable-mmx.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@122188
91177308-0d34-0410-b5e6-
96231b3b80d8
Chris Lattner [Sun, 19 Dec 2010 20:07:10 +0000 (20:07 +0000)]
reduce copy/paste programming with the power of for loops.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@122187
91177308-0d34-0410-b5e6-
96231b3b80d8
Chris Lattner [Sun, 19 Dec 2010 20:03:11 +0000 (20:03 +0000)]
X86 supports i8/i16 overflow ops (except i8 multiplies), we should
generate them.
Now we compile:
define zeroext i8 @X(i8 signext %a, i8 signext %b) nounwind ssp {
entry:
%0 = tail call %0 @llvm.sadd.with.overflow.i8(i8 %a, i8 %b)
%cmp = extractvalue %0 %0, 1
br i1 %cmp, label %if.then, label %if.end
into:
_X: ## @X
## BB#0: ## %entry
subl $12, %esp
movb 16(%esp), %al
addb 20(%esp), %al
jo LBB0_2
Before we were generating:
_X: ## @X
## BB#0: ## %entry
pushl %ebp
movl %esp, %ebp
subl $8, %esp
movb 12(%ebp), %al
testb %al, %al
setge %cl
movb 8(%ebp), %dl
testb %dl, %dl
setge %ah
cmpb %cl, %ah
sete %cl
addb %al, %dl
testb %dl, %dl
setge %al
cmpb %al, %ah
setne %al
andb %cl, %al
testb %al, %al
jne LBB0_2
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@122186
91177308-0d34-0410-b5e6-
96231b3b80d8
Chris Lattner [Sun, 19 Dec 2010 20:01:13 +0000 (20:01 +0000)]
add a general coverage test for overflow intrinsics.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@122185
91177308-0d34-0410-b5e6-
96231b3b80d8
Chris Lattner [Sun, 19 Dec 2010 19:43:52 +0000 (19:43 +0000)]
move a transformation to a more logical place, simplifying it.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@122183
91177308-0d34-0410-b5e6-
96231b3b80d8
Chris Lattner [Sun, 19 Dec 2010 19:37:52 +0000 (19:37 +0000)]
recognize an unsigned add with overflow idiom into uadd.
This resolves a README entry and technically resolves PR4916,
but we still get poor code for the testcase in that PR because
GVN isn't CSE'ing uadd with add, filed as PR8817.
Previously we got:
_test7: ## @test7
addq %rsi, %rdi
cmpq %rdi, %rsi
movl $42, %eax
cmovaq %rsi, %rax
ret
Now we get:
_test7: ## @test7
addq %rsi, %rdi
movl $42, %eax
cmovbq %rsi, %rax
ret
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@122182
91177308-0d34-0410-b5e6-
96231b3b80d8
Chris Lattner [Sun, 19 Dec 2010 19:35:32 +0000 (19:35 +0000)]
optimize uadd(x, cst) into a comparison when the normal
result is dead. This is required for my next patch to not
regress the testsuite.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@122181
91177308-0d34-0410-b5e6-
96231b3b80d8
Chris Lattner [Sun, 19 Dec 2010 19:16:22 +0000 (19:16 +0000)]
add a version of IRBuilder::SetInsertPoint that takes an instruction.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@122180
91177308-0d34-0410-b5e6-
96231b3b80d8
Chris Lattner [Sun, 19 Dec 2010 18:38:44 +0000 (18:38 +0000)]
use IC.ReplaceInstUsesWith instead of a raw RAUW so that uses of
the old thing end up on the instcombine worklist. Not doing this
can cause an extra top-level iteration of instcombine, burning
compile time.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@122179
91177308-0d34-0410-b5e6-
96231b3b80d8
Chris Lattner [Sun, 19 Dec 2010 18:35:09 +0000 (18:35 +0000)]
generalize the sadd creation code to not require that the
sadd formed is half the size of the original type. We can
now compile this into a sadd.i8:
unsigned char X(char a, char b) {
int res = a+b;
if ((unsigned )(res+128) > 255U)
abort();
return res;
}
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@122178
91177308-0d34-0410-b5e6-
96231b3b80d8
Chris Lattner [Sun, 19 Dec 2010 18:22:06 +0000 (18:22 +0000)]
fix another miscompile in the llvm.sadd formation logic: it wasn't
checking to see if the high bits of the original add result were dead.
Inserting a smaller add and zexting back to that size is not good enough.
This is likely to be the fix for 8816.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@122177
91177308-0d34-0410-b5e6-
96231b3b80d8
Cameron Zwarich [Sun, 19 Dec 2010 18:03:27 +0000 (18:03 +0000)]
Remove some checks for StrongPHIElim. These checks make it impossible to use an
alternative register allocator that does not require LiveIntervals by specifying
it on the command-line for a target that has StrongPHIElimination enabled by
default.
These checks are pretty meaningless anyways, since StrongPHIElimination and
PHIElimination are never used at the same time.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@122176
91177308-0d34-0410-b5e6-
96231b3b80d8
Chris Lattner [Sun, 19 Dec 2010 17:59:02 +0000 (17:59 +0000)]
fix a bug (possibly 8816) in the sadd forming xform: it isn't
profitable (or safe) to promote code when the add-with-constant
has other uses.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@122175
91177308-0d34-0410-b5e6-
96231b3b80d8
Chris Lattner [Sun, 19 Dec 2010 17:52:50 +0000 (17:52 +0000)]
rework the code added in r122072 to pull it out to its own
helper function, clean up comments, and reduce indentation.
No functionality change.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@122174
91177308-0d34-0410-b5e6-
96231b3b80d8
Chris Lattner [Sun, 19 Dec 2010 05:57:25 +0000 (05:57 +0000)]
Enhance LICM to promote alias sets whose pointers themselves are stored,
which doesn't affect the memory address being promoted.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@122172
91177308-0d34-0410-b5e6-
96231b3b80d8
Chris Lattner [Sun, 19 Dec 2010 05:51:54 +0000 (05:51 +0000)]
fix PR8602, a bug in an assertion: a volatile store *of* a pointer
does not make the alias set for that pointer volatile, just stores
*to* the pointer.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@122171
91177308-0d34-0410-b5e6-
96231b3b80d8
Chris Lattner [Sun, 19 Dec 2010 04:58:57 +0000 (04:58 +0000)]
fix PR8642: if a critical edge has a PHI value that can trap,
isel is *required* to split the edge. PHI values get evaluated
on the edge, not in their predecessor block.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@122170
91177308-0d34-0410-b5e6-
96231b3b80d8
Chris Lattner [Sun, 19 Dec 2010 04:49:11 +0000 (04:49 +0000)]
remove dead header
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@122169
91177308-0d34-0410-b5e6-
96231b3b80d8
Chris Lattner [Sun, 19 Dec 2010 04:23:03 +0000 (04:23 +0000)]
revert r122164, I'm going to go with a different approach.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@122168
91177308-0d34-0410-b5e6-
96231b3b80d8
Rafael Espindola [Sun, 19 Dec 2010 04:18:56 +0000 (04:18 +0000)]
Fixed version of 122160 (the previous one would fold undefined symbols).
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@122167
91177308-0d34-0410-b5e6-
96231b3b80d8
Rafael Espindola [Sun, 19 Dec 2010 03:22:05 +0000 (03:22 +0000)]
Revert 122160 while I debug it.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@122165
91177308-0d34-0410-b5e6-
96231b3b80d8
Chris Lattner [Sun, 19 Dec 2010 03:02:34 +0000 (03:02 +0000)]
first step to fixing PR8642: don't fold away empty basic blocks
which have trapping constant exprs in them due to PHI nodes.
Eliminating them can cause the constant expr to be evalutated
on new paths if the input edges are critical.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@122164
91177308-0d34-0410-b5e6-
96231b3b80d8
Chris Lattner [Sun, 19 Dec 2010 02:58:14 +0000 (02:58 +0000)]
move this test into the ARM test so that it is only run when the arm backend
is enabled.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@122163
91177308-0d34-0410-b5e6-
96231b3b80d8
Rafael Espindola [Sun, 19 Dec 2010 02:15:04 +0000 (02:15 +0000)]
Move all folding to AttemptToFoldSymbolOffsetDifference.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@122160
91177308-0d34-0410-b5e6-
96231b3b80d8
Michael J. Spencer [Sat, 18 Dec 2010 22:23:24 +0000 (22:23 +0000)]
Support/PathV1: Clarify deprecation warning.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@122159
91177308-0d34-0410-b5e6-
96231b3b80d8
Michael J. Spencer [Sat, 18 Dec 2010 22:23:15 +0000 (22:23 +0000)]
Fix whitespace.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@122158
91177308-0d34-0410-b5e6-
96231b3b80d8
Michael J. Spencer [Sat, 18 Dec 2010 22:23:07 +0000 (22:23 +0000)]
Support/PathV1: Deprecate get{Basename,Dirname,Suffix}.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@122157
91177308-0d34-0410-b5e6-
96231b3b80d8
Chris Lattner [Sat, 18 Dec 2010 20:22:49 +0000 (20:22 +0000)]
simplify this a bit.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@122156
91177308-0d34-0410-b5e6-
96231b3b80d8
Anton Korobeynikov [Sat, 18 Dec 2010 19:53:14 +0000 (19:53 +0000)]
Restore the behavior of frame lowering before my refactoring.
It turns out that ppc backend has really weird interdependencies
over different hooks and all stuff is fragile wrt small changes.
This should fix PR8749
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@122155
91177308-0d34-0410-b5e6-
96231b3b80d8
Benjamin Kramer [Sat, 18 Dec 2010 14:23:57 +0000 (14:23 +0000)]
Just rename the functions, relying on matching a instruction that has the same name as a symbol is way too fragile.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@122154
91177308-0d34-0410-b5e6-
96231b3b80d8
Benjamin Kramer [Sat, 18 Dec 2010 14:07:28 +0000 (14:07 +0000)]
Test more than just label names and make test work on non-x86 hosts.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@122153
91177308-0d34-0410-b5e6-
96231b3b80d8
Eric Christopher [Sat, 18 Dec 2010 10:54:29 +0000 (10:54 +0000)]
Header warning patrol.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@122152
91177308-0d34-0410-b5e6-
96231b3b80d8
Roman Divacky [Sat, 18 Dec 2010 08:56:37 +0000 (08:56 +0000)]
Add support for lexing single quotes like 'c'.
This fixed 8615.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@122150
91177308-0d34-0410-b5e6-
96231b3b80d8
Owen Anderson [Sat, 18 Dec 2010 07:37:18 +0000 (07:37 +0000)]
Revert r122143 through r122140, which collectively broke the LLVMC tests on
the buildbots.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@122149
91177308-0d34-0410-b5e6-
96231b3b80d8
Rafael Espindola [Sat, 18 Dec 2010 06:27:54 +0000 (06:27 +0000)]
Merge isAbsolute into IsSymbolRefDifferenceFullyResolved.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@122148
91177308-0d34-0410-b5e6-
96231b3b80d8
Rafael Espindola [Sat, 18 Dec 2010 05:37:28 +0000 (05:37 +0000)]
Remove the MCObjectFormat class.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@122147
91177308-0d34-0410-b5e6-
96231b3b80d8
Rafael Espindola [Sat, 18 Dec 2010 05:07:45 +0000 (05:07 +0000)]
Add a test that shows that we produce no fixups when computing the difference
of two symbols in the same fragment.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@122145
91177308-0d34-0410-b5e6-
96231b3b80d8
Rafael Espindola [Sat, 18 Dec 2010 04:19:20 +0000 (04:19 +0000)]
Add a FIXME and explain a hack.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@122144
91177308-0d34-0410-b5e6-
96231b3b80d8
Michael J. Spencer [Sat, 18 Dec 2010 04:13:54 +0000 (04:13 +0000)]
Support/PathV1: Clarify deprecation warning.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@122143
91177308-0d34-0410-b5e6-
96231b3b80d8
Michael J. Spencer [Sat, 18 Dec 2010 04:13:46 +0000 (04:13 +0000)]
Fix whitespace.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@122142
91177308-0d34-0410-b5e6-
96231b3b80d8
Michael J. Spencer [Sat, 18 Dec 2010 04:13:36 +0000 (04:13 +0000)]
Support/PathV1: Deprecate get{Basename,Dirname,Suffix}.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@122141
91177308-0d34-0410-b5e6-
96231b3b80d8
Rafael Espindola [Sat, 18 Dec 2010 04:01:45 +0000 (04:01 +0000)]
Fix the note.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@122139
91177308-0d34-0410-b5e6-
96231b3b80d8
Rafael Espindola [Sat, 18 Dec 2010 03:57:21 +0000 (03:57 +0000)]
Revert 122011, 122012, 122013, 122023 adding back an important optimization.
I added a note, but suggestions on how to add a test are really welcome.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@122138
91177308-0d34-0410-b5e6-
96231b3b80d8
Jakob Stoklund Olesen [Sat, 18 Dec 2010 03:28:32 +0000 (03:28 +0000)]
Apparently, operandices is not a word.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@122135
91177308-0d34-0410-b5e6-
96231b3b80d8
Rafael Espindola [Sat, 18 Dec 2010 03:27:34 +0000 (03:27 +0000)]
Move some data to the TargetWriter.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@122134
91177308-0d34-0410-b5e6-
96231b3b80d8
Jakob Stoklund Olesen [Sat, 18 Dec 2010 03:04:14 +0000 (03:04 +0000)]
Teach the inline spiller to attempt folding a load instruction into its single
use before rematerializing the load.
This allows us to produce:
addps LCPI0_1(%rip), %xmm2
Instead of:
movaps LCPI0_1(%rip), %xmm3
addps %xmm3, %xmm2
Saving a register and an instruction. The standard spiller already knows how to
do this.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@122133
91177308-0d34-0410-b5e6-
96231b3b80d8
Jakob Stoklund Olesen [Sat, 18 Dec 2010 03:04:11 +0000 (03:04 +0000)]
Tweak debug spew.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@122132
91177308-0d34-0410-b5e6-
96231b3b80d8
Bill Wendling [Sat, 18 Dec 2010 02:13:59 +0000 (02:13 +0000)]
r120333 changed the opcode for the Thumb1 stuff from ARM::tMOVr to
ARM::tMOVgpr2gpr. But this check didn't change. As a result, we were getting
misaligned references to the jump table from an ADR instruction.
There is a test case, but unfortunately it's sensitive to random code changes.
<rdar://problem/
8782223>
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@122131
91177308-0d34-0410-b5e6-
96231b3b80d8
Bill Wendling [Sat, 18 Dec 2010 01:53:06 +0000 (01:53 +0000)]
RemoveUnusedCPEntries can change things. Track it.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@122129
91177308-0d34-0410-b5e6-
96231b3b80d8
Rafael Espindola [Sat, 18 Dec 2010 01:16:59 +0000 (01:16 +0000)]
Test for push being relaxed.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@122124
91177308-0d34-0410-b5e6-
96231b3b80d8
Jakob Stoklund Olesen [Sat, 18 Dec 2010 01:06:19 +0000 (01:06 +0000)]
Check that the register is live-in to the loop header before inserting copies in
the loop predecessors.
The register can be live-out from a predecessor without being live-in to the
loop header if there is a critical edge from the predecessor.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@122123
91177308-0d34-0410-b5e6-
96231b3b80d8
Nick Lewycky [Sat, 18 Dec 2010 01:05:55 +0000 (01:05 +0000)]
Fix GCC warning:
lib/CodeGen/RegAllocGreedy.cpp:311: error: unused variable 'PhysReg' [-Wunused-variable]
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@122122
91177308-0d34-0410-b5e6-
96231b3b80d8
Rafael Espindola [Sat, 18 Dec 2010 01:01:34 +0000 (01:01 +0000)]
Relax push instructions.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@122121
91177308-0d34-0410-b5e6-
96231b3b80d8
Nick Lewycky [Sat, 18 Dec 2010 01:00:40 +0000 (01:00 +0000)]
Make LazyValueInfo non-recursive.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@122120
91177308-0d34-0410-b5e6-
96231b3b80d8
Bob Wilson [Sat, 18 Dec 2010 00:42:58 +0000 (00:42 +0000)]
Rearrange some Neon multiclasses. No functional changes.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@122119
91177308-0d34-0410-b5e6-
96231b3b80d8
Michael J. Spencer [Sat, 18 Dec 2010 00:19:10 +0000 (00:19 +0000)]
Support/PathV1: Deprecate getLast.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@122116
91177308-0d34-0410-b5e6-
96231b3b80d8
Michael J. Spencer [Sat, 18 Dec 2010 00:18:58 +0000 (00:18 +0000)]
CMake: Cleanup and document MSVC warning flags.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@122115
91177308-0d34-0410-b5e6-
96231b3b80d8
Owen Anderson [Sat, 18 Dec 2010 00:07:15 +0000 (00:07 +0000)]
Add support to CallbackVH to receive notification when a Value's use-list changes.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@122114
91177308-0d34-0410-b5e6-
96231b3b80d8
Jakob Stoklund Olesen [Sat, 18 Dec 2010 00:06:56 +0000 (00:06 +0000)]
Pass a Banner argument to the machine code verifier both from
createMachineVerifierPass and MachineFunction::verify.
The banner is printed before the machine code dump, just like the printer pass.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@122113
91177308-0d34-0410-b5e6-
96231b3b80d8
Bob Wilson [Sat, 18 Dec 2010 00:04:33 +0000 (00:04 +0000)]
Fix result type of Neon floating-point comparisons against zero.
The result vector elements are always integers. Radar
8782191.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@122112
91177308-0d34-0410-b5e6-
96231b3b80d8
Bob Wilson [Sat, 18 Dec 2010 00:04:26 +0000 (00:04 +0000)]
Add some missing entries in ARMTargetLowering::getTargetNodeName.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@122111
91177308-0d34-0410-b5e6-
96231b3b80d8
Bill Wendling [Fri, 17 Dec 2010 23:27:41 +0000 (23:27 +0000)]
Whitespace fixes. No functionality change.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@122110
91177308-0d34-0410-b5e6-
96231b3b80d8
Jakob Stoklund Olesen [Fri, 17 Dec 2010 23:16:38 +0000 (23:16 +0000)]
Avoid dereferencing end() in collectInterferingVRegs() when there is no
interference.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@122108
91177308-0d34-0410-b5e6-
96231b3b80d8
Jakob Stoklund Olesen [Fri, 17 Dec 2010 23:16:35 +0000 (23:16 +0000)]
Make the -verify-regalloc command line option available to base classes as
RegAllocBase::VerifyEnabled.
Run the machine code verifier in a few interesting places during RegAllocGreedy.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@122107
91177308-0d34-0410-b5e6-
96231b3b80d8
Jakob Stoklund Olesen [Fri, 17 Dec 2010 23:16:32 +0000 (23:16 +0000)]
Enable loop splitting in RegAllocGreedy.
The heuristics split around the largest loop where the current register may be
allocated without interference.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@122106
91177308-0d34-0410-b5e6-
96231b3b80d8
Nate Begeman [Fri, 17 Dec 2010 23:12:19 +0000 (23:12 +0000)]
Add vector versions of some existing scalar transforms to aid codegen in matching psign & pblend operations to the IR produced by clang/gcc for their C idioms.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@122105
91177308-0d34-0410-b5e6-
96231b3b80d8
Bill Wendling [Fri, 17 Dec 2010 23:09:14 +0000 (23:09 +0000)]
During local stack slot allocation, the materializeFrameBaseRegister function
may be called. If the entry block is empty, the insertion point iterator will be
the "end()" value. Calling ->getParent() on it (among others) causes problems.
Modify materializeFrameBaseRegister to take the machine basic block and insert
the frame base register at the beginning of that block. (It's very similar to
what the code does all ready. The only difference is that it will always insert
at the beginning of the entry block instead of after a previous materialization
of the frame base register. I doubt that that matters here.)
<rdar://problem/
8782198>
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@122104
91177308-0d34-0410-b5e6-
96231b3b80d8
Bob Wilson [Fri, 17 Dec 2010 23:06:49 +0000 (23:06 +0000)]
Fix a DAGCombiner crash when folding binary vector operations with constant
BUILD_VECTOR operands where the element type is not legal. I had previously
changed this code to insert TRUNCATE operations, but that was just wrong.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@122102
91177308-0d34-0410-b5e6-
96231b3b80d8
Bob Wilson [Fri, 17 Dec 2010 23:06:46 +0000 (23:06 +0000)]
Combine several vector-related DAGCombiner tests.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@122101
91177308-0d34-0410-b5e6-
96231b3b80d8
Bob Wilson [Fri, 17 Dec 2010 23:06:42 +0000 (23:06 +0000)]
Avoid report_fatal_error in ARM's PrintAsmOperand method.
The standard error handling in AsmPrinter::EmitInlineAsm handles this much
better, so just use it.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@122100
91177308-0d34-0410-b5e6-
96231b3b80d8
Bob Wilson [Fri, 17 Dec 2010 23:06:32 +0000 (23:06 +0000)]
Remove trailing whitespace.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@122099
91177308-0d34-0410-b5e6-
96231b3b80d8
Nate Begeman [Fri, 17 Dec 2010 22:55:37 +0000 (22:55 +0000)]
Add support for matching psign & plendvb to the x86 target
Remove unnecessary pandn patterns, 'vnot' patfrag looks through bitcasts
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@122098
91177308-0d34-0410-b5e6-
96231b3b80d8
Jakob Stoklund Olesen [Fri, 17 Dec 2010 22:07:54 +0000 (22:07 +0000)]
Add more checks to IntervalMapOverlaps::advance() to ensure that advanceTo sees
monotonic keys.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@122093
91177308-0d34-0410-b5e6-
96231b3b80d8
Jakob Stoklund Olesen [Fri, 17 Dec 2010 22:07:51 +0000 (22:07 +0000)]
It is allowed to call IntervalMap::const_iterator::advanceTo() with a key that
moves the iterator to end(), and it is valid to call it on end().
That means it is valid to call advanceTo() with any monotonic key sequence.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@122092
91177308-0d34-0410-b5e6-
96231b3b80d8
Owen Anderson [Fri, 17 Dec 2010 21:49:48 +0000 (21:49 +0000)]
Thumb's forced-PC-alignment requirement applies to the _total_ displacement, not just to the fragment relative
portion. While the fragment boundary is usually already aligned, it is possible for it not to be, which
would lead to a non-aligned final displacement.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@122091
91177308-0d34-0410-b5e6-
96231b3b80d8
Dale Johannesen [Fri, 17 Dec 2010 21:45:49 +0000 (21:45 +0000)]
Add a transform to DAG Combiner. This improves the
code for the case where 32-bit divide by constant is
turned into 64-bit multiply by constant.
8771012.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@122090
91177308-0d34-0410-b5e6-
96231b3b80d8
Michael J. Spencer [Fri, 17 Dec 2010 21:32:47 +0000 (21:32 +0000)]
Fix 80 col.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@122089
91177308-0d34-0410-b5e6-
96231b3b80d8
Michael J. Spencer [Fri, 17 Dec 2010 21:21:31 +0000 (21:21 +0000)]
Support/Path: Deprecate PathV1::isAbsolute.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@122086
91177308-0d34-0410-b5e6-
96231b3b80d8
Benjamin Kramer [Fri, 17 Dec 2010 20:27:37 +0000 (20:27 +0000)]
PathV2: Use StringRef::substr to simplify substring creation.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@122085
91177308-0d34-0410-b5e6-
96231b3b80d8
Jakob Stoklund Olesen [Fri, 17 Dec 2010 19:18:41 +0000 (19:18 +0000)]
Allow missing kill flags on an untied operand of a two-address instruction when
the operand uses the same register as a tied operand:
%r1 = add %r1, %r1
If add were a three-address instruction, kill flags would be required on at
least one of the uses. Since it is a two-address instruction, the tied use
operand must not have a kill flag.
This change makes the kill flag on the untied use operand optional.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@122082
91177308-0d34-0410-b5e6-
96231b3b80d8
Jakob Stoklund Olesen [Fri, 17 Dec 2010 19:18:38 +0000 (19:18 +0000)]
Fix crash when IntervalMapOverlaps::advanceTo moves past the last overlap.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@122081
91177308-0d34-0410-b5e6-
96231b3b80d8