use size_t type for memory amount in memory allocation routines