From c9a250b77f8a18d421fff2262be51abe1419504e Mon Sep 17 00:00:00 2001 From: momo5502 Date: Tue, 24 Dec 2024 10:15:57 +0100 Subject: [PATCH] Preallocate unicorn translation buffer to 2gb --- src/unicorn-emulator/unicorn_x64_emulator.cpp | 1 + 1 file changed, 1 insertion(+) diff --git a/src/unicorn-emulator/unicorn_x64_emulator.cpp b/src/unicorn-emulator/unicorn_x64_emulator.cpp index f6848195..bbcb2a8e 100644 --- a/src/unicorn-emulator/unicorn_x64_emulator.cpp +++ b/src/unicorn-emulator/unicorn_x64_emulator.cpp @@ -242,6 +242,7 @@ namespace unicorn unicorn_x64_emulator() { uce(uc_open(UC_ARCH_X86, UC_MODE_64, &this->uc_)); + uce(uc_ctl_set_tcg_buffer_size(this->uc_, 2 << 30 /* 2 gb */)); } ~unicorn_x64_emulator() override