Nate Begeman
9008ca6b6b
2nd attempt, fixing SSE4.1 issues and implementing feedback from duncan.
...
PR2957
ISD::VECTOR_SHUFFLE now stores an array of integers representing the shuffle
mask internal to the node, rather than taking a BUILD_VECTOR of ConstantSDNodes
as the shuffle mask. A value of -1 represents UNDEF.
In addition to eliminating the creation of illegal BUILD_VECTORS just to
represent shuffle masks, we are better about canonicalizing the shuffle mask,
resulting in substantially better code for some classes of shuffles.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@70225 91177308-0d34-0410-b5e6-96231b3b80d8
2009-04-27 18:41:29 +00:00
Chris Lattner
c167cac8f0
Print statistics for each record kind saying the number of bits
...
and % abbreviated. For example:
Record Histogram:
Count # Bits % Abv Record Kind
25738 3424174 100.00 SM_SLOC_INSTANTIATION_ENTRY
814 562079 100.00 SM_SLOC_FILE_ENTRY
798 34110 SM_HEADER_FILE_INFO
3 91104 100.00 SM_SLOC_BUFFER_BLOB
3 498 100.00 SM_SLOC_BUFFER_ENTRY
1 465 SM_LINE_TABLE
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@70215 91177308-0d34-0410-b5e6-96231b3b80d8
2009-04-27 18:15:27 +00:00
Chris Lattner
2443747e45
clean up the output of llvm-bcanalyzer by using printf
...
instead of ostreams for formatting.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@70214 91177308-0d34-0410-b5e6-96231b3b80d8
2009-04-27 17:59:34 +00:00
Evan Cheng
d521bc983b
Fix PR4056. It's possible a physical register def is dead if its implicit use is deleted by two-address pass.
...
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@70213 91177308-0d34-0410-b5e6-96231b3b80d8
2009-04-27 17:36:47 +00:00
Evan Cheng
27e4666c20
Also delete last unused val#.
...
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@70212 91177308-0d34-0410-b5e6-96231b3b80d8
2009-04-27 17:35:19 +00:00
Dan Gohman
4af325d1b4
Rename GR8_ABCD to GR8_ABCD_L and create GR8_ABCD_H, and use these
...
to precisely describe the h-register subreg register classes.
Thanks to Jakob Stoklund Olesen for spotting this and for the
initial patch!
Also, make getStoreRegOpcode and getLoadRegOpcode aware of the
needs of h registers.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@70211 91177308-0d34-0410-b5e6-96231b3b80d8
2009-04-27 16:41:36 +00:00
Dan Gohman
6241762c5a
Rename GR8_, GR16_, GR32_, and GR64_ to GR8_ABCD, GR16_ABCD,
...
GR32_ABCD, and GR64_ABCD, respectively, to help describe them.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@70210 91177308-0d34-0410-b5e6-96231b3b80d8
2009-04-27 16:33:14 +00:00
Dan Gohman
4d47b9bcb9
Break up long multi-mnemonic strings into separate lines for readability.
...
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@70209 91177308-0d34-0410-b5e6-96231b3b80d8
2009-04-27 15:13:28 +00:00
Dan Gohman
f45728dae3
Fix the syntax for a PR number in a test.
...
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@70208 91177308-0d34-0410-b5e6-96231b3b80d8
2009-04-27 15:08:34 +00:00
Duncan Sands
f044cff0a4
Fix some confusion in the Ada f-e build instructions between
...
building without optimization and building with checking.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@70205 91177308-0d34-0410-b5e6-96231b3b80d8
2009-04-27 11:21:35 +00:00
Mon P Wang
a7e01d7efd
Revised 68749 to allow matching of load/stores for address spaces < 256.
...
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@70197 91177308-0d34-0410-b5e6-96231b3b80d8
2009-04-27 07:22:10 +00:00
Nick Lewycky
e2bcf13be5
Under unusual circumstances (jitting a function that causes the creation of
...
another stub, but then never calling the jitted function) can cause the JIT to
leave a stub in place. Judging by the comments this is a known deficiency, so
we're just not going to use AssertingVH for the StubToFunctionTy map.
Also shorten some lines longer than 80 columns.
This fixes the "make check" failure with ocaml on x86-64 linux.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@70185 91177308-0d34-0410-b5e6-96231b3b80d8
2009-04-27 05:09:44 +00:00
Sanjiv Gupta
23c70f44e4
Now that any size of integer indices are allowed for sequential types, remove the unneccessary gyan about promoting them.
...
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@70181 91177308-0d34-0410-b5e6-96231b3b80d8
2009-04-27 03:21:00 +00:00
Dan Gohman
fa6c716842
Make this test slightly more strict.
...
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@70180 91177308-0d34-0410-b5e6-96231b3b80d8
2009-04-27 03:05:26 +00:00
Dan Gohman
c7b3444095
When transforming sext(trunc(load(x))) into sext(smaller load(x)),
...
the trunc is directly replaced with the smaller load, so don't
try to create a new sext node. This fixes PR4050.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@70179 91177308-0d34-0410-b5e6-96231b3b80d8
2009-04-27 02:00:55 +00:00
Dan Gohman
d6c329532b
Handle ands with ~0 correctly too. This fixes PR4052.
...
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@70176 91177308-0d34-0410-b5e6-96231b3b80d8
2009-04-27 01:41:10 +00:00
Dan Gohman
0324205bbb
Improve bugpoint's error messages when it runs out of memory,
...
or when some other std::exception is thrown.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@70175 91177308-0d34-0410-b5e6-96231b3b80d8
2009-04-27 01:30:37 +00:00
Chris Lattner
f9a3ec86c1
Add two new record types to the blockinfo block:
...
BLOCKNAME and SETRECORDNAME. This allows a bitcode
file to be self describing with pretty names for
records and blocks in addition to numbers. This
enhances llvm-bcanalyzer to use this to print prettily.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@70165 91177308-0d34-0410-b5e6-96231b3b80d8
2009-04-26 22:21:57 +00:00
Chris Lattner
7919b966a8
make BitstreamCursor's copyable and assignable.
...
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@70159 91177308-0d34-0410-b5e6-96231b3b80d8
2009-04-26 21:07:02 +00:00
Chris Lattner
962dde3cef
Make a major API change to BitstreamReader: split all the reading
...
state out of the BitstreamReader class into a BitstreamCursor class.
Doing this allows the client to have multiple cursors into the same
file, each with potentially different live block stacks and
abbreviation records.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@70157 91177308-0d34-0410-b5e6-96231b3b80d8
2009-04-26 20:59:02 +00:00
Bill Wendling
3485d25a0e
I cast, therefore I think I know what I'm doing.
...
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@70151 91177308-0d34-0410-b5e6-96231b3b80d8
2009-04-26 20:12:38 +00:00
Bill Wendling
b14a495c36
Use uint64_t instead of unsigned.
...
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@70148 91177308-0d34-0410-b5e6-96231b3b80d8
2009-04-26 19:46:41 +00:00
Chris Lattner
1e8db00e3b
revert an incorrect patch. This causes crashes all over the place on a
...
64-bit build.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@70147 91177308-0d34-0410-b5e6-96231b3b80d8
2009-04-26 19:44:20 +00:00
Bill Wendling
610cb31ac9
Suppress warnings about conversion shortening 64-bit to 32-bit.
...
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@70138 91177308-0d34-0410-b5e6-96231b3b80d8
2009-04-26 18:10:20 +00:00
Sanjiv Gupta
9341c808ae
Any size of integral indices are allowed in gep for indexing into sequential types. Also adding a test case to check the indices type allowed into struct.
...
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@70134 91177308-0d34-0410-b5e6-96231b3b80d8
2009-04-26 17:14:35 +00:00
Chris Lattner
efdb3bc8d0
improve documentation on build configurations, patch by
...
Josef Eisl!
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@70087 91177308-0d34-0410-b5e6-96231b3b80d8
2009-04-25 22:24:49 +00:00
Chris Lattner
b5fbb06e32
add testcase for strange types of gep indices
...
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@70085 91177308-0d34-0410-b5e6-96231b3b80d8
2009-04-25 22:20:49 +00:00
Chris Lattner
096fd7b5a7
Add a new TypeBuilder helper class, which eases making LLVM IR types.
...
Patch by Jeffrey Yasskin!
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@70084 91177308-0d34-0410-b5e6-96231b3b80d8
2009-04-25 22:14:04 +00:00
Chris Lattner
552672d285
improve documentation around memory lifetimes,
...
patch by Jeffrey Yasskin!
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@70083 91177308-0d34-0410-b5e6-96231b3b80d8
2009-04-25 22:10:06 +00:00
Chris Lattner
069429062d
aDd support for building a subset of the llvm tools, patch by Jeffrey Yasskin!
...
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@70082 91177308-0d34-0410-b5e6-96231b3b80d8
2009-04-25 22:08:52 +00:00
Chris Lattner
040f758e3a
testcase and asmparser fix for PR4066
...
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@70080 91177308-0d34-0410-b5e6-96231b3b80d8
2009-04-25 21:26:00 +00:00
Chris Lattner
a2165ed6ee
Allow aliasee to be a GEP or bitcast instead of just a bitcast.
...
The real fix for this whole mess is to require the operand of the
alias to be a *GlobalValue* (not a general constant, including
constant exprs) but allow the operand and the alias type to be
unrelated.
This fixes PR4066
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@70079 91177308-0d34-0410-b5e6-96231b3b80d8
2009-04-25 21:23:19 +00:00
Chris Lattner
4f4365eb4e
Update docs to not mention gcse/loadvn and mention memdep and
...
new stuff. PR3924.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@70077 91177308-0d34-0410-b5e6-96231b3b80d8
2009-04-25 21:11:37 +00:00
Bill Wendling
c2dbff3ba6
Use intptr_t.
...
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@70076 91177308-0d34-0410-b5e6-96231b3b80d8
2009-04-25 21:06:53 +00:00
Mon P Wang
8d34844bff
size() should return a size_t; avoids a warning for 64 bit machines.
...
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@70072 91177308-0d34-0410-b5e6-96231b3b80d8
2009-04-25 20:46:59 +00:00
Evan Cheng
a4b2bab233
Reuse unused val#'s to avoid running out of memory in extreme cases.
...
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@70069 91177308-0d34-0410-b5e6-96231b3b80d8
2009-04-25 20:20:15 +00:00
Chris Lattner
11d8fb9609
DenseMap.h needs <new> because it explicitly calls operator new/delete.
...
Patch by John McCall!
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@70068 91177308-0d34-0410-b5e6-96231b3b80d8
2009-04-25 19:50:14 +00:00
Chris Lattner
38300e91f5
Fix PR4040: APInt's string constructor is too strict
...
patch by Jeff Yasskin!
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@70058 91177308-0d34-0410-b5e6-96231b3b80d8
2009-04-25 18:34:04 +00:00
Chris Lattner
bc58322d6a
add support for detecting process features on win64, patch by
...
Nicolas Capens!
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@70057 91177308-0d34-0410-b5e6-96231b3b80d8
2009-04-25 18:27:23 +00:00
Dan Gohman
2bee0afb7d
Refactor the code to grab the low and high parts of a value
...
using EXTRACT_ELEMENT into a utility function.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@70056 91177308-0d34-0410-b5e6-96231b3b80d8
2009-04-25 17:55:53 +00:00
Dan Gohman
2fe4d0aacb
Return null instead of false, as appropriate.
...
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@70054 91177308-0d34-0410-b5e6-96231b3b80d8
2009-04-25 17:28:45 +00:00
Dan Gohman
1c8491ecc7
Add several more icmp simplifications. Transform signed comparisons
...
into unsigned ones when the operands are known to have the same
sign bit value.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@70053 91177308-0d34-0410-b5e6-96231b3b80d8
2009-04-25 17:12:48 +00:00
Dan Gohman
4128700ab1
Add a top-level comment about DAGCombiner's role in the compiler.
...
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@70052 91177308-0d34-0410-b5e6-96231b3b80d8
2009-04-25 17:09:45 +00:00
Dan Gohman
2c73d5fb9e
Handle ands with 0 and shifts by 0 correctly. These aren't
...
common, but indvars shouldn't crash on them. This fixes PR4054.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@70051 91177308-0d34-0410-b5e6-96231b3b80d8
2009-04-25 17:05:40 +00:00
Torok Edwin
4cdc44c82c
Fix g++-4.4.0 warning, it was causing llvm-nm to fail on wrapped BC files:
...
Path.cpp:59: warning: case label value exceeds maximum value for type
magic[0] is a (signed) char, but some case values are unsigned (e.g. 0xde).
When magic[0] was 0xde, the switch has taken the default branch instead of case
0xde branch.
Apparently this was the behaviour with older versions of gcc too, but not with g++.
Now g++-4.4 behaves as gcc, and ignores unsigned case values out of range signed
range.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@70038 91177308-0d34-0410-b5e6-96231b3b80d8
2009-04-25 10:25:12 +00:00
Evan Cheng
0adb527d16
Do not share a single unknown val# for all the live ranges merged into a physical sub-register live interval. When coalescer is merging in clobbered virtaul register live interval into a physical register live interval, give each virtual register val# a separate val# in the physical register live interval. Otherwise, the coalescer would have lost track of the definitions information it needs to make correct coalescing decisions.
...
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@70026 91177308-0d34-0410-b5e6-96231b3b80d8
2009-04-25 09:25:19 +00:00
Sanjiv Gupta
9f805c206e
Fixed the gep example for i16 type indices.
...
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@70019 91177308-0d34-0410-b5e6-96231b3b80d8
2009-04-25 07:27:44 +00:00
Bob Wilson
8091524d98
Change LowerCallResult method so that CCValAssign::BCvt can be used with
...
f64 types. This is not used for anything yet.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@70006 91177308-0d34-0410-b5e6-96231b3b80d8
2009-04-25 00:33:20 +00:00
Dale Johannesen
2f91f30b93
Fix PR 4057, a crash doing float->char const folding.
...
This particular one is undefined behavior (although this
isn't related to the crash), so it will no longer do it
at compile time, which seems better.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@69990 91177308-0d34-0410-b5e6-96231b3b80d8
2009-04-24 21:34:13 +00:00
Bob Wilson
d55bd51f31
Adjust a comment to reflect what the code does. Splitting a 64-bit argument
...
between registers and the stack may be required with the APCS ABI, but it
isn't tied to using a particular version of the ARM architecture.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@69978 91177308-0d34-0410-b5e6-96231b3b80d8
2009-04-24 17:05:01 +00:00