54void * ytLib_malloc_regist(
size_t size,
const char * file,
int line);
55void * ytLib_realloc_regist(
void * ptr,
size_t size,
const char * file,
int line);
56void ytLib_free_regist(
void * ptr,
const char * file,
int line);
57void ytLib_registMemoryTable(
void * ptr,
size_t size,
const char * file,
int line,
int type);
58void ytLib_removeMemoryTable(
void * ptr,
const char * file,
int line,
int type);
60void * ytLib_mallocBase(
size_t size,
const char * file,
int line,
const char * func,
int code,
int location);
61void * ytLib_reallocBase(
void * ptr,
size_t size,
const char * file,
int line,
const char * func,
int code,
int location);
65#define malloc(x) ytLib_malloc_regist(x, __FILE__, __LINE__)
66#define realloc(x,y) ytLib_realloc_regist(x, y, __FILE__, __LINE__)
67#define free(x) ytLib_free_regist(x, __FILE__, __LINE__)
69#define malloc(x) ytLib_mallocBase(x,__FILE__,__LINE__,__func__,999999,0)
70#define realloc(x,y) ytLib_reallocBase(x,y,__FILE__,__LINE__,__func__,999999,0)
73#define ytLib_malloc(x,y,z) ytLib_mallocBase(x,__FILE__,__LINE__,__func__,y,z)
74#define ytLib_realloc(x,y,z,a) ytLib_reallocBase(x,y,__FILE__,__LINE__,__func__,z,a)
79void ytLib_assertBase(
int value,
char * file,
int line);
80#define ytLib_assert(x) ytLib_assertBase(x, __FILE__, __LINE__)
size_t ytLib_getAllocMemory()
Returns the total size of allocated memory.
Definition ytLib.c:234
const char * ytLib_version()
Returns the ytLib Git version.
Definition ytLib.c:55
void ytLib_init()
Initializes the YT Lib library.
Definition ytLib.c:49
FILE * ytLib_ERR
File pointer for error output.
Definition ytLib.c:44
void ytLib_showMemoryTable(FILE *fp)
Prints the ytLib memory table.
Definition ytLib.c:205