Evan Cheng
8464a0bf00
Add a argument to storeRegToStackSlot and storeRegToAddr to specify whether
...
the stored register is killed.
llvm-svn: 44600
2007-12-05 03:14:33 +00:00
Evan Cheng
58b387dfb0
Remove redundant foldMemoryOperand variants and other code clean up.
...
llvm-svn: 44517
2007-12-02 08:30:39 +00:00
Evan Cheng
79e8b92dc3
Allow some reloads to be folded in multi-use cases. Specifically testl r, r -> cmpl [mem], 0.
...
llvm-svn: 44479
2007-12-01 02:07:52 +00:00
Dale Johannesen
5fd9e7a615
Add parameter to getDwarfRegNum to permit targets
...
to use different mappings for EH and debug info;
no functional change yet.
Fix warning in X86CodeEmitter.
llvm-svn: 44056
2007-11-13 19:13:01 +00:00
Bill Wendling
934fcd87e7
Unifacalize the CALLSEQ{START,END} stuff.
...
llvm-svn: 44045
2007-11-13 09:19:02 +00:00
Bill Wendling
cc75435ebf
Unify CALLSEQ_{START,END}. They take 4 parameters: the chain, two stack
...
adjustment fields, and an optional flag. If there is a "dynamic_stackalloc" in
the code, make sure that it's bracketed by CALLSEQ_START and CALLSEQ_END. If
not, then there is the potential for the stack to be changed while the stack's
being used by another instruction (like a call).
This can only result in tears...
llvm-svn: 44037
2007-11-13 00:44:25 +00:00
Bruno Cardoso Lopes
0661f1be90
Added JumpTable support
...
Fixed some AsmPrinter issues
Added GLOBAL_OFFSET_TABLE Node handle.
llvm-svn: 44024
2007-11-12 19:49:57 +00:00
Anton Korobeynikov
8e8473c783
Use TableGen to emit information for dwarf register numbers.
...
This makes DwarfRegNum to accept list of numbers instead.
Added three different "flavours", but only slightly tested on x86-32/linux.
Please check another subtargets if possible,
llvm-svn: 43997
2007-11-11 19:50:10 +00:00
Bruno Cardoso Lopes
77e5c419ec
Better processor definition
...
llvm-svn: 43749
2007-11-06 03:15:20 +00:00
Bruno Cardoso Lopes
569b5512b0
Added support for PIC code with "explicit relocations" *only*.
...
Removed all macro code for PIC (goodbye "la").
Support tested with shootout bench.
llvm-svn: 43697
2007-11-05 03:02:32 +00:00
Duncan Sands
d1bdbd010b
Eliminate the remaining uses of getTypeSize. This
...
should only effect x86 when using long double. Now
12/16 bytes are output for long double globals (the
exact amount depends on the alignment). This brings
globals in line with the rest of LLVM: the space
reserved for an object is now always the ABI size.
One tricky point is that only 10 bytes should be
output for long double if it is a field in a packed
struct, which is the reason for the additional
argument to EmitGlobalConstant.
llvm-svn: 43688
2007-11-05 00:04:43 +00:00
Eric Christopher
82c77dd85b
clo/clz aren't supported on mips I. Keep them around for when we'll
...
want them later (mips32/64).
llvm-svn: 43380
2007-10-26 04:00:13 +00:00
Evan Cheng
0449186690
- Added getOpcodeAfterMemoryUnfold(). It doesn't unfold an instruction, but only returns the opcode of the instruction post unfolding.
...
- Fix some copy+paste bugs.
llvm-svn: 43153
2007-10-18 22:40:57 +00:00
Evan Cheng
c852780685
Use SmallVectorImpl instead of SmallVector with hardcoded size in MRegister public interface.
...
llvm-svn: 43150
2007-10-18 21:29:24 +00:00
Evan Cheng
33df6a6bed
Revert 42908 for now.
...
llvm-svn: 42960
2007-10-14 05:57:21 +00:00
Dan Gohman
a75e4a62e6
Change the names used for internal labels to use the current
...
function symbol name instead of a codegen-assigned function
number.
Thanks Evan! :-)
llvm-svn: 42908
2007-10-12 14:53:36 +00:00
Bruno Cardoso Lopes
257d5a5127
Position Independent Code (PIC) support [3]
...
llvm-svn: 42780
2007-10-09 03:15:11 +00:00
Bruno Cardoso Lopes
627ba10946
Position Independent Code (PIC) support [2]
...
- Added a function to hold the stack location
where GP must be stored during LowerCALL
- AsmPrinter now emits directives based on
relocation type
- PIC_ set to default relocation type (same as GCC)
llvm-svn: 42779
2007-10-09 03:01:19 +00:00
Bruno Cardoso Lopes
3a48664e98
Position Independent Code (PIC) support [1]
...
- Modified instruction format to handle pseudo instructions
- Added LoadAddr SDNode to load symbols.
llvm-svn: 42778
2007-10-09 02:55:31 +00:00
Evan Cheng
f536e2f41e
- Added a few target hooks to generate load / store instructions from / to any
...
address (not just from / to frameindexes).
- Added target hooks to unfold load / store instructions / SDNodes into separate
load, data processing, store instructions / SDNodes.
llvm-svn: 42621
2007-10-05 01:32:41 +00:00
Evan Cheng
5f9e291240
Allow copyRegToReg to emit cross register classes copies.
...
Tested with "make check"!
llvm-svn: 42346
2007-09-26 06:25:56 +00:00
Dan Gohman
99e8e1ff08
More explicit keywords.
...
llvm-svn: 42316
2007-09-25 20:27:06 +00:00
Bruno Cardoso Lopes
23468a24c9
Added "LoadEffective" pattern to handle stack locations.
...
Fixed some comments
llvm-svn: 42271
2007-09-24 20:15:11 +00:00
Evan Cheng
b43255bc68
Remove (somewhat confusing) Imp<> helper, use let Defs = [], Uses = [] instead.
...
llvm-svn: 41863
2007-09-11 19:55:27 +00:00
Duncan Sands
c358890f73
Fold the adjust_trampoline intrinsic into
...
init_trampoline. There is now only one
trampoline intrinsic.
llvm-svn: 41841
2007-09-11 14:10:23 +00:00
Owen Anderson
4b71e55287
Add lengthof and endof templates that hide a lot of sizeof computations.
...
Patch by Sterling Stein!
llvm-svn: 41758
2007-09-07 04:06:50 +00:00
Evan Cheng
58ea935f6f
Add a variant of foldMemoryOperand to fold any load / store, not just load / store from / to stack slots.
...
llvm-svn: 41597
2007-08-30 05:52:20 +00:00
Bruno Cardoso Lopes
ff764398e6
Added method to get Mips register numbers
...
Changed the stack frame layout, StackGrowsUp fits better to Mips strange stack.
Stack offset calculation bug fixed!
llvm-svn: 41529
2007-08-28 05:13:42 +00:00
Bruno Cardoso Lopes
144486ca7e
Changed stack allocation On LowerFORMAL_ARGUMENTS.
...
Added comments about new stack allocation.
Expand SelectCC for i32 results
llvm-svn: 41527
2007-08-28 05:08:16 +00:00
Bruno Cardoso Lopes
96894b2c93
Mask directive completed with CalleeSave info
...
Comments for Mips directives added.
llvm-svn: 41526
2007-08-28 05:06:17 +00:00
Bruno Cardoso Lopes
b77d5cd9d5
Added methods to record SPOffsets from LowerFORMAL_ARGUMENTS
...
llvm-svn: 41525
2007-08-28 05:04:41 +00:00
Bruno Cardoso Lopes
14e39d7bcf
InlineAsm asm support for integer registers added
...
llvm-svn: 41225
2007-08-21 16:09:25 +00:00
Bruno Cardoso Lopes
4173f973e9
Instruction Itinerary attribution fixed
...
llvm-svn: 41224
2007-08-21 16:06:45 +00:00
Bruno Cardoso Lopes
40b9999770
MipsHi now has ouput flag
...
MipsAdd SDNode created to add support to an Add opcode which supports input flag
Added an instruction itinerary to all instruction classes
Added branches with zero cond codes
Now call clobbers all non-callee saved registers
Call w/ register support added
Added DelaySlot to branch and load instructions
Added patterns to handle all setcc, brcond/setcc and MipsAdd instructions
llvm-svn: 41161
2007-08-18 02:37:46 +00:00
Bruno Cardoso Lopes
3bc582fa67
Fixed stack frame addressing bug
...
llvm-svn: 41160
2007-08-18 02:19:09 +00:00
Bruno Cardoso Lopes
15cbbbb56f
support for Schedule included on Mips.td
...
llvm-svn: 41159
2007-08-18 02:18:07 +00:00
Bruno Cardoso Lopes
e2909db54c
Removed LowerRETURADDR, fixed small bug into LowerRET, LowerGlobalAddress
...
fixed to generate instructions (add, lui) glued!
llvm-svn: 41158
2007-08-18 02:16:30 +00:00
Bruno Cardoso Lopes
d13e0b33d1
Couple of small changes. Delay Slot handle header declared.
...
Newline added after macros at function init on generated asm!
llvm-svn: 41157
2007-08-18 02:05:24 +00:00
Bruno Cardoso Lopes
1ad2687157
Added InstrItinClass support for instruction formats
...
llvm-svn: 41156
2007-08-18 02:01:28 +00:00
Bruno Cardoso Lopes
0dce1a316c
Branch Analysis and InsertNoop inserted into header files
...
llvm-svn: 41155
2007-08-18 01:59:45 +00:00
Bruno Cardoso Lopes
ae01dc5e74
createMipsDelaySlotFillerPass added to mips codegen runtime
...
llvm-svn: 41154
2007-08-18 01:58:15 +00:00
Bruno Cardoso Lopes
7bca87bebd
Added Branch Analysis support
...
Added InsertNoop support
llvm-svn: 41153
2007-08-18 01:56:48 +00:00
Bruno Cardoso Lopes
c7eaab9c92
LowerRETURNADDR removed since it was wrong and does not have utility yet!
...
MipsAdd opcode added
llvm-svn: 41152
2007-08-18 01:54:09 +00:00
Bruno Cardoso Lopes
d97285f98a
InstrItineraryData support on added.
...
Added Mips3 ISA feature (needed when supporting R4000 machines)
llvm-svn: 41151
2007-08-18 01:52:27 +00:00
Bruno Cardoso Lopes
bc755b9969
A Pass to insert Nops on intructions with DelaySlot
...
llvm-svn: 41150
2007-08-18 01:50:47 +00:00
Bruno Cardoso Lopes
d67580757e
Mips generic fallback instruction schedule support!
...
llvm-svn: 41149
2007-08-18 01:46:44 +00:00
Dan Gohman
352de5aeb9
More explicit keywords.
...
llvm-svn: 40757
2007-08-02 21:21:54 +00:00
Duncan Sands
e8bb2c6d32
Support for trampolines, except for X86 codegen which is
...
still under discussion.
llvm-svn: 40549
2007-07-27 12:58:54 +00:00
Dan Gohman
0fc4e0cf47
Don't ignore the return value of AsmPrinter::doInitialization and
...
AsmPrinter::doFinalization.
llvm-svn: 40487
2007-07-25 19:33:14 +00:00
Evan Cheng
53cb03b583
No more noResults.
...
llvm-svn: 40132
2007-07-21 00:34:19 +00:00