mzd_realloc

Issue #1 new
Martin Albrecht repo owner created an issue

I have a memory problem with concatenating two matrices, appending two matrices and copy matrix (mzd_submatrix) . The problem is happened in case of I have two big matrices and during the concatenation or the appending process I have twice the size in > the memory which terminates the main process and the program (reach to the memory limit). I tried to make reallocation to the matrix to make the concatenation and the appending processes using a little bit less memory. But I have a problem with this code.

After performing mzd_reduce_m4ri on the matrix M. I removed the > zero row at the end by using the following statement: reallocating(M, rank, M->ncols); In the multiplication process when I tried to append M with other zero matrix T that has the same number of columns by the following statement: M = mzd_append(NULL, M, T);

the program terminated without printing any error message. But I think the program stopped because of it can not access >M->values[some index].

Bottomline: implement mzd_realloc(A, m, n) which restricts A to the first m rows and n columns in place.

Comments (0)

  1. Log in to comment