This is the mail archive of the gcc-patches@gcc.gnu.org mailing list for the GCC project.


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]
Other format: [Raw text]

Re: Improving reload inheritance code generation and predictability


On 11/18/10 12:34, Bernd Schmidt wrote:
On 11/18/2010 03:46 PM, Jeff Law wrote:
Basically we start searching forward in the stream from the current insn
needing a reload noting uses of spill regs as we go.
Isn't this quadratic in the number of insns?
Potentially, yes. If we want to go forward, then we probably would need a PARAM to limit the number of insns scanned.

The further away
from the insn needing reloads the spill reg is used the more desirable
that spill reg becomes.  If we can't find all the spill regs before
reaching the end of the block, the remaining spill regs are considered
the most desirable and we allocate these stragglers in the round-robin
fashion.
Ideally we'd allocate the valuable ones only to reloads which we know
we'll want to inherit in the future.
True. But that means knowing the set of reloads for future insns.

jeff


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]