Chris Lattner
0a276257ae
Add support for the new varargs intrinsics
...
llvm-svn: 9224
2003-10-18 05:56:40 +00:00
Chris Lattner
f2ed60c0b7
Decrease usage of use_size()
...
llvm-svn: 9135
2003-10-15 16:48:29 +00:00
Misha Brukman
868eac95dd
Fix spelling.
...
llvm-svn: 9027
2003-10-10 17:57:28 +00:00
Chris Lattner
fc3f9605a7
Instead of hacking in custom support for Invoke/Unwind, use the LowerInvoke pass
...
llvm-svn: 8871
2003-10-05 19:15:47 +00:00
Chris Lattner
e8ae7bf114
Eliminate support for the llvm.unwind intrinisic, using the Unwind instruction instead
...
llvm-svn: 8411
2003-09-08 19:44:26 +00:00
Chris Lattner
4ad8720f91
Add support for the unwind instruction
...
llvm-svn: 8408
2003-09-08 18:54:55 +00:00
Chris Lattner
062cc9d341
Add support for the llvm.unwind intrinsic, which we codegen to just do an abort
...
until we implement unwinding.
Add support for the invoke instruction, which codegens just like a call with
a branch after it.
The end effect of this change is that programs using the invoke instruction,
but never unwinding, will work fine. Programs that unwind will abort until
we get unwind support.
llvm-svn: 8187
2003-08-28 21:23:43 +00:00
Chris Lattner
d627d84e23
Implement: Jello/test-constantexpr.ll
...
llvm-svn: 8127
2003-08-24 19:19:47 +00:00
Chris Lattner
f54b131a49
Add support for the sig(set|long)jmp intrinsics
...
llvm-svn: 7951
2003-08-18 16:06:09 +00:00
Brian Gaeke
77c65be59e
Factory methods for FunctionPasses now return type FunctionPass *.
...
llvm-svn: 7823
2003-08-13 18:18:15 +00:00
Chris Lattner
17fc21b5fa
This is the real fix for the previous register allocator problem.
...
Physical registers should not float around.
llvm-svn: 7587
2003-08-05 00:48:47 +00:00
Chris Lattner
15891a50c1
Fix Bug: test/Regression/Jello/2003-08-03-CallArgLiveRanges.llx
...
llvm-svn: 7558
2003-08-04 02:12:48 +00:00
Chris Lattner
cf28d0f799
Use target specific interface instead of forcing it to be target-generic
...
llvm-svn: 7413
2003-07-30 05:33:48 +00:00
Chris Lattner
40cc4c1392
Rename function to be more consistent with filename
...
llvm-svn: 7352
2003-07-26 23:49:58 +00:00
Chris Lattner
b92653f037
If the pass changes _anything_ it must return true
...
llvm-svn: 7344
2003-07-26 23:05:37 +00:00
Chris Lattner
6ad460b336
Simplify code by using ConstantInt::getRawValue instead of checking to see
...
whether the constant is signed or unsigned, then casting
llvm-svn: 7252
2003-07-23 15:22:26 +00:00
Brian Gaeke
bf46d75365
Please, save your applause^H^H^H^H^H^H^H^Hflames for the end...
...
Avoid a fall-through in the (stubby) treatment of the longjmp intrinsic
call which causes llc & lli to core-dump.
Add a sort-of treatment of cast double to ulong. I am not really sure
what a user should expect to see upon casting a negative FP value to
unsigned long long. But with what is given here, I was able to write
a program that could cast -123.456 to ulong and back and get -123.0,
which seems like a step in the right direction. GCC seems to give you
0. I don't know if I'd consider that useful.
These cases were coming up in GNU coreutils-5.0.
llvm-svn: 7205
2003-07-18 20:23:43 +00:00
Brian Gaeke
638e6ef31c
Use getClassB for load and store; we don't want to abort when we
...
try to load or store through a bool*.
llvm-svn: 7195
2003-07-17 21:30:06 +00:00
Chris Lattner
d212141d9e
Setjmp should always return zero if we don't implement longjmp. This avoids
...
leaving trash in the register, fixing anagram
llvm-svn: 7013
2003-06-30 19:35:54 +00:00
Chris Lattner
6b31a873ee
Until there is a setjmp/longjmp transformation pass, codegen setjmp as a noop
...
and longjmp as an abort!
llvm-svn: 6977
2003-06-29 16:42:32 +00:00
Chris Lattner
38b7729915
Do not use the inefficient, fixed function, CBW, CDQ, ... instructions
...
llvm-svn: 6844
2003-06-22 03:31:18 +00:00
Chris Lattner
7fb273d416
Minor simplification to 64-bit instsel
...
llvm-svn: 6831
2003-06-21 18:15:27 +00:00
Chris Lattner
2840a1b4ee
For 16 and 32-bit multiplies, use the IMUL instruction instead of the MUL instruction.
...
This allows us to not force the use of the EAX/AX registers!
llvm-svn: 6830
2003-06-21 17:16:58 +00:00
Chris Lattner
4a8d96567f
Generate code for LONG indexes to getelementptr instructions more efficiently
...
llvm-svn: 6828
2003-06-21 16:01:24 +00:00
Chris Lattner
6a3d2fc70e
Implement generation of cmp R, C to not use an extra register
...
llvm-svn: 6627
2003-06-05 19:30:30 +00:00
Chris Lattner
ee044c3179
Special case simple binary operator X op C
...
This avoid generating a register to hold C, which in turn speeds up the
register allocator by a lot: ~9% on 164.gzip and ~17% on 256.bzip2. This
also speeds up other passes. This also speeds up execution of the program
marginally, and makes the asm much easier to read. :)
llvm-svn: 6626
2003-06-05 18:28:55 +00:00
Chris Lattner
1cb899dd19
Remove usage of typedef
...
llvm-svn: 6583
2003-06-03 15:41:58 +00:00
Chris Lattner
bf8929c4bb
* Implement cast (long|ulong) to bool
...
* Fix cast of (short|ushort|int|uint) to bool to work right
llvm-svn: 6510
2003-06-01 03:38:24 +00:00
Chris Lattner
92eb5bbb15
Add support for shl and shr for 64 bit integer types
...
llvm-svn: 6499
2003-06-01 01:56:54 +00:00
Chris Lattner
f365fdec06
Clean up #includes
...
llvm-svn: 6173
2003-05-13 20:21:19 +00:00
Chris Lattner
19ca50fe2a
Make abort more explicit
...
llvm-svn: 6151
2003-05-12 21:16:26 +00:00
Chris Lattner
f1a6a1fde1
Remove the assertion failure of course... doh
...
llvm-svn: 6150
2003-05-12 20:39:39 +00:00
Chris Lattner
ed3b3d7c99
Implement casts from unsigned integers to floating point
...
llvm-svn: 6148
2003-05-12 20:36:13 +00:00
Chris Lattner
a9a5cdb2be
Make error messages more useful than jsut an abort
...
llvm-svn: 6146
2003-05-12 20:16:58 +00:00
Chris Lattner
56f8186e3e
Do not insert multiple initializations for the same value in a PHI node
...
llvm-svn: 6113
2003-05-12 14:22:21 +00:00
Chris Lattner
78f5953056
Add support for Add, Sub, And, Or, & Xor constant exprs
...
llvm-svn: 6049
2003-05-08 20:49:25 +00:00
Chris Lattner
d747f762ff
Add support for variable argument functions!
...
llvm-svn: 6046
2003-05-08 19:44:13 +00:00
Chris Lattner
59c46ee655
IMPLICIT_DEF was not the beautiful elegant solution I thought it was going
...
to be. In fact, it made stuff worse. :(
llvm-svn: 6013
2003-05-07 19:21:28 +00:00
Chris Lattner
54c4b56baf
Emit pseudo instructions to indicate that some registers are live on entrance
...
and exit of the function. This fixes bug: Jello/2003-05-06-LivenessClobber.llx
and the Fhourstones benchmark
llvm-svn: 6010
2003-05-06 21:32:22 +00:00
Misha Brukman
bd9b827093
The Hyphenation-Adding Committee is now in session.
...
llvm-svn: 5986
2003-05-03 02:18:17 +00:00
Chris Lattner
1f7fab6047
Fix bogus assert
...
llvm-svn: 5949
2003-04-25 21:58:54 +00:00
Chris Lattner
6ae5107de6
Fix iterator invalidation problem with cast instructions
...
llvm-svn: 5876
2003-04-23 17:57:48 +00:00
Chris Lattner
c40d8cd8cd
Implement the constantexpr CAST instruction correctly
...
llvm-svn: 5875
2003-04-23 17:22:12 +00:00
Misha Brukman
c06beb4c03
It's "necessary" to spell "necessarily" correctly.
...
llvm-svn: 5833
2003-04-22 17:54:23 +00:00
Chris Lattner
a48a91d095
Add support for a simple constantexpr: cast of one ptr type to another
...
llvm-svn: 5829
2003-04-21 21:33:44 +00:00
Chris Lattner
bf414ca145
Don't emit unneccesary branch instructions!
...
llvm-svn: 5328
2003-01-16 18:07:23 +00:00
Chris Lattner
7455428f21
Implement optimization folding setcc into branch.
...
llvm-svn: 5324
2003-01-16 16:43:00 +00:00
Chris Lattner
013ad21206
Implement code to keep the stack pointer aligned to an 8 byte boundary.
...
This improves the performance of the power benchmark by a few percent.
This will be neccesary for SSE code, which requires 16 byte alignment of
the stack.
llvm-svn: 5320
2003-01-16 02:20:12 +00:00
Chris Lattner
b27d60ccf1
Rename MachineInstrInfo -> TargetInstrInfo
...
llvm-svn: 5272
2003-01-14 22:00:31 +00:00
Chris Lattner
f3989edae2
* Adjust to use new interfaces, eliminating CurReg stuff
...
* Support arbitrary FP constants
* Fix bugs in frame layout for function calls and incoming arguments
* Insert copies for constant arguments to PHI nodes into the BOTTOM of
predecessor blocks, not the top.
* Implement _floating point_ support: setcc, return, load, store, cast
* Fix several bugs in the cast instruction
* Abstract out call emission and load/store for FP
* Implement malloc/free without previous lowering pass.
* Make use of new forms of MachineOperand
* Implement _long_ support!
* Fix many bugs in FP support
* Change branch from je/jne to je/jmp
* Simplify code generated for GEP instructions
llvm-svn: 5223
2003-01-13 00:32:26 +00:00