diff options
| author | GPUCode <geoster3d@gmail.com> | 2023-11-19 11:21:53 +0200 |
|---|---|---|
| committer | t895 <clombardo169@gmail.com> | 2023-11-25 00:47:35 -0500 |
| commit | 3814ca9d84c60de40ef232bb5675eb0609617bc5 (patch) | |
| tree | 8c355b39a6f71e333ccc2f929816ce96e40d3f2c /src/common/host_memory.cpp | |
| parent | 3764cc4be287d5586b1a019febc49e75a7a5b0cb (diff) | |
Address some review comments
Diffstat (limited to 'src/common/host_memory.cpp')
| -rw-r--r-- | src/common/host_memory.cpp | 3 |
1 files changed, 3 insertions, 0 deletions
diff --git a/src/common/host_memory.cpp b/src/common/host_memory.cpp index 8a869e5589..f140777506 100644 --- a/src/common/host_memory.cpp +++ b/src/common/host_memory.cpp @@ -409,11 +409,14 @@ static void* ChooseVirtualBase(size_t virtual_size) { return MAP_FAILED; } + #else + static void* ChooseVirtualBase(size_t virtual_size) { return mmap(nullptr, virtual_size, PROT_READ | PROT_WRITE, MAP_PRIVATE | MAP_ANONYMOUS | MAP_NORESERVE, -1, 0); } + #endif class HostMemory::Impl { |
