Chris Lattner
7150a7038a
Add a new emitAlignment method
...
llvm-svn: 28072
2006-05-03 01:01:51 +00:00
Chris Lattner
77fe5b4459
Simplify some code. Don't add memory blocks to the Blocks list twice.
...
llvm-svn: 28071
2006-05-03 00:54:49 +00:00
Chris Lattner
667a056e11
Add assertions that verify that the actual arguments to a call or invoke match
...
the prototype of the called function.
llvm-svn: 28070
2006-05-03 00:48:22 +00:00
Chris Lattner
d8b192ba3b
Change the BasicBlockAddrs map to be a vector, indexed by MBB number.
...
llvm-svn: 28069
2006-05-03 00:32:55 +00:00
Chris Lattner
0267807ddc
Keep the alpha JIT similar to the PPC/X86 jits
...
llvm-svn: 28068
2006-05-03 00:31:21 +00:00
Jeff Cohen
488a40028e
Keep Visual Studio happy.
...
llvm-svn: 28067
2006-05-03 00:28:50 +00:00
Chris Lattner
0574e47dca
Simplify some code
...
llvm-svn: 28066
2006-05-03 00:13:06 +00:00
Chris Lattner
b8065a9a3a
Several related changes:
...
1. Change several methods in the MachineCodeEmitter class to be pure virtual.
2. Suck emitConstantPool/initJumpTableInfo into startFunction, removing them
from the MachineCodeEmitter interface, and reducing the amount of target-
specific code.
3. Change the JITEmitter so that it allocates constantpools and jump tables
*right* next to the functions that they belong to, instead of in a separate
pool of memory. This makes all memory for a function be contiguous, and
means the JITEmitter only tracks one block of memory now.
llvm-svn: 28065
2006-05-02 23:22:24 +00:00
Chris Lattner
ee1a61810c
Add a method for allocating space from the code buffer.
...
llvm-svn: 28064
2006-05-02 22:51:03 +00:00
Nate Begeman
233391f5f5
Remove some stuff from the README
...
llvm-svn: 28063
2006-05-02 22:43:31 +00:00
Chris Lattner
23621fe8f4
Do not make the JIT memory manager manage the memory for globals. Instead
...
just have the JIT malloc them.
llvm-svn: 28062
2006-05-02 21:57:51 +00:00
Chris Lattner
25b95ed868
Minor cleanups, no functionality change.
...
llvm-svn: 28061
2006-05-02 21:44:14 +00:00
Chris Lattner
e1c96369e2
Fix a purely hypothetical problem (for now): emitWord emits in the host
...
byte format. This doesn't work when using the code emitter in a cross target
environment. Since the code emitter is only really used by the JIT, this
isn't a current problem, but if we ever start emitting .o files, it would be.
llvm-svn: 28060
2006-05-02 19:14:47 +00:00
Chris Lattner
c9aa3715e8
Refactor the machine code emitter interface to pull the pointers for the current
...
code emission location into the base class, instead of being in the derived classes.
This change means that low-level methods like emitByte/emitWord now are no longer
virtual (yaay for speed), and we now have a framework to support growable code
segments. This implements feature request #1 of PR469.
llvm-svn: 28059
2006-05-02 18:27:26 +00:00
Nate Begeman
bbcbf48aab
Since we don't handle callee-save CRs right yet, don't allocate them. Also
...
don't step on R11 in the middle of a function when saving and restoring CRs
llvm-svn: 28058
2006-05-02 17:37:31 +00:00
Nate Begeman
4971ba5f41
Print function number instead of name
...
llvm-svn: 28057
2006-05-02 17:36:46 +00:00
Nate Begeman
287dc5be0d
Hooray, everyone now uses the same printBasicBlockLabel implementation
...
llvm-svn: 28056
2006-05-02 17:34:51 +00:00
Chris Lattner
67a3aa2aaa
Remove dead method
...
llvm-svn: 28055
2006-05-02 17:20:28 +00:00
Chris Lattner
b58f1fa905
Remove a now-dead method
...
llvm-svn: 28054
2006-05-02 17:17:13 +00:00
Chris Lattner
5bc9c583e3
There is no reason to use a virtual method to store this word.
...
llvm-svn: 28053
2006-05-02 17:16:20 +00:00
Chris Lattner
147bc61f6a
Remove the debug machine code emitter. The "FilePrinterEmitter" is moreuseful for debugging.
...
llvm-svn: 28052
2006-05-02 16:59:49 +00:00
Chris Lattner
bb1c345ec6
Remove the debug machine code emitter. The "FilePrinterEmitter" is more
...
useful for debugging.
llvm-svn: 28051
2006-05-02 16:59:24 +00:00
Nate Begeman
b9d4f8324d
Extend printBasicBlockLabel a bit so that it can be used to print all
...
basic block labels, consolidating the code to do so in one place for each
target.
llvm-svn: 28050
2006-05-02 05:37:32 +00:00
Nate Begeman
01364fbba8
Update the PPC compilation callback code to not need weird abi-violating
...
prologs and epilogs, keep all the asm in one place, and remove use of
compiler builtin functions.
llvm-svn: 28049
2006-05-02 04:50:05 +00:00
Chris Lattner
2d3a02725d
Add pass ID's for various passes, so they can be AddRequiredID. Patch by
...
Domagoj Babic!
llvm-svn: 28048
2006-05-02 04:24:36 +00:00
Jeff Cohen
470f431f44
De-virtualize SwitchSection.
...
llvm-svn: 28047
2006-05-02 03:58:45 +00:00
Jeff Cohen
f34ddb1e0d
De-virtualize EmitZeroes.
...
llvm-svn: 28046
2006-05-02 03:46:13 +00:00
Jeff Cohen
bfe9ffb449
Finish support for Microsoft ML/MASM. May still be a few rough edges.
...
llvm-svn: 28045
2006-05-02 03:11:50 +00:00
Jeff Cohen
24a62a9bc1
Make Intel syntax mode friendlier to Microsoft ML assembler (still needs more work).
...
llvm-svn: 28044
2006-05-02 01:16:28 +00:00
Chris Lattner
4b177f089e
Put instruction names into the first non TargetInstrInfo namespace found.
...
llvm-svn: 28043
2006-05-01 23:46:16 +00:00
Chris Lattner
5104e3b833
New testcase that crashes the new CFE.
...
llvm-svn: 28042
2006-05-01 23:18:55 +00:00
Chris Lattner
fd0a5478a1
Fix a latent bug that my spiller patch last week exposed: we were leaving
...
instructions in the virtregfolded map that were deleted. Because they
were deleted, newly allocated instructions could end up at the same address,
magically finding themselves in the map. The solution is to remove entries
from the map when we delete the instructions.
llvm-svn: 28041
2006-05-01 22:03:24 +00:00
Chris Lattner
ab7dbe0cc9
When promoting a load to a reg-reg copy, where the load was a previous
...
instruction folded with spill code, make sure the remove the load from
the virt reg folded map.
llvm-svn: 28040
2006-05-01 21:17:10 +00:00
Chris Lattner
4dee67c2cd
Remove previous patch, which wasn't quite right.
...
llvm-svn: 28039
2006-05-01 21:16:03 +00:00
Chris Lattner
017b93dd7c
instructions can be in different namespaces. Make sure to use the right
...
one for each instruction.
llvm-svn: 28038
2006-05-01 17:01:17 +00:00
Chris Lattner
85e9909755
Put PHI/INLINEASM into the correct namespace.
...
llvm-svn: 28037
2006-05-01 17:00:49 +00:00
Evan Cheng
8e63393bc3
Formating
...
llvm-svn: 28036
2006-05-01 09:30:17 +00:00
Evan Cheng
0d084fb9ca
Dis-favor stores more
...
llvm-svn: 28035
2006-05-01 09:20:44 +00:00
Evan Cheng
24e795496d
Bottom up register-pressure reduction scheduler now pushes store operations
...
up the schedule. This helps code that looks like this:
loads ...
computations (first set) ...
stores (first set) ...
loads
computations (seccond set) ...
stores (seccond set) ...
Without this change, the stores and computations are more likely to
interleave:
loads ...
loads ...
computations (first set) ...
computations (second set) ...
computations (first set) ...
stores (first set) ...
computations (second set) ...
stores (stores set) ...
This can increase the number of spills if we are unlucky.
llvm-svn: 28033
2006-05-01 09:14:40 +00:00
Evan Cheng
c2ef5e34a8
Mark instructions whose pattern is (store ...) isStore.
...
llvm-svn: 28032
2006-05-01 09:04:20 +00:00
Evan Cheng
10ff7b27ce
Didn't mean ScheduleDAGList.cpp to make the last checkin.
...
llvm-svn: 28030
2006-05-01 08:56:34 +00:00
Evan Cheng
a656242690
Remove temp. option -spiller-check-liveout, it didn't cause any failure nor performance regressions.
...
llvm-svn: 28029
2006-05-01 08:54:57 +00:00
Chris Lattner
78d9ae3f0c
Intel mode no longer uses %'s on registers
...
llvm-svn: 28028
2006-05-01 05:56:51 +00:00
Chris Lattner
563f0417d2
Remove %'s from register names when in intel mode.
...
llvm-svn: 28027
2006-05-01 05:53:50 +00:00
Chris Lattner
25f55ae74a
Format #APP lines a bit nicer
...
llvm-svn: 28026
2006-05-01 04:11:03 +00:00
Evan Cheng
f71f0f2e0b
Local spiller kills a store if the folded restore is turned into a copy.
...
But this is incorrect if the spilled value live range extends beyond the
current BB.
It is currently controlled by a temporary option -spiller-check-liveout.
llvm-svn: 28024
2006-04-30 08:41:47 +00:00
Jeff Cohen
71c2e0f262
Mingw32 patches supplied by Anton Korobeynikov.
...
llvm-svn: 28023
2006-04-29 18:41:44 +00:00
Chris Lattner
2b48a94413
Remove a bogus transformation. This fixes SingleSource/UnitTests/2006-01-23-InitializedBitField.c
...
with some changes I have to the new CFE.
llvm-svn: 28022
2006-04-28 23:33:20 +00:00
Evan Cheng
d369603df9
I can't spell: Register, not Regsiter.
...
llvm-svn: 28021
2006-04-28 23:19:39 +00:00
Evan Cheng
b244b80172
Implemented x86 inline asm b, h, w, k modifiers.
...
llvm-svn: 28020
2006-04-28 23:11:40 +00:00