1
0
mirror of https://github.com/RPCS3/llvm-mirror.git synced 2024-10-23 13:02:52 +02:00
Commit Graph

12444 Commits

Author SHA1 Message Date
Brian Gaeke
2a5dec63a6 Clean up the commented-out F3_3 stuff.
Replace it with a working class for FP instrs.

llvm-svn: 14226
2004-06-18 06:28:21 +00:00
Brian Gaeke
01309de73d Fix jmpl.
Add some FP moves.

llvm-svn: 14225
2004-06-18 06:28:10 +00:00
Brian Gaeke
c045f38dcb Support printing base+offset pairs where the offset is a register.
Use this for printing the jmpl indirect-call instruction.

llvm-svn: 14224
2004-06-18 06:27:59 +00:00
Brian Gaeke
92a3e14ac4 Support intrinsic calls (although no particular intrinsics are supported yet).
Support indirect calls.
Support returning a float value.

llvm-svn: 14223
2004-06-18 06:27:48 +00:00
Chris Lattner
4f71ea97e7 Calls to __builtin_isunordered and friends no longer cause llvmgcc to ICE.
llvm-svn: 14222
2004-06-18 06:26:29 +00:00
Chris Lattner
91b27e01b3 Implement Transforms/InstCombine/and.ll:test17, a common case that
occurs due to unordered comparison macros in math.h

llvm-svn: 14221
2004-06-18 06:07:51 +00:00
Chris Lattner
33fc8f4a89 New test
llvm-svn: 14220
2004-06-18 06:07:17 +00:00
Chris Lattner
8f9fb1d2ea Do not function resolve intrinsics. This prevents warnings and possible bad
things from happening due to

declare bool %llvm.isunordered(double, double)
declare bool %llvm.isunordered(float, float)

llvm-svn: 14219
2004-06-18 05:50:48 +00:00
Chris Lattner
81e7cd04ab Test that C99 unordered comparison functions are not being turned into libc calls
llvm-svn: 14218
2004-06-18 05:42:50 +00:00
Brian Gaeke
c5f1146e62 Add load instructions for floating-point registers.
llvm-svn: 14217
2004-06-18 05:19:27 +00:00
Brian Gaeke
7a618842f1 Support alloca instructions.
Support copying floating-point constants to registers.
Add assertion to visitCallInst to abort if we hit a NULL calledFunction, for now.

llvm-svn: 14216
2004-06-18 05:19:16 +00:00
Chris Lattner
3c61b2dd70 Fix printing of Argument objects, problem found by Patrick Meredith
llvm-svn: 14215
2004-06-18 04:07:20 +00:00
Chris Lattner
6fcaa7f2be New testcase for GCC unordered comparison builtins
llvm-svn: 14214
2004-06-18 03:39:56 +00:00
Chris Lattner
9e1bbe86ba Codegen sub C, X a little bit better for register pressure. Instead of
mov REG, C
sub REG, X

generate:

neg X
add X, C

which uses one less reg

llvm-svn: 14213
2004-06-18 00:50:37 +00:00
Chris Lattner
a5750b975a Fold setcc instructions into select and branches that are not in the same BB as
the setcc.

llvm-svn: 14212
2004-06-18 00:29:22 +00:00
Brian Gaeke
b824469b44 Make storeRegToStackSlot slightly shorter.
Make copyRegToReg return 1 instead of -1.
Edit a comment in emitPrologue().

llvm-svn: 14211
2004-06-17 22:34:48 +00:00
Brian Gaeke
9a0dc64af6 Set the isBranch and isTerminator flags on branch instructions correctly.
Add a FIXME about the (currently unused) JMPL instructions.

llvm-svn: 14210
2004-06-17 22:34:29 +00:00
Brian Gaeke
c82f209e72 Emit stores correctly; don't fail an assertion.
llvm-svn: 14209
2004-06-17 22:34:19 +00:00
Brian Gaeke
d084a534a2 Support generating machine instructions for Phi nodes (based on x86, but with
modifications for 1 LLVM BB --> many MBBs).
Fix store operand order: make it always be Base, Offset, SrcReg (think
"[ Base + Offset ] = SrcReg").
Rewrite visitBranchInst() to be even dumber (but working) -- give up on
the branch fallthrough trick, for the time being.
Make visitSetCondInst() work.

llvm-svn: 14208
2004-06-17 22:34:08 +00:00
Brian Gaeke
af2408a4ee Recognize more branches.
llvm-svn: 14207
2004-06-17 22:33:57 +00:00
Brian Gaeke
4a904bfdcc I love the smell of a freshly broken PowerPC build in the morning.
llvm-svn: 14206
2004-06-17 22:27:04 +00:00
Brian Gaeke
6f6eb93de3 Make debugging dumps w/ multiple MachineBBs for a given LLVM BB readable.
llvm-svn: 14205
2004-06-17 22:26:53 +00:00
Chris Lattner
f815117481 Do not fold loads into instructions if it is used more than once. In particular
we do not want to fold the load in cases like this:

  X = load
    = add A, X
    = add B, X

llvm-svn: 14204
2004-06-17 22:15:25 +00:00
Chris Lattner
13cea4ef6f Fix compilation problem on freebsd. Problem noted by Vladimir Merzliakov in
PR371

llvm-svn: 14203
2004-06-17 21:20:52 +00:00
Brian Gaeke
7d711d517b Use addGlobalAddress and addMBB for call & branch targets instead of addPCDisp.
Abort if we see a PCRelativeDisp MachineOperand, to be safe. This matches
the X86 backend.

llvm-svn: 14202
2004-06-17 19:39:23 +00:00
Chris Lattner
0cd29ae2cd Rename Type::PrimitiveID to TypeId and ::getPrimitiveID() to ::getTypeID()
llvm-svn: 14201
2004-06-17 18:19:28 +00:00
Chris Lattner
00b0a866dd Rename Type::PrimitiveID to TypeId and ::getPrimitiveID() to ::getTypeID()
Delete two functions that are now methods on the Type class

llvm-svn: 14200
2004-06-17 18:16:02 +00:00
Chris Lattner
18f8ae4e3e Minor cleanup
llvm-svn: 14199
2004-06-17 17:56:54 +00:00
Misha Brukman
8495487d8e Make header comment fit within 80 cols.
llvm-svn: 14198
2004-06-17 15:49:36 +00:00
Misha Brukman
66a7b8bc6d Since the Great LLVM Tool Renaming(tm), we no longer have collisions between our
assembler/linker and the system equivalents.

llvm-svn: 14197
2004-06-17 15:39:58 +00:00
Brian Gaeke
a46100448f Fix typo in DEBUG printout.
llvm-svn: 14196
2004-06-17 07:26:52 +00:00
Chris Lattner
1b8f37597d Fix a recent regression in Applications/sgefa that Alkis pointed out to me.
The vector may actually be empty if the register that we are marking as
recently used is not actually allocatable.  This happens for physical registers
that are not allocatable, like the ST(x) registers on X86.

llvm-svn: 14195
2004-06-16 06:57:29 +00:00
Brian Gaeke
19d2a396da Add int ferror(FILE *)
llvm-svn: 14194
2004-06-16 02:56:40 +00:00
Brian Gaeke
9f7f63256d I'm afraid this doesn't exist.
llvm-svn: 14193
2004-06-16 00:26:45 +00:00
Brian Gaeke
cf3cb8944a Um, did someone make a typo or something?
llvm-svn: 14192
2004-06-15 23:09:50 +00:00
Chris Lattner
7c3600a50e isnan is dead
llvm-svn: 14191
2004-06-15 21:52:58 +00:00
Chris Lattner
538a46b41c llvm.isnan is dead, long live llvm.isunordered!
llvm-svn: 14190
2004-06-15 21:50:46 +00:00
Chris Lattner
9bb0083d16 Remove support for llvm.isnan. Alkis wins :)
llvm-svn: 14189
2004-06-15 21:48:07 +00:00
Chris Lattner
5c115a9836 This testcase is a bit silly now, but oh well :)
llvm-svn: 14188
2004-06-15 21:46:16 +00:00
Chris Lattner
c9a6116586 Remove isnan support, correct isunordered support
llvm-svn: 14187
2004-06-15 21:42:23 +00:00
Chris Lattner
1adcf0441d Remove support for the isnan intrinsic
llvm-svn: 14186
2004-06-15 21:37:54 +00:00
Chris Lattner
d11493d8c4 Add basic support for the isunordered intrinsic. The isnan stuff still needs to go
llvm-svn: 14185
2004-06-15 21:36:44 +00:00
Chris Lattner
bb0198d8d2 Right, stop being silly
llvm-svn: 14184
2004-06-15 21:29:40 +00:00
Chris Lattner
1b81b46323 Add a nan, stop testing isnan
llvm-svn: 14183
2004-06-15 21:29:01 +00:00
Brian Gaeke
0a7b268b1a Fix thinko in visitor... ShiftInsts should currently be delegated
to visitBinaryOperator.

llvm-svn: 14182
2004-06-15 21:09:46 +00:00
Chris Lattner
8ca8002f88 Do not dereference end iterators. It's really bad for the asmwriter's health.
This possibly fixes PR370

llvm-svn: 14181
2004-06-15 21:07:32 +00:00
Brian Gaeke
5fe5e06bea I think we'll use the standard lowering passes for now.
llvm-svn: 14179
2004-06-15 20:37:12 +00:00
Brian Gaeke
d5f45ba4a1 Fix bug generating code for void call instructions: don't call
getReg() on void value.

llvm-svn: 14178
2004-06-15 20:06:32 +00:00
Brian Gaeke
79008f4648 Squash a warning from the Solaris assembler by aligning the stack
on a double-word boundary instead of a single-word boundary.

llvm-svn: 14177
2004-06-15 19:53:10 +00:00
Brian Gaeke
e02c780919 Allow special-casing of operand printing based on opcode. Print
non-register, non-immed. arguments to SETHI and OR using %hi() and
%lo() respectively.

llvm-svn: 14176
2004-06-15 19:52:59 +00:00