memory bleeding

Jordi Marcé Nogué jordi.marce at upc.edu
Mon May 8 05:10:07 CDT 2006


Thanks Barry, 
 
I'm using petsc 2.2.0. When I run my program ( " ./myprogram -trdump " or with 
-trmalloc, -trinfo...) I don't obtain anything... in the screen the code doesn't
print 
anything. 
 
If I use (for example) "./myprogram -start_on_debugger", in my screen apers gdb

and runs good... and with another options like -log_trace petsc writes messages
in 
my screen. Would I have to activate something in my internal petsc code? 
 
best regards, 
jordi 
 
 
 
 
 
 
Missatge citat per Barry Smith <bsmith at mcs.anl.gov>: 
 
>  
>     See 
> 
http://www-unix.mcs.anl.gov/petsc/petsc-as/documentation/troubleshooting.html 
> number 12 
>  
>     You can run for say a few iterations with the options 
> -malloc_debug -malloc_dump (in  PETSc 2.3.1. in early releases it had 
> different names). At PetscFinalize() PETSc will print all the memory 
> it has allocated that has not been freed and where it was allocated. 
> This can help determine what objects are not being freed. 
>  
>     Barry 
>  
> > 
> > Hi, 
> > 
> > I use PETSc, and after 5000 (more or less) iteations in which i solve a 
> little 
> > matrix 
> > (30x30) my swap is totally used!!! I'm sure that when I create my matrices 
> I 
> > destroy 
> > them. Could you help me about it? What happens? What thing I do bad? 
> > 
> > Mat K 
> > MatCreateSeqAIJ(PETSC_COMM_SELF, dim, dim, 9 , PETSC_NULL, &K); 
> > MatSetFromOptions(K); 
> > MatSetOption(K, MAT_SYMMETRIC); 
> > MatSetOption(K, MAT_ROW_ORIENTED); 
> > MatSetOption(K, MAT_IGNORE_ZERO_ENTRIES); 
> > MatSetOption(K, MAT_NEW_NONZERO_ALLOCATION_ERR); 
> > 
> > ( I use KSP solve, created and destroyed) 
> > 
> > MatDestroy(K); 
> > 
> > 
> > Thanks, 
> > jordi 
> > ----------- 
> > Jordi Marcé-Nogué 
> > Dept. Resistència de Materials i Estructures a l'Enginyeria 
> > Universitat Politècnica de Catalunya (UPC) 
> > 
> > Edifici T45 - despatx 137 
> > ETSEIAT (Terrassa) 
> > 
> > phone: +34 937 398 728 
> > mail: jordi.marce at upc.edu 
> > 
> > 
> > 
 
 
  




More information about the petsc-users mailing list