<div dir="ltr"><div class="gmail_extra"><div class="gmail_quote">On Fri, Dec 4, 2015 at 2:22 PM, Smith, Kevin B <span dir="ltr"><<a href="mailto:kevin.b.smith@intel.com" target="_blank">kevin.b.smith@intel.com</a>></span> wrote:<br><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 lang="EN-US" link="blue" vlink="purple">
<div>
<p><u></u><span style="font-family:Wingdings"><span>Ø<span style="font-style:normal;font-variant:normal;font-weight:normal;font-stretch:normal;font-size:7pt;line-height:normal;font-family:'Times New Roman'">
</span></span></span><u></u>It would be good to check that this maps correctly onto computeRegisterLiveness: there's a bug in analyzePhysReg and I think other parts of the code base are slightly wrong or will become slightly wrong as well :-(<u></u><u></u></p>
<p class="MsoNormal"><span style="font-size:10pt;font-family:Arial,sans-serif;color:rgb(68,84,106)"><u></u> <u></u></span></p>
<p class="MsoNormal"><span style="font-size:10pt;font-family:Arial,sans-serif;color:rgb(68,84,106)">Yes, I agree. I will also have to look into all other users of analyzePhysReg as well. There are surprisingly few users of either computeRegisterLiveness<u></u><u></u></span></p>
<p class="MsoNormal"><span style="font-size:10pt;font-family:Arial,sans-serif;color:rgb(68,84,106)">or analyzePhysReg. The other thing that I am trying to think about would be a way to comprehensively test the correctness of these, both as they stand,<u></u><u></u></span></p>
<p class="MsoNormal"><span style="font-size:10pt;font-family:Arial,sans-serif;color:rgb(68,84,106)">and after changes.</span></p></div></div></blockquote><div><br></div><div>Great, thanks! I'd be happy to review this, I just don't have much time to tackle the problem myself.</div><div><br></div><div>This code should also be fixed at the same time:</div><div><a href="http://lists.llvm.org/pipermail/llvm-commits/Week-of-Mon-20140317/209514.html">http://lists.llvm.org/pipermail/llvm-commits/Week-of-Mon-20140317/209514.html</a><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 lang="EN-US" link="blue" vlink="purple">
<p class="MsoNormal"><span style="font-size:10pt;font-family:Arial,sans-serif;color:rgb(68,84,106)">I am curious, does anyone know how do get this kind of Machine IR to be created from LLVM:<u></u><u></u></span></p>
<p class="MsoNormal"><span style="font-size:10pt;font-family:Arial,sans-serif;color:rgb(68,84,106)"><u></u> <u></u></span></p>
<p class="MsoNormal"><span style="font-size:10pt;font-family:Arial,sans-serif;color:rgb(68,84,106)">xor eax, eax<u></u><u></u></span></p>
<p class="MsoNormal"><span style="font-size:10pt;font-family:Arial,sans-serif;color:rgb(68,84,106)">movw ax, mem<u></u><u></u></span></p>
<p class="MsoNormal"><span style="font-size:10pt;font-family:Arial,sans-serif;color:rgb(68,84,106)">read eax<u></u><u></u></span></p>
<p class="MsoNormal"><span style="font-size:10pt;font-family:Arial,sans-serif;color:rgb(68,84,106)"><u></u> <u></u></span></p>
<p class="MsoNormal"><span style="font-size:10pt;font-family:Arial,sans-serif;color:rgb(68,84,106)">where the actual intent is for the xor, and the sub-register def in the movw to create form of zero-extension, and then to have full uses of eax? I know this isn't
very desirable<u></u><u></u></span></p>
<p class="MsoNormal"><span style="font-size:10pt;font-family:Arial,sans-serif;color:rgb(68,84,106)">code for X86, but these kinds of unusual machine IR are what would stress the implementations of these routines.</span></p></div></blockquote><div><br></div><div>I'm not sure, sorry. You could play tricks with asm and clobbers? </div></div></div></div>