+ Tom Stellard<div><br></div><div>This is separated from D6188, and focuses mostly on IndVarSimplify. </div><div><br></div><div>Jingyue</div><div><div><br><div class="gmail_quote">On Mon Nov 10 2014 at 10:08:31 AM Jingyue Wu <<a href="mailto:jingyue@google.com">jingyue@google.com</a>> wrote:<br><blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex">Hi atrick, jholewinski, eliben, meheff,<br>
<br>
IndVarSimplify should not widen an indvar if arithmetics on the wider<br>
indvar are more expensive than those on the narrower indvar. For<br>
instance, although NVPTX64 treats i64 as a legal type, an ADD on i64 is<br>
twice as expensive as that on i32, because the hardware needs to<br>
simulate a 64-bit integer using two 32-bit integers.<br>
<br>
Split from D6188, and based on D6195 which adds NVPTXTargetTransformInfo.<br>
<br>
Fixes PR21148.<br>
<br>
<a href="http://reviews.llvm.org/D6196" target="_blank">http://reviews.llvm.org/D6196</a><br>
<br>
Files:<br>
  lib/Target/NVPTX/<u></u>NVPTXTargetTransformInfo.cpp<br>
  lib/Transforms/Scalar/<u></u>IndVarSimplify.cpp<br>
  test/Transforms/<u></u>IndVarSimplify/no-widen-<u></u>expensive.ll<br>
</blockquote></div></div></div>