Commit Graph

33654 Commits

Author SHA1 Message Date
Owen Anderson
b97819852a Move some sets and maps to SmallPtrSet and DenseMap respectively. This
reduces the time to optimize 403.gcc from 17.6s to 16.4s.


git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@40036 91177308-0d34-0410-b5e6-96231b3b80d8
2007-07-19 03:32:44 +00:00
Devang Patel
a8a8a36629 After a basic block is split into two parts,
second part dominates all the blocks dominated
by original basic block. And first part dominates
second part.



git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@40035 91177308-0d34-0410-b5e6-96231b3b80d8
2007-07-19 02:29:24 +00:00
Devang Patel
72ea8d9060 Now this temp. fix is not required.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@40034 91177308-0d34-0410-b5e6-96231b3b80d8
2007-07-19 02:22:21 +00:00
Evan Cheng
64d80e3387 Change instruction description to split OperandList into OutOperandList and
InOperandList. This gives one piece of important information: # of results
produced by an instruction.
An example of the change:
def ADD32rr  : I<0x01, MRMDestReg, (ops GR32:$dst, GR32:$src1, GR32:$src2),
                 "add{l} {$src2, $dst|$dst, $src2}",
                 [(set GR32:$dst, (add GR32:$src1, GR32:$src2))]>;
=>
def ADD32rr  : I<0x01, MRMDestReg, (outs GR32:$dst), (ins GR32:$src1, GR32:$src2),
                 "add{l} {$src2, $dst|$dst, $src2}",
                 [(set GR32:$dst, (add GR32:$src1, GR32:$src2))]>;


git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@40033 91177308-0d34-0410-b5e6-96231b3b80d8
2007-07-19 01:14:50 +00:00
Evan Cheng
4558b807a2 Only adjust esp around calls in presence of alloca.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@40030 91177308-0d34-0410-b5e6-96231b3b80d8
2007-07-19 00:42:58 +00:00
Evan Cheng
7e7bbf8271 Only adjust esp around calls in presence of alloca.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@40028 91177308-0d34-0410-b5e6-96231b3b80d8
2007-07-19 00:42:05 +00:00
Devang Patel
24857a3fac Fix typo.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@40025 91177308-0d34-0410-b5e6-96231b3b80d8
2007-07-18 23:50:19 +00:00
Devang Patel
31ad75329e Fix dominator info update to accommodate CFG changes.
This fixes PR1559.


git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@40024 91177308-0d34-0410-b5e6-96231b3b80d8
2007-07-18 23:48:20 +00:00
Devang Patel
a8d507d970 New test.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@40023 91177308-0d34-0410-b5e6-96231b3b80d8
2007-07-18 23:47:02 +00:00
Evan Cheng
273288c888 Add comment.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@40022 91177308-0d34-0410-b5e6-96231b3b80d8
2007-07-18 23:34:48 +00:00
Evan Cheng
ccb21fdbb6 New test.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@40020 91177308-0d34-0410-b5e6-96231b3b80d8
2007-07-18 21:39:16 +00:00
Evan Cheng
3c46eefba2 Use MOV instead of LEA to restore ESP if callee-saved frame size is 0; if previous instruction updates esp, fold it in.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@40018 91177308-0d34-0410-b5e6-96231b3b80d8
2007-07-18 21:26:06 +00:00
Dan Gohman
6ab2d18f5e Add constructor overloads for LoadInst and StoreInst that insert at the
end of a BasicBlock and have an alignment parameter.


git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@40016 91177308-0d34-0410-b5e6-96231b3b80d8
2007-07-18 20:51:11 +00:00
Dan Gohman
4106f3714e Implement initial memory alignment awareness for SSE instructions. Vector loads
and stores that have a specified alignment of less than 16 bytes now use
instructions that support misaligned memory references.


git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@40015 91177308-0d34-0410-b5e6-96231b3b80d8
2007-07-18 20:23:34 +00:00
Owen Anderson
b54b315251 Fix an issue where assignments that caused a SmallPtrSet to become non-small
would result in calling realloc() on a null pointer.  Instead, if we encounter
this situation, make a normal call to malloc().


git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@40014 91177308-0d34-0410-b5e6-96231b3b80d8
2007-07-18 19:54:15 +00:00
Dan Gohman
48613b930a It's not necessary to do rounding for alloca operations when the requested
alignment is equal to the stack alignment.


git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@40004 91177308-0d34-0410-b5e6-96231b3b80d8
2007-07-18 16:29:46 +00:00
Evan Cheng
b5cd24973c New entry.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@39998 91177308-0d34-0410-b5e6-96231b3b80d8
2007-07-18 08:21:49 +00:00
Reid Spencer
cbb7ec7396 Fix a sys::Path API error caught by a gcc 4.2 warning.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@39995 91177308-0d34-0410-b5e6-96231b3b80d8
2007-07-18 05:27:33 +00:00
Chris Lattner
ad8c531e20 Work around a bogus gcc 4.2 warning.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@39993 91177308-0d34-0410-b5e6-96231b3b80d8
2007-07-18 04:51:57 +00:00
Reid Spencer
531ec1e7a2 Fix this test to not rely on the path but to use the
configured llvm-gcc instead.


git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@39992 91177308-0d34-0410-b5e6-96231b3b80d8
2007-07-18 04:37:24 +00:00
Reid Spencer
9a9d03dac1 The property is svn:executable not svn:execute.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@39991 91177308-0d34-0410-b5e6-96231b3b80d8
2007-07-18 04:26:05 +00:00
Nick Lewycky
254aa7cf2b Alphabetize. Document -mlimit parameter.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@39990 91177308-0d34-0410-b5e6-96231b3b80d8
2007-07-18 04:24:20 +00:00
Owen Anderson
b63c7b695f Turn on FastDSE by default.
Note: FastDSE now equals or exceeds the results of old DSE on all of SPEC2000 and SPEC2006. Unless major problems
show up in the testers, it will likely completely replace old DSE in the near future.


git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@39986 91177308-0d34-0410-b5e6-96231b3b80d8
2007-07-17 21:59:21 +00:00
Evan Cheng
9b8c674432 Fold prologue esp update when possible.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@39984 91177308-0d34-0410-b5e6-96231b3b80d8
2007-07-17 21:26:42 +00:00
Andrew Lenharth
0af32251c7 support poolalloc as checked out from svn
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@39983 91177308-0d34-0410-b5e6-96231b3b80d8
2007-07-17 20:37:35 +00:00
Evan Cheng
74b1e1424c Change sroa threshold back.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@39980 91177308-0d34-0410-b5e6-96231b3b80d8
2007-07-17 20:07:21 +00:00
Evan Cheng
f99002c143 Dead code.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@39979 91177308-0d34-0410-b5e6-96231b3b80d8
2007-07-17 20:01:19 +00:00
Evan Cheng
5b3332cc27 Make sure not to break eh_return.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@39978 91177308-0d34-0410-b5e6-96231b3b80d8
2007-07-17 18:40:47 +00:00
Evan Cheng
698b63862c Update.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@39977 91177308-0d34-0410-b5e6-96231b3b80d8
2007-07-17 18:39:45 +00:00
Evan Cheng
574470a561 Fix test.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@39976 91177308-0d34-0410-b5e6-96231b3b80d8
2007-07-17 18:16:09 +00:00
Tanya Lattner
c462d25776 Don't use * in XFAIL line unless you want it to XFAIL on everything. I don't believe you can use true regular expressions here. It will just look for those keywords. Please test this on sparc and see if they still are xfailed.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@39975 91177308-0d34-0410-b5e6-96231b3b80d8
2007-07-17 18:08:32 +00:00
Evan Cheng
f27795d174 Missed the case where alloca is used but the stack size (not including callee-saved portion) is zero. Thanks Dan.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@39974 91177308-0d34-0410-b5e6-96231b3b80d8
2007-07-17 18:03:34 +00:00
Rafael Espindola
969c44481b detect invalid combination of sret and byval
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@39971 91177308-0d34-0410-b5e6-96231b3b80d8
2007-07-17 13:34:23 +00:00
Gabor Greif
6bd7ada32d XFAIL these on sparc-solaris
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@39969 91177308-0d34-0410-b5e6-96231b3b80d8
2007-07-17 10:25:31 +00:00
Evan Cheng
89d1659cf2 Use push / pop for prologues and epilogues.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@39967 91177308-0d34-0410-b5e6-96231b3b80d8
2007-07-17 07:59:08 +00:00
Reid Spencer
8d1b8f7e38 Make use of the process_builder_args library function.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@39965 91177308-0d34-0410-b5e6-96231b3b80d8
2007-07-17 07:17:02 +00:00
Reid Spencer
cb5da4a8b6 For PR1558:
Move tests that have C/C++ sources into the appropriate directory. This
allows them to be selected for testing based on whether llvm-gcc is
present or not.


git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@39963 91177308-0d34-0410-b5e6-96231b3b80d8
2007-07-17 06:20:38 +00:00
Chris Lattner
c3dbe70ce7 no email addrs in file headers
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@39962 91177308-0d34-0410-b5e6-96231b3b80d8
2007-07-17 05:56:43 +00:00
Reid Spencer
845b31de0c Unbreak the build by putting calls to free into the implementation file and
having that implementation file #include <cstdlib>.


git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@39952 91177308-0d34-0410-b5e6-96231b3b80d8
2007-07-17 02:16:12 +00:00
Evan Cheng
a8b9a7b924 Temporarily set SROA threshold to 512.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@39950 91177308-0d34-0410-b5e6-96231b3b80d8
2007-07-17 01:52:05 +00:00
Owen Anderson
ce17b1c1f8 Take advantage of undefined behavior if the source program tries to GEP
beyond the end of an alloca to make FastDSE faster and more aggressive.


git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@39945 91177308-0d34-0410-b5e6-96231b3b80d8
2007-07-16 23:34:39 +00:00
Reid Spencer
162c518286 Normally, we don't want to install and we only need to build tools.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@39944 91177308-0d34-0410-b5e6-96231b3b80d8
2007-07-16 23:25:52 +00:00
Reid Spencer
3b52308476 No, we're not looking for a directory named /config.status.
Sigh .. fix copy & paste error.


git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@39939 91177308-0d34-0410-b5e6-96231b3b80d8
2007-07-16 22:54:42 +00:00
Reid Spencer
8c88b6de62 In ModuleInfo.txt, make sure that the script being executed can be
found by prepending a .
In build-for-llvm-top.sh, dereference variables for exansion.


git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@39936 91177308-0d34-0410-b5e6-96231b3b80d8
2007-07-16 22:25:13 +00:00
Reid Spencer
e68da83d49 Prepare for the future when llvm doesn't depend on llvm-gcc-4-0.
This also avoids a fork bomb from the llvm-top/build script which
doesn't know how to handle cycles in the dependence graph.


git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@39933 91177308-0d34-0410-b5e6-96231b3b80d8
2007-07-16 22:11:02 +00:00
Reid Spencer
63d6d7385f Remove insignificant test no longer needed.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@39931 91177308-0d34-0410-b5e6-96231b3b80d8
2007-07-16 22:03:36 +00:00
Owen Anderson
faac518ce0 Add support for walking up memory def chains, which enables finding many more
dead stores on 400.perlbench.


git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@39929 91177308-0d34-0410-b5e6-96231b3b80d8
2007-07-16 21:52:50 +00:00
Owen Anderson
1629a1fa87 Use realloc() to (potentially) resize the contents of SmallPtrSet in place.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@39926 91177308-0d34-0410-b5e6-96231b3b80d8
2007-07-16 21:27:44 +00:00
Reid Spencer
bde6869ef4 Return Undef if the block has no dominator. This was required to allow
llvm-gcc build to succeed. Without this change it fails in libstdc++
compilation. This causes no regressions in dejagnu tests. However, 
someone who knows this code better might want to review it.


git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@39924 91177308-0d34-0410-b5e6-96231b3b80d8
2007-07-16 21:03:44 +00:00
Dan Gohman
384152444d Use ConstantFoldFP for folding all unary floating-point operations which may
have an error, and refector out the code for binary operators into
ConstantFoldBinaryFP and use it for all binary floating-point operations
which may have an error. These functions still rely exclusively on errno
to detect errors though.


git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@39923 91177308-0d34-0410-b5e6-96231b3b80d8
2007-07-16 15:26:22 +00:00