<div dir="ltr">Hi Juan:<div><br></div><div>I haven't looked at SlotTracker, but have been using MemoryDependenceWrapperPass to do something similar.</div><div><br></div><div>hth...</div><div>don</div></div><div class="gmail_extra"><br><div class="gmail_quote">On Fri, Dec 23, 2016 at 5:55 AM, Juan Ceasar via llvm-dev <span dir="ltr"><<a href="mailto:llvm-dev@lists.llvm.org" target="_blank">llvm-dev@lists.llvm.org</a>></span> wrote:<br><blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex">Good Morning - Happy Holidays everyone!<br>
<br>
I had a question about the best way to do back tracing of variables via the IR. So for example, if I have the following simple IR:<br>
<br>
define i32 @squak(i32 %num) #0 {<br>
%1 = alloca i32, align 4<br>
store i32 %num, i32* %1, align 4<br>
%2 = load i32, i32* %1, align 4<br>
%3 = icmp sgt i32 %2, 10<br>
<br>
I’m grabbing the predicate of “icmp”, which in this case is a simple test “>” of the input “%num" and the constant “10" and I want to trace back to “%num" via the slots/virtual registers %2 and %1. I believe I can do this via the SlotTracker (in AsmWriter.cpp) but I wonder if there’s a better, more direct way? Any suggestions? I’m basically trying to track predicate formation in the IR and hence the need…<br>
<br>
Thanks for any help!<br>
<br>
<br>
______________________________<wbr>_________________<br>
LLVM Developers mailing list<br>
<a href="mailto:llvm-dev@lists.llvm.org">llvm-dev@lists.llvm.org</a><br>
<a href="http://lists.llvm.org/cgi-bin/mailman/listinfo/llvm-dev" rel="noreferrer" target="_blank">http://lists.llvm.org/cgi-bin/<wbr>mailman/listinfo/llvm-dev</a><br>
</blockquote></div><br></div>