diff options
| author | Markus Wick <markus@selfnet.de> | 2021-06-11 11:47:23 +0200 |
|---|---|---|
| committer | Markus Wick <markus@selfnet.de> | 2021-06-11 17:27:17 +0200 |
| commit | 161ade6da08c181a96d0f5e6f90b74fa99e04b78 (patch) | |
| tree | 0e4ce28226164e465b8739b22604b1741d2b1c11 /src/common/host_memory.h | |
| parent | f664a4d4c16e0779cb60c23641b0b8c04731744c (diff) | |
common/host_memory: Implement a fallback if fastmem fails.
This falls back to the old approach of using a virtual buffer.
Windows is untested, but this build should fix support for Windows < 10 v1803. However without fastmem support at all.
Diffstat (limited to 'src/common/host_memory.h')
| -rw-r--r-- | src/common/host_memory.h | 4 |
1 files changed, 4 insertions, 0 deletions
diff --git a/src/common/host_memory.h b/src/common/host_memory.h index eaa7d18ab5..9b8326d0fb 100644 --- a/src/common/host_memory.h +++ b/src/common/host_memory.h @@ -6,6 +6,7 @@ #include <memory> #include "common/common_types.h" +#include "common/virtual_buffer.h" namespace Common { @@ -61,6 +62,9 @@ private: u8* backing_base{}; u8* virtual_base{}; size_t virtual_base_offset{}; + + // Fallback if fastmem is not supported on this platform + std::unique_ptr<Common::VirtualBuffer<u8>> fallback_buffer; }; } // namespace Common |
