<div dir="ltr"><a href="https://clang.llvm.org/docs/UsersManual.html#profile-guided-optimization">https://clang.llvm.org/docs/UsersManual.html#profile-guided-optimization</a> is the documentation for Clang's PGO. It doesn't explicitly state which flags map to frontend and IR-based instrumentation.<div><div><br></div><div>* -fprofile-generate and -fprofile-use are for IR-based instrumentation and profile use.</div><div>* -fprofile-instr-generate and -fprofile-instr-use are for frontend-based instrumentation and profile use.</div><div>* -fprofile-sample-use is to use sparse profiles from hardware-counter-based profiles.</div><div><br></div><div><br></div></div></div><div class="gmail_extra"><br><div class="gmail_quote">On Wed, Dec 27, 2017 at 2:37 PM, Johan Engelen via cfe-dev <span dir="ltr"><<a href="mailto:cfe-dev@lists.llvm.org" target="_blank">cfe-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"><div dir="ltr"><span style="font-size:12.8px">Hello all,</span><div style="font-size:12.8px"> A while ago, I implemented frontend-based PGO in LDC (very similar to Clang's) and now I'd like to add IR-based PGO. I want the commandline interface to be the same (or very similar) to Clang's, but I am having trouble finding the current state of Clang's PGO commandline flags (and their meaning related to Clang/LLVM-IR PGO).</div><div style="font-size:12.8px"><br></div><div style="font-size:12.8px">Can you give me a pointer to where I can find this, or perhaps give me a brief overview of the current flags and how to select whether to use frontend-based or IR-based PGO ?</div><div style="font-size:12.8px"><br></div><div style="font-size:12.8px">Thanks a lot,</div><div style="font-size:12.8px"> Johan</div></div>
<br>______________________________<wbr>_________________<br>
cfe-dev mailing list<br>
<a href="mailto:cfe-dev@lists.llvm.org">cfe-dev@lists.llvm.org</a><br>
<a href="http://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-dev" rel="noreferrer" target="_blank">http://lists.llvm.org/cgi-bin/<wbr>mailman/listinfo/cfe-dev</a><br>
<br></blockquote></div><br></div>