<html>
<head>
<meta http-equiv="Content-Type" content="text/html; charset=UTF-8">
</head>
<body text="#000000" bgcolor="#FFFFFF">
<p>This is a known (but poorly documented) issue. Please can you
raise a bug on this?<br>
</p>
<div class="moz-cite-prefix">On 05/06/2019 18:43, Max Marrone via
cfe-users wrote:<br>
</div>
<blockquote type="cite"
cite="mid:CAJQ0MM3pv11Y0RjpgsPZP4DarTYaK0KEJ6umw8thgJB9-X=ogA@mail.gmail.com">
<meta http-equiv="content-type" content="text/html; charset=UTF-8">
<div dir="ltr"><a
href="https://llvm.org/docs/CommandGuide/llvm-mca.html#using-markers-to-analyze-specific-code-blocks"
moz-do-not-send="true">The docs for llvm-mca</a> suggest using
inline assembly to mark the region that llvm-mca should examine,
i.e.
<div><br>
</div>
<div>__asm volatile("# LLVM-MCA-BEGIN");
<div>// ...</div>
<div>__asm volatile("# LLVM-MCA-END");<br>
</div>
<div><br>
</div>
</div>
<div>However, these directives seem to interfere with
auto-vectorization.</div>
<div><br>
</div>
<div><source>:8:3: remark: loop not vectorized: call
instruction cannot be vectorized
[-Rpass-analysis=loop-vectorize]<br>
__asm volatile("# LLVM-MCA-BEGIN sum_marked");<br>
^<br>
<br>
<source>:6:2: remark: loop not vectorized: read with
atomic ordering or volatile read
[-Rpass-analysis=loop-vectorize]<br>
for (size_t index = 0; index < count; index++)<br>
^<br>
</div>
<div><a href="https://godbolt.org/z/NSQchu"
moz-do-not-send="true"><br>
</a></div>
<div><a href="https://godbolt.org/z/NSQchu"
moz-do-not-send="true">Compiler Explorer link.</a></div>
<div><br>
</div>
<div>Any ideas for a workaround, other than compiling unmarked
source and then manually inserting markers into the emitted
assembly?</div>
</div>
<br>
<fieldset class="mimeAttachmentHeader"></fieldset>
<pre class="moz-quote-pre" wrap="">_______________________________________________
cfe-users mailing list
<a class="moz-txt-link-abbreviated" href="mailto:cfe-users@lists.llvm.org">cfe-users@lists.llvm.org</a>
<a class="moz-txt-link-freetext" href="https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-users">https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-users</a>
</pre>
</blockquote>
</body>
</html>