<div dir="auto">Hi David,<div dir="auto">Thanks for your email. I'm just trying to perform some basic analysis on the IR. For instance, is it possible to understand if the variable %10 depends on the value of the first parameter? I know that the first parameter can be referenced as %0 but a proper name would increase the readability. It is not so crucial for me atm.</div><div dir="auto"><br></div><div dir="auto">Thanks</div><div dir="auto">Alberto</div></div><br><div class="gmail_quote"><div dir="ltr" class="gmail_attr">On Mon, Dec 9, 2019, 11:01 David Chisnall via llvm-dev <<a href="mailto:llvm-dev@lists.llvm.org">llvm-dev@lists.llvm.org</a>> wrote:<br></div><blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex">Hi Alberto,<br>
<br>
Note that even with this, there isn't necessarily a 1:1 correspondence <br>
between LLVM IR parameters and clang parameters. For example, a struct <br>
passed by value in a C function may be one IR parameter per field, or <br>
may be packed into an integer large enough to store the whole thing. <br>
Similarly, return values may be indirect via sret pointers or they may <br>
be explicit return values but of a different type (for example, on i386 <br>
a return of struct of a pair of int- or pointer-sized values may be <br>
returned as a single i64 in LLVM IR).<br>
<br>
It would help to understand what you are trying to do, because there may <br>
be a better way of achieving your goal.<br>
<br>
David<br>
<br>
<br>
On 08/12/2019 10:19, Alberto Barbaro via llvm-dev wrote:<br>
> Hi Tim,<br>
> My bad, I have installed a newer version of clang and all worked.<br>
> <br>
> Thanks<br>
> <br>
> On Sun, Dec 8, 2019, 10:05 Tim Northover <<a href="mailto:t.p.northover@gmail.com" target="_blank" rel="noreferrer">t.p.northover@gmail.com</a> <br>
> <mailto:<a href="mailto:t.p.northover@gmail.com" target="_blank" rel="noreferrer">t.p.northover@gmail.com</a>>> wrote:<br>
> <br>
> On Sun, 8 Dec 2019 at 09:54, Alberto Barbaro via llvm-dev<br>
> <<a href="mailto:llvm-dev@lists.llvm.org" target="_blank" rel="noreferrer">llvm-dev@lists.llvm.org</a> <mailto:<a href="mailto:llvm-dev@lists.llvm.org" target="_blank" rel="noreferrer">llvm-dev@lists.llvm.org</a>>> wrote:<br>
> > thanks for your answer. Unfortunately I'm still using llvm 6.0<br>
> and in llvm-dis I don't see that option. I tried reading the full<br>
> list of options but I didn't see an alternative.<br>
> <br>
> The option is for Clang. Once you have the IR generated it's too late,<br>
> the names will already have been discarded.<br>
> <br>
> Cheers.<br>
> <br>
> Tim.<br>
> <br>
> <br>
> _______________________________________________<br>
> LLVM Developers mailing list<br>
> <a href="mailto:llvm-dev@lists.llvm.org" target="_blank" rel="noreferrer">llvm-dev@lists.llvm.org</a><br>
> <a href="https://lists.llvm.org/cgi-bin/mailman/listinfo/llvm-dev" rel="noreferrer noreferrer" target="_blank">https://lists.llvm.org/cgi-bin/mailman/listinfo/llvm-dev</a><br>
> <br>
_______________________________________________<br>
LLVM Developers mailing list<br>
<a href="mailto:llvm-dev@lists.llvm.org" target="_blank" rel="noreferrer">llvm-dev@lists.llvm.org</a><br>
<a href="https://lists.llvm.org/cgi-bin/mailman/listinfo/llvm-dev" rel="noreferrer noreferrer" target="_blank">https://lists.llvm.org/cgi-bin/mailman/listinfo/llvm-dev</a><br>
</blockquote></div>