Rafael Espindola
b20b9e985a
propagate struct size and alignment of byval arguments to the DAG
...
llvm-svn: 40986
2007-08-10 14:44:42 +00:00
Bill Wendling
d0bee665d3
For kicks, I though it would be fun to use the correct opcode.
...
llvm-svn: 40985
2007-08-10 09:00:17 +00:00
Chris Lattner
f570f023cf
memcpy with zero length is hugely expensive, so avoid it. This speeds up coallescing from 1.17s to 0.88s on siod.
...
llvm-svn: 40984
2007-08-10 07:02:50 +00:00
Chris Lattner
8995eae095
small speedup in the case where a smallvector is default ctor'd from
...
an empty vector. This speeds up llc slightly.
llvm-svn: 40983
2007-08-10 06:54:38 +00:00
Bill Wendling
55c3dc2409
Adding SSSE3 intrinsics.
...
llvm-svn: 40982
2007-08-10 06:22:27 +00:00
Chris Lattner
de5f6f921a
minor simplifications.
...
llvm-svn: 40981
2007-08-10 06:22:25 +00:00
Chris Lattner
bbe3b1dbee
avoid copying strings.
...
llvm-svn: 40980
2007-08-10 06:17:04 +00:00
Devang Patel
b1160475fd
Remove unncessary duplication.
...
llvm-svn: 40979
2007-08-10 00:59:03 +00:00
Devang Patel
23c5e2dcd3
Calculate exit and start value of true loop and false loop respectively.
...
llvm-svn: 40978
2007-08-10 00:53:35 +00:00
Devang Patel
51da0a465a
ExitCondition and Induction variable are loop constraints
...
not split condition constraints.
llvm-svn: 40977
2007-08-10 00:33:50 +00:00
Chris Lattner
202e7f84e9
unbreak the build
...
llvm-svn: 40976
2007-08-09 23:55:17 +00:00
Evan Cheng
0293fe7483
Bug fix. ~1U marks the val# dead.
...
llvm-svn: 40975
2007-08-09 23:14:39 +00:00
Dale Johannesen
21c0eac378
Patch 10 for long double. Doing constants right needs expanding ConstantFP
...
to handle values bigger than double. If we assume host==target and host
long double works correctly, this is not too bad, but we don't want to
have that limitation longterm. I could implement accepting double
constants as long double or something like that, which would lead to
incorrect codegen with no errors; the more I think about that the worse
it seems. Rather than do such a hack that would be backed out later,
I'm settling for giving reasonable error messages, for now.
llvm-svn: 40974
2007-08-09 22:51:36 +00:00
Evan Cheng
3fae8e1c4a
Temporarily backing out this change until we know why some dejagnu tests are failing.
...
llvm-svn: 40973
2007-08-09 22:25:35 +00:00
Evan Cheng
a58ebc46dd
divb / mulb outputs to ah. Under x86-64 it's not legal to read ah if the instruction requires a rex prefix (i.e. outputs to r8b, etc.). So issue shift right by 8 on AX and then truncate it to 8 bits instead.
...
llvm-svn: 40972
2007-08-09 21:59:35 +00:00
Chris Lattner
3548932573
when we see a unaligned load from an insufficiently aligned global or
...
alloca, increase the alignment of the load, turning it into an aligned load.
This allows us to compile:
#include <xmmintrin.h>
__m128i foo(__m128i x){
static const unsigned int c_0[4] = { 0, 0, 0, 0 };
__m128i v_Zero = _mm_loadu_si128((__m128i*)c_0);
x = _mm_unpacklo_epi8(x, v_Zero);
return x;
}
into:
_foo:
punpcklbw _c_0.5944, %xmm0
ret
.data
.lcomm _c_0.5944,16,4 # c_0.5944
instead of:
_foo:
movdqu _c_0.5944, %xmm1
punpcklbw %xmm1, %xmm0
ret
.data
.lcomm _c_0.5944,16,2 # c_0.5944
llvm-svn: 40971
2007-08-09 19:05:49 +00:00
Evan Cheng
a822456bed
GR16_ sub-register class should be GR8_, not GR8. That is, it should only be 8-bit registers in 32-bit mode. Ditto for GR32_.
...
llvm-svn: 40970
2007-08-09 18:05:17 +00:00
Dale Johannesen
a1340d5916
Update per review comments.
...
llvm-svn: 40965
2007-08-09 17:27:48 +00:00
Owen Anderson
3eba1e8f5c
Make NonLocal and None const in the right way. :-)
...
llvm-svn: 40961
2007-08-09 04:42:44 +00:00
Devang Patel
652613b1db
Traverse loop blocks' terminators to find split candidates.
...
llvm-svn: 40960
2007-08-09 01:39:01 +00:00
Dale Johannesen
79551baaad
long double 9 of N. This finishes up the X86-32 bits
...
(constants are still not handled). Adds ConvertActions
to control fp-to-fp conversions (these are currently
defaulted for all other targets, so no changes there).
llvm-svn: 40958
2007-08-09 01:04:01 +00:00
Dale Johannesen
6c8f73eac6
Fix arguments for some Altivec instructions. From SWB.
...
llvm-svn: 40957
2007-08-09 00:49:19 +00:00
Scott Michel
86052f49c0
If a target really needs to custom lower constants, it should be allowed
...
to do so.
llvm-svn: 40955
2007-08-08 23:23:31 +00:00
Owen Anderson
3db807751b
Add more comments to memdep.
...
llvm-svn: 40953
2007-08-08 22:26:03 +00:00
Devang Patel
30bf54b9d3
Add cost analysis.
...
llvm-svn: 40952
2007-08-08 22:25:28 +00:00
Owen Anderson
d791c9f667
Make memdep fit in 80 cols.
...
llvm-svn: 40950
2007-08-08 22:01:54 +00:00
Owen Anderson
24f6b332cb
Add one more comment.
...
llvm-svn: 40949
2007-08-08 21:54:33 +00:00
Owen Anderson
f4aec9115f
Cleanup and comment-ize the memdep header.
...
llvm-svn: 40948
2007-08-08 21:53:20 +00:00
Devang Patel
ed9b08c44f
Preserve dom info while processing one iteration loop.
...
llvm-svn: 40947
2007-08-08 21:39:47 +00:00
Owen Anderson
f988c3ee5c
Change the None and NonLocal markers in memdep to be const.
...
llvm-svn: 40946
2007-08-08 21:39:39 +00:00
Reid Spencer
e6c778f11a
Separate program name from error message with a :
...
llvm-svn: 40945
2007-08-08 21:19:01 +00:00
Devang Patel
a74e533c5e
Clear split info.
...
llvm-svn: 40944
2007-08-08 21:18:27 +00:00
Reid Spencer
0bc68c6e6e
Terminate an error message with a newline.
...
llvm-svn: 40943
2007-08-08 21:17:59 +00:00
Devang Patel
4bd07b86ae
Handle multiple split conditions.
...
llvm-svn: 40941
2007-08-08 21:02:17 +00:00
Reid Spencer
6f88014eeb
Make it clear that getSTDIN returns null when stdin is empty.
...
llvm-svn: 40940
2007-08-08 20:02:20 +00:00
Reid Spencer
e8aa5a5832
Make getSTDIN return null if the standard input is empty, as the header file
...
documentation implies and as its uses depend.
llvm-svn: 40939
2007-08-08 20:01:58 +00:00
Reid Spencer
c5f311aa70
Allow the filename "-" to be a place holder for stdin. This allows directing
...
stdin through llvm-ld and llvm-link.
llvm-svn: 40938
2007-08-08 19:52:29 +00:00
Owen Anderson
04ba98d0f5
Global values also don't undead-ify pointers in our dead alloca's set.
...
llvm-svn: 40936
2007-08-08 19:12:31 +00:00
Owen Anderson
fd772509e9
Make handleEndBlock significantly faster with one trivial improvement,
...
and one hack to avoid hitting a bad case when the alias analysis is imprecise.
llvm-svn: 40935
2007-08-08 18:38:28 +00:00
Owen Anderson
930610cceb
Small improvement: if a function doesn't access memory, we don't need to scan
...
it for potentially undeading pointers.
llvm-svn: 40933
2007-08-08 17:58:56 +00:00
Owen Anderson
ecd9348bd6
Add some comments, remove a dead argument, and simplify some control flow.
...
No functionality change.
llvm-svn: 40932
2007-08-08 17:50:09 +00:00
Chris Lattner
a7dce8c173
eliminate redundant conditions from the signless types conversion.
...
llvm-svn: 40927
2007-08-08 16:19:57 +00:00
Chris Lattner
3e94308eb7
Handle functions with no name better.
...
llvm-svn: 40926
2007-08-08 16:07:23 +00:00
Evan Cheng
5227e36428
Adding kill info to val#.
...
llvm-svn: 40925
2007-08-08 07:03:29 +00:00
Chris Lattner
606d5bced1
significantly speed up constant folding of calls (and thus all clients that use
...
ConstantFoldInstruction on calls) by avoiding Value::getName(). getName() constructs
and returns an std::string, which does heap allocation stuff. This slightly speeds up
instcombine.
llvm-svn: 40924
2007-08-08 06:55:43 +00:00
Chris Lattner
b8959ef7a1
Speed up updateDFSNumbers with two observations:
...
1. domtree is a tree, not a graph. There is no need to avoid revisiting nodes with a set.
2. the worklist can contain the child iterator pointers so we don't get N^2 rescanning of children.
This speeds up updateDFSNumbers significantly, making it basically free. On the testcase in PR1432,
this speeds up loopsimplify by another 3x, dropping it from the 12th most expensive pass to the to
the 30th. :) It used to be #1 .
llvm-svn: 40923
2007-08-08 06:24:20 +00:00
Owen Anderson
02298f7388
A few more small cleanups.
...
llvm-svn: 40922
2007-08-08 06:06:02 +00:00
Evan Cheng
02e7fbd7c8
Clean up and bug fix.
...
llvm-svn: 40921
2007-08-08 05:56:18 +00:00
Chris Lattner
65d638a918
reimplement dfs number computation to be significantly faster. This speeds up
...
natural loop canonicalization (which does many cfg xforms) by 4.3x, for
example. This also fixes a bug in postdom dfnumber computation.
llvm-svn: 40920
2007-08-08 05:51:24 +00:00
Owen Anderson
a9facda8db
First round of cleanups from Chris' feedback.
...
llvm-svn: 40919
2007-08-08 04:52:29 +00:00