On 8/23/2013 7:37 PM, Jed Brown wrote:
Barry Smith <[email protected]> writes:
We call free() at that point. But not that in Unix this does not
mean the memory is returned to the operating system so you will not
see the process memory go down. If you then allocate new objects
they will reuse this memory.
Also note that MatDestroy only releases a references, so if another
object still holds a reference to your matrix, nothing will be freed.
Thank you!
Just to clarify: if a code reads like this:
Mat A;
MatCreate(MPI_COMM_WORLD, &A);
Mat B = A;
....
MatDestroy(&B);
Will the free() function be called for the memory that contains the
matrix data in this case?
Thank you,
Michael.