I've remove the conditional. What's the best way to figure out how the remainder of the patch affects compile time?<br><br><div class="gmail_quote">On Wed, Feb 22, 2012 at 11:24 AM, 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 20, 2012, at 10:22 PM, Craig Topper <<a href="mailto:craig.topper@gmail.com">craig.topper@gmail.com</a>> wrote:<br>
<br>
> Author: ctopper<br>
> Date: Tue Feb 21 00:22:36 2012<br>
> New Revision: 151038<br>
><br>
> URL: <a href="http://llvm.org/viewvc/llvm-project?rev=151038&view=rev" target="_blank">http://llvm.org/viewvc/llvm-project?rev=151038&view=rev</a><br>
> Log:<br>
> Merge some tables in generated RegisterInfo file. Store indices into larger table instead of pointers to reduce relocations and shrink table size on 64-bit builds. Shaves ~24K off X86MCTargetDesc.o<br>
<br>
</div>These functions are extremely hot. How does this affect compile times?<br>
<div class="im"><br>
>   const unsigned *getAliasSet(unsigned RegNo) const {<br>
>     // The Overlaps set always begins with Reg itself.<br>
> -    return get(RegNo).Overlaps + 1;<br>
> +    if (get(RegNo).Overlaps < 0) return 0;<br>
> +    return Overlaps + get(RegNo).Overlaps + 1;<br>
>   }<br>
<br>
</div>Please don't add conditional code to these functions. They should never return NULL anyway.<br>
<br>
It's probably easiest to give NOREG a dummy empty set.<br>
<span class="HOEnZb"><font color="#888888"><br>
/jakob<br>
<br>
</font></span></blockquote></div><br><br clear="all"><br>-- <br>~Craig<br>