Bill Wendling [Fri, 27 Jan 2012 02:02:24 +0000 (02:02 +0000)]
Place the GEP instructions nearer to the instructions which use them.
GEP instructions are there for the compiler and shouldn't really output much
code (if any at all). When a GEP is stored in the entry block, Fast ISel (for
one) will not know that it could fold it into further uses. For instance, inside
of the EH handling code. This results in a lot of unnecessary spills and loads
which bloat code and slows down pretty much everything.
<rdar://problem/
10694814>
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@149114
91177308-0d34-0410-b5e6-
96231b3b80d8
Chris Lattner [Fri, 27 Jan 2012 01:47:28 +0000 (01:47 +0000)]
make sure the file's matching header is #include'd first.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@149113
91177308-0d34-0410-b5e6-
96231b3b80d8
Chris Lattner [Fri, 27 Jan 2012 01:46:00 +0000 (01:46 +0000)]
Rewrite CanShareConstantPoolEntry to be implemented in terms of the
mid-level constant folding APIs instead of doing its own analysis.
This makes it more general (e.g. can now share a <2 x i64> with a
<4 x i32>) and avoid duplicating a bunch of logic.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@149111
91177308-0d34-0410-b5e6-
96231b3b80d8
Chris Lattner [Fri, 27 Jan 2012 01:44:03 +0000 (01:44 +0000)]
enhance constant folding to be able to constant fold bitcast of
ConstantVector's to integer type.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@149110
91177308-0d34-0410-b5e6-
96231b3b80d8
Jim Grosbach [Fri, 27 Jan 2012 00:51:27 +0000 (00:51 +0000)]
Keep source location information for X86 MCFixup's.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@149106
91177308-0d34-0410-b5e6-
96231b3b80d8
Jim Grosbach [Fri, 27 Jan 2012 00:51:23 +0000 (00:51 +0000)]
Source information in 'expected relocatable expression' diagnostic.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@149105
91177308-0d34-0410-b5e6-
96231b3b80d8
Jim Grosbach [Fri, 27 Jan 2012 00:37:12 +0000 (00:37 +0000)]
Better user diagnostics for more ARM MachO relocation errors.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@149102
91177308-0d34-0410-b5e6-
96231b3b80d8
Jim Grosbach [Fri, 27 Jan 2012 00:37:08 +0000 (00:37 +0000)]
Better diagnostic for malformed .org assembly directive.
Provide source line number information.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@149101
91177308-0d34-0410-b5e6-
96231b3b80d8
Lang Hames [Fri, 27 Jan 2012 00:05:42 +0000 (00:05 +0000)]
Rewrite instruction operands in AdjustCopiesBackFrom. Fixes PR11861.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@149097
91177308-0d34-0410-b5e6-
96231b3b80d8
Jim Grosbach [Thu, 26 Jan 2012 23:47:45 +0000 (23:47 +0000)]
Tidy up.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@149096
91177308-0d34-0410-b5e6-
96231b3b80d8
Jim Grosbach [Thu, 26 Jan 2012 23:20:15 +0000 (23:20 +0000)]
Keep source information, if available, around for ARM Fixups.
Adjust an example MachObjectWriter diagnostic to use the information
to issue a better message.
Before:
LLVM ERROR: unknown ARM fixup kind!
After:
x.s:6:5: error: unsupported relocation on symbol
beq bar
^
rdar://
9800182
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@149093
91177308-0d34-0410-b5e6-
96231b3b80d8
Jim Grosbach [Thu, 26 Jan 2012 23:20:11 +0000 (23:20 +0000)]
Add simple support for keeping MCFixup source information.
Can be used to issue more user friendly diagnostics for faulty
relocation constructs and such.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@149092
91177308-0d34-0410-b5e6-
96231b3b80d8
Jim Grosbach [Thu, 26 Jan 2012 23:20:07 +0000 (23:20 +0000)]
llvm-mc pass through SourceMgr to MCContext.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@149091
91177308-0d34-0410-b5e6-
96231b3b80d8
Jim Grosbach [Thu, 26 Jan 2012 23:20:05 +0000 (23:20 +0000)]
Add SourceMgr to MCContext for backend diagnostics.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@149090
91177308-0d34-0410-b5e6-
96231b3b80d8
Jakob Stoklund Olesen [Thu, 26 Jan 2012 22:59:28 +0000 (22:59 +0000)]
Handle call-clobbered ymm registers on Win64.
The Win64 calling convention has xmm6-15 as callee-saved while still
clobbering all ymm registers.
Add a YMM_HI_6_15 pseudo-register that aliases the clobbered part of the
ymm registers, and mark that as call-clobbered. This allows live xmm
registers across calls.
This hack wouldn't be necessary with RegisterMask operands representing
the call clobbers, but they are not quite operational yet.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@149088
91177308-0d34-0410-b5e6-
96231b3b80d8
Eric Christopher [Thu, 26 Jan 2012 22:06:23 +0000 (22:06 +0000)]
Use -H on darwin as well.
Patch by Liang Wang!
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@149085
91177308-0d34-0410-b5e6-
96231b3b80d8
Chris Lattner [Thu, 26 Jan 2012 21:37:55 +0000 (21:37 +0000)]
progress making the world safe to ConstantDataVector. While
we're at it, allow PatternMatch's "neg" pattern to match integer
vector negations, and enhance ComputeNumSigned bits to handle
shl of vectors.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@149082
91177308-0d34-0410-b5e6-
96231b3b80d8
Chris Lattner [Thu, 26 Jan 2012 20:44:57 +0000 (20:44 +0000)]
tidy up forward declarations.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@149078
91177308-0d34-0410-b5e6-
96231b3b80d8
Chris Lattner [Thu, 26 Jan 2012 20:40:56 +0000 (20:40 +0000)]
smallvectorize and ArrayRef'ize some stuff.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@149077
91177308-0d34-0410-b5e6-
96231b3b80d8
Chris Lattner [Thu, 26 Jan 2012 20:37:11 +0000 (20:37 +0000)]
Reduce a lot of code duplication by implementing
ConstantExpr::getWithOperandReplaced and ConstantExpr::replaceUsesOfWithOnConstant
in terms of ConstantExpr::getWithOperands. While we're at it,
make sure that ConstantExpr::getWithOperands covers all instructions: it was
missing insert/extractvalue.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@149076
91177308-0d34-0410-b5e6-
96231b3b80d8
Chad Rosier [Thu, 26 Jan 2012 20:19:05 +0000 (20:19 +0000)]
Update comment for r149070.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@149075
91177308-0d34-0410-b5e6-
96231b3b80d8
Chad Rosier [Thu, 26 Jan 2012 18:24:25 +0000 (18:24 +0000)]
Replace the use of isPredicable() with isPredicated() in
MachineBasicBlock::canFallThrough(). We're interested in the state of the
instruction (i.e., is this a barrier or not?), not if the instruction is
predicable or not.
rdar://
10501092
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@149070
91177308-0d34-0410-b5e6-
96231b3b80d8
Jakob Stoklund Olesen [Thu, 26 Jan 2012 17:52:15 +0000 (17:52 +0000)]
Clear kill flags before propagating a copy.
The live range of the source register may be extended when a redundant
copy is eliminated. Make sure any kill flags between the two copies are
cleared.
This fixes PR11765.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@149069
91177308-0d34-0410-b5e6-
96231b3b80d8
Jim Grosbach [Thu, 26 Jan 2012 15:56:45 +0000 (15:56 +0000)]
Tidy up. Fix mismatched return types for error handling.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@149062
91177308-0d34-0410-b5e6-
96231b3b80d8
Gabor Greif [Thu, 26 Jan 2012 10:28:58 +0000 (10:28 +0000)]
comment tweaks
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@149060
91177308-0d34-0410-b5e6-
96231b3b80d8
James Molloy [Thu, 26 Jan 2012 09:25:43 +0000 (09:25 +0000)]
Add support for the R_ARM_TARGET1 relocation, which should be given to relocations applied to all C++ constructors and destructors.
This enables the linker to match concrete relocation types (absolute or relative) with whatever library or C++ support code is being linked against.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@149057
91177308-0d34-0410-b5e6-
96231b3b80d8
Victor Umansky [Thu, 26 Jan 2012 08:51:39 +0000 (08:51 +0000)]
Fix for the following bug in AVX codegen for double-to-int conversions:
. "fptosi" and "fptoui" IR instructions are defined with round-to-zero rounding mode.
. Currently for AVX mode for <4xdouble> and <8xdouble> the "VCVTPD2DQ.128" and "VCVTPD2DQ.256" instructions are selected (for .fp_to_sint. DAG node operation ) by AVX codegen. However they use round-to-nearest-even rounding mode.
. Consequently, the conversion produces incorrect numbers.
The fix is to replace selection of VCVTPD2DQ instructions with VCVTTPD2DQ instructions. The latter use truncate (i.e. round-to-zero) rounding mode.
As .fp_to_sint. DAG node operation is used only for lowering of "fptosi" and "fptoui" IR instructions, the fix in X86InstrSSE.td definition file doesn.t have an impact on other LLVM flows.
The patch includes changes in the .td file, LIT test for the changes and a fix in a legacy LIT test (which produced asm code conflicting with LLVN IR spec).
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@149056
91177308-0d34-0410-b5e6-
96231b3b80d8
Craig Topper [Thu, 26 Jan 2012 07:51:55 +0000 (07:51 +0000)]
Add HasXOP predicate check covering a bunch of XOP intrinsic patterns.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@149054
91177308-0d34-0410-b5e6-
96231b3b80d8
Craig Topper [Thu, 26 Jan 2012 07:31:30 +0000 (07:31 +0000)]
Fix AVX vs SSE patterns ordering issue for VPCMPESTRM and VPCMPISTRM.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@149053
91177308-0d34-0410-b5e6-
96231b3b80d8
Craig Topper [Thu, 26 Jan 2012 07:18:03 +0000 (07:18 +0000)]
Remove some more patterns by custom lowering intrinsics to target specific nodes.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@149052
91177308-0d34-0410-b5e6-
96231b3b80d8
Chris Lattner [Thu, 26 Jan 2012 03:10:45 +0000 (03:10 +0000)]
unbreak test/Bitcode/shuffle.ll.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@149033
91177308-0d34-0410-b5e6-
96231b3b80d8
Chris Lattner [Thu, 26 Jan 2012 02:54:54 +0000 (02:54 +0000)]
simplify by using ShuffleVectorInst::getMaskValue.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@149029
91177308-0d34-0410-b5e6-
96231b3b80d8
Chris Lattner [Thu, 26 Jan 2012 02:51:13 +0000 (02:51 +0000)]
eliminate the Constant::getVectorElements method. There are better (and
more robust) ways to do what it was doing now. Also, add static methods
for decoding a ShuffleVector mask.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@149028
91177308-0d34-0410-b5e6-
96231b3b80d8
Chris Lattner [Thu, 26 Jan 2012 02:32:04 +0000 (02:32 +0000)]
Continue improving support for ConstantDataAggregate, and use the
new methods recently added to (sometimes greatly!) simplify code.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@149024
91177308-0d34-0410-b5e6-
96231b3b80d8
Chris Lattner [Thu, 26 Jan 2012 02:31:22 +0000 (02:31 +0000)]
Add a ConstantDataVector::getSplatValue() method, for parity with
ConstantVector. Fix some outright bugs in the implementation of
ConstantArray and Constant struct, which would cause us to not make
one big UndefValue when asking for an array/struct with all undef
elements. Enhance Constant::isAllOnesValue to work with
ConstantDataVector.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@149021
91177308-0d34-0410-b5e6-
96231b3b80d8
Peter Collingbourne [Thu, 26 Jan 2012 01:31:38 +0000 (01:31 +0000)]
llvm-config: Add support for CMake build trees in which the build
mode does not form part of the path.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@149010
91177308-0d34-0410-b5e6-
96231b3b80d8
Chris Lattner [Thu, 26 Jan 2012 00:42:34 +0000 (00:42 +0000)]
some general cleanup, using new methods and tidying up old code.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@149006
91177308-0d34-0410-b5e6-
96231b3b80d8
Chris Lattner [Thu, 26 Jan 2012 00:41:50 +0000 (00:41 +0000)]
fix pasto in the new (and still unused) ShuffleVectorInst::getShuffleMask method.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@149005
91177308-0d34-0410-b5e6-
96231b3b80d8
Chris Lattner [Thu, 26 Jan 2012 00:06:44 +0000 (00:06 +0000)]
add StructType helpers too.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@149000
91177308-0d34-0410-b5e6-
96231b3b80d8
Chris Lattner [Thu, 26 Jan 2012 00:01:10 +0000 (00:01 +0000)]
Ok, break down and add some cast<>'ing helper methods to the Type class
to reduce the number of cast<>'s we have. This allows someone to use
things like Ty->getVectorNumElements() instead of
cast<VectorType>(Ty)->getNumElements() when you know that a type is a
vector.
It would be a great general cleanup to move the codebase to use these,
I will do so in the code I'm touching.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@148999
91177308-0d34-0410-b5e6-
96231b3b80d8
Chris Lattner [Wed, 25 Jan 2012 23:49:49 +0000 (23:49 +0000)]
add some helper methods to ShuffleVectorInst and enhance its
"isValidOperands" and "getMaskValue" methods to allow
ConstantDataSequential.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@148998
91177308-0d34-0410-b5e6-
96231b3b80d8
Jakob Stoklund Olesen [Wed, 25 Jan 2012 23:36:27 +0000 (23:36 +0000)]
Improve sub-register def handling in ProcessImplicitDefs.
This boils down to using MachineOperand::readsReg() more.
This fixes PR11829 where a use ended up after the first def when
lowering REG_SEQUENCE instructions involving IMPLICIT_DEFs.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@148996
91177308-0d34-0410-b5e6-
96231b3b80d8
Anton Korobeynikov [Wed, 25 Jan 2012 22:24:19 +0000 (22:24 +0000)]
Properly emit ctors / dtors with priorities into desired sections
and let linker handle the rest.
This finally fixes PR5329
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@148990
91177308-0d34-0410-b5e6-
96231b3b80d8
Lang Hames [Wed, 25 Jan 2012 22:11:06 +0000 (22:11 +0000)]
Don't add live ranges for aliases of physregs that are live in to the
function. They don't appear to be used, and are inconsistent with handling of
other physreg intervals (i.e. intervals that are not live-in) where ranges are
not inserted for aliases.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@148986
91177308-0d34-0410-b5e6-
96231b3b80d8
Jim Grosbach [Wed, 25 Jan 2012 22:00:23 +0000 (22:00 +0000)]
Tidy up. s/Low Level Virtual Machine/LLVM/.
LLVM isn't an acronym anymore.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@148985
91177308-0d34-0410-b5e6-
96231b3b80d8
Lang Hames [Wed, 25 Jan 2012 21:53:23 +0000 (21:53 +0000)]
Always break upon finding a vreg operand (in Release as well as +Asserts). Remove assertion which can no longer trigger.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@148984
91177308-0d34-0410-b5e6-
96231b3b80d8
Jim Grosbach [Wed, 25 Jan 2012 19:52:01 +0000 (19:52 +0000)]
ARM assemly parsing and validation of IT instruction.
"Although a Thumb2 instruction, the IT mnemonic shall be permitted in
ARM mode, and the condition verified to match the condition code(s)
on the following instruction(s)."
PR11853
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@148969
91177308-0d34-0410-b5e6-
96231b3b80d8
Nick Lewycky [Wed, 25 Jan 2012 18:54:13 +0000 (18:54 +0000)]
Use precomputed BB size instead of BB->size().
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@148964
91177308-0d34-0410-b5e6-
96231b3b80d8
Chris Lattner [Wed, 25 Jan 2012 09:56:22 +0000 (09:56 +0000)]
fix a bug I introduced in r148929, this is not a splat!
Thanks to Eli for noticing.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@148947
91177308-0d34-0410-b5e6-
96231b3b80d8
Nick Lewycky [Wed, 25 Jan 2012 09:43:14 +0000 (09:43 +0000)]
Gracefully degrade precision in branch probability numbers.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@148946
91177308-0d34-0410-b5e6-
96231b3b80d8
Nick Lewycky [Wed, 25 Jan 2012 08:27:40 +0000 (08:27 +0000)]
Support pointer comparisons against constants, when looking at the inline-cost
savings from a pointer argument becoming an alloca. Sometimes callees will even
compare a pointer to null and then branch to an otherwise unreachable block!
Detect these cases and compute the number of saved instructions, instead of
bailing out and reporting no savings.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@148941
91177308-0d34-0410-b5e6-
96231b3b80d8
Chandler Carruth [Wed, 25 Jan 2012 07:40:15 +0000 (07:40 +0000)]
Revert a tiny bit of r148553 which extended LLVM's function attributes
to 64-bits, and added a new attribute in bit #32. Specifically, remove
this new attribute from the enum used in the C API. It's not yet clear
what the best approach is for exposing these new attributes in the
C API, and several different proposals are on the table. Until then, we
can simply not expose this bit in the API at all.
Also, I've reverted a somewhat unrelated change in the same revision
which switched from "1 << 31" to "1U << 31" for the top enum. While "1
<< 31" is technically undefined behavior, implementations DTRT here.
However, MS and -pedantic mode warn about non-'int' type enumerator
values. If folks feel strongly about this I can put the 'U' back in, but
it seemed best to wait for the proper solution.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@148937
91177308-0d34-0410-b5e6-
96231b3b80d8
Evan Cheng [Wed, 25 Jan 2012 07:38:48 +0000 (07:38 +0000)]
Update hasProperty comment.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@148936
91177308-0d34-0410-b5e6-
96231b3b80d8
Chris Lattner [Wed, 25 Jan 2012 06:48:06 +0000 (06:48 +0000)]
use Constant::getAggregateElement to simplify a bunch of code.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@148934
91177308-0d34-0410-b5e6-
96231b3b80d8
Craig Topper [Wed, 25 Jan 2012 06:43:11 +0000 (06:43 +0000)]
Custom lower PSIGN and PSHUFB intrinsics to their corresponding target specific nodes so we can remove the isel patterns.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@148933
91177308-0d34-0410-b5e6-
96231b3b80d8
Chris Lattner [Wed, 25 Jan 2012 06:16:32 +0000 (06:16 +0000)]
constify some methods and add a new Constant::getAggregateElement
helper method for the common operation of extracting an element
out of a constant aggregate.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@148931
91177308-0d34-0410-b5e6-
96231b3b80d8
Chris Lattner [Wed, 25 Jan 2012 06:02:56 +0000 (06:02 +0000)]
use ConstantVector::getSplat in a few places.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@148929
91177308-0d34-0410-b5e6-
96231b3b80d8
Craig Topper [Wed, 25 Jan 2012 05:37:32 +0000 (05:37 +0000)]
Custom lower phadd and phsub intrinsics to target specific nodes. Remove the patterns that are no longer necessary.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@148927
91177308-0d34-0410-b5e6-
96231b3b80d8
Chris Lattner [Wed, 25 Jan 2012 05:19:54 +0000 (05:19 +0000)]
reapply r148901 with a crucial fix.
"Introduce a new ConstantVector::getSplat constructor function to
simplify a really common case."
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@148924
91177308-0d34-0410-b5e6-
96231b3b80d8
Craig Topper [Wed, 25 Jan 2012 04:42:03 +0000 (04:42 +0000)]
Remove AVX 256-bit unaligned load intrinsics. 128-bit versions had been removed a while ago.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@148922
91177308-0d34-0410-b5e6-
96231b3b80d8
Akira Hatanaka [Wed, 25 Jan 2012 04:19:22 +0000 (04:19 +0000)]
Mark 64-bit register RA_64 unused too.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@148918
91177308-0d34-0410-b5e6-
96231b3b80d8
Akira Hatanaka [Wed, 25 Jan 2012 04:12:04 +0000 (04:12 +0000)]
Modify MipsFrameLowering::emitPrologue and emitEpilogue.
- Use MipsAnalyzeImmediate to expand immediates that do not fit in 16-bit.
- Change the types of variables so that they are sufficiently large to handle
64-bit pointers.
- Emit instructions to set register $28 in a function prologue after
instructions which store callee-saved registers have been emitted.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@148917
91177308-0d34-0410-b5e6-
96231b3b80d8
Akira Hatanaka [Wed, 25 Jan 2012 03:55:10 +0000 (03:55 +0000)]
Modify MipsRegisterInfo::eliminateFrameIndex to use MipsAnalyzeImmediate to
expand offsets that do not fit in the 16-bit immediate field of load and store
instructions. Also change the types of variables so that they are sufficiently
large to handle 64-bit pointers.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@148916
91177308-0d34-0410-b5e6-
96231b3b80d8
Craig Topper [Wed, 25 Jan 2012 03:52:09 +0000 (03:52 +0000)]
Merge intrinsic pattern and no pattern versions of VCVTSD2SI intruction definitions. Matches non-AVX version of same instructions.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@148914
91177308-0d34-0410-b5e6-
96231b3b80d8
Rafael Espindola [Wed, 25 Jan 2012 03:39:26 +0000 (03:39 +0000)]
-fvisibility-inlines-hidden is a c++ only option.
Thanks to Peter Collingbourne for noticing it.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@148913
91177308-0d34-0410-b5e6-
96231b3b80d8
NAKAMURA Takumi [Wed, 25 Jan 2012 03:34:41 +0000 (03:34 +0000)]
MipsAnalyzeImmediate.h: Fix to add DataTypes.h for msvc.
inttypes.h is not supplied in msvc.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@148912
91177308-0d34-0410-b5e6-
96231b3b80d8
Nick Lewycky [Wed, 25 Jan 2012 03:20:12 +0000 (03:20 +0000)]
Fix assert("msg"). Fix unused-variable warnings complaining about VT used only
in asserts.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@148910
91177308-0d34-0410-b5e6-
96231b3b80d8
NAKAMURA Takumi [Wed, 25 Jan 2012 03:15:46 +0000 (03:15 +0000)]
Target/Mips: Unbreak CMake build.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@148909
91177308-0d34-0410-b5e6-
96231b3b80d8
Akira Hatanaka [Wed, 25 Jan 2012 03:01:35 +0000 (03:01 +0000)]
Lower 64-bit immediates using MipsAnalyzeImmediate that has just been added.
Add a test case to show fewer instructions are needed to load an immediate
with the new way of loading immediates.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@148908
91177308-0d34-0410-b5e6-
96231b3b80d8
Argyrios Kyrtzidis [Wed, 25 Jan 2012 02:42:41 +0000 (02:42 +0000)]
Revert r148901 because it crashes llvm tests.
Original log:
Introduce a new ConstantVector::getSplat constructor function to
simplify a really common case.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@148906
91177308-0d34-0410-b5e6-
96231b3b80d8
Chris Lattner [Wed, 25 Jan 2012 01:53:58 +0000 (01:53 +0000)]
Introduce a new ConstantVector::getSplat constructor function to
simplify a really common case.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@148901
91177308-0d34-0410-b5e6-
96231b3b80d8
Akira Hatanaka [Wed, 25 Jan 2012 01:43:36 +0000 (01:43 +0000)]
Add class MipsAnalyzeImmediate which comes up with an instruction sequence to
load an immediate.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@148900
91177308-0d34-0410-b5e6-
96231b3b80d8
Chris Lattner [Wed, 25 Jan 2012 01:32:59 +0000 (01:32 +0000)]
Remove the Type::getNumElements() method, which is only called in 4 places,
did something extremely surprising, and shadowed actually useful
implementations that had completely different behavior.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@148898
91177308-0d34-0410-b5e6-
96231b3b80d8
Chris Lattner [Wed, 25 Jan 2012 01:27:20 +0000 (01:27 +0000)]
Use the right method to get the # elements in a CDS.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@148897
91177308-0d34-0410-b5e6-
96231b3b80d8
Jim Grosbach [Wed, 25 Jan 2012 00:01:08 +0000 (00:01 +0000)]
NEON VLD4(all lanes) assembly parsing and encoding.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@148884
91177308-0d34-0410-b5e6-
96231b3b80d8
Jim Grosbach [Tue, 24 Jan 2012 23:47:07 +0000 (23:47 +0000)]
Tidy up. Rename VLD4DUP patterns for consistency.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@148883
91177308-0d34-0410-b5e6-
96231b3b80d8
Jim Grosbach [Tue, 24 Jan 2012 23:47:04 +0000 (23:47 +0000)]
NEON VLD3(all lanes) assembly parsing and encoding.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@148882
91177308-0d34-0410-b5e6-
96231b3b80d8
Talin [Tue, 24 Jan 2012 23:43:59 +0000 (23:43 +0000)]
Additional methods for SmallString.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@148881
91177308-0d34-0410-b5e6-
96231b3b80d8
Jakob Stoklund Olesen [Tue, 24 Jan 2012 23:28:42 +0000 (23:28 +0000)]
Set correct <def,undef> flags when lowering REG_SEQUENCE.
A REG_SEQUENCE instruction is lowered into a sequence of partial defs:
%vreg7:ssub_0<def,undef> = COPY %vreg20:ssub_0
%vreg7:ssub_1<def> = COPY %vreg2
%vreg7:ssub_2<def> = COPY %vreg2
%vreg7:ssub_3<def> = COPY %vreg2
The first def needs an <undef> flag to indicate it is the beginning of
the live range, while the other defs are read-modify-write. Previously,
we depended on LiveIntervalAnalysis to notice and fix the missing
<def,undef>, but that solution was never robust, it was causing problems
with ProcessImplicitDefs and the lowering of chained REG_SEQUENCE
instructions.
This fixes PR11841.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@148879
91177308-0d34-0410-b5e6-
96231b3b80d8
Jakob Stoklund Olesen [Tue, 24 Jan 2012 23:28:38 +0000 (23:28 +0000)]
Use the standard MachineFunction::print() after SlotIndexes.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@148878
91177308-0d34-0410-b5e6-
96231b3b80d8
Akira Hatanaka [Tue, 24 Jan 2012 23:18:43 +0000 (23:18 +0000)]
Sign-extend 32-bit integer arguments when they are passed in 64-bit registers,
which is what N32/64 does.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@148875
91177308-0d34-0410-b5e6-
96231b3b80d8
Akira Hatanaka [Tue, 24 Jan 2012 22:07:36 +0000 (22:07 +0000)]
Pass CCState by reference.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@148871
91177308-0d34-0410-b5e6-
96231b3b80d8
Akira Hatanaka [Tue, 24 Jan 2012 22:05:25 +0000 (22:05 +0000)]
Pattern for f32 to i64 conversion.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@148869
91177308-0d34-0410-b5e6-
96231b3b80d8
Jim Grosbach [Tue, 24 Jan 2012 21:45:25 +0000 (21:45 +0000)]
ARM Darwin symbol ref differences w/o subsection-via-symbols.
When not using subsections via symbols, the assembler can resolve
symbol differences (including pcrel references) to non-local
labels at assembly time, not just those in the same atom.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@148865
91177308-0d34-0410-b5e6-
96231b3b80d8
Devang Patel [Tue, 24 Jan 2012 21:43:36 +0000 (21:43 +0000)]
Intel Syntax: Extend special hand coded logic, to recognize special instructions, for intel syntax.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@148864
91177308-0d34-0410-b5e6-
96231b3b80d8
Akira Hatanaka [Tue, 24 Jan 2012 21:41:09 +0000 (21:41 +0000)]
64-bit sign extension in register instructions.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@148862
91177308-0d34-0410-b5e6-
96231b3b80d8
Jim Grosbach [Tue, 24 Jan 2012 21:06:59 +0000 (21:06 +0000)]
Tidy up. Trailing whitespace.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@148856
91177308-0d34-0410-b5e6-
96231b3b80d8
Matt Beaumont-Gay [Tue, 24 Jan 2012 19:43:30 +0000 (19:43 +0000)]
Sink assert-only variables into the asserts
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@148849
91177308-0d34-0410-b5e6-
96231b3b80d8
Kostya Serebryany [Tue, 24 Jan 2012 19:34:43 +0000 (19:34 +0000)]
[asan] enable asan only for the functions that have Attribute::AddressSafety
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@148846
91177308-0d34-0410-b5e6-
96231b3b80d8
Jim Grosbach [Tue, 24 Jan 2012 18:53:13 +0000 (18:53 +0000)]
NEON VST4(one lane) assembly parsing and encoding.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@148836
91177308-0d34-0410-b5e6-
96231b3b80d8
Owen Anderson [Tue, 24 Jan 2012 18:37:29 +0000 (18:37 +0000)]
Widen the instruction encoder that TblGen emits to a 64 bits, which should accomodate every target I can think of offhand.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@148833
91177308-0d34-0410-b5e6-
96231b3b80d8
Jim Grosbach [Tue, 24 Jan 2012 18:37:25 +0000 (18:37 +0000)]
NEON VLD4(one lane) assembly parsing and encoding.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@148832
91177308-0d34-0410-b5e6-
96231b3b80d8
Jakob Stoklund Olesen [Tue, 24 Jan 2012 18:09:18 +0000 (18:09 +0000)]
Fix old doxygen comment.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@148825
91177308-0d34-0410-b5e6-
96231b3b80d8
Jakob Stoklund Olesen [Tue, 24 Jan 2012 18:06:05 +0000 (18:06 +0000)]
Add an (interleave A, B, ...) SetTheory operator.
This will interleave the elements from two or more lists.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@148824
91177308-0d34-0410-b5e6-
96231b3b80d8
Chandler Carruth [Tue, 24 Jan 2012 18:00:44 +0000 (18:00 +0000)]
Undo an over zealous rename. This bit of the CMake build really is
dealing in the host triple, be honest about it and document the decision
to default the target triple to the host triple unless overridden.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@148822
91177308-0d34-0410-b5e6-
96231b3b80d8
Jim Grosbach [Tue, 24 Jan 2012 17:55:36 +0000 (17:55 +0000)]
NEON Two-operand assembly aliases for VSRA.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@148821
91177308-0d34-0410-b5e6-
96231b3b80d8
Jim Grosbach [Tue, 24 Jan 2012 17:55:32 +0000 (17:55 +0000)]
Remove redundant test file.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@148820
91177308-0d34-0410-b5e6-
96231b3b80d8
Jim Grosbach [Tue, 24 Jan 2012 17:49:15 +0000 (17:49 +0000)]
NEON Two-operand assembly aliases for VSLI.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@148819
91177308-0d34-0410-b5e6-
96231b3b80d8
Jim Grosbach [Tue, 24 Jan 2012 17:46:58 +0000 (17:46 +0000)]
NEON Two-operand assembly aliases for VSRI.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@148818
91177308-0d34-0410-b5e6-
96231b3b80d8
Jim Grosbach [Tue, 24 Jan 2012 17:46:54 +0000 (17:46 +0000)]
Tidy up.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@148817
91177308-0d34-0410-b5e6-
96231b3b80d8