Good point. Fixed in r150553.<div><br></div><div>- Lang.<br><br><div class="gmail_quote">On Tue, Feb 14, 2012 at 4:23 PM, Jakob Stoklund Olesen <span dir="ltr"><<a href="mailto:stoklund@2pi.dk">stoklund@2pi.dk</a>></span> wrote:<br>
<blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex"><div class="im"><br>
On Feb 14, 2012, at 10:51 AM, Lang Hames <<a href="mailto:lhames@gmail.com">lhames@gmail.com</a>> wrote:<br>
<br>
>   // Live-in register might not be used at all.<br>
>   if (!SeenDefUse) {<br>
> -    DEBUG(dbgs() << " live through");<br>
> -    end = getMBBEndIdx(MBB);<br>
> +    if (isAllocatable(interval.reg) || isReserved(interval.reg)) {<br>
> +      // This must be an entry block or landing pad - we asserted so on entry<br>
> +      // to the function. For these blocks the interval is dead on entry.<br>
> +      DEBUG(dbgs() << " dead");<br>
> +      end = start.getDeadSlot();<br>
> +    } else {<br>
<br>
</div>When a physreg is marked as live-in to a block, but it turns out it is really dead, we shouldn't give it any live range at all in the basic block.<br>
<br>
I don't want live ranges to end at the getDeadSlot() if there is no underlying instruction backing the SlotIndex.<br>
<br>
Ideally, we should only ever refer to the getBlockSlot() of getMBBStartIdx() and getMBBEndIdx().<br>
<span class="HOEnZb"><font color="#888888"><br>
/jakob<br>
<br>
</font></span></blockquote></div><br></div>