1
0
mirror of https://github.com/RPCS3/llvm-mirror.git synced 2024-10-21 12:02:58 +02:00
Commit Graph

7537 Commits

Author SHA1 Message Date
Rafael Espindola
01b306e575 Refactor the memcpy lowering for the x86 target.
The only generated code difference is that now we call memcpy when
the size of the array is unknown. This matches GCC behavior and is
better since the run time value can be arbitrarily large.

llvm-svn: 42433
2007-09-28 12:53:01 +00:00
Evan Cheng
c2acb6f2e5 Stop inventing new words. :-)
llvm-svn: 42429
2007-09-28 01:35:02 +00:00
Evan Cheng
d3ff9d3ff7 Pessimisively assume ADJCALLSTACKDOWN / ADJCALLSTACKUP (which becomes sub / add) clobbers EFLAGS.
llvm-svn: 42426
2007-09-28 01:19:48 +00:00
Dan Gohman
50747737a5 TargetAsmInfo::getAddressSize() was incorrect for x86-64 and 64-bit targets
other than PPC64. Instead of fixing it, just remove it and fix all the
places that use it to use TargetData::getPointerSize() instead, as there
aren't very many. Most of the references were in DwarfWriter.cpp.

llvm-svn: 42419
2007-09-27 23:12:31 +00:00
Evan Cheng
d8ab90ae1f Use GR64 in 64-bit mode.
llvm-svn: 42417
2007-09-27 21:50:05 +00:00
Evan Cheng
826f0f94df Doh. Calls clobber EFLAGS.
llvm-svn: 42413
2007-09-27 19:01:55 +00:00
Dale Johannesen
089d2e760f Make temporaries explicit to avoid premature
destruction of compiler-created ones.

llvm-svn: 42383
2007-09-26 23:20:33 +00:00
Evan Cheng
29817845b3 - Move getPhysicalRegisterRegClass() from ScheduleDAG to MRegisterInfo.
- Added ability to emit cross class register copies to the BBRU scheduler.
- More aggressive backtracking.

llvm-svn: 42375
2007-09-26 21:36:17 +00:00
Evan Cheng
0f9e307353 - Added MRegisterInfo::getCrossCopyRegClass() hook. For register classes where reg to reg copies are not possible, this returns another register class which registers in the specified register class can be copied to (and copy back from).
- X86 copyRegToReg() now supports copying between EFLAGS and GR32 / GR64 registers.

llvm-svn: 42372
2007-09-26 21:31:07 +00:00
Evan Cheng
66eeb8440c Some assemblers do not recognize aliases pushfd, pushfq, popfd, and popfq. Just emit them as pushf and popf.
llvm-svn: 42371
2007-09-26 21:28:00 +00:00
Dale Johannesen
69595b587f Enable codegen for long double abs, sin, cos
llvm-svn: 42368
2007-09-26 21:10:55 +00:00
Evan Cheng
37ee6eba29 Typos: POPQ -> POPFQ, POPD -> POPFD.
llvm-svn: 42348
2007-09-26 06:38:29 +00:00
Chris Lattner
86e73ac224 move PR1160 here.
llvm-svn: 42347
2007-09-26 06:29:31 +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
Chris Lattner
2efd3899f2 move PR1264 here.
llvm-svn: 42345
2007-09-26 06:15:48 +00:00
Evan Cheng
5cb9dbaaa1 Add pushf{d|q}, popf{d|q} to push and pop EFLAGS register.
llvm-svn: 42335
2007-09-26 01:29:06 +00:00
Evan Cheng
38c7d5082a translateX86CC updates the last two operands.
llvm-svn: 42333
2007-09-26 00:45:55 +00:00
Anton Korobeynikov
8cd666b659 Correctly restore stack pointer after realignment in main() on Cygwin/Mingw32
llvm-svn: 42332
2007-09-26 00:13:34 +00:00
Evan Cheng
24c5a1a484 Missing load / store folding entries.
llvm-svn: 42323
2007-09-25 22:10:43 +00:00
Anton Korobeynikov
ca03aec919 Partly revert invalid r41774
llvm-svn: 42322
2007-09-25 21:52:30 +00:00
Dan Gohman
99e8e1ff08 More explicit keywords.
llvm-svn: 42316
2007-09-25 20:27:06 +00:00
Dan Gohman
a01dd49472 Fix a typo in a comment.
llvm-svn: 42313
2007-09-25 19:37:26 +00:00
Evan Cheng
a58633d67b New style x87 cmp instructions.
llvm-svn: 42312
2007-09-25 19:08:02 +00:00
Dan Gohman
1bb346f9f1 When both x/y and x%y are needed (x and y both scalar integer), compute
both results with a single div or idiv instruction. This uses new X86ISD
nodes for DIV and IDIV which are introduced during the legalize phase
so that the SelectionDAG's CSE can automatically eliminate redundant
computations.

llvm-svn: 42308
2007-09-25 18:23:27 +00:00
Dan Gohman
8385890394 Move the setOperationAction(ISD::DEBUG_LOC, MVT::Other, Expand) and
the check to see if the assembler supports .loc from X86TargetLowering
into the superclass TargetLowering.

llvm-svn: 42297
2007-09-25 15:10:49 +00:00
Evan Cheng
36b3babfde Added support for new condition code modeling scheme (i.e. physical register dependency). These are a bunch of instructions that are duplicated so the x86 backend can support both the old and new schemes at the same time. They will be deleted after
all the kinks are worked out.

llvm-svn: 42285
2007-09-25 01:57:46 +00:00
Evan Cheng
6bfaf13dd9 New temporary option -new-cc-modeling-scheme to test the new cc modeling scheme.
llvm-svn: 42283
2007-09-25 01:50:04 +00:00
Evan Cheng
0a3651a70d Rename keyword "modify" -> "implicit".
llvm-svn: 42282
2007-09-25 01:48:59 +00:00
Dale Johannesen
5ea6a9bc3a When mixing SSE and x87 codegen, it's possible to
have situations where an SSE instruction turns into
multiple blocks, with the live range of an x87
register crossing them.  To do this correctly make
sure we examine all blocks when inserting
FP_REG_KILL.  PR 1697.  (This was exposed by my
fix for PR 1681, but the same thing could happen
mixing x87 long double with SSE.)

llvm-svn: 42281
2007-09-24 22:52:39 +00:00
Dan Gohman
96d5f979bc Add support on x86 for having Legalize lower ISD::LOCATION to ISD::DEBUG_LOC
instead of ISD::LABEL with a manual .debug_line entry when the assembler
supports .file and .loc directives.

llvm-svn: 42278
2007-09-24 21:54:14 +00:00
Dan Gohman
b642a1ddf8 Merge hasDotLoc and hasDotFile into hasDotLocAndDotFile since .loc and .file
aren't really usable without each other. 

llvm-svn: 42274
2007-09-24 21:09:53 +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
Dan Gohman
a264777dc1 Fix the syntax for the .loc directive in preparation for using it.
llvm-svn: 42268
2007-09-24 19:25:06 +00:00
Dan Gohman
32b1df2aa3 The code that used the StartLabelId label was removed, so remove the
code that creates the label too.

llvm-svn: 42265
2007-09-24 16:44:26 +00:00
Chris Lattner
594d3aa066 claim that "st" is from the 80-bit register file. This causes x87-using inline
asm to die with:

ScheduleDAG.cpp:269: failed assertion `false && "Couldn't find the register class"'

instead of:
failed assertion `RegMap->getRegClass(VReg) == RC && "Register class of operand and regclass of use don't agree!"'

yay.

llvm-svn: 42259
2007-09-24 05:27:37 +00:00
Dale Johannesen
ea6ffa0b36 Fix PR 1681. When X86 target uses +sse -sse2,
keep f32 in SSE registers and f64 in x87.  This
is effectively a new codegen mode.
Change addLegalFPImmediate to permit float and
double variants to do different things.
Adjust callers.

llvm-svn: 42246
2007-09-23 14:52:20 +00:00
Chris Lattner
03d0e8d0ff Fix PR1679, by printing GEP indices as signed values instead of unsigned.
llvm-svn: 42239
2007-09-22 20:16:48 +00:00
Rafael Espindola
11ee0898b9 Don't add a default STACK_ALIGN (use the generic ABI alignment)
Implement calls to functions with byval arguments on X86

llvm-svn: 42192
2007-09-21 15:50:22 +00:00
Rafael Espindola
b0b536b597 small cleanup: use LowerMemArgument in LowerFastCCArguments also
llvm-svn: 42189
2007-09-21 14:55:38 +00:00
Evan Cheng
d675ed5400 Honor user-defined section specification of a global, ignores whether its initializer is null.
llvm-svn: 42182
2007-09-21 00:41:19 +00:00
Devang Patel
a6a6e699a1 Do not override user specified section.
llvm-svn: 42179
2007-09-20 23:07:37 +00:00
Dan Gohman
eb622df2ef Fix several more entries in the x86 reload/remat folding tables.
llvm-svn: 42162
2007-09-20 14:17:21 +00:00
Dale Johannesen
ab5a68edd5 another long double buglet
llvm-svn: 42159
2007-09-20 01:27:54 +00:00
Evan Cheng
267f595834 Enable if-conversion for ARM by default.
llvm-svn: 42156
2007-09-20 00:48:22 +00:00
Dale Johannesen
04682bdc81 More long double fixes. x86_64 should build now.
llvm-svn: 42155
2007-09-19 23:55:34 +00:00
Evan Cheng
9e2db47639 Avoid referencing deleted instruction.
llvm-svn: 42153
2007-09-19 21:48:07 +00:00
Evan Cheng
ec83699473 PSHUFDmi, etc. are actually folding a load, not a store.
llvm-svn: 42147
2007-09-19 19:02:47 +00:00
Evan Cheng
8e459700fe Set CCR (EFLAGS) copy cost to -1, i.e. extremely expensive to copy.
llvm-svn: 42124
2007-09-19 01:36:39 +00:00
Evan Cheng
859720c33b Add CopyCost to TargetRegisterClass. This specifies the cost of copying a value
between two registers in the specific class.

llvm-svn: 42123
2007-09-19 01:35:01 +00:00
Dan Gohman
be3b005b2d Move the entries for 64-bit CMP, IMUL, and a few others into the correct
tables so that they are eligible for reload/remat folding. And add
entries for JMP and CALL.

llvm-svn: 42094
2007-09-18 14:59:14 +00:00
Dale Johannesen
46adce144c Remove RSTRegClass case from loadRegFromStackSlot
and storeRegToStackSlot.  Evan and I concluded this
should never be needed and it appears to be true.
(It if is needed, adjustment would be needed for
long double to work.)

llvm-svn: 42049
2007-09-17 20:15:38 +00:00
Chris Lattner
cc315726f7 Merge DenseMapKeyInfo & DenseMapValueInfo into DenseMapInfo
Add a new DenseMapInfo::isEqual method to allow clients to redefine
the equality predicate used when probing the hash table.

llvm-svn: 42042
2007-09-17 18:34:04 +00:00
Evan Cheng
d7742e7939 X86ISD::TEST is dead.
llvm-svn: 42037
2007-09-17 17:42:53 +00:00
Dan Gohman
b096221b3e Add 64-bit jmp instructions to the list of instructions that
can terminate a block with no fall-through.

llvm-svn: 42029
2007-09-17 15:19:08 +00:00
Dan Gohman
41a6dea029 Use xorl instead of xorq to enter a zero into a 64-bit register.
llvm-svn: 42027
2007-09-17 14:55:08 +00:00
Dan Gohman
1aeaeec570 Emit integer x<1 as x<=0, as comparisons with zero (now includeing
64-bit) can use test instead of cmp with an immediate.

llvm-svn: 42026
2007-09-17 14:49:27 +00:00
Dan Gohman
b9449c9118 Use "test reg,reg" in place of "cmp reg,0" for 64-bit operands. This was
previously only done for 32-bit and smaller operands.

llvm-svn: 42024
2007-09-17 14:35:24 +00:00
Dale Johannesen
0ea2cc2e51 Implement x86 long double (uses host long double,
so only works on x86 target).

llvm-svn: 42019
2007-09-17 00:38:27 +00:00
Bill Wendling
f1335f46d4 Follow-up to patch r41999. Make the conditional that emits the personality stub
match the conditional that turns on exception handling emittion in the asm
printer.

llvm-svn: 42008
2007-09-16 19:21:08 +00:00
Bill Wendling
7932341cef Only emit the personality function as a global value if the backend actually
supports it. This solves this error on the Darwin x86-64 platform:

$ cat testcase.ii
struct A {
  A();
};

A *bork() {
  return new A;
}
$ llvm-g++ -arch x86_64 -c testcase.ii
/var/tmp//cc3U8fd8.s:52:unknown section type: non_lazy_symbol_pointers
/var/tmp//cc3U8fd8.s:52:Rest of line ignored. 1st junk character valued 76 (L).
/var/tmp//cc3U8fd8.s:53:Unknown pseudo-op: .indirect_symbol
/var/tmp//cc3U8fd8.s:53:Rest of line ignored. 1st junk character valued 95 (_).

llvm-svn: 41999
2007-09-16 10:36:17 +00:00
Chris Lattner
1b622ad721 Fix PR1666, SPASS with the CBE and 254.gap with the CBE.
GCC optimizes away things like ptr < NULL  to false.  To "fix" this,
have the CBE emit casts of pointers to intptr_t when doing relational
pointer comparisons.

llvm-svn: 41983
2007-09-15 06:51:03 +00:00
Dan Gohman
df419c2b4f Add patterns for SHLD64* and SHRD64*.
llvm-svn: 41975
2007-09-14 23:17:45 +00:00
Dale Johannesen
575bd6070a Remove the assumption that FP's are either float or
double from some of the many places in the optimizers
it appears, and do something reasonable with x86
long double.
Make APInt::dump() public, remove newline, use it to
dump ConstantSDNode's.
Allow APFloats in FoldingSet.
Expand X86 backend handling of long doubles (conversions
to/from int, mostly).

llvm-svn: 41967
2007-09-14 22:26:36 +00:00
Evan Cheng
13797e4a74 Add implicit def of EFLAGS on those instructions that may modify flags.
llvm-svn: 41962
2007-09-14 21:48:26 +00:00
Dan Gohman
fb60c0dfed Remove isReg, isImm, and isMBB, and change all their users to use
isRegister, isImmediate, and isMachineBasicBlock, which are equivalent,
and more popular.

llvm-svn: 41958
2007-09-14 20:33:02 +00:00
Rafael Espindola
5d8b225881 Add support for functions with byval arguments on x86
llvm-svn: 41953
2007-09-14 15:48:13 +00:00
Evan Cheng
3aafca793b Fix comments.
llvm-svn: 41947
2007-09-14 01:57:02 +00:00
Evan Cheng
bd4b11cfa9 Initial support for multi-result patterns:
1.
[(set GR32:$dst, (add GR32:$src1, GR32:$src2)),
 (modify EFLAGS)]
This indicates the source pattern expects the instruction would produce 2 values. The first is the result of the addition. The second is an implicit definition in register EFLAGS.
2.
def : Pat<(parallel (addc GR32:$src1, GR32:$src2), (modify EFLAGS)), ()>
Similar to #1 except this is used for def : Pat patterns.

llvm-svn: 41897
2007-09-12 23:30:14 +00:00
Dale Johannesen
4784ee3431 Revise previous patch per review comments.
Next round of x87 long double stuff.
Getting close now, basically works.

llvm-svn: 41875
2007-09-12 03:30:33 +00:00
Bill Wendling
89ced2f9b1 Enable indirect encoding for the personality function
llvm-svn: 41873
2007-09-11 23:55:40 +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
Evan Cheng
ce8087de3e Added status flags register: EFLAGS.
llvm-svn: 41862
2007-09-11 19:53:28 +00:00
Dale Johannesen
7bc3969cea Add APInt interfaces to APFloat (allows directly
access to bits).  Use them in place of float and
double interfaces where appropriate.
First bits of x86 long double constants handling 
(untested, probably does not work).

llvm-svn: 41858
2007-09-11 18:32:33 +00:00
Bill Wendling
74888e63e7 Add a bool to indicate if we should set the "indirect encoding" bit in the Dwarf
information for EH.

llvm-svn: 41852
2007-09-11 17:20:55 +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
Duncan Sands
8640185d45 My compiler warns about the semicolon.
llvm-svn: 41840
2007-09-11 12:30:25 +00:00
Bill Wendling
3c6a8b2814 The personality function on Darwin needs a global stub. We then refer to
that global stub instead of doing the ".set" thingy we were doing before.

llvm-svn: 41838
2007-09-11 08:27:17 +00:00
Evan Cheng
24e8e4d6ef 80 col.
llvm-svn: 41812
2007-09-10 22:22:23 +00:00
Evan Cheng
b639648fc5 New entry.
llvm-svn: 41810
2007-09-10 22:16:37 +00:00
Chris Lattner
d4602cc0e7 Add some notes about better flag handling.
llvm-svn: 41808
2007-09-10 21:43:18 +00:00
Evan Cheng
4715ccb29c It's not safe to rematerialize MOV32r0 etc. by simply cloning the original
instruction. These are implemented with xor which will modify the conditional
code. They should be rematerialized as move instructions.

llvm-svn: 41802
2007-09-10 20:48:53 +00:00
Evan Cheng
65df926ced TableGen no longer emit CopyFromReg nodes for implicit results in physical
registers. The scheduler is now responsible for emitting them.

llvm-svn: 41781
2007-09-07 23:59:02 +00:00
Bill Wendling
04a6163921 Add missing index versions of instructions to the map.
llvm-svn: 41776
2007-09-07 22:01:02 +00:00
Dan Gohman
3bc1bc2590 Avoid storing and reloading zeros and other constants from stack slots
by flagging the associated instructions as being trivially rematerializable.

llvm-svn: 41775
2007-09-07 21:32:51 +00:00
Dale Johannesen
783215c630 Apply feedback from previous patch.
llvm-svn: 41774
2007-09-07 21:07:57 +00:00
Rafael Espindola
8c57e70f93 Add support for having different alignment for objects on call frames.
The x86-64 ABI states that objects passed on the stack have
8 byte alignment. Implement that.

llvm-svn: 41768
2007-09-07 14:52:14 +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
Dale Johannesen
86f367a6b7 Next round of APFloat changes.
Use APFloat in UpgradeParser and AsmParser.
Change all references to ConstantFP to use the
APFloat interface rather than double.  Remove
the ConstantFP double interfaces.
Use APFloat functions for constant folding arithmetic
and comparisons.
(There are still way too many places APFloat is
just a wrapper around host float/double, but we're
getting there.)

llvm-svn: 41747
2007-09-06 18:13:44 +00:00
Evan Cheng
896c1ed385 Fix a bug in X86InstrInfo::convertToThreeAddress that caused it to codegen:
leal    (,%rcx,8), %rcx
It should be
leal    (,%rcx,8), %ecx

llvm-svn: 41735
2007-09-06 00:14:41 +00:00
Bill Wendling
46d5fb4e5d LVXL and STVXL are also a load and store resp.
llvm-svn: 41733
2007-09-05 23:47:12 +00:00
Bill Wendling
13549db795 Add the 64-bit versions of the DS* Altivec instructions.
llvm-svn: 41717
2007-09-05 04:05:20 +00:00
Evan Cheng
02c6081f2d Fix for PR1613: added 64-bit rotate left PPC instructions and patterns.
llvm-svn: 41711
2007-09-04 20:20:29 +00:00
Evan Cheng
4cae11d569 Mac OS X X86-64 ABI is same as the standard.
llvm-svn: 41700
2007-09-04 16:44:41 +00:00
Anton Korobeynikov
cf91be2c79 Reapply r41578 with proper fix
llvm-svn: 41680
2007-09-03 00:36:06 +00:00
Dale Johannesen
a79f7d4068 Revise per review of previous patch.
llvm-svn: 41645
2007-08-31 17:03:33 +00:00
Rafael Espindola
4ddaad4de0 Initial support for calling functions with byval arguments on x86-64
llvm-svn: 41643
2007-08-31 15:06:30 +00:00
Rafael Espindola
aa7930b4f0 Align i64 and f64 at 8 byte on x86-64.
This is mandated table 3.1 at
http://www.x86-64.org/documentation/abi.pdf

llvm-svn: 41642
2007-08-31 12:23:58 +00:00
Dale Johannesen
81d6ecb886 Enhance APFloat to retain bits of NaNs (fixes oggenc).
Use APFloat interfaces for more references, mostly
of ConstantFPSDNode.

llvm-svn: 41632
2007-08-31 04:03:46 +00:00
Raul Herbster
ffa8296e3f Instruction formats added used to generate multiply instructions of V5TE.
llvm-svn: 41629
2007-08-30 23:34:14 +00:00
Raul Herbster
7f1a7dc4e2 Unused relocation type reloc_arm_absolute removed.
llvm-svn: 41628
2007-08-30 23:31:35 +00:00
Raul Herbster
db2f42989b Comments added. It now generates V5TE multiply instructions. However, it is still necessary to model PUWLSH bits more clearly.
llvm-svn: 41627
2007-08-30 23:29:26 +00:00
Raul Herbster
49b44eae34 ARM instruction table was modified by adding information to generate multiply instruction of V5TE.
llvm-svn: 41626
2007-08-30 23:25:47 +00:00
Raul Herbster
26e15aed5c JITInfo now resolves function addrs and also relocations. It always emits a stub.
llvm-svn: 41625
2007-08-30 23:21:27 +00:00
Evan Cheng
cb317912b2 Added support to fold X86 load / store instructions. This allow rematerialized loads to be folded into their uses.
llvm-svn: 41599
2007-08-30 05:54:07 +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
Evan Cheng
527fe7ab57 Mark load instructions with isLoad = 1.
llvm-svn: 41595
2007-08-30 05:49:43 +00:00
Bill Wendling
c65cf7849d Use i64 on a PPC64 machine
llvm-svn: 41590
2007-08-30 00:59:19 +00:00
Dale Johannesen
e91a908971 Change LegalFPImmediates to use APFloat.
Add APFloat interfaces to ConstantFP, SelectionDAG.
Fix integer bit in double->APFloat conversion.
Convert LegalizeDAG to use APFloat interface in
ConstantFPSDNode uses.

llvm-svn: 41587
2007-08-30 00:23:21 +00:00
Duncan Sands
26ef2a1767 Move getX86RegNum into X86RegisterInfo and use it
in the trampoline lowering.  Lookup the jump and
mov opcodes for the trampoline rather than hard
coding them.

llvm-svn: 41577
2007-08-29 19:01: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
Rafael Espindola
dc5450f7fb Add a comment about using libc memset/memcpy or generating inline code.
llvm-svn: 41502
2007-08-27 17:48:26 +00:00
Rafael Espindola
3d52fe3ef3 call libc memcpy/memset if array size is bigger then threshold.
Coping 100MB array (after a warmup) shows that glibc 2.6.1 implementation on
x86-64 (core 2) is 30% faster (from 0.270917s to 0.188079s)

llvm-svn: 41479
2007-08-27 10:18:20 +00:00
Chris Lattner
1e089aac3a rename isOperandValidForConstraint to LowerAsmOperandForConstraint,
changing the interface to allow for future changes.

llvm-svn: 41384
2007-08-25 00:47:38 +00:00
Chris Lattner
d361c3e1ce Disable EH generation until PPC works 100%.
llvm-svn: 41360
2007-08-24 16:00:15 +00:00
Chris Lattner
4c84c39666 add a note
llvm-svn: 41359
2007-08-24 15:17:59 +00:00
Chris Lattner
9b22d7527c add some notes on really poor codegen.
llvm-svn: 41319
2007-08-23 15:22:07 +00:00
Chris Lattner
0c048bb115 new example
llvm-svn: 41318
2007-08-23 15:16:03 +00:00
Bill Wendling
dd451b602a Add the PCSymbol for Darwin x86 platforms.
llvm-svn: 41284
2007-08-22 18:44:05 +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
Anton Korobeynikov
f942eb0c45 Use only 1 knob to enable exceptions on Darwin :).
llvm-svn: 41208
2007-08-21 00:31:30 +00:00
Rafael Espindola
68d95ff2b1 Partial implementation of calling functions with byval arguments:
*) The needed information is propagated to the DAG
 *) The X86-64 backend detects it and aborts

llvm-svn: 41179
2007-08-20 15:18:24 +00:00
Chris Lattner
fdb4d38108 add a note
llvm-svn: 41178
2007-08-20 02:14:33 +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
Anton Korobeynikov
3094846993 Move ReturnAddrIndex variable to X86MachineFunctionInfo structure. This fixed
hard to catch bugs with retaddr lowering

llvm-svn: 41104
2007-08-15 17:12:32 +00:00
Chris Lattner
9fd664292f add a note.
llvm-svn: 41103
2007-08-15 16:58:38 +00:00
Evan Cheng
eef13203e7 Fix a typo pointd out by Maarten ter Huurne.
llvm-svn: 41059
2007-08-13 23:27:11 +00:00
Dan Gohman
2390ff5060 When x86 addresses matching exceeds its recursion limit, check to
see if the base register is already occupied before assuming it can be
used. This fixes bogus code generation in the accompanying testcase.

llvm-svn: 41049
2007-08-13 20:03:06 +00:00
Chris Lattner
7dfec1ee54 Fix PR1607
llvm-svn: 41048
2007-08-13 18:42:37 +00:00
Chris Lattner
fedbfd5f47 expand a note
llvm-svn: 41021
2007-08-11 18:19:07 +00:00
Chris Lattner
5f098dbbe5 With evan's explicit flag representation, hopefully we will finally be
able to 3-addressify away stuff like this:

        movl    %ecx, %eax
        decl    %eax

llvm-svn: 41020
2007-08-11 18:16:46 +00:00
Bill Wendling
e611c96a3c 64-bit SSSE3 ops that use MMX registers don't require 16-byte alignment.
Make a 'memop' pattern just for them.

llvm-svn: 41017
2007-08-11 09:52:53 +00:00
Christopher Lamb
7e52a97df5 Use subregs to improve any_extend code generation when feasible.
llvm-svn: 41013
2007-08-10 22:22:41 +00:00
Christopher Lamb
450f6815b9 Increase efficiency of sign_extend_inreg by using subregisters for truncation. As the README suggests sign_extend_subreg is selected to (sext(trunc)).
llvm-svn: 41010
2007-08-10 21:48:46 +00:00
Christopher Lamb
4e6cae3eae Edit README in light of previous LEA16 commit.
llvm-svn: 41009
2007-08-10 21:29:05 +00:00