Thanks, I think I have figured it out. However, I moved on to SplitEditor class. It was quite well done; I must say. Although the SpillAnalysis is a bit heavy-weight for the stuff I would like to do.<div><br></div><div>- Jeff<br>
<br><div class="gmail_quote">On Fri, Jan 21, 2011 at 6:11 PM, David A. Greene <span dir="ltr"><<a href="mailto:greened@obbligato.org">greened@obbligato.org</a>></span> wrote:<br><blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex;">
<div><div></div><div class="h5">Jeff Kunkel <<a href="mailto:jdkunk3@gmail.com">jdkunk3@gmail.com</a>> writes:<br>
<br>
> Spiller::Spill( LiveInterval *li,<br>
>                           SmallVectorImpl<LiveInterval*> &newIntervals,<br>
>                           const SmallVectorImpl<LiveInterval*> &spillIs );<br>
><br>
> has two reference vectors which contain a small list of Live<br>
> Intervals. What is the register allocator's job to do with these<br>
> intervals other than analysis. What more needed other than to know<br>
> they exist?<br>
<br>
</div></div>It's been a while since I looked at this, so Evan can correct any<br>
mistakes I make.  :)<br>
<br>
spillIs is passed into the spiller and indicates the intervals that<br>
alias the interval being spilled.  In other words, they indicate<br>
registers that are sub-/super-registers of the one being spilled.  These<br>
intervals must be spilled along with the "primary" one.<br>
<br>
I think this comes into play in linear scan when it has to force a<br>
reallocation of a physical register and must backtrack.  The details of<br>
this are very fuzzy to me.<br>
<br>
The newIntervals vector gets filled in by LiveIntervalAnalysis with the<br>
new intervals created when spilling in done.  Spilling is essentially a<br>
splitting of a live interval into multiple sub-intervals.  Those<br>
sub-intervals will need to be allocated to registers.  The newIntervals<br>
output tells the register allocator the new intervals it must add to its<br>
work queue.<br>
<br>
                             -Dave<br>
</blockquote></div><br></div>