1
0
mirror of https://github.com/RPCS3/llvm-mirror.git synced 2024-10-26 14:33:02 +02:00
Commit Graph

6288 Commits

Author SHA1 Message Date
Brian Gaeke
a7ab370eb9 Add file comment. Include <vector> and <string>. Update include guards
to reflect file's current location.  Add definition of class
MappingInfo.

llvm-svn: 6616
2003-06-04 22:02:47 +00:00
Chris Lattner
947a0974df Revert brians patch to get mapping info working again
sorry dude

llvm-svn: 6615
2003-06-04 21:01:12 +00:00
Tanya Lattner
f08c51ca3b Had to comment out a line in outByte() to get it to compile because Out and tmp were
undeclared. I was not sure what Brian wanted, so I will let him fix this. But now it compiles.

llvm-svn: 6614
2003-06-04 20:53:46 +00:00
Chris Lattner
3c98c8953a Make this work with counter > 127
llvm-svn: 6613
2003-06-04 20:08:47 +00:00
Misha Brukman
a8c409ad9b * Instead of re-inventing the MachineConstantPool emitter that's already given
in Emitter.cpp, just convert the Sparc version of the constant pool into
  what's already supported and inter-operate.
* Implemented a first pass at lazy function resolution in the JITResolver. That
  required adding a SparcV9CodeEmitter pointer to simplify generating
  bit-patterns of the instructions.
* SparcV9CodeEmitter now creates and destroys static TheJITResolver, which makes
  sense because the SparcV9CodeEmitter is the only user of TheJITResolver, and
  lives for the entire duration of the JIT (via PassManager which lives in VM).
* Changed all return values in the JITResolver to uint64_t because of the 64-bit
  Sparc architecture.
* Added a new version of getting the value of a GlobalValue in the
  SparcV9CodeEmitter, which now works for already-generated functions (JITted or
  library functions).
* Removed little-used and unused functions, cleaning up the internal view of the
  SparcV9CodeEmitter.

llvm-svn: 6612
2003-06-04 20:01:13 +00:00
Chris Lattner
f2efc03060 Add prerelease license to cvs
llvm-svn: 6611
2003-06-04 19:46:36 +00:00
Misha Brukman
b2cf47cfc1 * Institute a hack for the Sparc call to mmap() to get our generated code to be
laid out closer to the VM so that calls to library functions (e.g. puts()) and
  callback (e.g.  JITResolver::CompilationCallback) fit into 30 bits of the call
  instruction.
* Abort if architecture is not yet supported (not X86 or Sparc) because it
  likely requires a different set of parameters to mmap() .
* Stop using hard-coded values for page size; use sysconf(_SC_PAGESIZE) instead.

llvm-svn: 6610
2003-06-04 19:45:25 +00:00
Brian Gaeke
abf48764ff Make writeNumber() void. Get ready to decouple it from .byte directive output.
llvm-svn: 6609
2003-06-04 18:17:22 +00:00
Vikram S. Adve
aa4d93b55a Modify tracing rules to use opt -trace[m] instead of llc -trace[m].
llvm-svn: 6607
2003-06-04 14:24:52 +00:00
Sumant Kowshik
a961b3c083 Made changes suggested by Chris
llvm-svn: 6606
2003-06-04 08:03:57 +00:00
Sumant Kowshik
9336b0901b Made changes suggested by Chris; Renamed 'union' function to unionSetsWith
llvm-svn: 6605
2003-06-04 08:00:05 +00:00
Chris Lattner
95d21756aa Clean up previous code.
Add new combination to turn seteq X, 0 -> not(cast X to bool)

llvm-svn: 6604
2003-06-04 05:10:11 +00:00
Chris Lattner
9bd4cfa823 Add new setCondition member
llvm-svn: 6603
2003-06-04 05:08:31 +00:00
Misha Brukman
b126ea43eb I have finally seen the light. The code to change the opcode must live higher in
the loop, and in both cases. In the first case, it is a VReg that is a constant
so it may be actually converted to a constant. In the second case, it is already
a constant, but then if it doesn't change its type (e.g. to become a register
and have the value loaded from memory if it is too large to live in its
instruction field), we must change the opcode BEFORE the 'continue', otherwise
we miss the opportunity.

llvm-svn: 6602
2003-06-04 04:54:06 +00:00
Misha Brukman
29b191bbed Added the 4.7 instruction class and all the FMOVcc instructions in them.
llvm-svn: 6601
2003-06-04 04:48:31 +00:00
Chris Lattner
e52c988e7e Modernize testcase
llvm-svn: 6600
2003-06-04 04:47:40 +00:00
Chris Lattner
b2ea03d03a Implement combination of boolean not with branch
llvm-svn: 6599
2003-06-04 04:46:00 +00:00
Chris Lattner
ce0e236e49 Add new test for inverting branches
llvm-svn: 6598
2003-06-04 04:37:46 +00:00
Misha Brukman
168c089a59 Comment out opcodes currently unused in the Sparc backend.
llvm-svn: 6597
2003-06-04 02:57:55 +00:00
Chris Lattner
7190c04fc5 No really, you _cannot use_ getelementptr on an unsized type: that makes
no sense.

llvm-svn: 6595
2003-06-04 02:35:35 +00:00
Misha Brukman
ee88ddfc38 Added instruction format class 3.15 and floating-point compare instructions.
llvm-svn: 6594
2003-06-04 02:26:14 +00:00
Vikram S. Adve
15a27e40c6 Undo one of those last fixes -- it was incorrect.
llvm-svn: 6593
2003-06-04 02:10:37 +00:00
Misha Brukman
6e22f0fa52 Sparc's dlsym() requires the special operand RTLD_SELF to find a symbol in the
currently-running process.

llvm-svn: 6592
2003-06-04 01:57:22 +00:00
Chris Lattner
48586849db Avoid generating a getelementptr instruction of a function
llvm-svn: 6591
2003-06-04 01:24:40 +00:00
Misha Brukman
a69a008010 Pass through the emitConstantPool() call to the real emitter.
llvm-svn: 6590
2003-06-03 20:00:49 +00:00
Brian Gaeke
0caf021e69 Make the write*map methods more self-contained. Document some more.
llvm-svn: 6589
2003-06-03 19:30:15 +00:00
Vikram S. Adve
50cd0cd309 Improved how tracing can be used:
-- added new targets %.trace-out-llc and %.trace-out-cbe
-- either TRACE=yes or TRACEM=yes is still needed and chooses how to trace

llvm-svn: 6585
2003-06-03 18:56:57 +00:00
Chris Lattner
7aaea42f1e Minor cleanups:
* Document the MOTy namespace correctly for doxygen
  * Eliminate usage of the MachineOpCode typedef, which should eventually
    be eliminated entirely.

llvm-svn: 6584
2003-06-03 15:42:53 +00:00
Chris Lattner
1cb899dd19 Remove usage of typedef
llvm-svn: 6583
2003-06-03 15:41:58 +00:00
Chris Lattner
846c593142 Remove use of enum
llvm-svn: 6582
2003-06-03 15:41:45 +00:00
Chris Lattner
92fba99afb Add namespace comments for doxygen
llvm-svn: 6581
2003-06-03 15:31:23 +00:00
Chris Lattner
b91ad88918 There are now no uses of NonCopyableV
llvm-svn: 6580
2003-06-03 15:30:48 +00:00
Chris Lattner
775ec2f5fe Add doxygen comment for namespace
llvm-svn: 6579
2003-06-03 15:30:37 +00:00
Chris Lattner
b563188e45 Add comment for doxygen for namespace
llvm-svn: 6578
2003-06-03 15:30:13 +00:00
Chris Lattner
506de1c176 Minor cleanups:
* LLVM #include should use "", not <>
  * Fix line wrapping
  * Remove noncopyable base class to improve doxygen output

llvm-svn: 6577
2003-06-03 15:30:01 +00:00
Chris Lattner
b1c22980b1 Remove noncopyable base class as it was making the doxygen docs harder to read
llvm-svn: 6576
2003-06-03 15:29:12 +00:00
Chris Lattner
347bd5fb6f Remove noncopyableV base classes, as they were confusing the doxygen documentation,
making it harder to read.

llvm-svn: 6575
2003-06-03 15:28:40 +00:00
Brian Gaeke
e55a000638 I documented this file, in an attempt to understand it, with a view toward
rewriting it.  I also vacuumed out all the commented-out code and
inaccurate comments, etc.

(We need to put the mapping information in a data structure so that we can
pass it out to the JIT, instead of automagically converting it to .byte
directives.)

llvm-svn: 6574
2003-06-03 07:56:05 +00:00
Chris Lattner
b35f33f39e Spiff up options a bit
llvm-svn: 6573
2003-06-03 05:07:28 +00:00
Chris Lattner
88a500368b Use the new -o tablegen option
llvm-svn: 6572
2003-06-03 05:06:33 +00:00
Chris Lattner
3d2a9dcc14 Add -o support for TableGen
I figure that misha has done a lot of things on my todo list, the least I
can do is reciprocate a bit.  :)

llvm-svn: 6571
2003-06-03 05:04:42 +00:00
Chris Lattner
5531141028 Make tablegen use more structured command line options
llvm-svn: 6570
2003-06-03 04:56:29 +00:00
Chris Lattner
186c756f44 Fix minor bug
llvm-svn: 6569
2003-06-03 04:40:06 +00:00
Misha Brukman
e5c5705c02 Constants are laid out in memory in PC-relative form.
llvm-svn: 6568
2003-06-03 03:24:12 +00:00
Misha Brukman
1b73726832 Added opcode conversion for conditional move of integers.
llvm-svn: 6567
2003-06-03 03:23:35 +00:00
Misha Brukman
28430ecbc6 * Convert load/store opcodes from register to immediate forms.
* Stop code from wrapping to the next line.

llvm-svn: 6566
2003-06-03 03:21:58 +00:00
Misha Brukman
77188166d5 Convert load/store opcodes from register to immediate forms, if necessary.
llvm-svn: 6565
2003-06-03 03:20:57 +00:00
Misha Brukman
4c382415f6 Store instructions are different from other Format 3.1/3.2 instructions in that
they prefer the destination register to be last. Thus, two new classes were made
for them that accomodate for having this layout of operands (F3_1rd, F3_2rd).

llvm-svn: 6564
2003-06-03 03:20:14 +00:00
Misha Brukman
7a5eac8485 Moved code to modify the opcode from 'reg' to 'imm' form to a more logical place.
llvm-svn: 6563
2003-06-03 03:18:20 +00:00
Misha Brukman
2a257c6d5d * Added section A.34: Move FP register on int reg condition (FMOVr)
* Labeled sections that are not currently used in the Sparc backend as not
  requiring completion at this time.

llvm-svn: 6562
2003-06-03 01:16:27 +00:00