From 509157a8b04ddec0f20e39136877bd13ce83e4e4 Mon Sep 17 00:00:00 2001 From: ptitSeb Date: Fri, 30 Jun 2023 15:24:08 +0200 Subject: Go back to using regular malloc/free for Dynarec temporary allocation when building a block --- src/include/dynarec_native.h | 13 +++++++++++++ 1 file changed, 13 insertions(+) (limited to 'src/include') diff --git a/src/include/dynarec_native.h b/src/include/dynarec_native.h index 891485a9..a956f1cc 100755 --- a/src/include/dynarec_native.h +++ b/src/include/dynarec_native.h @@ -5,6 +5,19 @@ typedef struct dynablock_s dynablock_t; typedef struct x64emu_s x64emu_t; typedef struct instsize_s instsize_t; +//#define USE_CUSTOM_MEM +#ifdef USE_CUSTOM_MEM +#define dynaMalloc customMalloc +#define dynaCalloc customCalloc +#define dynaRealloc customRealloc +#define dynaFree customFree +#else +#define dynaMalloc malloc +#define dynaCalloc calloc +#define dynaRealloc realloc +#define dynaFree free +#endif + void addInst(instsize_t* insts, size_t* size, int x64_size, int native_size); void CancelBlock64(int need_lock); -- cgit 1.4.1