<div dir="ltr"><br><div class="gmail_extra"><br><br><div class="gmail_quote">On Tue, Feb 11, 2014 at 4:39 PM, Mark Abraham <span dir="ltr"><<a href="mailto:mark.j.abraham@gmail.com" target="_blank">mark.j.abraham@gmail.com</a>></span> wrote:<br>
<blockquote class="gmail_quote" style="margin:0px 0px 0px 0.8ex;border-left-width:1px;border-left-color:rgb(204,204,204);border-left-style:solid;padding-left:1ex">
<div><div class="">
<p dir="ltr"><br>
On Feb 11, 2014 7:26 PM, "Roland Schulz" <<a href="mailto:roland@utk.edu" target="_blank">roland@utk.edu</a>> wrote:<br>
><br>
><br>
><br>
><br>
> On Tue, Feb 11, 2014 at 1:08 PM, David van der Spoel <<a href="mailto:spoel@xray.bmc.uu.se" target="_blank">spoel@xray.bmc.uu.se</a>> wrote:<br>
>><br>
>> On 2014-02-11 14:40, Roland Schulz wrote:<br>
>> > Hi,<br>
>> ><br>
>> > why does TNG_USE_OPENMP even exist? Why would a user want to set<br>
>> > TNG_USE_OPENMP to something other than GMX_OPENMP? If it is really<br>
>> > needed I suggest making TNG_USE_OPENMP a multi-choice (on, off, auto),<br>
>> > where auto is the default and auto takes the value from GMX_OPENMP.<br>
>> ><br>
>> I guess because tng is also distributed as a separate package.<br>
><br>
><br>
> That would explain why we need the variable TNG_USE_OPENMP, but not why that variable ever needs to be different than GMX_OPENMP. If there is no need for the user to be able to choose them independent, then it is trivial, because we can simply set TNG_USE_OPENMP
to GMX_OPENMP.</p>
</div><p dir="ltr">Agree there is no known need to have them have different values. As I said earlier, our use of TNG needs this to be a cache variable, which means there are persistence issues when GMX_OPENMP changes, whether we use set(... CACHE FORCE) or not.
</p></div></blockquote><div>If they don't have to have different values then using 'set ( TNG_USE_OPENMP "${GMX_OPENMP}" CACHE FORCE )' should solve the issue (with the set being executed unconditional every time). This makes it a cache variable for TNG and it makes sure that the value is always the same as GMX_OPENMP.</div>
<blockquote class="gmail_quote" style="margin:0px 0px 0px 0.8ex;border-left-width:1px;border-left-color:rgb(204,204,204);border-left-style:solid;padding-left:1ex"><div><p dir="ltr"> Magnus is experimenting with an external project to see if we can set up the trivial coupling that would then be possible.</p>
</div></blockquote><div>See my comments on redmine why this doesn't help.</div><div><br></div><div>Roland </div><blockquote class="gmail_quote" style="margin:0px 0px 0px 0.8ex;border-left-width:1px;border-left-color:rgb(204,204,204);border-left-style:solid;padding-left:1ex">
<div>
<p dir="ltr">The auto enum suggestion is a good one to keep in mind for the future!</p><span class=""><font color="#888888">
<p dir="ltr">Mark</p></font></span><div><div class="h5">
<p dir="ltr">> Roland<br>
><br>
>><br>
>> > Roland<br>
>> ><br>
>> ><br>
>> > On Mon, Feb 10, 2014 at 1:36 PM, Mark Abraham <<a href="mailto:mark.j.abraham@gmail.com" target="_blank">mark.j.abraham@gmail.com</a><br>
>> > <mailto:<a href="mailto:mark.j.abraham@gmail.com" target="_blank">mark.j.abraham@gmail.com</a>>> wrote:<br>
>> ><br>
>> > Hi,<br>
>> ><br>
>> > Good question. I think it may be unsolvable in the current setup.<br>
>> > The TNG CMakeLists.cmake declares TNG_USE_OPENMP in its cache in the<br>
>> > normal way, but since there is only one cache and GROMACS accesses<br>
>> > that file with add_subdirectory, that makes that variable exist on<br>
>> > the GROMACS cache. Now getting that variable to track GMX_OPENMP<br>
>> > unless set by the user might be hard.<br>
>> ><br>
>> > Using gmx_dependent_option seems like it might work, but I have not<br>
>> > yet put enough time into reading/testing how those functions work. I<br>
>> > am not sure from reading the descriptions if it can implement "copy<br>
>> > this value unless at some point these two values differed." Unless<br>
>> > Teemu has some insight from how he built these, we might have to<br>
>> > experiment and then document/extend accordingly.<br>
>> ><br>
>> > Alternative: I believe we can give TNG its own cache by using what<br>
>> > is called an external project. Since I don't think we need a<br>
>> > separate cache variable in the GROMACS configuration UI for this<br>
>> > OpenMP setting, this should side-step the above, because the TNG<br>
>> > CMake will always see the parent project set the OpenMP in the TNG<br>
>> > cache. Might have other benefits also.<br>
>> ><br>
>> > Mark<br>
>> ><br>
>> > On Feb 10, 2014 2:49 PM, "Szilárd Páll" <<a href="mailto:pall.szilard@gmail.com" target="_blank">pall.szilard@gmail.com</a><br>
>> > <mailto:<a href="mailto:pall.szilard@gmail.com" target="_blank">pall.szilard@gmail.com</a>>> wrote:<br>
>> ><br>
>> > Hi,<br>
>> ><br>
>> > I'm trying to fix issue #1432, but I realized that I know very<br>
>> > little<br>
>> > about the gmxOptionUtilities cmake module, so I thought I'd ask for<br>
>> > comments and suggestions.<br>
>> ><br>
>> > Here's what I need to do (ideally/if possible):<br>
>> > - The value of the TNG_USE_OPENMP cache variable should always have<br>
>> > the same value as GMX_OPENMP (even if the latter gets changed<br>
>> > multiple<br>
>> > times) *unless*<br>
>> > - The user manually set a value for the TNG_USE_OPENMP variable.<br>
>> ><br>
>> > I'm guessing I should use the gmx_dependent_option() macro, but I'm<br>
>> > not sure how. Tips would be appreciated!<br>
>> ><br>
>> > Cheers,<br>
>> > --<br>
>> > Szilárd<br>
>> > --<br>
>> > Gromacs Developers mailing list<br>
>> ><br>
>> > * Please search the archive at<br>
>> > <a href="http://www.gromacs.org/Support/Mailing_Lists/GMX-developers_List" target="_blank">
http://www.gromacs.org/Support/Mailing_Lists/GMX-developers_List</a><br>
>> > before posting!<br>
>> ><br>
>> > * Can't post? Read <a href="http://www.gromacs.org/Support/Mailing_Lists" target="_blank">
http://www.gromacs.org/Support/Mailing_Lists</a><br>
>> ><br>
>> > * For (un)subscribe requests visit<br>
>> > <a href="https://maillist.sys.kth.se/mailman/listinfo/gromacs.org_gmx-developers" target="_blank">
https://maillist.sys.kth.se/mailman/listinfo/gromacs.org_gmx-developers</a><br>
>> > or send a mail to <a href="mailto:gmx-developers-request@gromacs.org" target="_blank">
gmx-developers-request@gromacs.org</a><br>
>> > <mailto:<a href="mailto:gmx-developers-request@gromacs.org" target="_blank">gmx-developers-request@gromacs.org</a>>.<br>
>> ><br>
>> ><br>
>> ><br>
>> ><br>
>> > --<br>
>> > ORNL/UT Center for Molecular Biophysics <a href="http://cmb.ornl.gov" target="_blank">cmb.ornl.gov</a> <<a href="http://cmb.ornl.gov" target="_blank">http://cmb.ornl.gov</a>><br>
>><br>
>> > <a href="tel:865-241-1537" value="+18652411537" target="_blank">865-241-1537</a>, ORNL PO BOX 2008 MS6309<br>
>> ><br>
>> ><br>
>><br>
>><br>
>> --<br>
>> David van der Spoel, Ph.D., Professor of Biology<br>
>> Dept. of Cell & Molec. Biol., Uppsala University.<br>
>> Box 596, 75124 Uppsala, Sweden. Phone: <a href="tel:%2B46184714205" value="+46184714205" target="_blank">+46184714205</a>.<br>
>> <a href="mailto:spoel@xray.bmc.uu.se" target="_blank">spoel@xray.bmc.uu.se</a> <a href="http://folding.bmc.uu.se" target="_blank">http://folding.bmc.uu.se</a><br>
>> --<br>
>> Gromacs Developers mailing list<br>
>><br>
>> * Please search the archive at <a href="http://www.gromacs.org/Support/Mailing_Lists/GMX-developers_List" target="_blank">
http://www.gromacs.org/Support/Mailing_Lists/GMX-developers_List</a> before posting!<br>
>><br>
>> * Can't post? Read <a href="http://www.gromacs.org/Support/Mailing_Lists" target="_blank">http://www.gromacs.org/Support/Mailing_Lists</a><br>
>><br>
>> * For (un)subscribe requests visit<br>
>> <a href="https://maillist.sys.kth.se/mailman/listinfo/gromacs.org_gmx-developers" target="_blank">
https://maillist.sys.kth.se/mailman/listinfo/gromacs.org_gmx-developers</a> or send a mail to
<a href="mailto:gmx-developers-request@gromacs.org" target="_blank">gmx-developers-request@gromacs.org</a>.<br>
>><br>
>><br>
>><br>
>><br>
><br>
><br>
><br>
> -- <br>
> ORNL/UT Center for Molecular Biophysics <a href="http://cmb.ornl.gov" target="_blank">cmb.ornl.gov</a><br>
> <a href="tel:865-241-1537" value="+18652411537" target="_blank">865-241-1537</a>, ORNL PO BOX 2008 MS6309<br>
><br>
> --<br>
> Gromacs Developers mailing list<br>
><br>
> * Please search the archive at <a href="http://www.gromacs.org/Support/Mailing_Lists/GMX-developers_List" target="_blank">
http://www.gromacs.org/Support/Mailing_Lists/GMX-developers_List</a> before posting!<br>
><br>
> * Can't post? Read <a href="http://www.gromacs.org/Support/Mailing_Lists" target="_blank">http://www.gromacs.org/Support/Mailing_Lists</a><br>
><br>
> * For (un)subscribe requests visit<br>
> <a href="https://maillist.sys.kth.se/mailman/listinfo/gromacs.org_gmx-developers" target="_blank">
https://maillist.sys.kth.se/mailman/listinfo/gromacs.org_gmx-developers</a> or send a mail to
<a href="mailto:gmx-developers-request@gromacs.org" target="_blank">gmx-developers-request@gromacs.org</a>.<br>
</p>
</div></div></div>
</blockquote></div><br><br clear="all"><div><br></div>-- <br>ORNL/UT Center for Molecular Biophysics <a href="http://cmb.ornl.gov">cmb.ornl.gov</a><br>865-241-1537, ORNL PO BOX 2008 MS6309
</div></div>