[petsc-users] Optimised vs Debug

Bogdan Dita bogdan at lmn.pub.ro
Wed Dec 7 18:16:13 CST 2011

Thanks Jed,
this is the kind of answer i really needed to hear(I hope it works), I was
sure that something in the shadows of mpich2 didn't act acording to my
expectations but honestly I didn't even knew where to start looking.
I'll try this and then get back to you.

To Barry:
Regarding the output from -log_summary for the debug and opt versions, I
already sent them a few weeks back in a mail to 'petsc-users', your answer
was that the time increase came from the factorization of the matrix.
If it will be necessary in my next post I'll attache the two files, but
first I want to try Jed's idea.


> On Wed, Dec 7, 2011 at 06:31, Bogdan Dita <bogdan at lmn.pub.ro> wrote:
>> A few weeks ago i posted a question regarding a problem with the
>> optimised version of PETSc, what i mean is that I obtained a higher
>> solving time with the optimised version then with the debug
>> version(~10-15% higher).
> What do you get from 'mpicc -show'?
> MPICH2 has a tendency to put optimization flags into the wrappers. It's
> possible that the "optimized" build of PETSc is effectively using -O2
> (from
> MPICH2) and -g3 (from PETSc with-debugging=1), which might be faster than
> -O2 (from MPICH2) -O (from PETSc with-debugging=0, taking precedence) that
> you get when you. You can use PETSc's --COPTFLAGS to set your own
> optimization flags for PETSc.
> Let us know if this works.

>  If this doesn't work produce the results from running the same code
>using the
>-log_summary option with and without debug. Then send the two outputs to
>petsc-maint at mcs.anl.gov this will tell us what parts of the code (all?)
>are slower
>and faster in the different versions.
>   Barry

More information about the petsc-users mailing list