<?xml version="1.0" encoding="UTF-8"?><rss version="2.0"
	xmlns:content="http://purl.org/rss/1.0/modules/content/"
	xmlns:dc="http://purl.org/dc/elements/1.1/"
	xmlns:atom="http://www.w3.org/2005/Atom"
	xmlns:sy="http://purl.org/rss/1.0/modules/syndication/"
	>
<channel>
	<title>Comments on: Breaking Out of Loops in OpenMP</title>
	<atom:link href="http://www.thinkingparallel.com/2007/06/29/breaking-out-of-loops-in-openmp/feed/" rel="self" type="application/rss+xml" />
	<link>http://www.thinkingparallel.com/2007/06/29/breaking-out-of-loops-in-openmp/</link>
	<description>A Blog on Parallel Programming and Concurrency by Michael Suess</description>
	<pubDate>Sun, 05 Sep 2010 10:17:15 +0000</pubDate>
	<generator>http://wordpress.org/?v=2.7</generator>
	<sy:updatePeriod>hourly</sy:updatePeriod>
	<sy:updateFrequency>1</sy:updateFrequency>
		<item>
		<title>By: Michael Suess</title>
		<link>http://www.thinkingparallel.com/2007/06/29/breaking-out-of-loops-in-openmp/comment-page-1/#comment-16019</link>
		<dc:creator>Michael Suess</dc:creator>
		<pubDate>Sun, 01 Jul 2007 19:16:07 +0000</pubDate>
		<guid isPermaLink="false">http://www.thinkingparallel.com/2007/06/29/breaking-out-of-loops-in-openmp/#comment-16019</guid>
		<description>@Sanjiv: thanks for the clarification, maybe that decision should be revised some time in the future, as this is by far not the first time I encounter a problem that could be solved with a directive like that...

@Santiago: I did not change that to atomic, because the original snippet used critical and (since its just a snippet) I cannot know if n is not modified elsewhere. Besides that, I only wanted to change as little as possible to get my point across. You are right, though, there is a good chance that atomic is the more optimal solution here...</description>
		<content:encoded><![CDATA[<p>@Sanjiv: thanks for the clarification, maybe that decision should be revised some time in the future, as this is by far not the first time I encounter a problem that could be solved with a directive like that&#8230;</p>
<p>@Santiago: I did not change that to atomic, because the original snippet used critical and (since its just a snippet) I cannot know if n is not modified elsewhere. Besides that, I only wanted to change as little as possible to get my point across. You are right, though, there is a good chance that atomic is the more optimal solution here&#8230;</p>
]]></content:encoded>
	</item>
	<item>
		<title>By: Santiago</title>
		<link>http://www.thinkingparallel.com/2007/06/29/breaking-out-of-loops-in-openmp/comment-page-1/#comment-15938</link>
		<dc:creator>Santiago</dc:creator>
		<pubDate>Sat, 30 Jun 2007 17:25:18 +0000</pubDate>
		<guid isPermaLink="false">http://www.thinkingparallel.com/2007/06/29/breaking-out-of-loops-in-openmp/#comment-15938</guid>
		<description>Just an optimization... why instead of
[code]
#pragma omp critical(UpdateProgress)
++n;
[/code]

you don't do better

[code]
#pragma omp atomic
++n;
[/code]

???</description>
		<content:encoded><![CDATA[<p>Just an optimization... why instead of</p>
<div class="igBar"><span id="lcode-1"><a href="#" onclick="javascript:showPlainTxt('code-1'); return false;">PLAIN TEXT</a></span></div>
<div class="syntax_hilite"><span class="langName">CODE:</span>
<div id="code-1">
<div class="code">
<ol>
<li style="font-family: 'Courier New', Courier, monospace; color: black; font-weight: normal; font-style: normal;color:#3A6A8B;">
<div style="font-family: 'Courier New', Courier, monospace; font-weight: normal;">#pragma omp critical<span style="color:#006600; font-weight:bold;">&#40;</span>UpdateProgress<span style="color:#006600; font-weight:bold;">&#41;</span></div>
</li>
<li style="font-weight: bold;color:#26536A;">
<div style="font-family: 'Courier New', Courier, monospace; font-weight: normal;">++n; </div>
</li>
</ol>
</div>
</div>
</div>
<p></p>
<p>you don't do better</p>
<div class="igBar"><span id="lcode-2"><a href="#" onclick="javascript:showPlainTxt('code-2'); return false;">PLAIN TEXT</a></span></div>
<div class="syntax_hilite"><span class="langName">CODE:</span>
<div id="code-2">
<div class="code">
<ol>
<li style="font-family: 'Courier New', Courier, monospace; color: black; font-weight: normal; font-style: normal;color:#3A6A8B;">
<div style="font-family: 'Courier New', Courier, monospace; font-weight: normal;">#pragma omp atomic</div>
</li>
<li style="font-weight: bold;color:#26536A;">
<div style="font-family: 'Courier New', Courier, monospace; font-weight: normal;">++n; </div>
</li>
</ol>
</div>
</div>
</div>
<p></p>
<p>???</p>
]]></content:encoded>
	</item>
	<item>
		<title>By: Sanjiv Shah</title>
		<link>http://www.thinkingparallel.com/2007/06/29/breaking-out-of-loops-in-openmp/comment-page-1/#comment-15927</link>
		<dc:creator>Sanjiv Shah</dc:creator>
		<pubDate>Sat, 30 Jun 2007 14:20:47 +0000</pubDate>
		<guid isPermaLink="false">http://www.thinkingparallel.com/2007/06/29/breaking-out-of-loops-in-openmp/#comment-15927</guid>
		<description>Hi Michael,

This was called the "PDONE" directive in the original ASCI X3H5 specification, and the DONE directive in the original OpenMP 1.0 effort.  The committee rejected it on the grounds that it was simple enough for the user to do, as you show above.

Yes, we pushed for it, but there wasn't enough support for it.

Sanjiv</description>
		<content:encoded><![CDATA[<p>Hi Michael,</p>
<p>This was called the "PDONE" directive in the original ASCI X3H5 specification, and the DONE directive in the original OpenMP 1.0 effort.  The committee rejected it on the grounds that it was simple enough for the user to do, as you show above.</p>
<p>Yes, we pushed for it, but there wasn't enough support for it.</p>
<p>Sanjiv</p>
]]></content:encoded>
	</item>
</channel>
</rss>
