[petsc-users] VecSetValue. fails with -O1/2/3

Jed Brown jed at 59A2.org
Mon May 16 01:49:38 CDT 2011


Try with valgrind. The compiler is probably initializing a variable only at
-O0.

On May 16, 2011 8:28 AM, "Clemens Domanig" <clemens.domanig at uibk.ac.at>
wrote:

Hi everyone,

maybe someone can explain to me what is going wrong with my code.

In my programm I read values from a vector A and write them at new positions
into a vector B. This works well as long as I don't use any
optimization-flags when compiling the code. If I use -O1/2/3 the petsc tells
me: "out of range error" at VecSetValue.
It always happens at the some position although I'm doing this kind of
operations at different places again.

petsc-version 3.1.6
g++-version: gcc version 4.1.2 20080704 (Red Hat 4.1.2-48)

Thx for your help - C. Domanig
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.mcs.anl.gov/pipermail/petsc-users/attachments/20110516/8f8be4fe/attachment.htm>


More information about the petsc-users mailing list