Commit Graph

17 Commits

Author SHA1 Message Date
Chris Lattner 1905ae69c1 When a virtual register is folded into an instruction, keep track of whether
it was a use, def, or both.  This allows us to be less pessimistic in our
analysis of them.  In practice, this doesn't make a big difference, but it
doesn't hurt either.

llvm-svn: 16632
2004-10-01 23:15:36 +00:00
Alkis Evlogimenos cc37da1bcc Document this class a bit :-)
llvm-svn: 16626
2004-10-01 00:35:07 +00:00
Chris Lattner 39fef8df03 Use longer and more explicit names for instance vars (particularly important
data structures).  Fix the print method to send to the right ostream, not
always cerr.  Delete typedefs that are only used once.

llvm-svn: 16606
2004-09-30 02:15:18 +00:00
Chris Lattner e2b77d57c0 Reindent code, improve comments, move huge nested methods out of classes,
prune #includes, add print/dump methods, etc.  No functionality changes.

llvm-svn: 16604
2004-09-30 01:54:45 +00:00
Reid Spencer 7c16caa336 Changes For Bug 352
Move include/Config and include/Support into include/llvm/Config,
include/llvm/ADT and include/llvm/Support. From here on out, all LLVM
public header files must be under include/llvm/.

llvm-svn: 16137
2004-09-01 22:55:40 +00:00
Alkis Evlogimenos 7eb2b1892b Add function to clear all virtual->physical mappings but not assigned
stack slots. This is in preparation for the iterative linear scan.

llvm-svn: 15032
2004-07-20 13:28:17 +00:00
Alkis Evlogimenos fd735bcf28 Add method to assign stack slot to virtual register without creating a
new one.

llvm-svn: 13895
2004-05-29 20:38:05 +00:00
Alkis Evlogimenos e3cec71bdc Add grow() member that grows the maps when the number of virtual
registers in the function has changed.

llvm-svn: 13893
2004-05-29 19:03:29 +00:00
Alkis Evlogimenos 31953c7a10 Add a spiller option to llc. A simple spiller will come soon. When we get CFG in the machine code represenation a global spiller will also be possible. Also document the linear scan register allocator but mark it as experimental for now.
llvm-svn: 12062
2004-03-01 23:18:15 +00:00
Alkis Evlogimenos b76d234ee9 Add the long awaited memory operand folding support for linear scan
llvm-svn: 12058
2004-03-01 20:05:10 +00:00
Alkis Evlogimenos e669caafe0 Rename member function to be consistent with the rest.
llvm-svn: 11898
2004-02-27 06:11:15 +00:00
Alkis Evlogimenos d8bace7f60 Add DenseMap template and actually use it for for mapping virtual regs
to objects.

llvm-svn: 11840
2004-02-25 21:55:45 +00:00
Alkis Evlogimenos 1dd872ce94 Move machine code rewriter and spiller outside the register
allocator.

The implementation is completely rewritten and now employs several
optimizations not exercised before. For example for 164.gzip we have
997 loads and 699 stores vs the 1221 loads and 880 stores we have
before.

llvm-svn: 11798
2004-02-24 08:58:30 +00:00
Alkis Evlogimenos 63aea0b6a5 Add predicates for checking if a virtual register has a physical
register mapping or a stack slot mapping.

llvm-svn: 11795
2004-02-24 06:30:36 +00:00
Alkis Evlogimenos 8b571a64ac Make enum private as it is an implementation detail.
llvm-svn: 11782
2004-02-23 23:49:40 +00:00
Alkis Evlogimenos ab77b05d8c Remove '4Virt' from member function names as it is obvious.
llvm-svn: 11781
2004-02-23 23:47:10 +00:00
Alkis Evlogimenos c794a9060f Refactor VirtRegMap out of RegAllocLinearScan as the first part of bug
251 (providing a generic machine code rewriter/spiller).

llvm-svn: 11780
2004-02-23 23:08:11 +00:00