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

23 Commits

Author SHA1 Message Date
Evan Cheng
d6e3e4d746 Fixed a stack slot coloring with reg bug: do not update implicit use / def when doing forward / backward propagation.
llvm-svn: 71574
2009-05-12 18:31:57 +00:00
Evan Cheng
7c7809eebd Eliminate a compiler warning.
llvm-svn: 71456
2009-05-11 18:40:35 +00:00
Bill Wendling
6edd6ef74f Just turn aggressive stack coloring off at -O3.
llvm-svn: 71140
2009-05-07 01:33:38 +00:00
Bill Wendling
7c50dcd02e Temporarily revert r71010. It was causing massive failures during self-hosting.
llvm-svn: 71138
2009-05-07 01:27:25 +00:00
Evan Cheng
984da04cd0 Enable stack coloring with regs at -O3.
llvm-svn: 71010
2009-05-05 20:30:36 +00:00
Evan Cheng
77e14276e0 Do not substitute if the new register isn't in the register class of the operand being updated.
llvm-svn: 70953
2009-05-05 00:46:16 +00:00
Evan Cheng
ecfc8e8464 Do forward and backward substitution to eliminate loads and stores when possible.
llvm-svn: 70937
2009-05-04 23:13:13 +00:00
Evan Cheng
bb12bac53b The stack slots which share the same stack slot after coloring can, but do not have to, use the same register. In fact, they each may have different register class requirements.
llvm-svn: 70815
2009-05-04 00:24:50 +00:00
Evan Cheng
a64d6b8822 Typo.
llvm-svn: 70792
2009-05-03 19:10:11 +00:00
Evan Cheng
28aa6c41d1 In some rare cases, the register allocator can spill registers but end up not utilizing registers at all. The fundamental problem is linearscan's backtracking can end up freeing more than one allocated registers. However, reloads and restores might be folded into uses / defs and freed registers might not be used at all.
VirtRegMap keeps track of allocations so it knows what's not used. As a horrible hack, the stack coloring can color spill slots with *free* registers. That is, it replace reload and spills with copies from and to the free register. It unfold instructions that load and store the spill slot and replace them with register using variants.

Not yet enabled. This is part 1. More coming.

llvm-svn: 70787
2009-05-03 18:32:42 +00:00
Owen Anderson
32d31bc5cc Enable stack slot coloring DCE. Evan's spiller fixes were needed before this could happen.
llvm-svn: 65501
2009-02-26 04:47:57 +00:00
Owen Anderson
ffcb59129f Add a debugging option for SSC DCE.
llvm-svn: 65375
2009-02-24 05:44:18 +00:00
Owen Anderson
9268f1ec92 Add a quick pass to the stack slot colorer to eliminate some trivially redundant spills after coloring.
Ideally these would never get created in the first place, but until we enhance the spiller to have a more
global picture of what's happening, this is necessary for code quality in some circumstances.

llvm-svn: 65120
2009-02-20 09:11:36 +00:00
Dan Gohman
c157324a23 Teach StackSlotColoring to update MachineMemOperands when
changing the stack slots on an instruction, to keep them
consistent with the actual memory addresses.

llvm-svn: 60584
2008-12-05 05:31:14 +00:00
Dan Gohman
2ed6f318da Adjust whitespace in debug messages to be more consistent
with other debug messages.

llvm-svn: 57543
2008-10-15 02:57:38 +00:00
Dan Gohman
30c5ce1b7d Switch the MachineOperand accessors back to the short names like
isReg, etc., from isRegister, etc.

llvm-svn: 57006
2008-10-03 15:45:36 +00:00
Evan Cheng
1ded8b6ad6 Instead of setPreservesAll, just mark them preseving machine loop info and machine dominators.
llvm-svn: 56475
2008-09-22 22:21:38 +00:00
Evan Cheng
3bcf0cdd72 Mark several codegen passes as preserving all analysis.
llvm-svn: 56469
2008-09-22 20:58:04 +00:00
Dan Gohman
e1f9be27bc Tidy up several unbeseeming casts from pointer to intptr_t.
llvm-svn: 55779
2008-09-04 17:05:41 +00:00
Dan Gohman
1f42b96c7e Make stack slot coloring's debug output more consistent with
other passes.

llvm-svn: 53415
2008-07-10 19:49:32 +00:00
Evan Cheng
73bdede529 Remove option used to debug stack coloring bugs. It's no longer needed since stack coloring is now bug free.
llvm-svn: 52644
2008-06-23 21:24:32 +00:00
Evan Cheng
6e5a126667 Instead of adding an isSS field to LiveInterval to denote stack slot. Use top bit of 'reg' instead. If the top bit is set, than the LiveInterval represents a stack slot live interval.
llvm-svn: 52639
2008-06-23 21:03:19 +00:00
Evan Cheng
2fc7954878 Add a stack slot coloring pass. Not yet enabled.
llvm-svn: 51934
2008-06-04 09:18:41 +00:00