oota-llvm.git
13 years agobuild: Update install-clang target.
Daniel Dunbar [Wed, 30 Jun 2010 22:22:46 +0000 (22:22 +0000)]
build: Update install-clang target.

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@107334 91177308-0d34-0410-b5e6-96231b3b80d8

13 years agoHandle array and vector typed parameters in sjljehprepare like we do
Jim Grosbach [Wed, 30 Jun 2010 22:20:38 +0000 (22:20 +0000)]
Handle array and vector typed parameters in sjljehprepare like we do
structs. rdar://8145832

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@107332 91177308-0d34-0410-b5e6-96231b3b80d8

13 years agoRemove all debug info related named mdnodes.
Devang Patel [Wed, 30 Jun 2010 21:29:00 +0000 (21:29 +0000)]
Remove all debug info related named mdnodes.

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@107323 91177308-0d34-0410-b5e6-96231b3b80d8

13 years agogrammar tweak in comment.
Jim Grosbach [Wed, 30 Jun 2010 21:27:56 +0000 (21:27 +0000)]
grammar tweak in comment.

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@107321 91177308-0d34-0410-b5e6-96231b3b80d8

13 years agoIn ScalarEvolution::forgetValue, eliminate any SCEVUnknown
Dan Gohman [Wed, 30 Jun 2010 20:21:12 +0000 (20:21 +0000)]
In ScalarEvolution::forgetValue, eliminate any SCEVUnknown
entries associated with the value being erased in the
folding set map.  These entries used to be harmless, because
a SCEVUnknown doesn't store any information about its Value*,
so having a new Value allocated at the old Value's address
wasn't a problem. But now that ScalarEvolution is storing more
information about values, this is no longer safe.

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@107316 91177308-0d34-0410-b5e6-96231b3b80d8

13 years agoMove MOVD/MODQ code around, creating sections for each of them
Bruno Cardoso Lopes [Wed, 30 Jun 2010 18:49:10 +0000 (18:49 +0000)]
Move MOVD/MODQ code around, creating sections for each of them

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@107308 91177308-0d34-0410-b5e6-96231b3b80d8

13 years agoSome fool committed without testing (or even building) first.
Jakob Stoklund Olesen [Wed, 30 Jun 2010 18:41:20 +0000 (18:41 +0000)]
Some fool committed without testing (or even building) first.

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@107307 91177308-0d34-0410-b5e6-96231b3b80d8

13 years agoAdd AVX SSE2 mask creation and conditional store instructions
Bruno Cardoso Lopes [Wed, 30 Jun 2010 18:38:10 +0000 (18:38 +0000)]
Add AVX SSE2 mask creation and conditional store instructions

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@107306 91177308-0d34-0410-b5e6-96231b3b80d8

13 years agoRemember to track spill slot uses in VirtRegMap when inserting loads and stores.
Jakob Stoklund Olesen [Wed, 30 Jun 2010 18:19:08 +0000 (18:19 +0000)]
Remember to track spill slot uses in VirtRegMap when inserting loads and stores.
LocalRewriter::runOnMachineFunction uses this information to mark dead spill
slots.

This means that InlineSpiller now also works for functions that spill.

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@107302 91177308-0d34-0410-b5e6-96231b3b80d8

13 years agoFix a bug introduced in r107211 where instructions with memory operands are declared...
Bruno Cardoso Lopes [Wed, 30 Jun 2010 18:06:01 +0000 (18:06 +0000)]
Fix a bug introduced in r107211 where instructions with memory operands are declared as commutable

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@107300 91177308-0d34-0410-b5e6-96231b3b80d8

13 years agoRevert the part of r107257 which introduced new logic for using
Dan Gohman [Wed, 30 Jun 2010 17:27:11 +0000 (17:27 +0000)]
Revert the part of r107257 which introduced new logic for using
nsw and nuw flags from IR Instructions. On further consideration,
this isn't valid.

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@107298 91177308-0d34-0410-b5e6-96231b3b80d8

13 years agoRename NextPowerOfTwo to RoundUpToPowerOfTwo.
Duncan Sands [Wed, 30 Jun 2010 17:24:28 +0000 (17:24 +0000)]
Rename NextPowerOfTwo to RoundUpToPowerOfTwo.

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@107297 91177308-0d34-0410-b5e6-96231b3b80d8

13 years agoRemove an unused variable. The call to getRoot has side-effects, so
Duncan Sands [Wed, 30 Jun 2010 17:22:28 +0000 (17:22 +0000)]
Remove an unused variable.  The call to getRoot has side-effects, so
this could break something (but doesn't seem to).

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@107295 91177308-0d34-0410-b5e6-96231b3b80d8

13 years agoAdd AVX SSE2 packed integer extract/insert instructions
Bruno Cardoso Lopes [Wed, 30 Jun 2010 17:03:03 +0000 (17:03 +0000)]
Add AVX SSE2 packed integer extract/insert instructions

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@107293 91177308-0d34-0410-b5e6-96231b3b80d8

13 years agoClarify that the NextPowerOfTwo template is idempotent.
Duncan Sands [Wed, 30 Jun 2010 15:29:46 +0000 (15:29 +0000)]
Clarify that the NextPowerOfTwo template is idempotent.

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@107286 91177308-0d34-0410-b5e6-96231b3b80d8

13 years agoRather than giving SmallPtrSetImpl a member field SmallArray which is magically
Duncan Sands [Wed, 30 Jun 2010 15:02:37 +0000 (15:02 +0000)]
Rather than giving SmallPtrSetImpl a member field SmallArray which is magically
replaced by a bigger array in SmallPtrSet (by overridding it), instead just use a
pointer to the start of the storage, and have SmallPtrSet pass in the value to use.
This has the disadvantage that SmallPtrSet becomes bigger by one pointer.  It has
the advantage that it no longer uses tricky C++ rules, and is clearly correct while
I'm not sure the previous version was.  This was inspired by g++-4.6 pointing out
that SmallPtrSetImpl was writing off the end of SmallArray, which it was.  Since
SmallArray is replaced with a bigger array in SmallPtrSet, the write was still to
valid memory.  But it was writing off the end of the declared array type - sounds
kind of dubious to me, like it sounded dubious to g++-4.6.  Maybe g++-4.6 is wrong
and this construct is perfectly valid and correctly compiled by all compilers, but
I think it is better to avoid the whole can of worms by avoiding this construct.

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@107285 91177308-0d34-0410-b5e6-96231b3b80d8

13 years agouse ArgOperand API
Gabor Greif [Wed, 30 Jun 2010 13:45:50 +0000 (13:45 +0000)]
use ArgOperand API

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@107282 91177308-0d34-0410-b5e6-96231b3b80d8

13 years agouse ArgOperand API
Gabor Greif [Wed, 30 Jun 2010 13:03:37 +0000 (13:03 +0000)]
use ArgOperand API

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@107280 91177308-0d34-0410-b5e6-96231b3b80d8

13 years agouse ArgOperand API
Gabor Greif [Wed, 30 Jun 2010 12:55:46 +0000 (12:55 +0000)]
use ArgOperand API

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@107279 91177308-0d34-0410-b5e6-96231b3b80d8

13 years agouse ArgOperand API
Gabor Greif [Wed, 30 Jun 2010 12:42:43 +0000 (12:42 +0000)]
use ArgOperand API

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@107278 91177308-0d34-0410-b5e6-96231b3b80d8

13 years agouse ArgOperand API
Gabor Greif [Wed, 30 Jun 2010 12:40:35 +0000 (12:40 +0000)]
use ArgOperand API

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@107277 91177308-0d34-0410-b5e6-96231b3b80d8

13 years agouse CallSite::arg_end instead of CallInst::op_end
Gabor Greif [Wed, 30 Jun 2010 12:39:23 +0000 (12:39 +0000)]
use CallSite::arg_end instead of CallInst::op_end

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@107276 91177308-0d34-0410-b5e6-96231b3b80d8

13 years agouse getArgOperand (corrected by CallInst::ArgOffset) instead of getOperand
Gabor Greif [Wed, 30 Jun 2010 12:38:26 +0000 (12:38 +0000)]
use getArgOperand (corrected by CallInst::ArgOffset) instead of getOperand

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@107275 91177308-0d34-0410-b5e6-96231b3b80d8

13 years agouse getArgOperand (corrected by CallInst::ArgOffset) instead of getOperand
Gabor Greif [Wed, 30 Jun 2010 09:19:23 +0000 (09:19 +0000)]
use getArgOperand (corrected by CallInst::ArgOffset) instead of getOperand

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@107273 91177308-0d34-0410-b5e6-96231b3b80d8

13 years agouse getNumArgOperands instead of getNumOperands
Gabor Greif [Wed, 30 Jun 2010 09:17:53 +0000 (09:17 +0000)]
use getNumArgOperands instead of getNumOperands

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@107272 91177308-0d34-0410-b5e6-96231b3b80d8

13 years agouse getArgOperand instead of getOperand
Gabor Greif [Wed, 30 Jun 2010 09:16:16 +0000 (09:16 +0000)]
use getArgOperand instead of getOperand

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@107271 91177308-0d34-0410-b5e6-96231b3b80d8

13 years agouse getArgOperand instead of getOperand
Gabor Greif [Wed, 30 Jun 2010 09:15:28 +0000 (09:15 +0000)]
use getArgOperand instead of getOperand

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@107270 91177308-0d34-0410-b5e6-96231b3b80d8

13 years agouse getArgOperand instead of getOperand
Gabor Greif [Wed, 30 Jun 2010 09:14:26 +0000 (09:14 +0000)]
use getArgOperand instead of getOperand

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@107269 91177308-0d34-0410-b5e6-96231b3b80d8

13 years agoAdd a testcase for scev-aa's new capability.
Dan Gohman [Wed, 30 Jun 2010 07:17:47 +0000 (07:17 +0000)]
Add a testcase for scev-aa's new capability.

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@107258 91177308-0d34-0410-b5e6-96231b3b80d8

13 years agoImprove ScalarEvolution's nsw and nuw preservation.
Dan Gohman [Wed, 30 Jun 2010 07:16:37 +0000 (07:16 +0000)]
Improve ScalarEvolution's nsw and nuw preservation.

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@107257 91177308-0d34-0410-b5e6-96231b3b80d8

13 years agoWhen computing a new ConservativeResult, intersect it with
Dan Gohman [Wed, 30 Jun 2010 06:58:35 +0000 (06:58 +0000)]
When computing a new ConservativeResult, intersect it with
the old one instead of replacing it, to be more precise.

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@107256 91177308-0d34-0410-b5e6-96231b3b80d8

13 years agoRework scev-aa's basic computation so that it doesn't depend
Dan Gohman [Wed, 30 Jun 2010 06:12:16 +0000 (06:12 +0000)]
Rework scev-aa's basic computation so that it doesn't depend
on ScalarEvolution successfully folding and preserving
range information for both A-B and B-A. Now, if it gets
either one, it's sufficient.

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@107249 91177308-0d34-0410-b5e6-96231b3b80d8

13 years agoSimplify.
Dan Gohman [Wed, 30 Jun 2010 06:09:46 +0000 (06:09 +0000)]
Simplify.

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@107248 91177308-0d34-0410-b5e6-96231b3b80d8

13 years agoAdd AVX SSE2 integer unpack instructions
Bruno Cardoso Lopes [Wed, 30 Jun 2010 04:06:39 +0000 (04:06 +0000)]
Add AVX SSE2 integer unpack instructions

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@107246 91177308-0d34-0410-b5e6-96231b3b80d8

13 years agoAdd AVX SSE2 packed integer shuffle instructions
Bruno Cardoso Lopes [Wed, 30 Jun 2010 03:47:56 +0000 (03:47 +0000)]
Add AVX SSE2 packed integer shuffle instructions

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@107245 91177308-0d34-0410-b5e6-96231b3b80d8

13 years agoRemove trailing whitespace, no functionality changes.
John Mosby [Wed, 30 Jun 2010 03:40:54 +0000 (03:40 +0000)]
Remove trailing whitespace, no functionality changes.

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@107244 91177308-0d34-0410-b5e6-96231b3b80d8

13 years agoSmall refactoring of SSE2 packed integer shuffle instructions
Bruno Cardoso Lopes [Wed, 30 Jun 2010 03:29:36 +0000 (03:29 +0000)]
Small refactoring of SSE2 packed integer shuffle instructions

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@107243 91177308-0d34-0410-b5e6-96231b3b80d8

13 years agoAdd AVX SSE2 pack with saturation integer instructions
Bruno Cardoso Lopes [Wed, 30 Jun 2010 02:30:25 +0000 (02:30 +0000)]
Add AVX SSE2 pack with saturation integer instructions

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@107241 91177308-0d34-0410-b5e6-96231b3b80d8

13 years agoAdd AVX SSE2 integer packed compare instructions
Bruno Cardoso Lopes [Wed, 30 Jun 2010 02:21:09 +0000 (02:21 +0000)]
Add AVX SSE2 integer packed compare instructions

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@107240 91177308-0d34-0410-b5e6-96231b3b80d8

13 years ago- Add AVX form of all SSE2 logical instructions
Bruno Cardoso Lopes [Wed, 30 Jun 2010 01:58:37 +0000 (01:58 +0000)]
- Add AVX form of all SSE2 logical instructions
- Add VEX encoding bits to x86 MRM0r-MRM7r

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@107238 91177308-0d34-0410-b5e6-96231b3b80d8

13 years agoDo not construct DIE for already processed MDNode.
Devang Patel [Wed, 30 Jun 2010 01:40:11 +0000 (01:40 +0000)]
Do not construct DIE for already processed MDNode.

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@107237 91177308-0d34-0410-b5e6-96231b3b80d8

13 years agoUse skipInstruction() as a simpler way of iterating over instructions using SrcReg
Jakob Stoklund Olesen [Wed, 30 Jun 2010 00:30:36 +0000 (00:30 +0000)]
Use skipInstruction() as a simpler way of iterating over instructions using SrcReg

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@107234 91177308-0d34-0410-b5e6-96231b3b80d8

13 years agoUse clEnumValN macro to work around keyword clash
Jakob Stoklund Olesen [Wed, 30 Jun 2010 00:24:51 +0000 (00:24 +0000)]
Use clEnumValN macro to work around keyword clash

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@107233 91177308-0d34-0410-b5e6-96231b3b80d8

13 years agoAdd variables into a scope before constructing scope DIE otherwise variables won...
Devang Patel [Wed, 30 Jun 2010 00:11:08 +0000 (00:11 +0000)]
Add variables into a scope before constructing scope DIE otherwise variables won't be included DIE tree.

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@107228 91177308-0d34-0410-b5e6-96231b3b80d8

13 years agoBegin implementation of an inline spiller.
Jakob Stoklund Olesen [Tue, 29 Jun 2010 23:58:39 +0000 (23:58 +0000)]
Begin implementation of an inline spiller.

InlineSpiller inserts loads and spills immediately instead of deferring to
VirtRegMap. This is possible now because SlotIndexes allows instructions to be
inserted and renumbered.

This is work in progress, and is mostly a copy of TrivialSpiller so far. It
works very well for functions that don't require spilling.

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@107227 91177308-0d34-0410-b5e6-96231b3b80d8

13 years agoAdd *several* AVX integer packed binop instructions
Bruno Cardoso Lopes [Tue, 29 Jun 2010 23:47:49 +0000 (23:47 +0000)]
Add *several* AVX integer packed binop instructions

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@107225 91177308-0d34-0410-b5e6-96231b3b80d8

13 years agoFix ScalarEvolution's tripcount computation for chains of loops
Dan Gohman [Tue, 29 Jun 2010 23:43:06 +0000 (23:43 +0000)]
Fix ScalarEvolution's tripcount computation for chains of loops
where each loop's induction variable's start value is the exit
value of a preceding loop.

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@107224 91177308-0d34-0410-b5e6-96231b3b80d8

13 years agoRevert r107205 and r107207.
Bill Wendling [Tue, 29 Jun 2010 22:34:52 +0000 (22:34 +0000)]
Revert r107205 and r107207.

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@107215 91177308-0d34-0410-b5e6-96231b3b80d8

13 years agoPrint InlinedAt location.
Devang Patel [Tue, 29 Jun 2010 22:29:15 +0000 (22:29 +0000)]
Print InlinedAt location.

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@107214 91177308-0d34-0410-b5e6-96231b3b80d8

13 years agoAdd another bswap idiom that isn't matched.
Eric Christopher [Tue, 29 Jun 2010 22:22:22 +0000 (22:22 +0000)]
Add another bswap idiom that isn't matched.

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@107213 91177308-0d34-0410-b5e6-96231b3b80d8

13 years agoUse -l option to remove symbols from i386.
Bill Wendling [Tue, 29 Jun 2010 22:17:37 +0000 (22:17 +0000)]
Use -l option to remove symbols from i386.

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@107212 91177308-0d34-0410-b5e6-96231b3b80d8

13 years agoMove SSE2 Packed Integer instructions around, and create specific sections for each...
Bruno Cardoso Lopes [Tue, 29 Jun 2010 22:12:16 +0000 (22:12 +0000)]
Move SSE2 Packed Integer instructions around, and create specific sections for each of them

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@107211 91177308-0d34-0410-b5e6-96231b3b80d8

13 years agoPrint InlinedAt location.
Devang Patel [Tue, 29 Jun 2010 21:51:32 +0000 (21:51 +0000)]
Print InlinedAt location.

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@107208 91177308-0d34-0410-b5e6-96231b3b80d8

13 years agoImprove explanation.
Bill Wendling [Tue, 29 Jun 2010 21:41:58 +0000 (21:41 +0000)]
Improve explanation.

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@107207 91177308-0d34-0410-b5e6-96231b3b80d8

13 years agoAdd AVX Move Aligned/Unaligned packed integers
Bruno Cardoso Lopes [Tue, 29 Jun 2010 21:25:12 +0000 (21:25 +0000)]
Add AVX Move Aligned/Unaligned packed integers

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@107206 91177308-0d34-0410-b5e6-96231b3b80d8

13 years agoIntroducing the "linker_weak" linkage type. This will be used for Objective-C
Bill Wendling [Tue, 29 Jun 2010 21:24:00 +0000 (21:24 +0000)]
Introducing the "linker_weak" linkage type. This will be used for Objective-C
metadata types which should be marked as "weak", but which the linker will
remove upon final linkage. For example, the "objc_msgSend_fixup_alloc" symbol is
defined like this:

       .globl l_objc_msgSend_fixup_alloc
       .weak_definition l_objc_msgSend_fixup_alloc
       .section __DATA, __objc_msgrefs, coalesced
       .align 3
l_objc_msgSend_fixup_alloc:
        .quad   _objc_msgSend_fixup
        .quad   L_OBJC_METH_VAR_NAME_1

This is different from the "linker_private" linkage type, because it can't have
the metadata defined with ".weak_definition".

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@107205 91177308-0d34-0410-b5e6-96231b3b80d8

13 years agoAdd AVX ld/st XCSR register.
Bruno Cardoso Lopes [Tue, 29 Jun 2010 20:35:48 +0000 (20:35 +0000)]
Add AVX ld/st XCSR register.
Add VEX encoding bits for MRMXm x86 form

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@107204 91177308-0d34-0410-b5e6-96231b3b80d8

13 years agoDo not hardcode DW_AT_stmt_list value.
Devang Patel [Tue, 29 Jun 2010 20:17:53 +0000 (20:17 +0000)]
Do not hardcode DW_AT_stmt_list value.
Inspired by Artur Pietrek.

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@107202 91177308-0d34-0410-b5e6-96231b3b80d8

13 years agoAdd support for encoding VDUP (ARM core register) instructions.
Bob Wilson [Tue, 29 Jun 2010 20:13:29 +0000 (20:13 +0000)]
Add support for encoding VDUP (ARM core register) instructions.

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@107201 91177308-0d34-0410-b5e6-96231b3b80d8

13 years agoFix a buffer overflow noticed by gcc-4.6: zero is written into
Duncan Sands [Tue, 29 Jun 2010 20:12:02 +0000 (20:12 +0000)]
Fix a buffer overflow noticed by gcc-4.6: zero is written into
SmallArray[SmallSize] in the SmallPtrSetIteratorImpl, and this is
one off the end of the array.  For those who care, right now gcc
warns about writing off the end because it is confused about the
declaration of SmallArray as having length 1 in the parent class
SmallPtrSetIteratorImpl.  However if you tweak code to unconfuse
it, then it still warns about writing off the end of the array,
because of this buffer overflow.  In short, even with this fix
gcc-4.6 will warn about writing off the end of the array, but now
that is only because it is confused.

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@107200 91177308-0d34-0410-b5e6-96231b3b80d8

13 years agoNextPowerOfTwo was already used to ensure that SmallSizePowTwo is a power
Duncan Sands [Tue, 29 Jun 2010 20:05:34 +0000 (20:05 +0000)]
NextPowerOfTwo was already used to ensure that SmallSizePowTwo is a power
of two, no need to do it a second time (NextPowerOfTwo is idempotent).

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@107199 91177308-0d34-0410-b5e6-96231b3b80d8

13 years agogive PATypeHolder an explicit copy ctor which initializes the type pointer,
Chris Lattner [Tue, 29 Jun 2010 19:20:38 +0000 (19:20 +0000)]
give PATypeHolder an explicit copy ctor which initializes the type pointer,
and make PATypeHolder work with null pointers.

The implicitly generated one didn't work on numerous levels, but was still
accepted, allowing all sorts of bugs with default constructed pa type holders.

Previously, they "sort of" worked if they were default constructed and then
destructed.  Now they really work, and you can even default construct one,
then assign to it, amazing.

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@107195 91177308-0d34-0410-b5e6-96231b3b80d8

13 years agoFix the handling of partial redefines in the fast register allocator.
Jakob Stoklund Olesen [Tue, 29 Jun 2010 19:15:30 +0000 (19:15 +0000)]
Fix the handling of partial redefines in the fast register allocator.

A partial redefine needs to be treated like a tied operand, and the register
must be reloaded while processing use operands.

This fixes a bug where partially redefined registers were processed as normal
defs with a reload added. The reload could clobber another use operand if it was
a kill that allowed register reuse.

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@107193 91177308-0d34-0410-b5e6-96231b3b80d8

13 years agoFix a register scavenger crash when dealing with undefined subregs.
Bob Wilson [Tue, 29 Jun 2010 18:42:49 +0000 (18:42 +0000)]
Fix a register scavenger crash when dealing with undefined subregs.
The LowerSubregs pass needs to preserve implicit def operands attached to
EXTRACT_SUBREG instructions when it replaces those instructions with copies.

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@107189 91177308-0d34-0410-b5e6-96231b3b80d8

13 years agoAdd AVX non-temporal stores
Bruno Cardoso Lopes [Tue, 29 Jun 2010 18:22:01 +0000 (18:22 +0000)]
Add AVX non-temporal stores

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@107178 91177308-0d34-0410-b5e6-96231b3b80d8

13 years agoAdd a few more interesting testcases.
Dan Gohman [Tue, 29 Jun 2010 18:17:11 +0000 (18:17 +0000)]
Add a few more interesting testcases.

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@107177 91177308-0d34-0410-b5e6-96231b3b80d8

13 years agoFix whitespace style.
Dan Gohman [Tue, 29 Jun 2010 18:12:34 +0000 (18:12 +0000)]
Fix whitespace style.

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@107175 91177308-0d34-0410-b5e6-96231b3b80d8

13 years agoMove non-temporal movs to their own section
Bruno Cardoso Lopes [Tue, 29 Jun 2010 17:42:37 +0000 (17:42 +0000)]
Move non-temporal movs to their own section

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@107168 91177308-0d34-0410-b5e6-96231b3b80d8

13 years agoAdd support for encoding NEON VMOV (from core register to scalar) instructions.
Bob Wilson [Tue, 29 Jun 2010 17:34:07 +0000 (17:34 +0000)]
Add support for encoding NEON VMOV (from core register to scalar) instructions.
The encoding is the same as VMOV (from scalar to core register) except that
the operands are in different places.

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@107167 91177308-0d34-0410-b5e6-96231b3b80d8

13 years agoAdd sqrt, rsqrt and rcp AVX instructions
Bruno Cardoso Lopes [Tue, 29 Jun 2010 17:26:30 +0000 (17:26 +0000)]
Add sqrt, rsqrt and rcp AVX instructions

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@107166 91177308-0d34-0410-b5e6-96231b3b80d8

13 years agoskip dbg_value instructions
Jim Grosbach [Tue, 29 Jun 2010 16:55:24 +0000 (16:55 +0000)]
skip dbg_value instructions

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@107154 91177308-0d34-0410-b5e6-96231b3b80d8

13 years agominor cosmetics
Gabor Greif [Tue, 29 Jun 2010 16:27:38 +0000 (16:27 +0000)]
minor cosmetics

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@107148 91177308-0d34-0410-b5e6-96231b3b80d8

13 years agoThe t2MOVi16 and t2MOVTi16 instructions do not set CPSR. Trying to add
Bob Wilson [Tue, 29 Jun 2010 16:25:11 +0000 (16:25 +0000)]
The t2MOVi16 and t2MOVTi16 instructions do not set CPSR.  Trying to add
a CPSR operand to them causes an assertion failure, so apparently these
instructions haven't been getting a lot of use.

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@107147 91177308-0d34-0410-b5e6-96231b3b80d8

13 years agouse ArgOffset constant to prepare for operand rotation
Gabor Greif [Tue, 29 Jun 2010 16:21:20 +0000 (16:21 +0000)]
use ArgOffset constant to prepare for operand rotation

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@107146 91177308-0d34-0410-b5e6-96231b3b80d8

13 years agouse ArgOperand API
Gabor Greif [Tue, 29 Jun 2010 16:17:26 +0000 (16:17 +0000)]
use ArgOperand API

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@107145 91177308-0d34-0410-b5e6-96231b3b80d8

13 years agouse ArgOperand API
Gabor Greif [Tue, 29 Jun 2010 16:01:30 +0000 (16:01 +0000)]
use ArgOperand API

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@107144 91177308-0d34-0410-b5e6-96231b3b80d8

13 years agoReturn Changed. This required setting Changed if dbg metadata
Duncan Sands [Tue, 29 Jun 2010 14:52:10 +0000 (14:52 +0000)]
Return Changed.  This required setting Changed if dbg metadata
is stripped off.  Currently set unconditionally, since the API
does not provide a way of working out if anything was actually
stripped off.

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@107142 91177308-0d34-0410-b5e6-96231b3b80d8

13 years agoIt seems clear that this should return Changed.
Duncan Sands [Tue, 29 Jun 2010 14:49:35 +0000 (14:49 +0000)]
It seems clear that this should return Changed.

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@107141 91177308-0d34-0410-b5e6-96231b3b80d8

13 years agoAdd a VT argument to getMinimalPhysRegClass and replace the copy related uses
Rafael Espindola [Tue, 29 Jun 2010 14:02:34 +0000 (14:02 +0000)]
Add a VT argument to getMinimalPhysRegClass and replace the copy related uses
of getPhysicalRegisterRegClass with it.

If we want to make a copy (or estimate its cost), it is better to use the
smallest class as more efficient operations might be possible.

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@107140 91177308-0d34-0410-b5e6-96231b3b80d8

13 years agogetMachineBasicBlockAddress returns a uintptr_t - don't truncate
Duncan Sands [Tue, 29 Jun 2010 13:34:20 +0000 (13:34 +0000)]
getMachineBasicBlockAddress returns a uintptr_t - don't truncate
to unsigned only to extend back to a pointer sized value on the
next line.

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@107139 91177308-0d34-0410-b5e6-96231b3b80d8

13 years agoThe variable ValueSize is set to 1 on both code paths, and then
Duncan Sands [Tue, 29 Jun 2010 13:30:08 +0000 (13:30 +0000)]
The variable ValueSize is set to 1 on both code paths, and then
ignored!  Remove it.

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@107138 91177308-0d34-0410-b5e6-96231b3b80d8

13 years agoThe variable "Value" is carefully set to Layout.getSymbolAddress,
Duncan Sands [Tue, 29 Jun 2010 13:26:33 +0000 (13:26 +0000)]
The variable "Value" is carefully set to Layout.getSymbolAddress,
but then not actually used - maybe a bug?  Remove the variable.

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@107137 91177308-0d34-0410-b5e6-96231b3b80d8

13 years agoRemove unused calls to Lexer.getLoc and the pointless variable HasFillExpr.
Duncan Sands [Tue, 29 Jun 2010 13:24:40 +0000 (13:24 +0000)]
Remove unused calls to Lexer.getLoc and the pointless variable HasFillExpr.

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@107136 91177308-0d34-0410-b5e6-96231b3b80d8

13 years agoRemove pointless variable LastDef.
Duncan Sands [Tue, 29 Jun 2010 13:23:22 +0000 (13:23 +0000)]
Remove pointless variable LastDef.

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@107135 91177308-0d34-0410-b5e6-96231b3b80d8

13 years agoLooks like this test is missing an XFAIL line.
Duncan Sands [Tue, 29 Jun 2010 13:18:50 +0000 (13:18 +0000)]
Looks like this test is missing an XFAIL line.

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@107134 91177308-0d34-0410-b5e6-96231b3b80d8

13 years agoRemove unused variable Loc and pointless variables unified_syntax
Duncan Sands [Tue, 29 Jun 2010 13:04:35 +0000 (13:04 +0000)]
Remove unused variable Loc and pointless variables unified_syntax
and thumb_mode.

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@107133 91177308-0d34-0410-b5e6-96231b3b80d8

13 years agouse ArgOperand APIs
Gabor Greif [Tue, 29 Jun 2010 13:03:46 +0000 (13:03 +0000)]
use ArgOperand APIs

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@107132 91177308-0d34-0410-b5e6-96231b3b80d8

13 years agoRemove an unused and a pointless variable.
Duncan Sands [Tue, 29 Jun 2010 13:00:29 +0000 (13:00 +0000)]
Remove an unused and a pointless variable.

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@107131 91177308-0d34-0410-b5e6-96231b3b80d8

13 years agoRemove pointless and unused variables.
Duncan Sands [Tue, 29 Jun 2010 12:48:49 +0000 (12:48 +0000)]
Remove pointless and unused variables.

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@107130 91177308-0d34-0410-b5e6-96231b3b80d8

13 years agoencode operand initializations (at fixed index)
Gabor Greif [Tue, 29 Jun 2010 11:41:38 +0000 (11:41 +0000)]
encode operand initializations (at fixed index)
in terms of Op<> and ArgOffset. This works for
values of {0, 1} for ArgOffset.
Please note that ArgOffset will become 0 soon and
will go away eventually.

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@107129 91177308-0d34-0410-b5e6-96231b3b80d8

13 years agoRemove a pointless variable.
Duncan Sands [Tue, 29 Jun 2010 11:39:45 +0000 (11:39 +0000)]
Remove a pointless variable.

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@107128 91177308-0d34-0410-b5e6-96231b3b80d8

13 years agoRemove initialized but otherwise unused variables.
Duncan Sands [Tue, 29 Jun 2010 11:22:26 +0000 (11:22 +0000)]
Remove initialized but otherwise unused variables.

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@107127 91177308-0d34-0410-b5e6-96231b3b80d8

13 years agoRemove variables that are written by not read.
Duncan Sands [Tue, 29 Jun 2010 11:07:47 +0000 (11:07 +0000)]
Remove variables that are written by not read.

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@107126 91177308-0d34-0410-b5e6-96231b3b80d8

13 years agoUse a more obvious way to avoid compiling functions which are only used when XDEBUG...
Benjamin Kramer [Tue, 29 Jun 2010 10:03:11 +0000 (10:03 +0000)]
Use a more obvious way to avoid compiling functions which are only used when XDEBUG is enabled.

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@107125 91177308-0d34-0410-b5e6-96231b3b80d8

13 years agoJump through some silly hoops to make GCC accept that a function may not always
Chandler Carruth [Tue, 29 Jun 2010 06:46:00 +0000 (06:46 +0000)]
Jump through some silly hoops to make GCC accept that a function may not always
be called.

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@107124 91177308-0d34-0410-b5e6-96231b3b80d8

13 years agoPR7503: uxtb16 is not available for ARMv7-M. Patch by Brian G. Lucas.
Evan Cheng [Tue, 29 Jun 2010 05:38:36 +0000 (05:38 +0000)]
PR7503: uxtb16 is not available for ARMv7-M. Patch by Brian G. Lucas.

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@107122 91177308-0d34-0410-b5e6-96231b3b80d8

13 years agoChange if-cvt options to something that actually as useable.
Evan Cheng [Tue, 29 Jun 2010 05:37:59 +0000 (05:37 +0000)]
Change if-cvt options to something that actually as useable.

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@107121 91177308-0d34-0410-b5e6-96231b3b80d8

13 years agoWhen processing loops for scheduling latencies (used for live outs on loop
Jim Grosbach [Tue, 29 Jun 2010 04:48:13 +0000 (04:48 +0000)]
When processing loops for scheduling latencies (used for live outs on loop
back-edges), make sure not to include dbg_value instructions in the count.
Closing in on the end of rdar://7797940

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@107119 91177308-0d34-0410-b5e6-96231b3b80d8

13 years agoJust as its not safe to blindly transfer the nsw bit from an add
Dan Gohman [Tue, 29 Jun 2010 01:41:41 +0000 (01:41 +0000)]
Just as its not safe to blindly transfer the nsw bit from an add
instruction to an add scev, it's not safe to blindly transfer the
inbounds flag from a gep instruction to an nsw on the scev for the
gep.

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@107117 91177308-0d34-0410-b5e6-96231b3b80d8

13 years agoRefactoring of arithmetic instruction classes with unary operator
Bruno Cardoso Lopes [Tue, 29 Jun 2010 01:33:09 +0000 (01:33 +0000)]
Refactoring of arithmetic instruction classes with unary operator

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@107116 91177308-0d34-0410-b5e6-96231b3b80d8