<div dir="ltr">On 7 October 2013 23:42, Quentin Colombet <span dir="ltr"><<a href="mailto:qcolombet@apple.com" target="_blank">qcolombet@apple.com</a>></span> wrote:<br><div class="gmail_extra"><div class="gmail_quote">
<blockquote class="gmail_quote" style="margin:0px 0px 0px 0.8ex;border-left-width:1px;border-left-color:rgb(204,204,204);border-left-style:solid;padding-left:1ex"><div style="word-wrap:break-word"><div>0001:</div><div>LGTM.</div>
</div></blockquote><div><br></div><div>+1.</div><div><br></div><div><br></div><blockquote class="gmail_quote" style="margin:0px 0px 0px 0.8ex;border-left-width:1px;border-left-color:rgb(204,204,204);border-left-style:solid;padding-left:1ex">
<div style="word-wrap:break-word"><div>0002:<br></div><div><div>Unless I am missing the semantic of CHECK-DAG, this seems wrong:</div><div>+;CHECK-DAG: <span style="white-space:pre-wrap">   </span>str<span style="white-space:pre-wrap">     </span>r0, [sp, #8]</div>
<div>+;CHECK-DAG: <span style="white-space:pre-wrap">     </span>add<span style="white-space:pre-wrap">     </span>r0, sp, #8</div><div>How could a str-add sequence with a write-after-read dependency be semantically equivalent to a add-str with a read-after-write dependency?</div>
</div></div></blockquote><div><br></div><div>If you're referring to the first change, I think it's up to add r0 + str r2, which could then be:</div><div><br></div><div><div>;CHECK: <span class="" style="white-space:pre">    </span>str<span class="" style="white-space:pre">       </span>r0, [sp, #8]</div>
<div>;CHECK-DAG: <span class="" style="white-space:pre">        </span>add<span class="" style="white-space:pre">       </span>r0, sp, #8</div><div>;CHECK-DAG: <span class="" style="white-space:pre">     </span>str<span class="" style="white-space:pre">       </span>r2, [sp, #12]</div>
</div><div><br></div><div>This also looks dangerous:</div><div><br></div><div><div>+; CHECK-DAG: vld1.32 {[[REG1:d[0-9]+]][0]}, {{\[}}[[BASE]]:32]</div><div>+; CHECK-DAG: add [[BASE2:r[0-9]+]], [[BASE]], #4</div><div>+; CHECK-DAG: vld1.32 {[[REG1]][1]}, {{\[}}[[BASE2]]:32]</div>
</div><div><br></div><div>one will define REG1 and the other will use, in this case, it's not possible for them to be in different order. If CHECK-DAG can deal with that and impose the correct ordering, than that's fine.</div>
<div><br></div><div>Same here, with SOURCE and ADDR:</div><div><br></div><div><div>+; CHECK-DAG:  vst1.64 {d{{[0-9]+}}, d{{[0-9]+}}}, [r[[SOURCE:[0-9]+]]:128]</div><div>+; CHECK-DAG:  add.w r[[ADDR:[0-9]+]], r[[SOURCE]], {{r[0-9]+}}, lsl #2</div>
<div>+; CHECK-DAG:  vld1.32 {[[DREG:d[0-9]+]][], [[DREG2:d[0-9]+]][]}, [r[[ADDR]]:32]</div><div><br></div></div><div>In this case, it looks impossible to have it in any other order...</div><div><br></div><div><br></div><blockquote class="gmail_quote" style="margin:0px 0px 0px 0.8ex;border-left-width:1px;border-left-color:rgb(204,204,204);border-left-style:solid;padding-left:1ex">
<div style="word-wrap:break-word"><div><div>0003:</div><div>LGTM.</div></div></div></blockquote><div><br></div><div>+1</div><div><br></div><div>cheers,</div><div>--renato</div></div></div></div>