Owen Anderson
f43ab30bc0
Fix a bug that was causing major slowdowns in povray. This was due to LCSSA
...
not handling PHI nodes correctly when determining if a value was live-out.
This patch reduces the number of detected live-out variables in the testcase
from 6565 to 485.
llvm-svn: 28771
2006-06-13 19:37:18 +00:00
Andrew Lenharth
a903a21a85
It really helps to be returning to the correct place
...
llvm-svn: 28769
2006-06-13 18:27:39 +00:00
Chris Lattner
bbbcb8cceb
Port some bugfixes in shift handling from SimplifyDemandedBits over to
...
ComputeMaskedBits. DemandedMasks and KnownZero/One masks should never have
bits set out of the range of the base datatype.
llvm-svn: 28768
2006-06-13 16:52:37 +00:00
Jim Laskey
422c9a610a
My original test case was bogus. Reverting to crasher case.
...
llvm-svn: 28767
2006-06-13 15:22:49 +00:00
Jim Laskey
7d9997132e
Tests to make sure that ComputeMaskedBits discards bits for shifts.
...
llvm-svn: 28766
2006-06-13 13:10:44 +00:00
Jim Laskey
c9a71e96ae
TargetLowering::ComputeMaskedBits was not clearing reciprocal bits on shifts.
...
llvm-svn: 28765
2006-06-13 13:08:58 +00:00
Evan Cheng
2a0f3b2e79
Cygwin support: use _alloca to allocate stack if > 4k. Patch by Anton Korobeynikov.
...
llvm-svn: 28764
2006-06-13 05:14:44 +00:00
Chris Lattner
05b6364eef
Teach bugpoint to kill optimization passes that run over the timeout limit,
...
which allows it to debug optimizer infinite loops. This patch is contributed
by Nick Lewycky, thanks!
llvm-svn: 28763
2006-06-13 03:10:48 +00:00
Chris Lattner
f04cf06b5a
Decribe the "implementation" keyword.
...
llvm-svn: 28762
2006-06-13 03:05:47 +00:00
Chris Lattner
6f45959365
Gaar! Don't use r11 for CR save/restore, use R0. R11 can be register
...
allocated, thus live across the save/reload. This fixes
llc-beta /MultiSource/Applications/spiff/spiff
llc-beta /MultiSource/Benchmarks/sim/sim:
llc-beta /MultiSource/Benchmarks/Ptrdist/bc/bc
llc-beta /MultiSource/Benchmarks/McCat/12-IOtest/iotest:
llc-beta /MultiSource/Benchmarks/FreeBench/fourinarow/fourinarow
llc-beta /MultiSource/Benchmarks/Fhourstones-3.1/fhourstones3.1
llc-beta /MultiSource/Benchmarks/mediabench/adpcm/rawdaudio/rawdaudio
llc-beta /MultiSource/Benchmarks/mediabench/adpcm/rawcaudio/rawcaudio
llc-beta /MultiSource/Benchmarks/mediabench/g721/g721encode/encode
llc-beta /MultiSource/Benchmarks/mediabench/jpeg/jpeg-6a/cjpeg
and probably others, with -regalloc=local.
llvm-svn: 28761
2006-06-12 23:59:16 +00:00
Chris Lattner
93ed4373c4
Fix spilling and reloading of CR regs to reload the right values. This fixes
...
Olden/power (and probably others) with -regalloc=local.
llvm-svn: 28760
2006-06-12 21:50:57 +00:00
Owen Anderson
276e728e4b
Reapply my 6/9 changes. The bug Evan saw no longer occurs.
...
llvm-svn: 28759
2006-06-12 21:49:21 +00:00
Chris Lattner
649af38df3
Fix an infinite loop on Transforms/SimplifyCFG/2006-06-12-InfLoop.ll
...
llvm-svn: 28758
2006-06-12 20:18:01 +00:00
Chris Lattner
8e718346df
TEstcase that makes simplifycfg infloop.
...
llvm-svn: 28757
2006-06-12 20:17:44 +00:00
Chris Lattner
d1b52e51fa
Add a new -compileflags options, remove old externals location specifiers.
...
People should just use -with-externals.
llvm-svn: 28756
2006-06-12 19:03:17 +00:00
Chris Lattner
2d4ba3f9ca
Make sure to update the CFG correctly if a switch only has a default dest.
...
This fixes CodeGen/Generic/2006-06-12-LowerSwitchCrash.ll
llvm-svn: 28755
2006-06-12 18:25:29 +00:00
Chris Lattner
317d8c2ae3
New testcase that crashes llc
...
llvm-svn: 28754
2006-06-12 18:24:32 +00:00
Andrew Lenharth
fe127f3de7
Let the alpha breakage begin. First Formals and RET. next Calls
...
llvm-svn: 28753
2006-06-12 18:09:24 +00:00
Andrew Lenharth
a2bda5b0e1
Start on my todo list
...
llvm-svn: 28752
2006-06-12 16:07:18 +00:00
Rafael Espindola
bcba226a99
lower more then 4 formal arguments. The offset is currently hard coded.
...
implement SelectFrameIndex
llvm-svn: 28751
2006-06-12 12:28:08 +00:00
Owen Anderson
a947d699dd
Fix for 2006-06-26-MultipleExitsSingleBlock.
...
If a single exit block has multiple predecessors within the loop, it will
appear in the exit blocks list more than once. LCSSA needs to take that into
account so that it doesn't double process that exit block.
llvm-svn: 28750
2006-06-12 07:10:16 +00:00
Owen Anderson
4796bc9bda
Make sure that LCSSA works properly when it encounters an exit block that has
...
more than one predecessor inside the loop.
llvm-svn: 28749
2006-06-12 07:05:47 +00:00
Owen Anderson
15b85dbfa5
Re-commit the safe parts of my 6/9 patch. Still working on fixing the unsafe parts.
...
llvm-svn: 28748
2006-06-11 19:22:28 +00:00
Evan Cheng
d99c8e2e5f
Back out Owen's 6/9 changes. They broke MultiSource/Benchmarks/Prolangs-C/bison (and perhaps others).
...
llvm-svn: 28747
2006-06-11 09:32:57 +00:00
Chris Lattner
d05099f30a
Add a missing assertion that would have helped out Reid
...
llvm-svn: 28746
2006-06-10 04:16:23 +00:00
Chris Lattner
7bc8eae1f0
Work around a nasty tblgen bug where it doesn't add operands for varargs
...
nodes correctly.
llvm-svn: 28745
2006-06-10 01:15:02 +00:00
Chris Lattner
b231c3d11c
Fix a problem exposed by the local allocator. CALL instructions are not marked
...
as using incoming argument registers, so the local allocator would clobber them
between their set and use. To fix this, we give the call instructions a variable
number of uses in the CALL MachineInstr itself, so live variables understands
the live ranges of these register arguments.
llvm-svn: 28744
2006-06-10 01:14:28 +00:00
Chris Lattner
f506d91be6
Wrap to 80 cols
...
llvm-svn: 28743
2006-06-09 23:59:44 +00:00
Chris Lattner
f9bb91746c
After telling GCC to type of the input file with -x asm/-x c, switch back to
...
-x none, to not foul up autodetection of .a file or .dylibs.
llvm-svn: 28741
2006-06-09 21:31:53 +00:00
Evan Cheng
cd37f47980
Don't pull in environ, not always safe. Global variables are bad anyway.
...
Use execve when explicit environment variables ptr is available. Otherwise
just use execv.
llvm-svn: 28740
2006-06-09 20:43:11 +00:00
Owen Anderson
4a0ceb1e6d
Add LCSSA as a requirement for LoopUnswitch, and assert that LoopUnswitch preserves
...
LCSSA.
llvm-svn: 28739
2006-06-09 18:40:32 +00:00
Owen Anderson
6c2f7512a6
Make Loop able to verify that it is in LCSSA-form, and have the LCSSA pass assert
...
on this.
llvm-svn: 28738
2006-06-09 18:33:30 +00:00
Evan Cheng
9e5e585c89
Comments to appease sabre.
...
llvm-svn: 28737
2006-06-09 06:25:10 +00:00
Evan Cheng
8f46dba83d
Minor compilation speed improvement.
...
llvm-svn: 28736
2006-06-09 06:24:42 +00:00
Evan Cheng
6039769dc1
RewriteExpr, either the new PHI node of induction variable or the
...
post-increment value, should be first cast to the appropriated type (to the
type of the common expr). Otherwise, the rewrite of a use based on (common +
iv) may end up with an incorrect type.
llvm-svn: 28735
2006-06-09 00:12:42 +00:00
Owen Anderson
0d9583aa41
Update some comments, and expose LCSSAID in preparation for having other passes
...
require LCSSA.
llvm-svn: 28734
2006-06-08 20:02:53 +00:00
Chris Lattner
a05c244289
Fix X86/inline-asm.ll:test2, a case where an input value was implicitly
...
truncated.
llvm-svn: 28733
2006-06-08 18:27:11 +00:00
Chris Lattner
864081185f
Add new testcase
...
llvm-svn: 28732
2006-06-08 18:26:48 +00:00
Chris Lattner
963fd11359
Fix Regression/CodeGen/X86/inline-asm.ll, a case where inline asm causes
...
implement extension of a register.
llvm-svn: 28731
2006-06-08 18:22:48 +00:00
Chris Lattner
3f67ad5d1d
New testcase, using "AX" as i32.
...
llvm-svn: 28730
2006-06-08 18:20:13 +00:00
Reid Spencer
7451e7b784
Squelch a warning about signed/unsigned.
...
llvm-svn: 28729
2006-06-08 18:08:43 +00:00
Chris Lattner
82b121e762
Add support for "m" inline asm constraints.
...
llvm-svn: 28728
2006-06-08 18:03:49 +00:00
Chris Lattner
8affee249a
Fix an assert-on-inline-inline-asm bug.
...
llvm-svn: 28727
2006-06-08 18:00:47 +00:00
Reid Spencer
aa140d6fef
For PR804:
...
Change the file size field of StatusInfo to be uint64_t instead of size_t
so that we know it is always 64 bits. This prevents some overflow on
systems where size_t is 32 bits when it ought to be 64.
llvm-svn: 28726
2006-06-08 17:00:08 +00:00
Vladimir Prus
01d543c581
Remove dead code.
...
llvm-svn: 28725
2006-06-08 16:03:13 +00:00
Vladimir Prus
5278a7380e
New method BasicBlock::getFirstNonPHI.
...
llvm-svn: 28724
2006-06-08 15:46:18 +00:00
Chris Lattner
89d4612326
This no longer needs plugins, this it doesn't need all of VMCore.
...
llvm-svn: 28723
2006-06-08 00:25:44 +00:00
Reid Spencer
3c338b3803
For PR787:
...
Provide new llvm::sys::Program facilities for converting the stdout and
stdin to binary mode. There is no standard way to do this and the available
mechanisms are platform specific. Adjust the bytecode reader and writer to
use these methods when their input is stdin or output is stdout. THis avoids
the problem with \n writing CRLF to a bytecode file on windows.
Patch Contributed by Michael Smith.
llvm-svn: 28722
2006-06-07 23:18:34 +00:00
Reid Spencer
8077d5bf7f
Shorten a value description so --help out isn't so wide.
...
llvm-svn: 28721
2006-06-07 23:07:51 +00:00
Reid Spencer
c309a17fb7
Make sure this tool links in all of libVMCore.a because it can --load
...
shared objects.
llvm-svn: 28720
2006-06-07 23:06:50 +00:00