Commit Graph

47068 Commits

Author SHA1 Message Date
Bill Wendling
3ae67f5910 Simplified logic of this if-then statement to reduce nesting. No functionality
change.


git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@73143 91177308-0d34-0410-b5e6-96231b3b80d8
2009-06-09 20:08:51 +00:00
Owen Anderson
6cbd8da86e Add the beginnings of an implementatation of lazy liveness analysis, based on "Fast Liveness Checking for SSA-form Programs" by Boissinot, et al.
This is still very early, hasn't been tested, and is not yet well documented.  More to come soon.


git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@73141 91177308-0d34-0410-b5e6-96231b3b80d8
2009-06-09 19:30:45 +00:00
Bill Wendling
68a9cb1226 Remove empty file.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@73140 91177308-0d34-0410-b5e6-96231b3b80d8
2009-06-09 18:55:39 +00:00
Bill Wendling
ee1f6b0fc5 I'm going to assume that this was meant to be an assignment instead of a
computation that isn't used. Please correct this if it's wrong!


git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@73139 91177308-0d34-0410-b5e6-96231b3b80d8
2009-06-09 18:49:42 +00:00
David Greene
ffc0ab6037 Revert 73074 and 73099 because Windows doesn't have POSIX
regular expressions.  We will add an OpenBSD implementation
and re-apply ASAP.


git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@73138 91177308-0d34-0410-b5e6-96231b3b80d8
2009-06-09 18:31:17 +00:00
Dan Gohman
92fcdcac54 Use expandCodeFor instead of expand when the result will be
immediately casted. At present, this is just a minor code
simplification. In the future, the expansion code may be able
to make better choices if it knows what the desired result
type will be.


git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@73137 91177308-0d34-0410-b5e6-96231b3b80d8
2009-06-09 17:18:38 +00:00
Sanjiv Gupta
b157f25926 PIC16 emits auto variables as globals. When optimizer removes a function entierly by estimating its side effects on globals, those globals(autos) without a function were not being printed by the Asm printer.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@73135 91177308-0d34-0410-b5e6-96231b3b80d8
2009-06-09 15:31:19 +00:00
David Greene
f5aefbdb79 Change IndexedModeAction representation.
This changes the IndexedModeAction representation to remove the
limitation on the number of value types in MVT.  This limitation
prevents us from specifying AVX types.

Prior to this change IndexedModActions was represented as follows...

uint64_t IndexedModeActions[2][ISD::LAST_INDEXED_MODE];

the first dimension was used to represent loads, then stores.  This
imposed a limitation of 32 on the number of value types that could be
handled with this method.  The value type was used to shift the two bits
into and out of the approprate bits in the uint64_t.

With this change the array is now represented as ...

uint8_t IndexedModeActions[MVT::LAST_VALUETYPE][2][ISD::LAST_INDEXED_MODE];

Takes more space but removes the limitation on MVT::LAST_VALUETYPE.  The
first dimension is now the value_type for the reference.  The second
dimension is the load [0] vs. store[1].  The third dimension represents
the various modes for load store.  Accesses are now direct, no shifting
or masking.

There are other limitations that need to be removed, so that
MVT::LAST_VALUETYPE can be greater than 32.  This is merely the first
step towards that goal.


git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@73104 91177308-0d34-0410-b5e6-96231b3b80d8
2009-06-09 00:19:10 +00:00
David Greene
63ec51d86b Oops, didn't mean to commit 73102 yet. Revert it.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@73103 91177308-0d34-0410-b5e6-96231b3b80d8
2009-06-08 23:54:42 +00:00
David Greene
9df4eb8cfe Change IndexedModeAction representation.
This changes the IndexedModeAction representation to remove the
limitation on the number of value types in MVT.  This limitation
prevents us from specifying AVX types.

Prior to this change IndexedModActions was represented as follows...

uint64_t IndexedModeActions[2][ISD::LAST_INDEXED_MODE];

the first dimension was used to represent loads, then stores.  This
imposed a limitation of 32 on the number of value types that could be
handled with this method.  The value type was used to shift the two bits
into and out of the approprate bits in the uint64_t.

With this change the array is now represented as ...

uint8_t IndexedModeActions[MVT::LAST_VALUETYPE][2][ISD::LAST_INDEXED_MODE];

Takes more space but removes the limitation on MVT::LAST_VALUETYPE.  The
first dimension is now the value_type for the reference.  The second
dimension is the load [0] vs. store[1].  The third dimension represents
the various modes for load store.  Accesses are now direct, no shifting
or masking.

There are other limitations that need to be removed, so that
MVT::LAST_VALUETYPE can be greater than 32.  This is merely the first
step towards that goal.


git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@73102 91177308-0d34-0410-b5e6-96231b3b80d8
2009-06-08 23:53:19 +00:00
David Greene
0d973999f3 Add a !patsubst operator. Use on string types.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@73099 91177308-0d34-0410-b5e6-96231b3b80d8
2009-06-08 23:05:37 +00:00
Anton Korobeynikov
2e7ccfce98 Typo
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@73098 91177308-0d34-0410-b5e6-96231b3b80d8
2009-06-08 22:59:50 +00:00
Anton Korobeynikov
dada95b5b3 Revert hunk commited by accident
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@73097 91177308-0d34-0410-b5e6-96231b3b80d8
2009-06-08 22:57:18 +00:00
Anton Korobeynikov
f194b0edc9 Add testcase for register scanveger assertion fix in r72755
(double def due to livevars)

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@73096 91177308-0d34-0410-b5e6-96231b3b80d8
2009-06-08 22:54:15 +00:00
Anton Korobeynikov
0eebf653a7 The attached patches implement most of the ARM AAPCS-VFP hard float
ABI. The missing piece is support for putting "homogeneous aggregates"
into registers.

Patch by Sandeep Patel!

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@73095 91177308-0d34-0410-b5e6-96231b3b80d8
2009-06-08 22:53:56 +00:00
David Greene
ccbfb8d3d8 Update documentation.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@73092 91177308-0d34-0410-b5e6-96231b3b80d8
2009-06-08 22:38:07 +00:00
David Greene
5f323419f3 Add a more robust !if test.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@73091 91177308-0d34-0410-b5e6-96231b3b80d8
2009-06-08 22:34:57 +00:00
David Greene
d725189254 Fix DejaGNU run line to escape special characters.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@73090 91177308-0d34-0410-b5e6-96231b3b80d8
2009-06-08 22:20:58 +00:00
Daniel Dunbar
87bde0b7d3 Document the stack alignment part of target data description.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@73089 91177308-0d34-0410-b5e6-96231b3b80d8
2009-06-08 22:17:53 +00:00
Anton Korobeynikov
fbbf1eeccf Separate V6 from V6T2 since the latter has some extra nice instructions
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@73085 91177308-0d34-0410-b5e6-96231b3b80d8
2009-06-08 21:20:36 +00:00
Stefanus Du Toit
4ba3a0ec6c Allow setting the C runtime to be used with MSVC from cmake.
Patch by Tareq Siraj.


git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@73084 91177308-0d34-0410-b5e6-96231b3b80d8
2009-06-08 21:18:31 +00:00
Anton Korobeynikov
a7b0ded2a2 Add helper for checking of Thumb1 mode
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@73080 91177308-0d34-0410-b5e6-96231b3b80d8
2009-06-08 20:31:02 +00:00
David Greene
e1b469170b Make IntInits and ListInits typed. This helps deduce types of !if and
other operators.  For the rare cases where a list type cannot be
deduced, provide a []<type> syntax, where <type> is the list element
type.


git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@73078 91177308-0d34-0410-b5e6-96231b3b80d8
2009-06-08 20:23:18 +00:00
David Greene
77c489dcae Make !if short-circuit when possible.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@73076 91177308-0d34-0410-b5e6-96231b3b80d8
2009-06-08 19:16:56 +00:00
Bill Wendling
faf2671776 Revert r72898. It does not solve the problem I want it to solve.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@73075 91177308-0d34-0410-b5e6-96231b3b80d8
2009-06-08 18:18:28 +00:00
David Greene
938c8ab0a0 Add a !regmatch operator to do pattern matching in TableGen.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@73074 91177308-0d34-0410-b5e6-96231b3b80d8
2009-06-08 17:00:34 +00:00
Bruno Cardoso Lopes
06bfa33eef Delete comment and fix typo
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@73040 91177308-0d34-0410-b5e6-96231b3b80d8
2009-06-07 21:49:11 +00:00
Bruno Cardoso Lopes
24f14f16fd Fix wrong elf class and byte order initializations.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@73039 91177308-0d34-0410-b5e6-96231b3b80d8
2009-06-07 21:33:20 +00:00
Bruno Cardoso Lopes
a029a27fae Simple ELF32/64 binary files can now be emitted for x86 and x86_64 without
relocation sections.


git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@73038 91177308-0d34-0410-b5e6-96231b3b80d8
2009-06-07 21:22:38 +00:00
Eli Friedman
faeedf1254 Fix the run-line for this test to work correctly outside of x86.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@73025 91177308-0d34-0410-b5e6-96231b3b80d8
2009-06-07 09:44:19 +00:00
Eli Friedman
f10d3a7bcd Tweak the expansion code for BIT_CONVERT to generate better code
converting from an MMX vector to an i64.



git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@73024 91177308-0d34-0410-b5e6-96231b3b80d8
2009-06-07 09:41:57 +00:00
Eli Friedman
5d28eb9e97 Get rid of some unnecessary code.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@73017 91177308-0d34-0410-b5e6-96231b3b80d8
2009-06-07 07:28:45 +00:00
Nick Lewycky
a5f54a06b0 Create FunctionType::isValidArgumentType to go along with isValidReturnType.
Also create isValidElementType for ArrayType, PointerType, StructType and
VectorType.

Make LLParser use them. This closes up some holes like an assertion failure on:

  %x = type {label}

but largely doesn't change any semantics. The only thing we accept now which
we didn't before is vectors of opaque type such as "<4 x opaque>". The opaque
can be resolved to an int or float when linking.


git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@73016 91177308-0d34-0410-b5e6-96231b3b80d8
2009-06-07 07:26:46 +00:00
Mikhail Glushenkov
9dcc26b6a0 A basic PIC16 toolchain driver.
Nice addition to the examples and also a starting point for Sanjiv to work on.

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@73013 91177308-0d34-0410-b5e6-96231b3b80d8
2009-06-07 07:08:01 +00:00
Eli Friedman
7a5e55509b Slightly generalize the code that handles shuffles of consecutive loads
on x86 to handle more cases.  Fix a bug in said code that would cause it 
to read past the end of an object.  Rewrite the code in 
SelectionDAGLegalize::ExpandBUILD_VECTOR to be a bit more general. 
Remove PerformBuildVectorCombine, which is no longer necessary with 
these changes.  In addition to simplifying the code, with this change, 
we can now catch a few more cases of consecutive loads.



git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@73012 91177308-0d34-0410-b5e6-96231b3b80d8
2009-06-07 06:52:44 +00:00
Nick Lewycky
dcef849ab0 Remove cyclic MDNode detection. Any attempt to create a cyclic MDNode will
crash LLVM first.


git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@73011 91177308-0d34-0410-b5e6-96231b3b80d8
2009-06-07 04:03:01 +00:00
Nick Lewycky
00907c7d81 Refuse metadata* type for function arguments.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@73010 91177308-0d34-0410-b5e6-96231b3b80d8
2009-06-07 01:45:11 +00:00
Eli Friedman
0da9975299 PR3628: Add patterns to match SHL/SRL/SRA to the corresponding Altivec
instructions.



git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@73009 91177308-0d34-0410-b5e6-96231b3b80d8
2009-06-07 01:07:55 +00:00
Nick Lewycky
a9b9032df1 Add option for specifying the path to assembler, "as". This overrides the path
to gcc.


git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@73008 91177308-0d34-0410-b5e6-96231b3b80d8
2009-06-07 00:50:45 +00:00
Nick Lewycky
d7f20b6b98 Don't crash on multiple return value with no obvious inserted value.
Fixes PR4314.


git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@73007 91177308-0d34-0410-b5e6-96231b3b80d8
2009-06-06 23:13:08 +00:00
Eli Friedman
b9a4cacc91 PR4340: Run SimplifyDemandedVectorElts on insertelement instructions;
sometimes it can find simplifications that won't be found otherwise.



git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@73006 91177308-0d34-0410-b5e6-96231b3b80d8
2009-06-06 20:08:03 +00:00
Nick Lewycky
9d813df391 Move </pre> to column one to avoid an extra line of spaces in the example.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@73003 91177308-0d34-0410-b5e6-96231b3b80d8
2009-06-06 18:14:04 +00:00
Jay Foad
0906b1bf09 Use cast<> instead of dyn_cast<> for things that are known to be
Instructions.

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@73002 91177308-0d34-0410-b5e6-96231b3b80d8
2009-06-06 17:49:35 +00:00
Dan Gohman
86fbf2fe4c Rename UnknownValue to CouldNotCompute, since it holds an instance of
SCEVCouldNotCompute, and not SCEVUnknown.


git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@72999 91177308-0d34-0410-b5e6-96231b3b80d8
2009-06-06 14:37:11 +00:00
Eli Friedman
5257106c4d Fix the expansion for CONCAT_VECTORS so that it doesn't create illegal
types.



git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@72993 91177308-0d34-0410-b5e6-96231b3b80d8
2009-06-06 07:08:26 +00:00
Eli Friedman
7ef3d17866 Factor out a couple of helpers.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@72992 91177308-0d34-0410-b5e6-96231b3b80d8
2009-06-06 07:04:42 +00:00
Eli Friedman
30e71eb61b Avoid crashing on a variable-index insertelement with element type i16.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@72991 91177308-0d34-0410-b5e6-96231b3b80d8
2009-06-06 06:32:50 +00:00
Nick Lewycky
b4a921af05 Regenerate.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@72990 91177308-0d34-0410-b5e6-96231b3b80d8
2009-06-06 06:25:09 +00:00
Nick Lewycky
84bd075a07 Add a flag to permit disabling libffi.
Also, there were a bunch of flags with no text in --help because the square
brackets were in the wrong place. I've fixed those too.


git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@72989 91177308-0d34-0410-b5e6-96231b3b80d8
2009-06-06 06:24:44 +00:00
Eli Friedman
1041553424 Get rid of some bogus patterns for X86vzmovl. Don't create VZEXT_MOVL
nodes for vectors with an i16 element type.  Add an optimization for 
building a vector which is all zeros/undef except for the bottom 
element, where the bottom element is an i8 or i16.



git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@72988 91177308-0d34-0410-b5e6-96231b3b80d8
2009-06-06 06:05:10 +00:00