Chris Lattner
9492af43c4
New testcase that instcombine should help out with.
...
llvm-svn: 15023
2004-07-20 01:47:49 +00:00
Chris Lattner
5823ac1c21
Implement SimplifyCFG/BrUnwind.ll
...
llvm-svn: 15022
2004-07-20 01:17:38 +00:00
Chris Lattner
d4cecb9e2f
test that unconditional branches to unwinds are always eliminated
...
llvm-svn: 15021
2004-07-20 01:17:19 +00:00
Misha Brukman
5e744fa1a3
Move handing of GlobalValues from getReg() to copyConstantToRegister(), this
...
will avoid extra register-to-register copies. Thanks to Chris for the idea.
llvm-svn: 15019
2004-07-20 00:59:38 +00:00
Chris Lattner
4e2dbc6b4a
Rewrite cast->cast elimination code completely based on the information we
...
actually care about. Someday when the cast instruction is gone, we can do
better here, but this will do for now. This implements
instcombine/cast.ll:test17/18 as well.
llvm-svn: 15018
2004-07-20 00:59:32 +00:00
Chris Lattner
10a4194651
Testcases missed by the instruction combiner
...
llvm-svn: 15017
2004-07-20 00:57:21 +00:00
Misha Brukman
d21ef91bc4
isupper() and tolower() are declared in <ctype.h>
...
llvm-svn: 15016
2004-07-20 00:52:16 +00:00
Misha Brukman
22802cc6cd
* Fn args passed in registers are now recorded as used by the call instruction
...
`-> asm printer updated to not print out those registers with the call instr
All of Shootout tests now work. Great thanks to Nate Begeman for the patch!
llvm-svn: 15015
2004-07-20 00:42:19 +00:00
Misha Brukman
818a9dc317
* cFP class split into cFP32 and cFP64
...
* Fn args passed in registers are now recorded as used by the call instruction
`-> asm printer updated to not print out those registers with the call instr
* Stack frame layout in prolog/epilog fixed, spills and vararg fns now work
* float/double to signed int codegen now correct
* various single precision float codegen bugs fixed
* const integer multiply codegen fixed
* select and setcc blocks inserted into the correct place in machine CFG
* load of integer constant code optimized
All of Shootout tests now work. Great thanks to Nate Begeman for the patch!
llvm-svn: 15014
2004-07-20 00:41:46 +00:00
Chris Lattner
f8cf35855a
While I'm at it, don't break codegen of mul by 3,5,9.
...
llvm-svn: 15013
2004-07-19 23:50:57 +00:00
Chris Lattner
7c06d44f42
Generate better code for multiplies by negative constants like -4, -1, -9, etc.
...
llvm-svn: 15012
2004-07-19 23:47:21 +00:00
Alkis Evlogimenos
12a71ea03e
Remove dead code.
...
llvm-svn: 15011
2004-07-19 23:35:55 +00:00
Misha Brukman
8e677e88f6
Tabs to spaces.
...
llvm-svn: 15010
2004-07-19 21:22:02 +00:00
Misha Brukman
a270467ceb
Convert tabs to spaces; fix name of function in assert() description.
...
llvm-svn: 15009
2004-07-19 21:11:45 +00:00
Chris Lattner
8a92e19ba1
Fix broken link
...
llvm-svn: 15008
2004-07-19 19:30:40 +00:00
Chris Lattner
c88858f576
Just run 'make', not all-gcc
...
llvm-svn: 15007
2004-07-19 18:47:59 +00:00
John Criswell
b92c7c2270
Added support for stdint.h. It is now automatically included by
...
DataTypes.h. So far, it doesn't seem to break Linux, Solaris, or MacOS X.
This should automatically include it for those people who need it.
llvm-svn: 15006
2004-07-19 16:12:29 +00:00
Chris Lattner
15dfdb4e01
Fix a bug that occurs when the last instruction in a range is dead
...
llvm-svn: 15005
2004-07-19 15:16:53 +00:00
Chris Lattner
c8fb1fb5bb
When joining intervals, join intervals in deeply nested loops first. This
...
is a simple change, but seems to improve code a little. For example, on
256.bzip2, we went from 75.0s -> 73.33s (2% speedup).
llvm-svn: 15004
2004-07-19 14:40:29 +00:00
Chris Lattner
d10d373ce9
Split joinIntervals into two methods
...
llvm-svn: 15003
2004-07-19 14:08:10 +00:00
Chris Lattner
6345fbe820
Fix comment
...
llvm-svn: 15002
2004-07-19 13:28:39 +00:00
Reid Spencer
82e7fe5b5b
bug 122:
...
Simplify a conditional operator for a constant result from
GV->isNullValue()
llvm-svn: 15001
2004-07-19 13:25:02 +00:00
Chris Lattner
57ca7382d9
Inline 4 methods
...
llvm-svn: 15000
2004-07-19 07:52:35 +00:00
Chris Lattner
056ee8a0a5
Delete 4 methods, make clients use hte mark* methods directly
...
llvm-svn: 14999
2004-07-19 07:52:25 +00:00
Chris Lattner
aef6c2a350
There is no need to store the MBB along with the MI any more, we can now
...
ask instructions for their parent.
llvm-svn: 14998
2004-07-19 07:04:55 +00:00
Chris Lattner
a74cf5a7d9
Simplify the interface to LiveVariables::addVirtualRegister(Killed|Dead)
...
llvm-svn: 14997
2004-07-19 06:55:21 +00:00
Chris Lattner
5027de35ed
Remove the DefBlock element of VarInfo. DefBlock is always DefInst->getParent()
...
llvm-svn: 14996
2004-07-19 06:26:50 +00:00
Chris Lattner
46c48a9654
Err, fix last checkin
...
llvm-svn: 14995
2004-07-19 06:03:51 +00:00
Chris Lattner
874ffdd592
Fix bugpoint miscompilation support on OS/X
...
Patch contributed by the fabulous Nate Begeman.
llvm-svn: 14994
2004-07-19 06:00:17 +00:00
Chris Lattner
a618e13c83
Two changes, both very significant:
...
* vreg <-> vreg joining now works, enable it unconditionally when joining
is enabled (which is the default).
* Fix a serious pessimization of spill code where we were saying that a
spilled DEF operand was live into the subsequent instruction. This allows
for substantially better code when spilling starts to happen.
llvm-svn: 14993
2004-07-19 05:55:50 +00:00
Chris Lattner
c56f90d156
See comments. The live intervals were not coming out of the spiller in sorted
...
order, causing the inactive list in the linearscan list to get unsorted, which
basically fuxored everything up severely.
These seems to fix the joiner, so with more testing I will enable it by default.
llvm-svn: 14992
2004-07-19 05:15:10 +00:00
Chris Lattner
8c8144b958
Fix assertion to not dereference end!
...
llvm-svn: 14991
2004-07-19 05:02:09 +00:00
Chris Lattner
70f8dca59b
Add some asserts that the list of intervals returned by addIntervalsForSpills
...
is sorted. This is not the case currently, which is causing no end of
problems.
llvm-svn: 14990
2004-07-19 04:47:36 +00:00
Chris Lattner
4f2e2a3f80
remove the mbbi2mbbMap_, which was just keeping track of mbb order anyway.
...
Heavily refactor handleVirtualRegisterDef, adding comments and making it more
efficient. It is also much easier to follow and convince ones self that it is
correct :)
Add -debug output to the joine, showing the result of joining the intervals.
llvm-svn: 14989
2004-07-19 02:15:56 +00:00
Chris Lattner
05920e7a70
fill comment to 80 cols
...
remove map that is not needed
llvm-svn: 14988
2004-07-19 02:13:59 +00:00
Chris Lattner
5230e70834
classof implementations are now inlined
...
llvm-svn: 14987
2004-07-19 00:59:10 +00:00
Chris Lattner
370f8871a6
inline classof implementations, eliminate use of virtual methods.
...
classof<ConstantXXX> is now MUCH faster than it used to be.
llvm-svn: 14986
2004-07-19 00:58:47 +00:00
Chris Lattner
1f46ad5a2d
eliminate isConstantExpr, changes to isa<Constant> implementation
...
llvm-svn: 14985
2004-07-19 00:58:02 +00:00
Chris Lattner
afde969989
Add new enum entries for ConstantAggregateZeroVal/ConstantExprVal and
...
rename ConstantVal to SimpleConstantVal
llvm-svn: 14984
2004-07-19 00:57:40 +00:00
Chris Lattner
2730e6aef1
Method now returns null, dtor is inlined
...
llvm-svn: 14983
2004-07-19 00:55:35 +00:00
Chris Lattner
d20f27064b
Change method to return void. Inline dtor
...
llvm-svn: 14982
2004-07-19 00:55:19 +00:00
Chris Lattner
1bfcb28da4
Remove dead file
...
llvm-svn: 14981
2004-07-18 23:44:15 +00:00
Chris Lattner
421cd083d6
Remove this printer
...
llvm-svn: 14980
2004-07-18 23:43:34 +00:00
Reid Spencer
44a81c6bdd
A description of what this library is about, reference to the documentation
...
and a list of don'ts for the library. All so future maintainers don't
break the important contract this library has with its user: LLVM.
llvm-svn: 14979
2004-07-18 22:33:08 +00:00
Chris Lattner
e0050f06b0
Add note about GCC 3.3.2 being completely broken
...
llvm-svn: 14978
2004-07-18 22:32:22 +00:00
Reid Spencer
9673fb744c
Initiali Makefile for this library.
...
llvm-svn: 14977
2004-07-18 22:31:28 +00:00
Chris Lattner
13e5831bd0
Add a workaround for a GCC 3.3.2 bug
...
llvm-svn: 14976
2004-07-18 21:56:20 +00:00
Chris Lattner
517f1847ba
Doesn't exist
...
llvm-svn: 14975
2004-07-18 21:44:13 +00:00
Chris Lattner
e2774757fe
Fix a performance regression from the CPR patch, simplify code
...
llvm-svn: 14974
2004-07-18 21:34:16 +00:00
Chris Lattner
d47504d9db
Strip out and simplify some code. This also fixes the regression last
...
night compiling cfrac. It did not realize that code like this:
int G; int *H = &G;
takes the address of G.
llvm-svn: 14973
2004-07-18 19:56:20 +00:00