<html>
<head>
<meta http-equiv="content-type" content="text/html; charset=ISO-8859-1">
</head>
<body text="#000000" bgcolor="#FFFFFF">
Hi All,<br>
<br>
I have the following codes, it can be compiled but it always throw
out error when running. I also tried the example ex44f.F90, it
although throw out similar error. <br>
<br>
call
DMDAGetInfo(da,PETSC_NULL_INTEGER,mx,PETSC_NULL_INTEGER, &<br>
PETSC_NULL_INTEGER,PETSC_NULL_INTEGER,PETSC_NULL_INTEGER,
&<br>
PETSC_NULL_INTEGER,PETSC_NULL_INTEGER,PETSC_NULL_INTEGER,
&<br>
PETSC_NULL_INTEGER,PETSC_NULL_INTEGER,PETSC_NULL_INTEGER,
&<br>
PETSC_NULL_INTEGER,ierr)<br>
call
DMDAGetCorners(da,xs,PETSC_NULL_INTEGER,PETSC_NULL_INTEGER, &<br>
xm,PETSC_NULL_INTEGER,PETSC_NULL_INTEGER,ierr)<br>
call VecGetArrayF90(b,vecpointer,ierr)<br>
do i = xs, xs+xm-1<br>
<b><font color="#ff0000">vecpointer(i)=b_in(i+1)
!!!Error here</font></b><br>
end do<br>
call VecRestoreArrayF90(b,vecpointer,ierr)<br>
<br>
<b>The compiler information are:</b><br>
<br>
$ make ksp_inhm_d<br>
/cygdrive/c/cygwin/packages/petsc-3.4.2/bin/win32fe/win32fe ifort
-c -MT -Z7 -fpp -I/cygdrive/c/cygwin/packages/petsc-<br>
3.4.2/include
-I/cygdrive/c/cygwin/packages/petsc-3.4.2/arch-mswin-c-debug/include
-I/cygdrive/c/cygwin/packages/parmeti<br>
s-4.0.3/include -I/cygdrive/c/cygwin/packages/metis-5.1.0/include
-I/cygdrive/c/Program\ Files/MPICH2/include -o ksp_<br>
inhm.o ksp_inhm.F90<br>
/cygdrive/c/cygwin/packages/petsc-3.4.2/bin/win32fe/win32fe cl -MT
-wd4996 -Z7 -o ksp_inhm_d ksp_inhm.o -L/cygdrive/c/<br>
cygwin/packages/petsc-3.4.2/arch-mswin-c-debug/lib -lpetsc
-lflapack -lfblas /cygdrive/c/cygwin/packages/parmetis-4.0.3<br>
/build/libparmetis/Release/parmetis.lib
/cygdrive/c/cygwin/packages/metis-5.1.0/build/libmetis/Release/metis.lib
/cygdri<br>
ve/c/Program\ Files/MPICH2/lib/fmpich2.lib /cygdrive/c/Program\
Files/MPICH2/lib/fmpich2g.lib /cygdrive/c/Program\ Files<br>
/MPICH2/lib/mpi.lib Gdi32.lib User32.lib Advapi32.lib Kernel32.lib
Ws2_32.lib<br>
/usr/bin/rm -f ksp_inhm.o ksp_inhm.mod<br>
<br>
<b>And the error information are:</b><br>
[1]PETSC ERROR: PetscTrFreeDefault() called from VecDestroy_MPI()
line 20 in src/vec/vec/impls/mpi/C:\cygwin\packages\PE<br>
TSC-~1.2\src\vec\vec\impls\mpi\pdvec.c<br>
[1]PETSC ERROR: Block [id=0(4048)] at address 000000000279DBE0 is
corrupted (probably write past end of array)<br>
[1]PETSC ERROR: Block allocated in VecCreate_MPI_Private() line 197
in src/vec/vec/impls/mpi/C:\cygwin\packages\PETSC-~1<br>
.2\src\vec\vec\impls\mpi\pbvec.c<br>
[1]PETSC ERROR: --------------------- Error Message
------------------------------------<br>
[1]PETSC ERROR: Memory corruption!<br>
[1]PETSC ERROR: Corrupted memory!<br>
[1]PETSC ERROR:
------------------------------------------------------------------------<br>
[1]PETSC ERROR: Petsc Release Version 3.4.2, Jul, 02, 2013<br>
[1]PETSC ERROR: See docs/changes/index.html for recent updates.<br>
[1]PETSC ERROR: See docs/faq.html for hints about trouble shooting.<br>
[1]PETSC ERROR: See docs/index.html for manual pages.<br>
[1]PETSC ERROR:
------------------------------------------------------------------------<br>
[1]PETSC ERROR:
D:\dsu\ResearchAtUBC\Dropbox\ParallelDevelop\AuxiliaryPrograms\Petsc-Solver-Test\petsc_unsym_f\ksp_inhm_<br>
d.exe on a arch-mswin-c-debug named NWMOP by dsu Tue Aug 13 18:46:55
2013<br>
[1]PETSC ERROR: Libraries linked from
/cygdrive/c/cygwin/packages/petsc-3.4.2/arch-mswin-c-debug/lib<br>
[1]PETSC ERROR: Configure run at Tue Aug 6 10:46:18 2013<br>
[1]PETSC ERROR: Configure options --with-cc="win32fe cl"
--with-fc="win32fe ifort" --with-cxx="win32fe cl" --with-parmet<br>
is-include=/cygdrive/c/cygwin/packages/parmetis-4.0.3/include
--with-parmetis-lib=/cygdrive/c/cygwin/packages/parmetis-4<br>
.0.3/build/libparmetis/Release/parmetis.lib
--with-metis-include=/cygdrive/c/cygwin/packages/metis-5.1.0/include
--with-<br>
metis-lib=/cygdrive/c/cygwin/packages/metis-5.1.0/build/libmetis/Release/metis.lib
--download-f-blas-lapack --useThreads<br>
=0<br>
[1]PETSC ERROR:
------------------------------------------------------------------------<br>
[1]PETSC ERROR: PetscTrFreeDefault() line 301 in
src/sys/memory/C:\cygwin\packages\PETSC-~1.2\src\sys\memory\mtr.c<br>
[1]PETSC ERROR: VecDestroy_MPI() line 20 in
src/vec/vec/impls/mpi/C:\cygwin\packages\PETSC-~1.2\src\vec\vec\impls\mpi\pd<br>
vec.c<br>
[1]PETSC ERROR: VecDestroy() line 546 in
src/vec/vec/interface/C:\cygwin\packages\PETSC-~1.2\src\vec\vec\INTERF~1\vector<br>
.c<br>
[1]PETSC ERROR: PetscTrFreeDefault() called from VecDestroy_MPI()
line 30 in src/vec/vec/impls/mpi/C:\cygwin\packages\PE<br>
TSC-~1.2\src\vec\vec\impls\mpi\pdvec.c<br>
[1]PETSC ERROR: Block at address 000000000279FDD0 is corrupted;
cannot free;<br>
may be block not allocated with PetscMalloc()<br>
[1]PETSC ERROR: --------------------- Error Message
------------------------------------<br>
[1]PETSC ERROR: Memory corruption!<br>
[1]PETSC ERROR: Bad location or corrupted memory!<br>
[1]PETSC ERROR:
------------------------------------------------------------------------<br>
[1]PETSC ERROR: Petsc Release Version 3.4.2, Jul, 02, 2013<br>
[1]PETSC ERROR: See docs/changes/index.html for recent updates.<br>
[1]PETSC ERROR: See docs/faq.html for hints about trouble shooting.<br>
[1]PETSC ERROR: See docs/index.html for manual pages.<br>
[1]PETSC ERROR:
------------------------------------------------------------------------<br>
[1]PETSC ERROR:
D:\dsu\ResearchAtUBC\Dropbox\ParallelDevelop\AuxiliaryPrograms\Petsc-Solver-Test\petsc_unsym_f\ksp_inhm_<br>
d.exe on a arch-mswin-c-debug named NWMOP by dsu Tue Aug 13 18:46:55
2013<br>
[1]PETSC ERROR: Libraries linked from
/cygdrive/c/cygwin/packages/petsc-3.4.2/arch-mswin-c-debug/lib<br>
[1]PETSC ERROR: Configure run at Tue Aug 6 10:46:18 2013<br>
[1]PETSC ERROR: Configure options --with-cc="win32fe cl"
--with-fc="win32fe ifort" --with-cxx="win32fe cl" --with-parmet<br>
is-include=/cygdrive/c/cygwin/packages/parmetis-4.0.3/include
--with-parmetis-lib=/cygdrive/c/cygwin/packages/parmetis-4<br>
.0.3/build/libparmetis/Release/parmetis.lib
--with-metis-include=/cygdrive/c/cygwin/packages/metis-5.1.0/include
--with-<br>
metis-lib=/cygdrive/c/cygwin/packages/metis-5.1.0/build/libmetis/Release/metis.lib
--download-f-blas-lapack --useThreads<br>
=0<br>
[1]PETSC ERROR:
------------------------------------------------------------------------<br>
[1]PETSC ERROR: PetscTrFreeDefault() line 283 in
src/sys/memory/C:\cygwin\packages\PETSC-~1.2\src\sys\memory\mtr.c<br>
[1]PETSC ERROR: VecDestroy_MPI() line 30 in
src/vec/vec/impls/mpi/C:\cygwin\packages\PETSC-~1.2\src\vec\vec\impls\mpi\pd<br>
vec.c<br>
[1]PETSC ERROR: VecDestroy() line 546 in
src/vec/vec/interface/C:\cygwin\packages\PETSC-~1.2\src\vec\vec\INTERF~1\vector<br>
.c<br>
<br>
<br>
Thanks and regards,<br>
<br>
Danyang<br>
</body>
</html>