1
0
mirror of https://github.com/RPCS3/llvm-mirror.git synced 2024-10-27 22:12:47 +01:00
Commit Graph

2770 Commits

Author SHA1 Message Date
Chris Lattner
58fce6cc00 Rename DataStructure to LocalDataStructures
llvm-svn: 2873
2002-07-10 22:42:53 +00:00
Chris Lattner
567a072523 New implementation of data structure analysis
This diff is completely meaningless because this is a replacement
implementation.

llvm-svn: 2872
2002-07-10 22:42:17 +00:00
Chris Lattner
5d62e136c5 New implementation of data structure analysis. Only local analysis has been
implemented so far.

llvm-svn: 2871
2002-07-10 22:38:08 +00:00
Chris Lattner
83577a047e Disable folding g-e-p instructions into loads and stores.
llvm-svn: 2870
2002-07-10 22:37:17 +00:00
Chris Lattner
a6842aa353 Disable pool allocation stuff until data structure analysis is sorted back out
llvm-svn: 2869
2002-07-10 22:36:47 +00:00
Chris Lattner
d00a93318e Reimplement data structure analysis
llvm-svn: 2868
2002-07-10 22:36:26 +00:00
Chris Lattner
7185d128c3 Fix broken test
llvm-svn: 2867
2002-07-10 22:31:09 +00:00
Vikram S. Adve
ad64895c22 Include Makefile.singlesrc in order to compile .c tests.
Some of these are not regression tests and this directory needs
to be reorganized, but the tests are important.

llvm-svn: 2866
2002-07-10 22:02:37 +00:00
Vikram S. Adve
e0f2f074bb Some of these are feature tests, not regression tests.
This directory needs to be reorganized and some of the tests
need changes to make them executable.  Also comments would help...

llvm-svn: 2865
2002-07-10 21:54:05 +00:00
Vikram S. Adve
8967349e85 Bug fix: cast (bool) has higher precedence than %... who knew!
llvm-svn: 2864
2002-07-10 21:51:46 +00:00
Vikram S. Adve
36b62ee33a Add support for marking each operand as a %hh, %hm, %lm or %lo.
Represent previous bools and these ones with flags in a single byte
per operand.

llvm-svn: 2863
2002-07-10 21:50:57 +00:00
Vikram S. Adve
cd651d5577 Added a few more methods for creating instructions.
llvm-svn: 2862
2002-07-10 21:49:38 +00:00
Vikram S. Adve
cd544ed252 Fix print of BB name in dump().
llvm-svn: 2861
2002-07-10 21:45:30 +00:00
Vikram S. Adve
62f569e4ea Add support for marking each operand as a %hh, %hm, %lm or %lo.
Represent previous bools and these ones with flags in a single byte
per operand.

llvm-svn: 2860
2002-07-10 21:45:04 +00:00
Vikram S. Adve
b2fc122acd Changed interface to insertCallerSavingCode().
llvm-svn: 2859
2002-07-10 21:42:42 +00:00
Vikram S. Adve
56ae7788d7 Stop using pseudo-instructions (SETX, SETUW, SETSW)
and generate actual machine instruction sequences directly.

llvm-svn: 2858
2002-07-10 21:42:13 +00:00
Vikram S. Adve
268137274b Add support to print %hh, %hm, %lm, or %lo in an operand field.
llvm-svn: 2857
2002-07-10 21:41:21 +00:00
Vikram S. Adve
3df324e6e8 Major overhaul to stop using pseudo-instructions (SETX, SETUW, SETSW)
and generate actual machine instruction sequences directly.

Also a couple of bug fixes in code for putting constants into registers:
-- Do *not* sign-extend unsigned constant that is shorter than int reg size
-- Fix handling of address constant (a GlobalValue) vs. constant that
   must be loaded.

llvm-svn: 2856
2002-07-10 21:39:50 +00:00
Vikram S. Adve
9d7346bbf9 More important fixes:
-- FP argument to a function with no prototype going on stack
   was not being copied to the stack in colorCallArgs().
-- Put caller-saving code *before* argument copying code so that
   we don't trash a register before saving it!
-- Two other minor fixes.

llvm-svn: 2855
2002-07-10 21:36:00 +00:00
Vikram S. Adve
47a8810964 Put caller-saving code *before* argument copying code!
(This file has a minor change required for this fix.)

llvm-svn: 2854
2002-07-10 21:30:17 +00:00
Vikram S. Adve
4543e3c252 Minor change in comments.
llvm-svn: 2853
2002-07-10 21:29:22 +00:00
Chris Lattner
c27a459095 *** empty log message ***
llvm-svn: 2852
2002-07-10 16:48:17 +00:00
Chris Lattner
23cfaec9ce Allow specifying a module for context instead of a slot calculator directly
llvm-svn: 2851
2002-07-10 16:48:14 +00:00
Chris Lattner
0f86d605e1 Add a new testcase. It actually is not infinite looping. It just takes
FOREVER to run.  That's the bug.  :)

llvm-svn: 2850
2002-07-09 19:58:06 +00:00
Vikram S. Adve
391040c398 Disabling reassociate pass until it is fixed.
llvm-svn: 2849
2002-07-09 19:53:09 +00:00
Chris Lattner
617103c154 New testcase for problem effecting mst
llvm-svn: 2848
2002-07-09 19:41:21 +00:00
Anand Shukla
33b491bba2 changed mem_fun to std::mem_fun
llvm-svn: 2847
2002-07-09 19:18:56 +00:00
Anand Shukla
b9a34f17ff added std:: to hash_set
llvm-svn: 2846
2002-07-09 19:18:16 +00:00
Anand Shukla
e2179159e5 Added std:: to mem_fun for 64-bit gcc
llvm-svn: 2845
2002-07-09 19:16:59 +00:00
Chris Lattner
128410dd4c Implementing shift left & shift right on pointers
llvm-svn: 2844
2002-07-09 18:42:36 +00:00
Chris Lattner
bc68100d59 Include header in the compiler-neutral location
llvm-svn: 2843
2002-07-09 16:50:24 +00:00
Vikram S. Adve
f5760a424d Added support for printing constant global references to
assembly.

llvm-svn: 2842
2002-07-09 12:30:29 +00:00
Vikram S. Adve
b06eb93a26 Add makefile-mode flag for emacs.
llvm-svn: 2841
2002-07-09 12:04:21 +00:00
Vikram S. Adve
c98bc8cd5e Fix iteration and InsertPos bugs introduced when Chris changed over to ilist.
llvm-svn: 2840
2002-07-08 23:37:07 +00:00
Vikram S. Adve
901578090d Numerous changes in interface to class SparcRegInfo corresponding to
changes in class MachineRegInfo (see MachineRegInfo.h for details).

Added {LD,ST}[X]FSR instructions.

llvm-svn: 2839
2002-07-08 23:34:10 +00:00
Vikram S. Adve
35bc4cb020 class MachineCodeForBasicBlock is now an annotation on BasicBlock.
llvm-svn: 2838
2002-07-08 23:31:24 +00:00
Vikram S. Adve
8b06b38495 BA no longer has the unused CC operand.
llvm-svn: 2837
2002-07-08 23:30:59 +00:00
Vikram S. Adve
a771830ea1 Have to save a boolean (setCC) value whenever use is outside the current
basic block.

Mark setCCInstr used as dest. of conditional-move as both a def and a use.

BA instruction no longer has the unused CC argument.

llvm-svn: 2836
2002-07-08 23:30:14 +00:00
Vikram S. Adve
30cc745aec BA has only one argument.
Added LDFSR, LDXFSR, STFSR and STXFSR.
Fixed operands info for RDCCR, WRCCR.

llvm-svn: 2835
2002-07-08 23:25:17 +00:00
Vikram S. Adve
b94ede185c Significant changes to correctly spill CC registers and to correctly
handle conditional move instructions:
-- cpMem<->Reg functions now support CC registers (int and FP) correctly.
   Also, cpMem<->Reg functions now return a vector of machine instructions.
-- Scratch registers must be explicitly provided to cpMem<->Reg when
   needed, since CC regs need one to be copied to/from memory.
-- CC regs are saved to a scratch register instead of stack.
-- All regs used by a instruction are now recorded in MachineInstr::regsUsed,
   since regs used to save values *across* an instruction are not obvious
   either from the operands or from the LiveVar sets.
-- An (explicit or implicit) operand may now be both a def and a use.
   This is needed for conditional move operations.
   So an operand may need spill code both before and after the instruction.

Other changes:
-- Added several get{Class,Type} functions.
-- Added unified-to-local register number conversion.
-- class MachineCodeForBasicBlock is now an annotation on BasicBlock.
-- Suggest/Color methods may modify the MachineInstr (and always did),
   so don't make that argument const!
-- Caller-saving code doesn't need its special purpose code for
   handling CC registers since cpMem<->Reg handle those correctly now.

llvm-svn: 2834
2002-07-08 23:23:12 +00:00
Vikram S. Adve
0b32273208 Significant changes to correctly spill CC registers and to correctly
handle conditional move instructions:
-- cpMem<->Reg functions now support CC registers (int and FP) correctly.
-- Scratch registers must be explicitly provided to cpMem<->Reg when
   needed, since CC regs need one to be copied to/from memory.
-- CC regs are saved to a scratch register instead of stack.
-- All regs used by a instruction are now recorded in MachineInstr::regsUsed,
   since regs used to save values *across* an instruction are not obvious
   either from the operands or from the LiveVar sets.
-- An (explicit or implicit) operand may now be both a def and a use.
   This is needed for conditional move operations.
   So an operand may need spill code both before and after the instruction.
-- class MachineCodeForBasicBlock is now an annotation on BasicBlock.

llvm-svn: 2833
2002-07-08 23:15:32 +00:00
Vikram S. Adve
a8c7633d5b MachineInstr* in vector are not const (and never really were)
because operands may be modified directly to set register.
Also, class MachineCodeForBasicBlock is now an annotation on BasicBlock.

llvm-svn: 2832
2002-07-08 23:07:26 +00:00
Vikram S. Adve
3e8b72f0e3 Rename static struct Initializer to avoid name conflict with BB.
llvm-svn: 2831
2002-07-08 23:04:31 +00:00
Vikram S. Adve
25d81936d2 Fix printing of BB in dump.
llvm-svn: 2830
2002-07-08 23:03:54 +00:00
Vikram S. Adve
f6d73e9711 Moved class MachineCodeForBasicBlock to MachineCodeForBasicBlock.h.
This class is now an annotation on BasicBlock.

llvm-svn: 2829
2002-07-08 23:03:10 +00:00
Vikram S. Adve
5b4c4a9326 MachineInstr::dump() now takes no arguments.
llvm-svn: 2828
2002-07-08 23:01:46 +00:00
Vikram S. Adve
a2381d3998 Implementation of class MachineCodeForBasicBlock.
Moved here from MachineInstr.cpp to make it an annotation on BasicBlock.

llvm-svn: 2827
2002-07-08 23:01:11 +00:00
Vikram S. Adve
4efbb9c931 A single MachineInstr operand may now be both a def and a use,
so additional dep. edges have to be added.
This was needed to correctly handle conditional move instructions!
MachineCodeForBasicBlock is now an annotation on BasicBlock.
Renamed "earliestForNode" to "earliestReadyTimeForNode".

llvm-svn: 2826
2002-07-08 22:59:23 +00:00
Vikram S. Adve
daf9b38ed9 A single MachineInstr operand may now be both a def and a use.
llvm-svn: 2825
2002-07-08 22:56:34 +00:00
Vikram S. Adve
bfd03d50ce cpMem<->Reg functions now support CC registers (int and FP) correctly.
A scratch register has to be provided when needed to do the copy.
Also, cpMem<->Reg functions now return a vector of machine instructions.

Added several get{Class,Type} functions.

Suggest/Color methods may modify the MachineInstr (and always did),
so don't make that argument const!

llvm-svn: 2824
2002-07-08 22:44:14 +00:00