<html><head><meta http-equiv="Content-Type" content="text/html charset=utf-8"></head><body style="word-wrap: break-word; -webkit-nbsp-mode: space; -webkit-line-break: after-white-space;" class=""><br class=""><div><blockquote type="cite" class=""><div class="">On Jan 17, 2017, at 4:36 PM, Hal Finkel via llvm-dev <<a href="mailto:llvm-dev@lists.llvm.org" class="">llvm-dev@lists.llvm.org</a>> wrote:</div><br class="Apple-interchange-newline"><div class="">
<meta content="text/html; charset=utf-8" http-equiv="Content-Type" class="">
<div bgcolor="#FFFFFF" text="#000000" class=""><p class=""><br class="">
</p>
<div class="moz-cite-prefix">On 01/17/2017 05:36 PM, Wael Yehia via
llvm-dev wrote:<br class="">
</div>
<blockquote cite="mid:106645892.5350347.1484696219444@mail.yahoo.com" type="cite" class="">
<meta http-equiv="Content-Type" content="text/html; charset=utf-8" class="">
<div style="background-color: rgb(255, 255, 255); font-family: HelveticaNeue, 'Helvetica Neue', Helvetica, Arial, 'Lucida Grande', sans-serif; font-size: 16px;" class="">
<div id="yui_3_16_0_ym19_1_1484694384976_9332" dir="ltr" class="">Hi.
Regarding the token approach, I've read some documentation
(review D11861, EH in llvm, and Reid and David's presentation)
but couldn't answer the following question.</div>
<div id="yui_3_16_0_ym19_1_1484694384976_9332" dir="ltr" class="">Does
the intrinsic or the instruction returning a <i id="yui_3_16_0_ym19_1_1484694384976_33732" class="">token</i> type
object act as a code motion barrier? In other words, does it
prevent other operations from being reordered with it?</div>
<div id="yui_3_16_0_ym19_1_1484694384976_9332" dir="ltr" class="">If the
answer is no, then does it mean the intrinsic has to be marked
with the <i class="">convergent</i> property to achieve the code
motion barrier effect?</div>
</div>
</blockquote>
<br class="">
To clarify, convergent does not form a code-motion barrier. It
prevents transformations from adding additional control
dependencies. I suspect that the token type does the same (because
tokens can't appear in PHIs).<br class=""></div></div></blockquote><div><br class=""></div><div>What if the only user of the token is in a branch? It seems to me that you’d be allowed to sink the token producer there, but not if it is marked convergent.</div><div><br class=""></div><div>— </div><div>Mehdi</div><div><br class=""></div><div><br class=""></div><br class=""><blockquote type="cite" class=""><div class=""><div bgcolor="#FFFFFF" text="#000000" class="">
<br class="">
Actual code motion barriers are generally achieved by adding unknown
memory dependencies.<br class="">
<br class="">
-Hal<br class="">
<br class="">
<blockquote cite="mid:106645892.5350347.1484696219444@mail.yahoo.com" type="cite" class="">
<div style="background-color: rgb(255, 255, 255); font-family: HelveticaNeue, 'Helvetica Neue', Helvetica, Arial, 'Lucida Grande', sans-serif; font-size: 16px;" class="">
<div id="yui_3_16_0_ym19_1_1484694384976_9332" dir="ltr" class="">If yes,
can someone explain how is that achieved in llvm?<br class="">
Greatly appreciated. Thanks.</div>
<div id="yui_3_16_0_ym19_1_1484694384976_9332" dir="ltr" class=""><br class="">
</div>
<div id="yui_3_16_0_ym19_1_1484694384976_9332" dir="ltr" class="">Wael</div>
</div>
<br class="">
<fieldset class="mimeAttachmentHeader"></fieldset>
<br class="">
<pre wrap="" class="">_______________________________________________
LLVM Developers mailing list
<a class="moz-txt-link-abbreviated" href="mailto:llvm-dev@lists.llvm.org">llvm-dev@lists.llvm.org</a>
<a class="moz-txt-link-freetext" href="http://lists.llvm.org/cgi-bin/mailman/listinfo/llvm-dev">http://lists.llvm.org/cgi-bin/mailman/listinfo/llvm-dev</a>
</pre>
</blockquote>
<br class="">
<pre class="moz-signature" cols="72">--
Hal Finkel
Lead, Compiler Technology and Programming Languages
Leadership Computing Facility
Argonne National Laboratory</pre>
</div>
_______________________________________________<br class="">LLVM Developers mailing list<br class=""><a href="mailto:llvm-dev@lists.llvm.org" class="">llvm-dev@lists.llvm.org</a><br class="">http://lists.llvm.org/cgi-bin/mailman/listinfo/llvm-dev<br class=""></div></blockquote></div><br class=""></body></html>