Files
FEX-Emu--FEX/Source/Common/Linux/SBRKAllocations.h
T
Ryan Houdek 1caa9d5294 FEX: Move SBRK handling to the frontend
This is fundamentally a frontend only problem, and also Linux only.
Moves it to the frontend where it belongs.

There's likely more things in Allocator.cpp that can be moved to the
frontend but this is the first thing.

NFC
2026-01-12 13:18:01 -08:00

12 lines
382 B
C++

// SPDX-License-Identifier: MIT
#pragma once
namespace FEX::SBRKAllocations {
// Disable allocations through glibc's sbrk allocation method.
// Returns a pointer at the end of the sbrk region.
void* DisableSBRKAllocations();
// Allow sbrk again. Pass in the pointer returned by `DisableSBRKAllocations`
void ReenableSBRKAllocations(void* Ptr);
} // namespace FEX::SBRKAllocations