C
Chang Byun
I have question about memory allocation.
I have a trouble when I run a C program.
My C program has several big double pointer(** var) variables to
structure data like 4 by 5000000.
It is supposed to calculate those varibles with different parameters
repeatedly with same size of variables.
When it is running, the first several run is fine
But it uses more and more memory, is used up all the main memory
and swap memory and is stop.
I am pretty sure that I free every variable for each run using free().
My questions are,
1. if the process needs more memory space even though every
variables are released with free().
2. How can I check if there is memory leak?
3. Would it be better if big variables breaks down to smaller size
variables.
Any seggestions and helps would be very appreciated.
Thanks,
Chang Byun
I have a trouble when I run a C program.
My C program has several big double pointer(** var) variables to
structure data like 4 by 5000000.
It is supposed to calculate those varibles with different parameters
repeatedly with same size of variables.
When it is running, the first several run is fine
But it uses more and more memory, is used up all the main memory
and swap memory and is stop.
I am pretty sure that I free every variable for each run using free().
My questions are,
1. if the process needs more memory space even though every
variables are released with free().
2. How can I check if there is memory leak?
3. Would it be better if big variables breaks down to smaller size
variables.
Any seggestions and helps would be very appreciated.
Thanks,
Chang Byun