[gmx-developers] Adding computing kernels in shared linked library

Sebastian Jodłowski jodelek at icm.edu.pl
Fri Aug 26 10:04:00 CEST 2011

I am using only real and rvec variable types.
I traced variables and printfed them to 6th place after comma. At the
very begining everything is ok but after, say, 40 iterations it starts
to diverge. I also run a 1500-iteration-test, printed everything (took
a while) and compared final results - it was simillar. My supervisors
agreed that it must be some kind of reproduction bug but accepted the
result as relativly proper, cause the algorithm is proper.
Now I'm starting porting it to CUDA and it will occur if the
differences propagate.

After relinking statically and disabling optimization I got different
result from earliers (as expected) but lib version still diverges from

On 25 August 2011 16:49, Bogdan Costescu <bcostescu at gmail.com> wrote:
> 2011/8/25 Sebastian Jodłowski <jodelek at icm.edu.pl>:
>> I run valgrind on mdrun and for 100 step of minimization set in
>> mini.mdp file do_cg() is called 148 times in non-library version
>> wherease in library version it is called only 132 times.
> My guess is that you are mixing types of different precision, such
> that small differences that you don't even see when printing with only
> say 3 digits after comma account for the different behavior. Without
> seeing the code and the way it is built it's hard to be more
> precise... but let's give it a try: are you using only "real" and
> "rvec" type variables ? Or are you converting to/from some other
> precision ?
> Cheers,
> Bogdan
> --
> gmx-developers mailing list
> gmx-developers at gromacs.org
> http://lists.gromacs.org/mailman/listinfo/gmx-developers
> Please don't post (un)subscribe requests to the list. Use the
> www interface or send it to gmx-developers-request at gromacs.org.

More information about the gromacs.org_gmx-developers mailing list