Commit graph

17 commits

Author SHA1 Message Date
Liam
9509fb30a4 Initial ARM64 support 2022-11-09 16:58:49 -05:00
Morph
2b87305d31 general: Convert source file copyright comments over to SPDX
This formats all copyright comments according to SPDX formatting guidelines.
Additionally, this resolves the remaining GPLv2 only licensed files by relicensing them to GPLv2.0-or-later.
2022-04-23 05:55:32 -04:00
Merry
ae642bbff2 common: Replace lock_guard with scoped_lock 2022-04-07 19:30:55 +01:00
ameerj
f9709bb9e9 general: Fix clang/gcc build errors 2022-03-20 02:25:09 -04:00
ameerj
e70b4f3fc5 common: Reduce unused includes 2022-03-19 15:01:31 -04:00
Morph
5ea520a149 host_memory: Fix fastmem crashes in debug builds
It is possible for virtual_offset to not be 0 when the iterator is at the beginning, and thus, std::prev(it) may be evaluated, leading to a crash in debug mode.

Co-Authored-By: Fernando S. <1731197+FernandoS27@users.noreply.github.com>
2022-03-02 18:36:59 -05:00
ameerj
8969273d2d general: Add missing copyright notices 2021-12-05 16:18:53 -05:00
Andrew Strelsky
a24aa6e5bd Fixed invalid iterator usage 2021-09-29 06:58:48 -04:00
Jan Beich
471ddd0674 host_memory: Add workaround for FreeBSD 12
src/common/host_memory.cpp:360:14: error: use of undeclared identifier
      'memfd_create'
        fd = memfd_create("HostMemory", 0);
             ^
2021-07-27 20:15:23 +00:00
Jan Beich
112a8e017d host_memory: Enable Linux implementation on FreeBSD
HW.Memory <Critical> common/host_memory.cpp:HostMemory:492: Fastmem unavailable, falling back to VirtualBuffer for memory allocation
2021-07-27 20:09:43 +00:00
lat9nq
bee420dcfb host_memory: Correct MEM_RESERVE_PLACEHOLDER
Microsoft defines `MEM_RESERVE_PLACEHOLDER` as `0x00040000`, but our
manually imported version of it drops the last zero.
2021-06-19 04:38:33 -04:00
Markus Wick
161ade6da0 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.
2021-06-11 17:27:17 +02:00
ReinUsesLisp
f664a4d4c1 common/host_shader: Load Windows 10 functions dynamically
Workaround old headers and libraries shipped on MinGW.
2021-06-11 17:27:17 +02:00
ReinUsesLisp
f36a769085 host_memory: Support staged VirtualProtect calls 2021-06-11 17:27:17 +02:00
Markus Wick
8d2a08553e common/host_memory: Optimize for huge tables.
In theory, if we have 2 MB continously mapped, this should save one layer of TLB.
Let's make it at least more likely by aligning the memory.
2021-06-11 17:27:06 +02:00
Markus Wick
9a4cec64e1 common/host_memory: Add Linux implementation 2021-06-11 17:27:06 +02:00
ReinUsesLisp
1f0491900b common/host_memory: Add interface and Windows implementation 2021-06-11 17:27:06 +02:00