oota-llvm.git
13 years agoFix Thumb encoding of VMOV (scalar to ARM core register). The encoding is
Bob Wilson [Tue, 29 Jun 2010 00:26:13 +0000 (00:26 +0000)]
Fix Thumb encoding of VMOV (scalar to ARM core register).  The encoding is
the same as ARM except that the condition code field is always set to ARMCC::AL.

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

13 years agoThe comment string does not match for all targets. PowerPC uses ;.
Devang Patel [Tue, 29 Jun 2010 00:04:40 +0000 (00:04 +0000)]
The comment string does not match for all targets. PowerPC uses ;.

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

13 years agoUnlike other targets, ARM now uses BUILD_VECTORs post-legalization so they
Bob Wilson [Mon, 28 Jun 2010 23:40:25 +0000 (23:40 +0000)]
Unlike other targets, ARM now uses BUILD_VECTORs post-legalization so they
can't be changed arbitrarily by the DAGCombiner without checking if it is
running after legalization.

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

13 years agoRefix XTARGET. Previous attempt matches on powerpc-apple-darwin,
Dale Johannesen [Mon, 28 Jun 2010 22:45:33 +0000 (22:45 +0000)]
Refix XTARGET.  Previous attempt matches on powerpc-apple-darwin,
although I don't see why.

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

13 years agoAttempt to fix XTARGET.
Dale Johannesen [Mon, 28 Jun 2010 22:31:52 +0000 (22:31 +0000)]
Attempt to fix XTARGET.

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

13 years agoMake the ARMCodeEmitter identify Thumb functions via ARMFunctionInfo instead
Bob Wilson [Mon, 28 Jun 2010 22:23:17 +0000 (22:23 +0000)]
Make the ARMCodeEmitter identify Thumb functions via ARMFunctionInfo instead
of the Subtarget.

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

13 years agoUse DW_FORM_addr for DW_AT_entry_pc.
Devang Patel [Mon, 28 Jun 2010 22:22:47 +0000 (22:22 +0000)]
Use DW_FORM_addr for DW_AT_entry_pc.

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

13 years agoAdd a blurb about -scev-aa.
Dan Gohman [Mon, 28 Jun 2010 22:09:52 +0000 (22:09 +0000)]
Add a blurb about -scev-aa.

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

13 years agoIn asm's, output operands with matching input constraints
Dale Johannesen [Mon, 28 Jun 2010 22:09:45 +0000 (22:09 +0000)]
In asm's, output operands with matching input constraints
have to be registers, per gcc documentation.  This affects
the logic for determining what "g" should lower to.  PR 7393.
A couple of existing testcases are affected.

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

13 years agoAdded the darwin .secure_log_unique and .secure_log_reset directives.
Kevin Enderby [Mon, 28 Jun 2010 21:45:58 +0000 (21:45 +0000)]
Added the darwin .secure_log_unique and .secure_log_reset directives.

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

13 years agoConstant fold x == undef to undef.
Dan Gohman [Mon, 28 Jun 2010 21:30:07 +0000 (21:30 +0000)]
Constant fold x == undef to undef.

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

13 years agotidy up style. no functional change.
Jim Grosbach [Mon, 28 Jun 2010 21:29:17 +0000 (21:29 +0000)]
tidy up style. no functional change.

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

13 years agoFix Value::stripPointerCasts and BasicAA to avoid trouble on
Dan Gohman [Mon, 28 Jun 2010 21:16:52 +0000 (21:16 +0000)]
Fix Value::stripPointerCasts and BasicAA to avoid trouble on
code in unreachable blocks, which have have use-def cycles.
This fixes PR7514.

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

13 years agoRefactor encoding function for NEON 1-register with modified immediate format.
Bob Wilson [Mon, 28 Jun 2010 21:16:30 +0000 (21:16 +0000)]
Refactor encoding function for NEON 1-register with modified immediate format.

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

13 years agoSupport Thumb mode encoding of NEON instructions.
Bob Wilson [Mon, 28 Jun 2010 21:12:19 +0000 (21:12 +0000)]
Support Thumb mode encoding of NEON instructions.

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

13 years agoReduce indentation via early exit. NFC.
Bill Wendling [Mon, 28 Jun 2010 21:08:32 +0000 (21:08 +0000)]
Reduce indentation via early exit. NFC.

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

13 years agoInclude inlined function in list of processed subprograms.
Devang Patel [Mon, 28 Jun 2010 20:53:04 +0000 (20:53 +0000)]
Include inlined function in list of processed subprograms.

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

13 years agonew, no longer brain-dead, r106907
Jim Grosbach [Mon, 28 Jun 2010 20:26:00 +0000 (20:26 +0000)]
new, no longer brain-dead, r106907

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

13 years agoRemove this weak test.
Devang Patel [Mon, 28 Jun 2010 20:24:35 +0000 (20:24 +0000)]
Remove this weak test.

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

13 years agoTestcase for llvm-gcc fix 107051.
Dale Johannesen [Mon, 28 Jun 2010 20:07:30 +0000 (20:07 +0000)]
Testcase for llvm-gcc fix 107051.

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

13 years agoDon't write temporary files in test directory
Jakob Stoklund Olesen [Mon, 28 Jun 2010 20:01:15 +0000 (20:01 +0000)]
Don't write temporary files in test directory

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

13 years agoAfter physreg coalescing, physical registers might not have live ranges where
Jakob Stoklund Olesen [Mon, 28 Jun 2010 19:39:57 +0000 (19:39 +0000)]
After physreg coalescing, physical registers might not have live ranges where
you would expect.

Don't assert on that case, just give up.

This fixes PR7513.

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

13 years agoAdd a triple so test runs on Linux as well.
Jakob Stoklund Olesen [Mon, 28 Jun 2010 19:31:15 +0000 (19:31 +0000)]
Add a triple so test runs on Linux as well.

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

13 years agoAdd more special treatment for inline asm in RegAllocFast.
Jakob Stoklund Olesen [Mon, 28 Jun 2010 18:34:34 +0000 (18:34 +0000)]
Add more special treatment for inline asm in RegAllocFast.

When an instruction has tied operands and physreg defines, we must take extra
care that the tied operands conflict with neither physreg defs nor uses.

The special treatment is given to inline asm and instructions with tied operands
/ early clobbers and physreg defines.

This fixes PR7509.

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

13 years agoFix thinko.
Eric Christopher [Mon, 28 Jun 2010 18:33:48 +0000 (18:33 +0000)]
Fix thinko.

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

13 years agoPull in the libCrashReporterClient.a information with a warning comment.
Eric Christopher [Mon, 28 Jun 2010 18:25:51 +0000 (18:25 +0000)]
Pull in the libCrashReporterClient.a information with a warning comment.

Remove library check and regenerate configure.

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

13 years agoPreserve deleted function's local variables' debug info.
Devang Patel [Mon, 28 Jun 2010 18:25:03 +0000 (18:25 +0000)]
Preserve deleted function's local variables' debug info.
Radar 8122864.

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

13 years agoMake this test darwin specific.
Devang Patel [Mon, 28 Jun 2010 18:04:03 +0000 (18:04 +0000)]
Make this test darwin specific.

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

13 years agouse ArgOperand API
Gabor Greif [Mon, 28 Jun 2010 16:50:57 +0000 (16:50 +0000)]
use ArgOperand API

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

13 years agouse ArgOperand API
Gabor Greif [Mon, 28 Jun 2010 16:45:00 +0000 (16:45 +0000)]
use ArgOperand API

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

13 years agoemploy CallInst::ArgOffset (for now)
Gabor Greif [Mon, 28 Jun 2010 16:43:57 +0000 (16:43 +0000)]
employ CallInst::ArgOffset (for now)

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

13 years agosimplify: we have solid argument iterator range
Gabor Greif [Mon, 28 Jun 2010 16:40:52 +0000 (16:40 +0000)]
simplify: we have solid argument iterator range

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

13 years agoGeneralize AAEval so that it can be used both per-function and
Dan Gohman [Mon, 28 Jun 2010 16:01:37 +0000 (16:01 +0000)]
Generalize AAEval so that it can be used both per-function and
interprocedurally. Note that as of this writing, existing alias
analysis passes are not prepared to be used interprocedurally.

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

13 years agoFix this build message so that it displays the correct library
Dan Gohman [Mon, 28 Jun 2010 15:55:15 +0000 (15:55 +0000)]
Fix this build message so that it displays the correct library
name, specifically the "lib" prefix.

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

13 years agoRevert r106907, "make sure to handle dbg_value instructions in the middle of the
Daniel Dunbar [Mon, 28 Jun 2010 15:47:17 +0000 (15:47 +0000)]
Revert r106907, "make sure to handle dbg_value instructions in the middle of the
block, not...", it caused a bunch of nightly test regressions.

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

13 years agouse setArgOperand
Gabor Greif [Mon, 28 Jun 2010 12:31:35 +0000 (12:31 +0000)]
use setArgOperand

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

13 years agouse CallInst::ArgOffset
Gabor Greif [Mon, 28 Jun 2010 12:30:07 +0000 (12:30 +0000)]
use CallInst::ArgOffset

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

13 years agouse ArgOperand API and CallInst::ArgOffset
Gabor Greif [Mon, 28 Jun 2010 12:29:20 +0000 (12:29 +0000)]
use ArgOperand API and CallInst::ArgOffset

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

13 years agoextend ArgOperand interface: setArgOperand
Gabor Greif [Mon, 28 Jun 2010 12:23:36 +0000 (12:23 +0000)]
extend ArgOperand interface: setArgOperand
(in both CallInst and InvokeInst)

also add a (short-lived) constant to CallInst, that names
the operand index of the first call argument. This is
strictly transitional and should not be used for new code.

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

13 years agouse cached value
Gabor Greif [Mon, 28 Jun 2010 11:20:42 +0000 (11:20 +0000)]
use cached value

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

13 years agoRemove dead code.
Devang Patel [Mon, 28 Jun 2010 05:59:13 +0000 (05:59 +0000)]
Remove dead code.

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

13 years agoUse named MDNode, llvm.dbg.sp, to collect subprogram info. This will be used to emit...
Devang Patel [Mon, 28 Jun 2010 05:53:08 +0000 (05:53 +0000)]
Use named MDNode, llvm.dbg.sp, to collect subprogram info. This will be used to emit  local variable's debug info of deleted functions.

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

13 years agominor housekeeping cleanup: 80-column, trailing whitespace, spelling, etc.. No functi...
Jim Grosbach [Mon, 28 Jun 2010 04:27:01 +0000 (04:27 +0000)]
minor housekeeping cleanup: 80-column, trailing whitespace, spelling, etc.. No functional change.

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

13 years agoDo not forget last element, function, while creating Subprogram definition MDNode...
Devang Patel [Sun, 27 Jun 2010 21:04:31 +0000 (21:04 +0000)]
Do not forget last element, function, while creating Subprogram definition MDNode from subprogram declare MDNode.

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

13 years agominor cleanup to SROA: when lowering type unsafe accesses to
Chris Lattner [Sun, 27 Jun 2010 07:58:26 +0000 (07:58 +0000)]
minor cleanup to SROA: when lowering type unsafe accesses to
large integers, the first inserted value would always create
an 'or X, 0'.  Even though this is trivially zapped by
instcombine, don't bother creating this pointless instruction.

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

13 years agoadd some named accessors for StoreInst
Chris Lattner [Sat, 26 Jun 2010 23:26:37 +0000 (23:26 +0000)]
add some named accessors for StoreInst

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

13 years agofit in 80 cols
Chris Lattner [Sat, 26 Jun 2010 23:26:22 +0000 (23:26 +0000)]
fit in 80 cols

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

13 years agothis test is failing nondeterministically and blaming me, just disable
Chris Lattner [Sat, 26 Jun 2010 22:08:30 +0000 (22:08 +0000)]
this test is failing nondeterministically and blaming me, just disable
it for now.

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

13 years agoFix test weirdness.
Benjamin Kramer [Sat, 26 Jun 2010 22:06:50 +0000 (22:06 +0000)]
Fix test weirdness.

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

13 years agoFix some tests that didn't test anything.
Benjamin Kramer [Sat, 26 Jun 2010 20:05:06 +0000 (20:05 +0000)]
Fix some tests that didn't test anything.

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

13 years agoPartial specialization test should not depend on the order of specialization operatio...
Kenneth Uildriks [Sat, 26 Jun 2010 18:47:40 +0000 (18:47 +0000)]
Partial specialization test should not depend on the order of specialization operations or the names assigned to the specialized functions

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

13 years agoWhen splitting a VAARG, remember its alignment.
Rafael Espindola [Sat, 26 Jun 2010 18:22:20 +0000 (18:22 +0000)]
When splitting a VAARG, remember its alignment.
This produces terrible but correct code.

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

13 years agoRevert my if-conversion cleanup since it caused a bunch of nightly test
Bob Wilson [Sat, 26 Jun 2010 17:47:06 +0000 (17:47 +0000)]
Revert my if-conversion cleanup since it caused a bunch of nightly test
regressions.

--- Reverse-merging r106939 into '.':
U    test/CodeGen/Thumb2/thumb2-ifcvt3.ll
U    lib/CodeGen/IfConversion.cpp

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

13 years agoFix PR7328: when turning a tail recursion into a loop, need to preserve
Duncan Sands [Sat, 26 Jun 2010 12:53:31 +0000 (12:53 +0000)]
Fix PR7328: when turning a tail recursion into a loop, need to preserve
the returned value after the tail call if it differs from other return
values.  The optimal thing to do would be to introduce a phi node for
the return value, but for the moment just fix the miscompile.

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

13 years agouse ArgOperand API
Gabor Greif [Sat, 26 Jun 2010 12:17:21 +0000 (12:17 +0000)]
use ArgOperand API

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

13 years agouse ArgOperand API
Gabor Greif [Sat, 26 Jun 2010 12:09:10 +0000 (12:09 +0000)]
use ArgOperand API

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

13 years agouse ArgOperand API
Gabor Greif [Sat, 26 Jun 2010 11:51:52 +0000 (11:51 +0000)]
use ArgOperand API

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

13 years agoVNInfos don't need to be destructed anymore.
Benjamin Kramer [Sat, 26 Jun 2010 11:30:59 +0000 (11:30 +0000)]
VNInfos don't need to be destructed anymore.

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

13 years agoresort to ArgOperand API
Gabor Greif [Sat, 26 Jun 2010 09:35:09 +0000 (09:35 +0000)]
resort to ArgOperand API

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

13 years agoRemove bogus test.
Eli Friedman [Sat, 26 Jun 2010 04:59:56 +0000 (04:59 +0000)]
Remove bogus test.

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

13 years agoFollowup to r106770: actually generate SXTB and SXTH for sign-extensions.
Eli Friedman [Sat, 26 Jun 2010 04:36:50 +0000 (04:36 +0000)]
Followup to r106770: actually generate SXTB and SXTH for sign-extensions.

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

13 years agoClean up some problems with extra CFG edges being introduced during
Bob Wilson [Sat, 26 Jun 2010 04:27:33 +0000 (04:27 +0000)]
Clean up some problems with extra CFG edges being introduced during
if-conversion.  The RemoveExtraEdges function doesn't work for blocks that
end with unanalyzable branches, so in those cases, the "extra" edges must
be explicitly removed.  The CopyAndPredicateBlock and MergeBlocks methods
can also avoid copying successor edges due to branches that have already
been removed.  The latter case is especially helpful when MergeBlocks is
called for handling "diamond" if-conversions, where otherwise you can end
up with some weird intermediate states in the CFG.  Unfortunately I've
been unable to find cases where this cleanup actually makes a significant
difference in the code.  There is one test where we manage to remove an
empty block at the end of a function.  Radar 6911268.

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

13 years agoAdd support for encoding NEON VMOV (from scalar to core register) instructions.
Bob Wilson [Sat, 26 Jun 2010 04:07:15 +0000 (04:07 +0000)]
Add support for encoding NEON VMOV (from scalar to core register) instructions.

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

13 years agoIt's now possible to run code placement pass for ARM.
Evan Cheng [Sat, 26 Jun 2010 01:52:05 +0000 (01:52 +0000)]
It's now possible to run code placement pass for ARM.

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

13 years agoWhen creating X86 MUL8 and DIV8 instructions, make sure we don't produce
Jakob Stoklund Olesen [Sat, 26 Jun 2010 00:39:23 +0000 (00:39 +0000)]
When creating X86 MUL8 and DIV8 instructions, make sure we don't produce
CopyFromReg nodes for aliasing registers (AX and AL). This confuses the fast
register allocator.

Instead of CopyFromReg(AL), use ExtractSubReg(CopyFromReg(AX), sub_8bit).

This fixes PR7312.

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

13 years agoRenumber NEON instruction formats to be consecutive.
Bob Wilson [Sat, 26 Jun 2010 00:05:09 +0000 (00:05 +0000)]
Renumber NEON instruction formats to be consecutive.

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

13 years agoRename ARM instruction formats NEONGetLnFrm, NEONSetLnFrm and NEONDupFrm to
Bob Wilson [Fri, 25 Jun 2010 23:56:05 +0000 (23:56 +0000)]
Rename ARM instruction formats NEONGetLnFrm, NEONSetLnFrm and NEONDupFrm to
"N..." instead of "NEON..." for consistency with the other NEON format names.

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

13 years agoAdd AVX convert CVTSS2SI{rr,rm} and CVTDQ2PS{rr,rm} instructions
Bruno Cardoso Lopes [Fri, 25 Jun 2010 23:47:23 +0000 (23:47 +0000)]
Add AVX convert CVTSS2SI{rr,rm} and CVTDQ2PS{rr,rm} instructions

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

13 years agoRemove unused NEONFrm and ThumbMiscFrm ARM instruction formats.
Bob Wilson [Fri, 25 Jun 2010 23:45:37 +0000 (23:45 +0000)]
Remove unused NEONFrm and ThumbMiscFrm ARM instruction formats.
Renumber MiscFrm to 25.

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

13 years agoReapply r106896:
Bruno Cardoso Lopes [Fri, 25 Jun 2010 23:33:42 +0000 (23:33 +0000)]
Reapply r106896:
Add several AVX MOV flavors
Support VEX encoding for MRMDestReg

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

13 years agoThumb2ITBlockPass: Fix a possible dereference of an invalid iterator. This was
Daniel Dunbar [Fri, 25 Jun 2010 23:14:54 +0000 (23:14 +0000)]
Thumb2ITBlockPass: Fix a possible dereference of an invalid iterator. This was
introduced in r106343, but only showed up recently (with a particular compiler &
linker combination) because of the particular check, and because we have no
builtin checking for dereferencing the end of an array, which is truly
unfortunate.

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

13 years agomake sure to handle dbg_value instructions in the middle of the block, not
Jim Grosbach [Fri, 25 Jun 2010 23:05:46 +0000 (23:05 +0000)]
make sure to handle dbg_value instructions in the middle of the block, not
just at the head, when doing diamond if-conversion. rdar://7797940

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

13 years agorevert this now, it's using avx instead of sse :)
Bruno Cardoso Lopes [Fri, 25 Jun 2010 23:04:29 +0000 (23:04 +0000)]
revert this now, it's using avx instead of sse :)

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

13 years agoDon't track kills in VNInfo. Use interval ends instead.
Jakob Stoklund Olesen [Fri, 25 Jun 2010 22:53:05 +0000 (22:53 +0000)]
Don't track kills in VNInfo. Use interval ends instead.

The VNInfo.kills vector was almost unused except for all the code keeping it
updated. The few places using it were easily rewritten to check for interval
ends instead.

The two new methods LiveInterval::killedAt and killedInRange are replacements.

This brings us down to 3 independent data structures tracking kills.

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

13 years agoChange if-conversion block size limit checks to add some flexibility.
Evan Cheng [Fri, 25 Jun 2010 22:42:03 +0000 (22:42 +0000)]
Change if-conversion block size limit checks to add some flexibility.

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

13 years agoAdd support for encoding 3-register NEON instructions, and fix
Bob Wilson [Fri, 25 Jun 2010 22:40:46 +0000 (22:40 +0000)]
Add support for encoding 3-register NEON instructions, and fix
emitNEON2RegInstruction's handling of 2-address operands.

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

13 years agoIn GenerateReassociations, don't bother thinking about individual
Dan Gohman [Fri, 25 Jun 2010 22:32:18 +0000 (22:32 +0000)]
In GenerateReassociations, don't bother thinking about individual
SCEVUnknown values which are loop-variant, as LSR can't do anything
interesting with these values in any case. This fixes very slow compile
times on loops which have large numbers of such values.

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

13 years agoAdd several AVX MOV flavors
Bruno Cardoso Lopes [Fri, 25 Jun 2010 22:27:51 +0000 (22:27 +0000)]
Add several AVX MOV flavors
Support VEX encoding for MRMDestReg

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

13 years agoCollect debug info for optimized variables of inlined functions.
Devang Patel [Fri, 25 Jun 2010 22:07:34 +0000 (22:07 +0000)]
Collect debug info for optimized variables of inlined functions.

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

13 years ago80 column and typo fix
Jim Grosbach [Fri, 25 Jun 2010 22:02:28 +0000 (22:02 +0000)]
80 column and typo fix

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

13 years agoThe hasMemory argument is irrelevant to how the argument
Dale Johannesen [Fri, 25 Jun 2010 21:55:36 +0000 (21:55 +0000)]
The hasMemory argument is irrelevant to how the argument
for an "i" constraint should get lowered; PR 6309.  While
this argument was passed around a lot, this is the only
place it was used, so it goes away from a lot of other
places.

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

13 years agoAdd support for encoding 2-register NEON instructions.
Bob Wilson [Fri, 25 Jun 2010 21:17:19 +0000 (21:17 +0000)]
Add support for encoding 2-register NEON instructions.

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

13 years agopcmpeqd and friends are Commutable.
Dan Gohman [Fri, 25 Jun 2010 21:05:35 +0000 (21:05 +0000)]
pcmpeqd and friends are Commutable.

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

13 years ago80-column and trailing whitespace cleanup
Jim Grosbach [Fri, 25 Jun 2010 21:02:24 +0000 (21:02 +0000)]
80-column and trailing whitespace cleanup

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

13 years agoFix indentation.
Bob Wilson [Fri, 25 Jun 2010 20:54:44 +0000 (20:54 +0000)]
Fix indentation.

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

13 years ago- Reapply r106066 now that the bzip2 build regression has been fixed.
Bill Wendling [Fri, 25 Jun 2010 20:48:10 +0000 (20:48 +0000)]
- Reapply r106066 now that the bzip2 build regression has been fixed.
- 2010-06-25-CoalescerSubRegDefDead.ll is the testcase for r106878.

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

13 years agoWe should remove the live range from the destination register only if *all* defs
Bill Wendling [Fri, 25 Jun 2010 20:42:55 +0000 (20:42 +0000)]
We should remove the live range from the destination register only if *all* defs
are dead, not just the def of this register. I.e., a register could be dead, but
it's subreg isn't.

Testcase to follow with a subsequent patch.

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

13 years agoMove the last piece of SSE2 convert instructions to the Convert Instructions section
Bruno Cardoso Lopes [Fri, 25 Jun 2010 20:29:27 +0000 (20:29 +0000)]
Move the last piece of SSE2 convert instructions to the Convert Instructions section

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

13 years agoMore SSE refactoring, this time with different types of MOVs
Bruno Cardoso Lopes [Fri, 25 Jun 2010 20:22:12 +0000 (20:22 +0000)]
More SSE refactoring, this time with different types of MOVs

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

13 years agoEliminate a redundant FoldingSet lookup.
Dan Gohman [Fri, 25 Jun 2010 18:47:08 +0000 (18:47 +0000)]
Eliminate a redundant FoldingSet lookup.

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

13 years agoIT instructions are considered to be scheduling hazards, but are scheduled
Jim Grosbach [Fri, 25 Jun 2010 18:43:14 +0000 (18:43 +0000)]
IT instructions are considered to be scheduling hazards, but are scheduled
with the following instructions. This is done via trickery by considering the
instruction preceding the IT to be the hazard. Care must be taken to ensure
it's the first non-debug instruction, or the presence of debug info will
affect codegen.

Part of the continuing work for rdar://7797940, making ARM code-gen unaffected
by the presence of debug information.

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

13 years agoRefactoring of more SSE conversion instructions. Also add some AVX instrinsics Int_V...
Bruno Cardoso Lopes [Fri, 25 Jun 2010 18:06:22 +0000 (18:06 +0000)]
Refactoring of more SSE conversion instructions. Also add some AVX instrinsics Int_V... placeholders

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

13 years agoCosmetic.
Dale Johannesen [Fri, 25 Jun 2010 17:41:07 +0000 (17:41 +0000)]
Cosmetic.

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

13 years agoXFAIL this test on powerpc for now.
Devang Patel [Fri, 25 Jun 2010 17:32:23 +0000 (17:32 +0000)]
XFAIL this test on powerpc for now.

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

13 years agoFix LLVM CMake PACKAGE_VERSION variable.
Daniel Dunbar [Fri, 25 Jun 2010 16:29:14 +0000 (16:29 +0000)]
Fix LLVM CMake PACKAGE_VERSION variable.

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

13 years agoRewrite MemoryBuffer::getSTDIN to use read(2) and a SmallVector buffer.
Benjamin Kramer [Fri, 25 Jun 2010 16:07:18 +0000 (16:07 +0000)]
Rewrite MemoryBuffer::getSTDIN to use read(2) and a SmallVector buffer.

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

13 years agoRemove variables which are assigned to but for which the value
Duncan Sands [Fri, 25 Jun 2010 14:48:39 +0000 (14:48 +0000)]
Remove variables which are assigned to but for which the value
is not used.  Spotted by gcc-4.6.

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

13 years agoBring back the empty vector workaround I removed in r106839. Looks like MSVC needs it.
Benjamin Kramer [Fri, 25 Jun 2010 12:51:01 +0000 (12:51 +0000)]
Bring back the empty vector workaround I removed in r106839. Looks like MSVC needs it.

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

13 years agoTweak MemoryBuffer to allocate the class itself, the name and possibly the
Benjamin Kramer [Fri, 25 Jun 2010 11:50:40 +0000 (11:50 +0000)]
Tweak MemoryBuffer to allocate the class itself, the name and possibly the
buffer in the same chunk of memory.

2 less mallocs for every uninitialized MemoryBuffer and 1 less malloc for every
MemoryBuffer pointing to a memory range translate into 20% less mallocs on
clang -cc1 -Eonly Cocoa_h.m.

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

13 years agouse ArgOperand accessors
Gabor Greif [Fri, 25 Jun 2010 11:25:30 +0000 (11:25 +0000)]
use ArgOperand accessors
and CallInst for getting hold
of the intrinsic's arguments

simplify along the way (at least for me this is much more legible now)
Bill, Baldrick or Anton, please review\!

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