mirror of
https://github.com/WinampDesktop/winamp.git
synced 2025-06-18 10:25:45 -04:00
Haiku port of duckstation libretro core (#716)
* Haiku build 1st attempt * fix load on Haiku * Removed debugging flags * Added a couple ifndef
This commit is contained in:
@ -20,9 +20,11 @@ constexpr bool USE_BLOCK_LINKING = true;
|
||||
#ifdef WITH_RECOMPILER
|
||||
static constexpr u32 RECOMPILER_CODE_CACHE_SIZE = 32 * 1024 * 1024;
|
||||
static constexpr u32 RECOMPILER_FAR_CODE_CACHE_SIZE = 32 * 1024 * 1024;
|
||||
#ifndef __HAIKU__
|
||||
static constexpr u32 RECOMPILER_GUARD_SIZE = 4096;
|
||||
alignas(Recompiler::CODE_STORAGE_ALIGNMENT) static u8
|
||||
s_code_storage[RECOMPILER_CODE_CACHE_SIZE + RECOMPILER_FAR_CODE_CACHE_SIZE];
|
||||
#endif
|
||||
static JitCodeBuffer s_code_buffer;
|
||||
|
||||
enum : u32
|
||||
@ -90,8 +92,12 @@ void Initialize(bool use_recompiler)
|
||||
|
||||
#ifdef WITH_RECOMPILER
|
||||
s_use_recompiler = use_recompiler;
|
||||
#ifndef __HAIKU__
|
||||
if (!s_code_buffer.Initialize(s_code_storage, sizeof(s_code_storage), RECOMPILER_FAR_CODE_CACHE_SIZE,
|
||||
RECOMPILER_GUARD_SIZE))
|
||||
#else
|
||||
if (!s_code_buffer.Allocate(RECOMPILER_CODE_CACHE_SIZE, RECOMPILER_FAR_CODE_CACHE_SIZE))
|
||||
#endif
|
||||
{
|
||||
Panic("Failed to initialize code space");
|
||||
}
|
||||
|
Reference in New Issue
Block a user