<div dir="ltr"><div dir="ltr">Dear Stefanos,<div><br></div><div>I want to know whether after loop optimization, llvm indicates which loop is optimized and what all optimizations have been applied successfully to the individual loop which is optimized. Suppose, the loop L1 is optimized and the optimizations t1, t2, t3 have been attempted and are actually applied also. Again, the loop L2 is optimized and  <span style="color:rgb(0,0,0);font-family:-webkit-standard;font-size:medium">the optimizations t1, t2, t3 have been attempted and only t1 is finally applied. Does LLVM output the following ?</span></div><div><span style="color:rgb(0,0,0);font-family:-webkit-standard;font-size:medium"><br></span></div><div><span style="color:rgb(0,0,0);font-family:-webkit-standard;font-size:medium">Loop L1 : optimizations t1, t2, t3</span></div><div><span style="color:rgb(0,0,0);font-family:-webkit-standard;font-size:medium">Loop L2 : optimization t1</span></div><div><span style="color:rgb(0,0,0);font-family:-webkit-standard;font-size:medium"><br></span></div><div><span style="color:rgb(0,0,0);font-family:-webkit-standard;font-size:medium">Thanks,</span></div><div><span style="color:rgb(0,0,0);font-family:-webkit-standard;font-size:medium">Sudakshina</span></div></div></div><br><div class="gmail_quote"><div dir="ltr" class="gmail_attr">On Fri, Jan 29, 2021 at 10:13 PM Michael Kruse <<a href="mailto:llvmdev@meinersbur.de">llvmdev@meinersbur.de</a>> wrote:<br></div><blockquote class="gmail_quote" style="margin:0px 0px 0px 0.8ex;border-left-width:1px;border-left-style:solid;border-left-color:rgb(204,204,204);padding-left:1ex">Am Fr., 29. Jan. 2021 um 06:18 Uhr schrieb Sudakshina Dutta via<br>
llvm-dev <<a href="mailto:llvm-dev@lists.llvm.org" target="_blank">llvm-dev@lists.llvm.org</a>>:<br>
> Thanks for all your reply. I have one simple question to ask. I am new to llvm. I know that the loop to be optimized has to be enclosed between #pragma scop and #pragma endoscop.<br>
<br>
#pragma scop/endscop are used by polyhedral source-to-source<br>
optimizers such as ppcg[1] and OpenScop[2]. LLVM's polyhedral<br>
optimizer Polly does not use them.<br>
<br>
Polly has several report options available, such as<br>
`-Rpass-analysis=polly-scops`, `-mllvm -polly-report`, `-mllvm<br>
-polly-show`.<br>
<br>
[1] <a href="https://repo.or.cz/ppcg.git" rel="noreferrer" target="_blank">https://repo.or.cz/ppcg.git</a><br>
[2] <a href="http://icps.u-strasbg.fr/~bastoul/development/openscop/index.html" rel="noreferrer" target="_blank">http://icps.u-strasbg.fr/~bastoul/development/openscop/index.html</a><br>
<br>
Michael<br>
</blockquote></div>