#include "memmanager.h"
#include <stdlib.h>
-#if ENABLE_TINYMM
-#include <tinymm.h>
-#endif
#ifdef ENABLE_THREADED_COMPILER
#include <stdatomic.h>
{
void *ptr;
-#if ENABLE_TINYMM
- if (type == MEM_FOR_IR)
- ptr = tinymm_malloc(state->tinymm, len);
- else
-#endif
- ptr = malloc(len);
+ ptr = malloc(len);
if (!ptr)
return NULL;
{
void *ptr;
-#if ENABLE_TINYMM
- if (type == MEM_FOR_IR)
- ptr = tinymm_zalloc(state->tinymm, len);
- else
-#endif
- ptr = calloc(1, len);
+ ptr = calloc(1, len);
if (!ptr)
return NULL;
enum mem_type type, unsigned int len, void *ptr)
{
lightrec_unregister(type, len);
-#if ENABLE_TINYMM
- if (type == MEM_FOR_IR)
- tinymm_free(state->tinymm, ptr);
- else
-#endif
- free(ptr);
+ free(ptr);
}
float lightrec_get_average_ipi(void)