oota-llvm.git
16 years agoVerify loop info.
Devang Patel [Thu, 19 Jul 2007 18:02:32 +0000 (18:02 +0000)]
Verify loop info.

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@40062 91177308-0d34-0410-b5e6-96231b3b80d8

16 years agoProperly initialize value :)
Anton Korobeynikov [Thu, 19 Jul 2007 15:32:47 +0000 (15:32 +0000)]
Properly initialize value :)

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@40059 91177308-0d34-0410-b5e6-96231b3b80d8

16 years agoReplace mysterious code causing a g++-4.2 warning
Duncan Sands [Thu, 19 Jul 2007 09:42:01 +0000 (09:42 +0000)]
Replace mysterious code causing a g++-4.2 warning
with hopefully correct code that pleases g++-4.2.

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@40051 91177308-0d34-0410-b5e6-96231b3b80d8

16 years agoFix this test. We produce pretty cruddy code for this
Duncan Sands [Thu, 19 Jul 2007 09:38:34 +0000 (09:38 +0000)]
Fix this test.  We produce pretty cruddy code for this
nowadays, unfortunately it's not so easy to get good
code here while still producing correct code in exotic
situations.

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@40050 91177308-0d34-0410-b5e6-96231b3b80d8

16 years agoAs pointed out by g++-4.2, the original code didn't do
Duncan Sands [Thu, 19 Jul 2007 07:31:58 +0000 (07:31 +0000)]
As pointed out by g++-4.2, the original code didn't do
what it thought it was doing.

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@40044 91177308-0d34-0410-b5e6-96231b3b80d8

16 years agoRemember to free the heap allocated array if we're not going to use it.
Owen Anderson [Thu, 19 Jul 2007 06:45:33 +0000 (06:45 +0000)]
Remember to free the heap allocated array if we're not going to use it.

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@40043 91177308-0d34-0410-b5e6-96231b3b80d8

16 years agoUse SmallVector and DenseMap in even more places.
Owen Anderson [Thu, 19 Jul 2007 06:37:56 +0000 (06:37 +0000)]
Use SmallVector and DenseMap in even more places.
With this, the time to optimize 403.gcc is down to 15.1s.

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@40042 91177308-0d34-0410-b5e6-96231b3b80d8

16 years agoTestcase for PR1549
Bill Wendling [Thu, 19 Jul 2007 06:31:11 +0000 (06:31 +0000)]
Testcase for PR1549

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@40041 91177308-0d34-0410-b5e6-96231b3b80d8

16 years agoChange ValueTable to use a DenseMap for mapping expressions to value numbers.
Owen Anderson [Thu, 19 Jul 2007 06:13:15 +0000 (06:13 +0000)]
Change ValueTable to use a DenseMap for mapping expressions to value numbers.
This results in a slight speedup for 403.gcc.

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@40040 91177308-0d34-0410-b5e6-96231b3b80d8

16 years agoSet up ground work to verify preserved analysis info.
Devang Patel [Thu, 19 Jul 2007 05:36:09 +0000 (05:36 +0000)]
Set up ground work to verify preserved analysis info.

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@40039 91177308-0d34-0410-b5e6-96231b3b80d8

16 years agoMove some sets and maps to SmallPtrSet and DenseMap respectively. This
Owen Anderson [Thu, 19 Jul 2007 03:32:44 +0000 (03:32 +0000)]
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

16 years agoAfter a basic block is split into two parts,
Devang Patel [Thu, 19 Jul 2007 02:29:24 +0000 (02:29 +0000)]
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

16 years agoNow this temp. fix is not required.
Devang Patel [Thu, 19 Jul 2007 02:22:21 +0000 (02:22 +0000)]
Now this temp. fix is not required.

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@40034 91177308-0d34-0410-b5e6-96231b3b80d8

16 years agoChange instruction description to split OperandList into OutOperandList and
Evan Cheng [Thu, 19 Jul 2007 01:14:50 +0000 (01:14 +0000)]
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

16 years agoOnly adjust esp around calls in presence of alloca.
Evan Cheng [Thu, 19 Jul 2007 00:42:58 +0000 (00:42 +0000)]
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

16 years agoOnly adjust esp around calls in presence of alloca.
Evan Cheng [Thu, 19 Jul 2007 00:42:05 +0000 (00:42 +0000)]
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

16 years agoFix typo.
Devang Patel [Wed, 18 Jul 2007 23:50:19 +0000 (23:50 +0000)]
Fix typo.

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@40025 91177308-0d34-0410-b5e6-96231b3b80d8

16 years agoFix dominator info update to accommodate CFG changes.
Devang Patel [Wed, 18 Jul 2007 23:48:20 +0000 (23:48 +0000)]
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

16 years agoNew test.
Devang Patel [Wed, 18 Jul 2007 23:47:02 +0000 (23:47 +0000)]
New test.

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@40023 91177308-0d34-0410-b5e6-96231b3b80d8

16 years agoAdd comment.
Evan Cheng [Wed, 18 Jul 2007 23:34:48 +0000 (23:34 +0000)]
Add comment.

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@40022 91177308-0d34-0410-b5e6-96231b3b80d8

16 years agoNew test.
Evan Cheng [Wed, 18 Jul 2007 21:39:16 +0000 (21:39 +0000)]
New test.

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@40020 91177308-0d34-0410-b5e6-96231b3b80d8

16 years agoUse MOV instead of LEA to restore ESP if callee-saved frame size is 0; if previous...
Evan Cheng [Wed, 18 Jul 2007 21:26:06 +0000 (21:26 +0000)]
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

16 years agoAdd constructor overloads for LoadInst and StoreInst that insert at the
Dan Gohman [Wed, 18 Jul 2007 20:51:11 +0000 (20:51 +0000)]
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

16 years agoImplement initial memory alignment awareness for SSE instructions. Vector loads
Dan Gohman [Wed, 18 Jul 2007 20:23:34 +0000 (20:23 +0000)]
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

16 years agoFix an issue where assignments that caused a SmallPtrSet to become non-small
Owen Anderson [Wed, 18 Jul 2007 19:54:15 +0000 (19:54 +0000)]
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

16 years agoIt's not necessary to do rounding for alloca operations when the requested
Dan Gohman [Wed, 18 Jul 2007 16:29:46 +0000 (16:29 +0000)]
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

16 years agoNew entry.
Evan Cheng [Wed, 18 Jul 2007 08:21:49 +0000 (08:21 +0000)]
New entry.

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@39998 91177308-0d34-0410-b5e6-96231b3b80d8

16 years agoFix a sys::Path API error caught by a gcc 4.2 warning.
Reid Spencer [Wed, 18 Jul 2007 05:27:33 +0000 (05:27 +0000)]
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

16 years agoWork around a bogus gcc 4.2 warning.
Chris Lattner [Wed, 18 Jul 2007 04:51:57 +0000 (04:51 +0000)]
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

16 years agoFix this test to not rely on the path but to use the
Reid Spencer [Wed, 18 Jul 2007 04:37:24 +0000 (04:37 +0000)]
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

16 years agoThe property is svn:executable not svn:execute.
Reid Spencer [Wed, 18 Jul 2007 04:26:05 +0000 (04:26 +0000)]
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

16 years agoAlphabetize. Document -mlimit parameter.
Nick Lewycky [Wed, 18 Jul 2007 04:24:20 +0000 (04:24 +0000)]
Alphabetize. Document -mlimit parameter.

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@39990 91177308-0d34-0410-b5e6-96231b3b80d8

16 years agoTurn on FastDSE by default.
Owen Anderson [Tue, 17 Jul 2007 21:59:21 +0000 (21:59 +0000)]
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

16 years agoFold prologue esp update when possible.
Evan Cheng [Tue, 17 Jul 2007 21:26:42 +0000 (21:26 +0000)]
Fold prologue esp update when possible.

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@39984 91177308-0d34-0410-b5e6-96231b3b80d8

16 years agosupport poolalloc as checked out from svn
Andrew Lenharth [Tue, 17 Jul 2007 20:37:35 +0000 (20:37 +0000)]
support poolalloc as checked out from svn

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@39983 91177308-0d34-0410-b5e6-96231b3b80d8

16 years agoChange sroa threshold back.
Evan Cheng [Tue, 17 Jul 2007 20:07:21 +0000 (20:07 +0000)]
Change sroa threshold back.

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@39980 91177308-0d34-0410-b5e6-96231b3b80d8

16 years agoDead code.
Evan Cheng [Tue, 17 Jul 2007 20:01:19 +0000 (20:01 +0000)]
Dead code.

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@39979 91177308-0d34-0410-b5e6-96231b3b80d8

16 years agoMake sure not to break eh_return.
Evan Cheng [Tue, 17 Jul 2007 18:40:47 +0000 (18:40 +0000)]
Make sure not to break eh_return.

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@39978 91177308-0d34-0410-b5e6-96231b3b80d8

16 years agoUpdate.
Evan Cheng [Tue, 17 Jul 2007 18:39:45 +0000 (18:39 +0000)]
Update.

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@39977 91177308-0d34-0410-b5e6-96231b3b80d8

16 years agoFix test.
Evan Cheng [Tue, 17 Jul 2007 18:16:09 +0000 (18:16 +0000)]
Fix test.

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@39976 91177308-0d34-0410-b5e6-96231b3b80d8

16 years agoDon't use * in XFAIL line unless you want it to XFAIL on everything. I don't believe...
Tanya Lattner [Tue, 17 Jul 2007 18:08:32 +0000 (18:08 +0000)]
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

16 years agoMissed the case where alloca is used but the stack size (not including callee-saved...
Evan Cheng [Tue, 17 Jul 2007 18:03:34 +0000 (18:03 +0000)]
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

16 years agodetect invalid combination of sret and byval
Rafael Espindola [Tue, 17 Jul 2007 13:34:23 +0000 (13:34 +0000)]
detect invalid combination of sret and byval

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@39971 91177308-0d34-0410-b5e6-96231b3b80d8

16 years agoXFAIL these on sparc-solaris
Gabor Greif [Tue, 17 Jul 2007 10:25:31 +0000 (10:25 +0000)]
XFAIL these on sparc-solaris

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@39969 91177308-0d34-0410-b5e6-96231b3b80d8

16 years agoUse push / pop for prologues and epilogues.
Evan Cheng [Tue, 17 Jul 2007 07:59:08 +0000 (07:59 +0000)]
Use push / pop for prologues and epilogues.

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@39967 91177308-0d34-0410-b5e6-96231b3b80d8

16 years agoMake use of the process_builder_args library function.
Reid Spencer [Tue, 17 Jul 2007 07:17:02 +0000 (07:17 +0000)]
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

16 years agoFor PR1558:
Reid Spencer [Tue, 17 Jul 2007 06:20:38 +0000 (06:20 +0000)]
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

16 years agono email addrs in file headers
Chris Lattner [Tue, 17 Jul 2007 05:56:43 +0000 (05:56 +0000)]
no email addrs in file headers

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@39962 91177308-0d34-0410-b5e6-96231b3b80d8

16 years agoUnbreak the build by putting calls to free into the implementation file and
Reid Spencer [Tue, 17 Jul 2007 02:16:12 +0000 (02:16 +0000)]
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

16 years agoTemporarily set SROA threshold to 512.
Evan Cheng [Tue, 17 Jul 2007 01:52:05 +0000 (01:52 +0000)]
Temporarily set SROA threshold to 512.

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@39950 91177308-0d34-0410-b5e6-96231b3b80d8

16 years agoTake advantage of undefined behavior if the source program tries to GEP
Owen Anderson [Mon, 16 Jul 2007 23:34:39 +0000 (23:34 +0000)]
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

16 years agoNormally, we don't want to install and we only need to build tools.
Reid Spencer [Mon, 16 Jul 2007 23:25:52 +0000 (23:25 +0000)]
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

16 years agoNo, we're not looking for a directory named /config.status.
Reid Spencer [Mon, 16 Jul 2007 22:54:42 +0000 (22:54 +0000)]
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

16 years agoIn ModuleInfo.txt, make sure that the script being executed can be
Reid Spencer [Mon, 16 Jul 2007 22:25:13 +0000 (22:25 +0000)]
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

16 years agoPrepare for the future when llvm doesn't depend on llvm-gcc-4-0.
Reid Spencer [Mon, 16 Jul 2007 22:11:02 +0000 (22:11 +0000)]
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

16 years agoRemove insignificant test no longer needed.
Reid Spencer [Mon, 16 Jul 2007 22:03:36 +0000 (22:03 +0000)]
Remove insignificant test no longer needed.

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@39931 91177308-0d34-0410-b5e6-96231b3b80d8

16 years agoAdd support for walking up memory def chains, which enables finding many more
Owen Anderson [Mon, 16 Jul 2007 21:52:50 +0000 (21:52 +0000)]
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

16 years agoUse realloc() to (potentially) resize the contents of SmallPtrSet in place.
Owen Anderson [Mon, 16 Jul 2007 21:27:44 +0000 (21:27 +0000)]
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

16 years agoReturn Undef if the block has no dominator. This was required to allow
Reid Spencer [Mon, 16 Jul 2007 21:03:44 +0000 (21:03 +0000)]
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

16 years agoUse ConstantFoldFP for folding all unary floating-point operations which may
Dan Gohman [Mon, 16 Jul 2007 15:26:22 +0000 (15:26 +0000)]
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

16 years agoFix the documentation for llvm.sqrt so that sqrt(0) has defined behavior,
Dan Gohman [Mon, 16 Jul 2007 14:37:41 +0000 (14:37 +0000)]
Fix the documentation for llvm.sqrt so that sqrt(0) has defined behavior,
which appears to be the intent.

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@39922 91177308-0d34-0410-b5e6-96231b3b80d8

16 years agoFix comments about vectors to use the current wording.
Dan Gohman [Mon, 16 Jul 2007 14:29:03 +0000 (14:29 +0000)]
Fix comments about vectors to use the current wording.

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@39921 91177308-0d34-0410-b5e6-96231b3b80d8

16 years agoRemove the trailing semicolon from function declarations in LLVM,
Dan Gohman [Mon, 16 Jul 2007 13:37:30 +0000 (13:37 +0000)]
Remove the trailing semicolon from function declarations in LLVM,
where it's interpreted as a comment, not part of the syntax.

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@39920 91177308-0d34-0410-b5e6-96231b3b80d8

16 years agoFix validation errors
Bill Wendling [Mon, 16 Jul 2007 08:52:56 +0000 (08:52 +0000)]
Fix validation errors

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@39917 91177308-0d34-0410-b5e6-96231b3b80d8

16 years agoClean up some formatting
Bill Wendling [Mon, 16 Jul 2007 08:46:40 +0000 (08:46 +0000)]
Clean up some formatting

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@39916 91177308-0d34-0410-b5e6-96231b3b80d8

16 years agoClean up some formatting. Add some doc_code div tags.
Bill Wendling [Mon, 16 Jul 2007 08:44:39 +0000 (08:44 +0000)]
Clean up some formatting. Add some doc_code div tags.

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@39915 91177308-0d34-0410-b5e6-96231b3b80d8

16 years agoPrepare for building from llvm-top. Unfortunately, this doesn't work because
Reid Spencer [Mon, 16 Jul 2007 08:05:18 +0000 (08:05 +0000)]
Prepare for building from llvm-top. Unfortunately, this doesn't work because
of the cyclic depndency between llvm and llvm-gcc-4-0.

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@39910 91177308-0d34-0410-b5e6-96231b3b80d8

16 years agoRepair a regression in Transforms/InstCombine/mul.ll that Reid noticed.
Chris Lattner [Mon, 16 Jul 2007 04:15:34 +0000 (04:15 +0000)]
Repair a regression in Transforms/InstCombine/mul.ll that Reid noticed.

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@39896 91177308-0d34-0410-b5e6-96231b3b80d8

16 years agorename function to avoid llvm-upgrade warning
Chris Lattner [Mon, 16 Jul 2007 04:09:00 +0000 (04:09 +0000)]
rename function to avoid llvm-upgrade warning

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@39895 91177308-0d34-0410-b5e6-96231b3b80d8

16 years agoStart adding and cleaning up comments.
Nick Lewycky [Mon, 16 Jul 2007 02:58:37 +0000 (02:58 +0000)]
Start adding and cleaning up comments.

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@39894 91177308-0d34-0410-b5e6-96231b3b80d8

16 years agoHandle decrementing loops properly. Fixes PR1533.
Nick Lewycky [Mon, 16 Jul 2007 02:08:00 +0000 (02:08 +0000)]
Handle decrementing loops properly. Fixes PR1533.

Always pass the constant as the second parameter to HowManyLessThans.

Remove obsolete "isSigned" parameter.

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@39893 91177308-0d34-0410-b5e6-96231b3b80d8

16 years agoadd a helper method.
Chris Lattner [Sun, 15 Jul 2007 23:32:03 +0000 (23:32 +0000)]
add a helper method.

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@39885 91177308-0d34-0410-b5e6-96231b3b80d8

16 years agonew testcase
Chris Lattner [Sun, 15 Jul 2007 22:30:34 +0000 (22:30 +0000)]
new testcase

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@39882 91177308-0d34-0410-b5e6-96231b3b80d8

16 years agoImplement shift-simplify.ll:test[45].
Chris Lattner [Sun, 15 Jul 2007 20:54:51 +0000 (20:54 +0000)]
Implement shift-simplify.ll:test[45].

First teach instcombine that sign bit checks only demand the
sign bit, this allows simplify demanded bits to hack on
expressions better.

Second, teach instcombine that ashr is useless if only the
sign bit is demanded.

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@39880 91177308-0d34-0410-b5e6-96231b3b80d8

16 years agoImplement shift-simplify.ll:test3, turning:
Chris Lattner [Sun, 15 Jul 2007 20:42:37 +0000 (20:42 +0000)]
Implement shift-simplify.ll:test3, turning:
(X << 31) <s 0  --> (X&1) != 0

This happens dozens of times in the CFE.

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@39879 91177308-0d34-0410-b5e6-96231b3b80d8

16 years agoClarify the language. Pointed out by Duncan Sands.
Nick Lewycky [Sat, 14 Jul 2007 17:41:03 +0000 (17:41 +0000)]
Clarify the language. Pointed out by Duncan Sands.

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@39857 91177308-0d34-0410-b5e6-96231b3b80d8

16 years agoFix the build. Patch from Holger Schurig.
Nick Lewycky [Sat, 14 Jul 2007 15:11:14 +0000 (15:11 +0000)]
Fix the build. Patch from Holger Schurig.

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@39856 91177308-0d34-0410-b5e6-96231b3b80d8

16 years agoLong live the exception handling!
Anton Korobeynikov [Sat, 14 Jul 2007 14:06:15 +0000 (14:06 +0000)]
Long live the exception handling!

This patch fills the last necessary bits to enable exceptions
handling in LLVM. Currently only on x86-32/linux.

In fact, this patch adds necessary intrinsics (and their lowering) which
represent really weird target-specific gcc builtins used inside unwinder.

After corresponding llvm-gcc patch will land (easy) exceptions should be
more or less workable. However, exceptions handling support should not be
thought as 'finished': I expect many small and not so small glitches
everywhere.

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@39855 91177308-0d34-0410-b5e6-96231b3b80d8

16 years agoUse maximal intersection algorithm exclusively. Fixes miscompile bug.
Nick Lewycky [Sat, 14 Jul 2007 04:28:04 +0000 (04:28 +0000)]
Use maximal intersection algorithm exclusively. Fixes miscompile bug.

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@39852 91177308-0d34-0410-b5e6-96231b3b80d8

16 years agoAdd alternate ConstantRange intersection algorithm.
Nick Lewycky [Sat, 14 Jul 2007 02:51:34 +0000 (02:51 +0000)]
Add alternate ConstantRange intersection algorithm.

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@39851 91177308-0d34-0410-b5e6-96231b3b80d8

16 years agoAdded test case from PR1540.
Evan Cheng [Fri, 13 Jul 2007 23:57:33 +0000 (23:57 +0000)]
Added test case from PR1540.

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@39845 91177308-0d34-0410-b5e6-96231b3b80d8

16 years agoMake LCSSA a loop pass.
Devang Patel [Fri, 13 Jul 2007 23:57:11 +0000 (23:57 +0000)]
Make LCSSA a loop pass.

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@39844 91177308-0d34-0410-b5e6-96231b3b80d8

16 years agoFix for PR1540: Specify F0, F1 are sub-registers of D0, etc.
Evan Cheng [Fri, 13 Jul 2007 23:55:50 +0000 (23:55 +0000)]
Fix for PR1540: Specify F0, F1 are sub-registers of D0, etc.

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@39843 91177308-0d34-0410-b5e6-96231b3b80d8

16 years agoHandle GEPs with all-zero indices in the same way we handle pointer-pointer bitcasts...
Owen Anderson [Fri, 13 Jul 2007 22:50:48 +0000 (22:50 +0000)]
Handle GEPs with all-zero indices in the same way we handle pointer-pointer bitcasts. Also, fix a potentia infinite loop.

This brings FastDSE to parity with old DSE on 175.vpr.

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@39839 91177308-0d34-0410-b5e6-96231b3b80d8

16 years agoDisable claims to preserve analysis until open issues are resolved.
Devang Patel [Fri, 13 Jul 2007 21:53:42 +0000 (21:53 +0000)]
Disable claims to preserve analysis until open issues are resolved.

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@39834 91177308-0d34-0410-b5e6-96231b3b80d8

16 years agoEliminate an unused parameter.
Dan Gohman [Fri, 13 Jul 2007 20:16:50 +0000 (20:16 +0000)]
Eliminate an unused parameter.

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@39828 91177308-0d34-0410-b5e6-96231b3b80d8

16 years agoFix the comment for LegalizeOp to more accurately reflect what it does.
Dan Gohman [Fri, 13 Jul 2007 20:14:11 +0000 (20:14 +0000)]
Fix the comment for LegalizeOp to more accurately reflect what it does.

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@39827 91177308-0d34-0410-b5e6-96231b3b80d8

16 years agoremove obsolete note
Chris Lattner [Fri, 13 Jul 2007 20:08:19 +0000 (20:08 +0000)]
remove obsolete note

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@39825 91177308-0d34-0410-b5e6-96231b3b80d8

16 years agoDon't call SimplifyVBinOp for non-vector operations, following earlier review
Dan Gohman [Fri, 13 Jul 2007 20:03:40 +0000 (20:03 +0000)]
Don't call SimplifyVBinOp for non-vector operations, following earlier review
feedback. This theoretically makes the common (scalar) case more efficient.

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@39823 91177308-0d34-0410-b5e6-96231b3b80d8

16 years agofix some bugs in the manual
Chris Lattner [Fri, 13 Jul 2007 20:01:46 +0000 (20:01 +0000)]
fix some bugs in the manual

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@39822 91177308-0d34-0410-b5e6-96231b3b80d8

16 years agoBe more aggressive in removing dead stores, and in removing instructions trivially...
Owen Anderson [Fri, 13 Jul 2007 18:26:26 +0000 (18:26 +0000)]
Be more aggressive in removing dead stores, and in removing instructions trivially dead after DSE.
This drastically improves the effect of FastDSE on kimwitu++.

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@39819 91177308-0d34-0410-b5e6-96231b3b80d8

16 years agoModify previous patch per review comments.
Dale Johannesen [Fri, 13 Jul 2007 17:31:29 +0000 (17:31 +0000)]
Modify previous patch per review comments.

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@39817 91177308-0d34-0410-b5e6-96231b3b80d8

16 years agoSkeleton of post-RA scheduler; doesn't do anything yet.
Dale Johannesen [Fri, 13 Jul 2007 17:13:54 +0000 (17:13 +0000)]
Skeleton of post-RA scheduler; doesn't do anything yet.
Change name of -sched option and DEBUG_TYPE to
pre-RA-sched; adjust testcases.

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@39816 91177308-0d34-0410-b5e6-96231b3b80d8

16 years agoFix CodeGen/Generic/print-arith-fp.ll on sparc (PR1551)
Chris Lattner [Fri, 13 Jul 2007 16:24:10 +0000 (16:24 +0000)]
Fix CodeGen/Generic/print-arith-fp.ll on sparc (PR1551)

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@39813 91177308-0d34-0410-b5e6-96231b3b80d8

16 years agothese tests do not need a triple on Solaris. Thanks sabre!
Gabor Greif [Fri, 13 Jul 2007 10:08:18 +0000 (10:08 +0000)]
these tests do not need a triple on Solaris. Thanks sabre!

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@39803 91177308-0d34-0410-b5e6-96231b3b80d8

16 years agoRegenerate to pick up Gabor's changes.
Reid Spencer [Fri, 13 Jul 2007 10:05:30 +0000 (10:05 +0000)]
Regenerate to pick up Gabor's changes.

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@39802 91177308-0d34-0410-b5e6-96231b3b80d8

16 years agoSet the mime-type of this file to text/plain because (silly) SVN
Reid Spencer [Fri, 13 Jul 2007 10:02:45 +0000 (10:02 +0000)]
Set the mime-type of this file to text/plain because (silly) SVN
doesn't know that application/x-sh is text.

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@39801 91177308-0d34-0410-b5e6-96231b3b80d8

16 years ago* llvm.spec.in: update blurb
Gabor Greif [Fri, 13 Jul 2007 09:48:29 +0000 (09:48 +0000)]
* llvm.spec.in: update blurb
* autoconf/AutoRegen.sh: use variables for autofoo versions
* autoconf/configure.ac: test for some more functions
                         that are not guaranteed on solaris

Note: the svn:mime-type of autoconf/AutoRegen.sh
      should be set to something that allows for
text compares using svn diff

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@39800 91177308-0d34-0410-b5e6-96231b3b80d8

16 years agoReimplement removing stores to allocas at the end of a function. This should be...
Owen Anderson [Thu, 12 Jul 2007 21:41:30 +0000 (21:41 +0000)]
Reimplement removing stores to allocas at the end of a function.  This should be safe now.

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@39790 91177308-0d34-0410-b5e6-96231b3b80d8

16 years agoMake the condition-checking for free with non-trivial dependencies more correct.
Owen Anderson [Thu, 12 Jul 2007 18:08:51 +0000 (18:08 +0000)]
Make the condition-checking for free with non-trivial dependencies more correct.

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@39789 91177308-0d34-0410-b5e6-96231b3b80d8