<html><head></head><body style="word-wrap: break-word; -webkit-nbsp-mode: space; -webkit-line-break: after-white-space; "><div><br></div><div>Dave, </div><div><br></div><div>You are correct, I didn't review your example code. I'll take a look.</div><div><br></div><div>Thanks for the architectural overview. It would be convenient if this information was recorded in software design document. </div><div><br></div><div><br></div><div><br></div><div><pre style="white-space: pre-wrap; color: rgb(0, 0, 0); font-style: normal; font-variant: normal; font-weight: normal; letter-spacing: normal; line-height: normal; orphans: 2; text-align: -webkit-auto; text-indent: 0px; text-transform: none; widows: 2; word-spacing: 0px; -webkit-text-size-adjust: auto; -webkit-text-stroke-width: 0px; ">"I guess you didn't bother wasting your time looking at my example for 
dvariables.

The big problem with these objects is not some trivial locking in the 
constructor etc.
It comes from the fact that the data structure which store all the 
information for
multiple levels of reverse AD are not thread safe. If you are doing 
df1b2variable
arithmetic each thread needs its own copy of these."
</pre></div><div><br></div><div><div>On Dec 3, 2012, at 2:39 PM, <a href="mailto:developers-request@admb-project.org">developers-request@admb-project.org</a> wrote:</div><br class="Apple-interchange-newline"><blockquote type="cite"><div>Send Developers mailing list submissions to<br><span class="Apple-tab-span" style="white-space:pre">   </span><a href="mailto:developers@admb-project.org">developers@admb-project.org</a><br><br>To subscribe or unsubscribe via the World Wide Web, visit<br><span class="Apple-tab-span" style="white-space:pre">   </span>http://lists.admb-project.org/mailman/listinfo/developers<br>or, via email, send a message with subject or body 'help' to<br><span class="Apple-tab-span" style="white-space:pre">   </span>developers-request@admb-project.org<br><br>You can reach the person managing the list at<br><span class="Apple-tab-span" style="white-space:pre">      </span>developers-owner@admb-project.org<br><br>When replying, please edit your Subject line so it is more specific<br>than "Re: Contents of Developers digest..."<br><br><br>Today's Topics:<br><br>   1. Re: admb threading (Matthew Supernaw)<br><br><br>----------------------------------------------------------------------<br><br>Message: 1<br>Date: Mon, 3 Dec 2012 14:29:01 -0500<br>From: Matthew Supernaw <matthew.supernaw@noaa.gov><br>To: developers@admb-project.org<br>Subject: Re: [Developers] admb threading<br>Message-ID: <C8E76651-698E-4D98-A995-40A2F259B069@noaa.gov><br>Content-Type: text/plain; charset="us-ascii"<br><br><br>Perhaps making admb type containers thread safe is a good place to start. This would make it easier to modify admb internally as well as allow end users to make their own applications concurrent.<br><br>I've started working on this issue for one of our staff. After profiling his model, I found nearly 70-80% of the runtime was in his user_function looping through a df1b2matrix and doing operations on its elements. In this particular case,<br>admb is quite fast and is really just waiting for user_function evaluations(nested for loops). This is the perfect location for multi-threading.<br><br><br>At the moment I'm working on a thread safe wrapper for df1b2matrix in order to speed up this particular model. This should be all that is needed for this particular case, but I suspect this cause may be a common.<br><br><br>Attached is a simple platform independent threading library. <br><br><br>My strategy for making df1b2matrix thread safe is to wrap it as follows:<br><br><br> 11 #include <admodel.h><br> 12 #include "Threads.hpp"<br> 13 <br> 14 <br> 15 namespace admb {<br> 16<br>17   class ts_df1b2matrix {<br> 18 <br> 19         int allocated(void) {<br> 20             noaa::threads::Lock(mutex_);<br> 21             df1b2matrix_.allocated();<br> 22         }<br> 23 <br> 24         void initialize(void) {<br> 25             noaa::threads::Lock(mutex_);<br> 26             df1b2matrix_.initialize();<br> 27 <br> 28         }<br> 29 <br> 30         ~ts_df1b2matrix() {<br> 31             noaa::threads::Lock(mutex_);<br> 32             ~df1b2matrix_;<br> 33         }<br> 34 <br> 35         int rowmin(void) const {<br> 36             noaa::threads::Lock(mutex_);<br> 37             df1b2matrix_.rowmin();<br> 38         }<br> 39 <br> 40         int indexmin(void) const {<br> 41             noaa::threads::Lock(mutex_);<br> 42             df1b2matrix_.indexmin();<br> 43         }<br> 44 <br> 45         int indexmax(void) const {<br> 46             noaa::threads::Lock(mutex_);<br> 47             df1b2matrix_.indexmax();<br> 48         }<br> 49 <br> 50         int rowmax(void) const {<br> 51             noaa::threads::Lock(mutex_);<br> 52             df1b2matrix_.rowmax();<br> 53         }<br> 54 <br> 55         int size(void) const {<br> 56             noaa::threads::Lock(mutex_);<br> 57             df1b2matrix_.size();<br> 58         }<br> 59 <br> 60         ts_df1b2matrix(int nrl, int nrh) {<br> 61             noaa::threads::Lock(mutex_);<br> 62             df1b2matrix_(nrl, nrh);<br> 63         }<br> 64 <br> 65         ts_df1b2matrix(const df1b2matrix &other) {<br> 66             noaa::threads::Lock(mutex_);<br> 67             df1b2matrix_(other);<br> 68         }<br> 69 <br> 70         ts_df1b2matrix(const ts_df1b2matrix &other) {<br> 71             noaa::threads::Lock(mutex_);<br> 72               noaa::threads::Lock2(other.mutex_);<br> 73             df1b2matrix_(other.df1b2matrix_);<br> 74         }<br> 75 <br> 76         ts_df1b2matrix(int nrl, int nrh, const index_type &ncl, const index_type &nch) {<br> 77             noaa::threads::Lock(mutex_);<br> 78             df1b2matrix(nrl, nrh, ncl, nch);<br> 79         }<br> 80 <br> 81          ts_df1b2matrix& operator=(const df3_one_matrix &other) {<br> 82             noaa::threads::Lock(mutex_);<br> 83             this->df1b2matrix_ = other;<br> 84         }<br> 85  <br>.<br>.<br>.<br>.<br><br>162 <br>163     private:<br>164         mutable noaa::threads::Mutex mutex_;<br>165         df1b2matrix df1b2matrix_;<br>166 <br>167 <br>168     };<br><br><br>The call "noaa::threads::Lock(mutex_); " will lock the function and then unlock it as it goes out of scope.<br>I'll be happy to pass the finished product for review.<br><br><br><br><br><br><br><br><br><br><br>Matthew Supernaw<br>Scientific Programmer<br>National Oceanic and Atmospheric Administration<br>National Marine Fisheries Service<br>Sustainable Fisheries Division<br>St. Petersburg, FL, 33701<br>Office 727-551-5606<br>Fax 727-824-5300<br><br>On Nov 29, 2012, at 3:00 PM, developers-request@admb-project.org wrote:<br><br><blockquote type="cite">Send Developers mailing list submissions to<br></blockquote><blockquote type="cite"><span class="Apple-tab-span" style="white-space:pre">  </span>developers@admb-project.org<br></blockquote><blockquote type="cite"><br></blockquote><blockquote type="cite">To subscribe or unsubscribe via the World Wide Web, visit<br></blockquote><blockquote type="cite"><span class="Apple-tab-span" style="white-space:pre"> </span>http://lists.admb-project.org/mailman/listinfo/developers<br></blockquote><blockquote type="cite">or, via email, send a message with subject or body 'help' to<br></blockquote><blockquote type="cite"><span class="Apple-tab-span" style="white-space:pre">     </span>developers-request@admb-project.org<br></blockquote><blockquote type="cite"><br></blockquote><blockquote type="cite">You can reach the person managing the list at<br></blockquote><blockquote type="cite"><span class="Apple-tab-span" style="white-space:pre">     </span>developers-owner@admb-project.org<br></blockquote><blockquote type="cite"><br></blockquote><blockquote type="cite">When replying, please edit your Subject line so it is more specific<br></blockquote><blockquote type="cite">than "Re: Contents of Developers digest..."<br></blockquote><blockquote type="cite"><br></blockquote><blockquote type="cite"><br></blockquote><blockquote type="cite">Today's Topics:<br></blockquote><blockquote type="cite"><br></blockquote><blockquote type="cite">  1. Re: admb threading (Mark Maunder)<br></blockquote><blockquote type="cite">  2. Re: admb threading (dave fournier)<br></blockquote><blockquote type="cite"><br></blockquote><blockquote type="cite"><br></blockquote><blockquote type="cite">----------------------------------------------------------------------<br></blockquote><blockquote type="cite"><br></blockquote><blockquote type="cite">Message: 1<br></blockquote><blockquote type="cite">Date: Thu, 29 Nov 2012 17:50:41 +0000<br></blockquote><blockquote type="cite">From: Mark Maunder <mmaunder@iattc.org><br></blockquote><blockquote type="cite">To: dave fournier <davef@otter-rsch.com>,<br></blockquote><blockquote type="cite"><span class="Apple-tab-span" style="white-space:pre">  </span>"developers@admb-project.org"<span class="Apple-tab-span" style="white-space:pre">     </span><developers@admb-project.org><br></blockquote><blockquote type="cite">Subject: Re: [Developers] admb threading<br></blockquote><blockquote type="cite">Message-ID:<br></blockquote><blockquote type="cite"><span class="Apple-tab-span" style="white-space:pre">       </span><339913E1960AE142A9373DFCD849F3DA325FA148@mail1.lajolla.iattc.org><br></blockquote><blockquote type="cite">Content-Type: text/plain; charset="us-ascii"<br></blockquote><blockquote type="cite"><br></blockquote><blockquote type="cite">What about the calculation of the hessian, which can be quite long on parameter rich models.<br></blockquote><blockquote type="cite">Profile likelihoods would also be another easy one  <br></blockquote><blockquote type="cite"><br></blockquote><blockquote type="cite"><br></blockquote><blockquote type="cite">-----Original Message-----<br></blockquote><blockquote type="cite">From: developers-bounces@admb-project.org [mailto:developers-bounces@admb-project.org] On Behalf Of dave fournier<br></blockquote><blockquote type="cite">Sent: Thursday, November 29, 2012 9:26 AM<br></blockquote><blockquote type="cite">To: developers@admb-project.org<br></blockquote><blockquote type="cite">Subject: Re: [Developers] admb threading<br></blockquote><blockquote type="cite"><br></blockquote><blockquote type="cite">On 12-11-29 09:11 AM, Hans J. Skaug wrote:<br></blockquote><blockquote type="cite"><br></blockquote><blockquote type="cite">The obvious transparent one is the -ndb (num der blocks) which was already set up for mult-threading, and I recall Derek was doing something with that, but I never heard about it again, and it is not for separable models.  For separable models one could split up the separable function calls by different threads in a transparent manner.  Both of these involve using the __thread declaration to deal with some global data structures.  The real point of my proof of concept example was to demonstrate that this can be done quite easily.<br></blockquote><blockquote type="cite"><br></blockquote><blockquote type="cite"><br></blockquote><blockquote type="cite"><br></blockquote><blockquote type="cite"><blockquote type="cite">Both are useful, but currently "transparent to the user" is the most important.<br></blockquote></blockquote><blockquote type="cite"><blockquote type="cite"><br></blockquote></blockquote><blockquote type="cite"><blockquote type="cite">hans<br></blockquote></blockquote><blockquote type="cite"><blockquote type="cite"><br></blockquote></blockquote><blockquote type="cite"><blockquote type="cite"><blockquote type="cite">-----Original Message-----<br></blockquote></blockquote></blockquote><blockquote type="cite"><blockquote type="cite"><blockquote type="cite">From: developers-bounces@admb-project.org [mailto:developers- <br></blockquote></blockquote></blockquote><blockquote type="cite"><blockquote type="cite"><blockquote type="cite">bounces@admb-project.org] On Behalf Of Mark Maunder<br></blockquote></blockquote></blockquote><blockquote type="cite"><blockquote type="cite"><blockquote type="cite">Sent: Thursday, November 29, 2012 8:23 AM<br></blockquote></blockquote></blockquote><blockquote type="cite"><blockquote type="cite"><blockquote type="cite">To: John Sibert; ADMB Developers<br></blockquote></blockquote></blockquote><blockquote type="cite"><blockquote type="cite"><blockquote type="cite">Subject: Re: [Developers] admb threading<br></blockquote></blockquote></blockquote><blockquote type="cite"><blockquote type="cite"><blockquote type="cite"><br></blockquote></blockquote></blockquote><blockquote type="cite"><blockquote type="cite"><blockquote type="cite">parallel code that is "transparent" to the user<br></blockquote></blockquote></blockquote><blockquote type="cite"><blockquote type="cite"><blockquote type="cite"><br></blockquote></blockquote></blockquote><blockquote type="cite"><blockquote type="cite"><blockquote type="cite">-----Original Message-----<br></blockquote></blockquote></blockquote><blockquote type="cite"><blockquote type="cite"><blockquote type="cite">From: developers-bounces@admb-project.org [mailto:developers- <br></blockquote></blockquote></blockquote><blockquote type="cite"><blockquote type="cite"><blockquote type="cite">bounces@admb-project.org] On Behalf Of John Sibert<br></blockquote></blockquote></blockquote><blockquote type="cite"><blockquote type="cite"><blockquote type="cite">Sent: Wednesday, November 28, 2012 4:30 PM<br></blockquote></blockquote></blockquote><blockquote type="cite"><blockquote type="cite"><blockquote type="cite">To: ADMB Developers<br></blockquote></blockquote></blockquote><blockquote type="cite"><blockquote type="cite"><blockquote type="cite">Subject: [Developers] admb threading<br></blockquote></blockquote></blockquote><blockquote type="cite"><blockquote type="cite"><blockquote type="cite"><br></blockquote></blockquote></blockquote><blockquote type="cite"><blockquote type="cite"><blockquote type="cite">Johnoel and I need some feedback about how to approach threading. <br></blockquote></blockquote></blockquote><blockquote type="cite"><blockquote type="cite"><blockquote type="cite">Dave has provided a nice proof of concept using pthreads to implement <br></blockquote></blockquote></blockquote><blockquote type="cite"><blockquote type="cite"><blockquote type="cite">parallel processing on larger chunks of code. This approach is likely <br></blockquote></blockquote></blockquote><blockquote type="cite"><blockquote type="cite"><blockquote type="cite">to have the biggest performance improvement, but seems application <br></blockquote></blockquote></blockquote><blockquote type="cite"><blockquote type="cite"><blockquote type="cite">specific and would require more expertize on the part of users.<br></blockquote></blockquote></blockquote><blockquote type="cite"><blockquote type="cite"><blockquote type="cite"><br></blockquote></blockquote></blockquote><blockquote type="cite"><blockquote type="cite"><blockquote type="cite">Alternatively it is possible to implement threading internally in the <br></blockquote></blockquote></blockquote><blockquote type="cite"><blockquote type="cite"><blockquote type="cite">ADMB libraries, concentrating on smaller chunks of code, for instance <br></blockquote></blockquote></blockquote><blockquote type="cite"><blockquote type="cite"><blockquote type="cite">the solve(...) function. This approach would probably have smaller <br></blockquote></blockquote></blockquote><blockquote type="cite"><blockquote type="cite"><blockquote type="cite">performance payoff in most applications, but would be more transparent to users.<br></blockquote></blockquote></blockquote><blockquote type="cite"><blockquote type="cite"><blockquote type="cite"><br></blockquote></blockquote></blockquote><blockquote type="cite"><blockquote type="cite"><blockquote type="cite">In principle, the two approaches are not mutually exclusive.<br></blockquote></blockquote></blockquote><blockquote type="cite"><blockquote type="cite"><blockquote type="cite"><br></blockquote></blockquote></blockquote><blockquote type="cite"><blockquote type="cite"><blockquote type="cite">So my question to the ADMB Developer group is what did we mean when <br></blockquote></blockquote></blockquote><blockquote type="cite"><blockquote type="cite"><blockquote type="cite">we assigned a high priority to parallelization?  Do we want parallel <br></blockquote></blockquote></blockquote><blockquote type="cite"><blockquote type="cite"><blockquote type="cite">code that is "transparent" to the user (if so what parts of the would <br></blockquote></blockquote></blockquote><blockquote type="cite"><blockquote type="cite"><blockquote type="cite">have the highest priority)? Or do we want to develop tools that allow <br></blockquote></blockquote></blockquote><blockquote type="cite"><blockquote type="cite"><blockquote type="cite">users to create their on threaded code for specific applications? <br></blockquote></blockquote></blockquote><blockquote type="cite"><blockquote type="cite"><blockquote type="cite">(Don't tell me both.)<br></blockquote></blockquote></blockquote><blockquote type="cite"><blockquote type="cite"><blockquote type="cite"><br></blockquote></blockquote></blockquote><blockquote type="cite"><blockquote type="cite"><blockquote type="cite">Cheers,<br></blockquote></blockquote></blockquote><blockquote type="cite"><blockquote type="cite"><blockquote type="cite">John<br></blockquote></blockquote></blockquote><blockquote type="cite"><blockquote type="cite"><blockquote type="cite">PS enjoy the attached.<br></blockquote></blockquote></blockquote><blockquote type="cite"><blockquote type="cite"><blockquote type="cite"><br></blockquote></blockquote></blockquote><blockquote type="cite"><blockquote type="cite"><blockquote type="cite">--<br></blockquote></blockquote></blockquote><blockquote type="cite"><blockquote type="cite"><blockquote type="cite">John Sibert<br></blockquote></blockquote></blockquote><blockquote type="cite"><blockquote type="cite"><blockquote type="cite">Emeritus Researcher, SOEST<br></blockquote></blockquote></blockquote><blockquote type="cite"><blockquote type="cite"><blockquote type="cite">University of Hawaii at Manoa<br></blockquote></blockquote></blockquote><blockquote type="cite"><blockquote type="cite"><blockquote type="cite"><br></blockquote></blockquote></blockquote><blockquote type="cite"><blockquote type="cite"><blockquote type="cite">Visit the ADMB project http://admb-project.org/<br></blockquote></blockquote></blockquote><blockquote type="cite"><blockquote type="cite"><blockquote type="cite"><br></blockquote></blockquote></blockquote><blockquote type="cite"><blockquote type="cite"><blockquote type="cite">_______________________________________________<br></blockquote></blockquote></blockquote><blockquote type="cite"><blockquote type="cite"><blockquote type="cite">Developers mailing list<br></blockquote></blockquote></blockquote><blockquote type="cite"><blockquote type="cite"><blockquote type="cite">Developers@admb-project.org<br></blockquote></blockquote></blockquote><blockquote type="cite"><blockquote type="cite"><blockquote type="cite">http://lists.admb-project.org/mailman/listinfo/developers<br></blockquote></blockquote></blockquote><blockquote type="cite"><blockquote type="cite">_______________________________________________<br></blockquote></blockquote><blockquote type="cite"><blockquote type="cite">Developers mailing list<br></blockquote></blockquote><blockquote type="cite"><blockquote type="cite">Developers@admb-project.org<br></blockquote></blockquote><blockquote type="cite"><blockquote type="cite">http://lists.admb-project.org/mailman/listinfo/developers<br></blockquote></blockquote><blockquote type="cite"><br></blockquote><blockquote type="cite">_______________________________________________<br></blockquote><blockquote type="cite">Developers mailing list<br></blockquote><blockquote type="cite">Developers@admb-project.org<br></blockquote><blockquote type="cite">http://lists.admb-project.org/mailman/listinfo/developers<br></blockquote><blockquote type="cite"><br></blockquote><blockquote type="cite"><br></blockquote><blockquote type="cite">------------------------------<br></blockquote><blockquote type="cite"><br></blockquote><blockquote type="cite">Message: 2<br></blockquote><blockquote type="cite">Date: Thu, 29 Nov 2012 09:53:45 -0800<br></blockquote><blockquote type="cite">From: dave fournier <davef@otter-rsch.com><br></blockquote><blockquote type="cite">To: Mark Maunder <mmaunder@iattc.org><br></blockquote><blockquote type="cite">Cc: "developers@admb-project.org" <developers@admb-project.org><br></blockquote><blockquote type="cite">Subject: Re: [Developers] admb threading<br></blockquote><blockquote type="cite">Message-ID: <50B7A129.5030200@otter-rsch.com><br></blockquote><blockquote type="cite">Content-Type: text/plain; charset=ISO-8859-1; format=flowed<br></blockquote><blockquote type="cite"><br></blockquote><blockquote type="cite">On 12-11-29 09:50 AM, Mark Maunder wrote:<br></blockquote><blockquote type="cite"><br></blockquote><blockquote type="cite">The biggest improvement to the profile likelihood would be to replace <br></blockquote><blockquote type="cite">the current<br></blockquote><blockquote type="cite">penalty function method with the augmented Lagrangian.<br></blockquote><blockquote type="cite"><br></blockquote><blockquote type="cite"><blockquote type="cite">What about the calculation of the hessian, which can be quite long on parameter rich models.<br></blockquote></blockquote><blockquote type="cite"><blockquote type="cite">Profile likelihoods would also be another easy one<br></blockquote></blockquote><blockquote type="cite"><blockquote type="cite"><br></blockquote></blockquote><blockquote type="cite"><blockquote type="cite"><br></blockquote></blockquote><blockquote type="cite"><blockquote type="cite">-----Original Message-----<br></blockquote></blockquote><blockquote type="cite"><blockquote type="cite">From: developers-bounces@admb-project.org [mailto:developers-bounces@admb-project.org] On Behalf Of dave fournier<br></blockquote></blockquote><blockquote type="cite"><blockquote type="cite">Sent: Thursday, November 29, 2012 9:26 AM<br></blockquote></blockquote><blockquote type="cite"><blockquote type="cite">To: developers@admb-project.org<br></blockquote></blockquote><blockquote type="cite"><blockquote type="cite">Subject: Re: [Developers] admb threading<br></blockquote></blockquote><blockquote type="cite"><blockquote type="cite"><br></blockquote></blockquote><blockquote type="cite"><blockquote type="cite">On 12-11-29 09:11 AM, Hans J. Skaug wrote:<br></blockquote></blockquote><blockquote type="cite"><blockquote type="cite"><br></blockquote></blockquote><blockquote type="cite"><blockquote type="cite">The obvious transparent one is the -ndb (num der blocks) which was already set up for mult-threading, and I recall Derek was doing something with that, but I never heard about it again, and it is not for separable models.  For separable models one could split up the separable function calls by different threads in a transparent manner.  Both of these involve using the __thread declaration to deal with some global data structures.  The real point of my proof of concept example was to demonstrate that this can be done quite easily.<br></blockquote></blockquote><blockquote type="cite"><blockquote type="cite"><br></blockquote></blockquote><blockquote type="cite"><blockquote type="cite"><br></blockquote></blockquote><blockquote type="cite"><blockquote type="cite"><br></blockquote></blockquote><blockquote type="cite"><blockquote type="cite"><blockquote type="cite">Both are useful, but currently "transparent to the user" is the most important.<br></blockquote></blockquote></blockquote><blockquote type="cite"><blockquote type="cite"><blockquote type="cite"><br></blockquote></blockquote></blockquote><blockquote type="cite"><blockquote type="cite"><blockquote type="cite">hans<br></blockquote></blockquote></blockquote><blockquote type="cite"><blockquote type="cite"><blockquote type="cite"><br></blockquote></blockquote></blockquote><blockquote type="cite"><blockquote type="cite"><blockquote type="cite"><blockquote type="cite">-----Original Message-----<br></blockquote></blockquote></blockquote></blockquote><blockquote type="cite"><blockquote type="cite"><blockquote type="cite"><blockquote type="cite">From: developers-bounces@admb-project.org [mailto:developers-<br></blockquote></blockquote></blockquote></blockquote><blockquote type="cite"><blockquote type="cite"><blockquote type="cite"><blockquote type="cite">bounces@admb-project.org] On Behalf Of Mark Maunder<br></blockquote></blockquote></blockquote></blockquote><blockquote type="cite"><blockquote type="cite"><blockquote type="cite"><blockquote type="cite">Sent: Thursday, November 29, 2012 8:23 AM<br></blockquote></blockquote></blockquote></blockquote><blockquote type="cite"><blockquote type="cite"><blockquote type="cite"><blockquote type="cite">To: John Sibert; ADMB Developers<br></blockquote></blockquote></blockquote></blockquote><blockquote type="cite"><blockquote type="cite"><blockquote type="cite"><blockquote type="cite">Subject: Re: [Developers] admb threading<br></blockquote></blockquote></blockquote></blockquote><blockquote type="cite"><blockquote type="cite"><blockquote type="cite"><blockquote type="cite"><br></blockquote></blockquote></blockquote></blockquote><blockquote type="cite"><blockquote type="cite"><blockquote type="cite"><blockquote type="cite">parallel code that is "transparent" to the user<br></blockquote></blockquote></blockquote></blockquote><blockquote type="cite"><blockquote type="cite"><blockquote type="cite"><blockquote type="cite"><br></blockquote></blockquote></blockquote></blockquote><blockquote type="cite"><blockquote type="cite"><blockquote type="cite"><blockquote type="cite">-----Original Message-----<br></blockquote></blockquote></blockquote></blockquote><blockquote type="cite"><blockquote type="cite"><blockquote type="cite"><blockquote type="cite">From: developers-bounces@admb-project.org [mailto:developers-<br></blockquote></blockquote></blockquote></blockquote><blockquote type="cite"><blockquote type="cite"><blockquote type="cite"><blockquote type="cite">bounces@admb-project.org] On Behalf Of John Sibert<br></blockquote></blockquote></blockquote></blockquote><blockquote type="cite"><blockquote type="cite"><blockquote type="cite"><blockquote type="cite">Sent: Wednesday, November 28, 2012 4:30 PM<br></blockquote></blockquote></blockquote></blockquote><blockquote type="cite"><blockquote type="cite"><blockquote type="cite"><blockquote type="cite">To: ADMB Developers<br></blockquote></blockquote></blockquote></blockquote><blockquote type="cite"><blockquote type="cite"><blockquote type="cite"><blockquote type="cite">Subject: [Developers] admb threading<br></blockquote></blockquote></blockquote></blockquote><blockquote type="cite"><blockquote type="cite"><blockquote type="cite"><blockquote type="cite"><br></blockquote></blockquote></blockquote></blockquote><blockquote type="cite"><blockquote type="cite"><blockquote type="cite"><blockquote type="cite">Johnoel and I need some feedback about how to approach threading.<br></blockquote></blockquote></blockquote></blockquote><blockquote type="cite"><blockquote type="cite"><blockquote type="cite"><blockquote type="cite">Dave has provided a nice proof of concept using pthreads to implement<br></blockquote></blockquote></blockquote></blockquote><blockquote type="cite"><blockquote type="cite"><blockquote type="cite"><blockquote type="cite">parallel processing on larger chunks of code. This approach is likely<br></blockquote></blockquote></blockquote></blockquote><blockquote type="cite"><blockquote type="cite"><blockquote type="cite"><blockquote type="cite">to have the biggest performance improvement, but seems application<br></blockquote></blockquote></blockquote></blockquote><blockquote type="cite"><blockquote type="cite"><blockquote type="cite"><blockquote type="cite">specific and would require more expertize on the part of users.<br></blockquote></blockquote></blockquote></blockquote><blockquote type="cite"><blockquote type="cite"><blockquote type="cite"><blockquote type="cite"><br></blockquote></blockquote></blockquote></blockquote><blockquote type="cite"><blockquote type="cite"><blockquote type="cite"><blockquote type="cite">Alternatively it is possible to implement threading internally in the<br></blockquote></blockquote></blockquote></blockquote><blockquote type="cite"><blockquote type="cite"><blockquote type="cite"><blockquote type="cite">ADMB libraries, concentrating on smaller chunks of code, for instance<br></blockquote></blockquote></blockquote></blockquote><blockquote type="cite"><blockquote type="cite"><blockquote type="cite"><blockquote type="cite">the solve(...) function. This approach would probably have smaller<br></blockquote></blockquote></blockquote></blockquote><blockquote type="cite"><blockquote type="cite"><blockquote type="cite"><blockquote type="cite">performance payoff in most applications, but would be more transparent to users.<br></blockquote></blockquote></blockquote></blockquote><blockquote type="cite"><blockquote type="cite"><blockquote type="cite"><blockquote type="cite"><br></blockquote></blockquote></blockquote></blockquote><blockquote type="cite"><blockquote type="cite"><blockquote type="cite"><blockquote type="cite">In principle, the two approaches are not mutually exclusive.<br></blockquote></blockquote></blockquote></blockquote><blockquote type="cite"><blockquote type="cite"><blockquote type="cite"><blockquote type="cite"><br></blockquote></blockquote></blockquote></blockquote><blockquote type="cite"><blockquote type="cite"><blockquote type="cite"><blockquote type="cite">So my question to the ADMB Developer group is what did we mean when<br></blockquote></blockquote></blockquote></blockquote><blockquote type="cite"><blockquote type="cite"><blockquote type="cite"><blockquote type="cite">we assigned a high priority to parallelization?  Do we want parallel<br></blockquote></blockquote></blockquote></blockquote><blockquote type="cite"><blockquote type="cite"><blockquote type="cite"><blockquote type="cite">code that is "transparent" to the user (if so what parts of the would<br></blockquote></blockquote></blockquote></blockquote><blockquote type="cite"><blockquote type="cite"><blockquote type="cite"><blockquote type="cite">have the highest priority)? Or do we want to develop tools that allow<br></blockquote></blockquote></blockquote></blockquote><blockquote type="cite"><blockquote type="cite"><blockquote type="cite"><blockquote type="cite">users to create their on threaded code for specific applications?<br></blockquote></blockquote></blockquote></blockquote><blockquote type="cite"><blockquote type="cite"><blockquote type="cite"><blockquote type="cite">(Don't tell me both.)<br></blockquote></blockquote></blockquote></blockquote><blockquote type="cite"><blockquote type="cite"><blockquote type="cite"><blockquote type="cite"><br></blockquote></blockquote></blockquote></blockquote><blockquote type="cite"><blockquote type="cite"><blockquote type="cite"><blockquote type="cite">Cheers,<br></blockquote></blockquote></blockquote></blockquote><blockquote type="cite"><blockquote type="cite"><blockquote type="cite"><blockquote type="cite">John<br></blockquote></blockquote></blockquote></blockquote><blockquote type="cite"><blockquote type="cite"><blockquote type="cite"><blockquote type="cite">PS enjoy the attached.<br></blockquote></blockquote></blockquote></blockquote><blockquote type="cite"><blockquote type="cite"><blockquote type="cite"><blockquote type="cite"><br></blockquote></blockquote></blockquote></blockquote><blockquote type="cite"><blockquote type="cite"><blockquote type="cite"><blockquote type="cite">--<br></blockquote></blockquote></blockquote></blockquote><blockquote type="cite"><blockquote type="cite"><blockquote type="cite"><blockquote type="cite">John Sibert<br></blockquote></blockquote></blockquote></blockquote><blockquote type="cite"><blockquote type="cite"><blockquote type="cite"><blockquote type="cite">Emeritus Researcher, SOEST<br></blockquote></blockquote></blockquote></blockquote><blockquote type="cite"><blockquote type="cite"><blockquote type="cite"><blockquote type="cite">University of Hawaii at Manoa<br></blockquote></blockquote></blockquote></blockquote><blockquote type="cite"><blockquote type="cite"><blockquote type="cite"><blockquote type="cite"><br></blockquote></blockquote></blockquote></blockquote><blockquote type="cite"><blockquote type="cite"><blockquote type="cite"><blockquote type="cite">Visit the ADMB project http://admb-project.org/<br></blockquote></blockquote></blockquote></blockquote><blockquote type="cite"><blockquote type="cite"><blockquote type="cite"><blockquote type="cite"><br></blockquote></blockquote></blockquote></blockquote><blockquote type="cite"><blockquote type="cite"><blockquote type="cite"><blockquote type="cite">_______________________________________________<br></blockquote></blockquote></blockquote></blockquote><blockquote type="cite"><blockquote type="cite"><blockquote type="cite"><blockquote type="cite">Developers mailing list<br></blockquote></blockquote></blockquote></blockquote><blockquote type="cite"><blockquote type="cite"><blockquote type="cite"><blockquote type="cite">Developers@admb-project.org<br></blockquote></blockquote></blockquote></blockquote><blockquote type="cite"><blockquote type="cite"><blockquote type="cite"><blockquote type="cite">http://lists.admb-project.org/mailman/listinfo/developers<br></blockquote></blockquote></blockquote></blockquote><blockquote type="cite"><blockquote type="cite"><blockquote type="cite">_______________________________________________<br></blockquote></blockquote></blockquote><blockquote type="cite"><blockquote type="cite"><blockquote type="cite">Developers mailing list<br></blockquote></blockquote></blockquote><blockquote type="cite"><blockquote type="cite"><blockquote type="cite">Developers@admb-project.org<br></blockquote></blockquote></blockquote><blockquote type="cite"><blockquote type="cite"><blockquote type="cite">http://lists.admb-project.org/mailman/listinfo/developers<br></blockquote></blockquote></blockquote><blockquote type="cite"><blockquote type="cite">_______________________________________________<br></blockquote></blockquote><blockquote type="cite"><blockquote type="cite">Developers mailing list<br></blockquote></blockquote><blockquote type="cite"><blockquote type="cite">Developers@admb-project.org<br></blockquote></blockquote><blockquote type="cite"><blockquote type="cite">http://lists.admb-project.org/mailman/listinfo/developers<br></blockquote></blockquote><blockquote type="cite"><br></blockquote><blockquote type="cite"><br></blockquote><blockquote type="cite"><br></blockquote><blockquote type="cite">------------------------------<br></blockquote><blockquote type="cite"><br></blockquote><blockquote type="cite">_______________________________________________<br></blockquote><blockquote type="cite">Developers mailing list<br></blockquote><blockquote type="cite">Developers@admb-project.org<br></blockquote><blockquote type="cite">http://lists.admb-project.org/mailman/listinfo/developers<br></blockquote><blockquote type="cite"><br></blockquote><blockquote type="cite"><br></blockquote><blockquote type="cite">End of Developers Digest, Vol 45, Issue 5<br></blockquote><blockquote type="cite">*****************************************<br></blockquote><br>-------------- next part --------------<br>An HTML attachment was scrubbed...<br>URL: <http://lists.admb-project.org/pipermail/developers/attachments/20121203/086c40d2/attachment.html><br>-------------- next part --------------<br>A non-text attachment was scrubbed...<br>Name: Threads.hpp<br>Type: application/octet-stream<br>Size: 27706 bytes<br>Desc: not available<br>URL: <http://lists.admb-project.org/pipermail/developers/attachments/20121203/086c40d2/attachment.obj><br>-------------- next part --------------<br>An HTML attachment was scrubbed...<br>URL: <http://lists.admb-project.org/pipermail/developers/attachments/20121203/086c40d2/attachment-0001.html><br><br>------------------------------<br><br>_______________________________________________<br>Developers mailing list<br>Developers@admb-project.org<br>http://lists.admb-project.org/mailman/listinfo/developers<br><br><br>End of Developers Digest, Vol 46, Issue 3<br>*****************************************<br></div></blockquote></div><br></body></html>