<div dir="ltr"><div class="gmail_extra"><br><div class="gmail_quote">On Mon, May 7, 2018 at 10:46 AM, Sedat Dilek <span dir="ltr"><<a href="mailto:sedat.dilek@gmail.com" target="_blank">sedat.dilek@gmail.com</a>></span> wrote:<br><blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex"><span class="">On Mon, May 7, 2018 at 5:19 PM, Brian Cain <<a href="mailto:brian.cain@gmail.com">brian.cain@gmail.com</a>> wrote:<br>
><br>
><br>...</span></blockquote><div><br></div><div> </div><blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex"><span class="">>  Can you give a little more context?  What is your ultimate goal for this<br>
> activity?  Why would you want to run the test in this fashion and what<br>
> meaning would you attribute to the test passing or failing?<br>
><br>
<br>
</span>When compiling a Linux-kernel I hit a problem in the<br>
KVM/paravirtualization area and "clobbering RCX" on Debian/testing<br>
AMD64.<br>
The question came up, is this is a compiler bug or not.<br>
Details see [1].<br>
<br>
Thus, I was looking for a reproducible testcase.<br>
I have seen that clang ships some tests.<br>
So, I was curious to run a single one.<br>
Not sure if clang/test/Sema/asm.c is suitable here to see "clobbering<br>
RCX" on Debian/x86-64.<br>
<br></blockquote><div><br></div><div>Yes, I agree that it might not be the right test.</div><div> </div><blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex">
On my host I have installed a clang-7 package from <<a href="http://apt.llvm.org" rel="noreferrer" target="_blank">apt.llvm.org</a>>.<br>
I wanted to test against that version.<br>
<br>
Does this help you?<br>
<br>
- Sedat -<br>
<br>
[1] <a href="https://lkml.org/lkml/2018/4/24/1227" rel="noreferrer" target="_blank">https://lkml.org/lkml/2018/4/<wbr>24/1227</a><br>
</blockquote></div><br>I see, yes, this is clearer now.</div><div class="gmail_extra"><br></div><div class="gmail_extra">IIUC, this test is testing clang's behavior regarding inline assembly and probably won't verify things like which registers are saved and restored.</div><div class="gmail_extra"><br></div><div class="gmail_extra">I think you might get resolution on this issue faster if you reduce <span style="color:rgb(0,0,0)">native_save_fl() and its caller to a simple example that shows RCX not being saved.  Bonus points if you can identify any conditions that change this behavior -- or versions of clang that behave differently.  Then share your test and ask on llvm-dev and/or cfe-dev whether or not this behavior is expected.</span><div><br></div>-- <br><div class="gmail_signature" data-smartmail="gmail_signature">-Brian</div>
</div></div>