Commit Graph

152 Commits

Author SHA1 Message Date
Henrik Rydgård 732288c03a Brave Story: Hack to make the bloom effect run much more efficiently.
Fixes #19820

Not ready for merge, it needs more checks and maybe a compat flag.
2026-01-23 23:13:04 +01:00
Henrik Rydgård 34473fc621 Add a compat flag to map some extra memory at address 0.
Can be used to work around certain types of crashes without having to
disable fast memory.
2026-01-23 15:14:15 +01:00
Henrik Rydgård 2940c64c95 MemMap: Minor refactor 2026-01-23 14:45:33 +01:00
Henrik Rydgård 4ef11c8262 Memory::Memset: Ignore addresses if size == 0 2025-12-30 20:31:07 +01:00
Henrik Rydgård f5a211884b Minor cleanups, comments
Comments and warnings
2025-12-30 20:31:06 +01:00
Henrik Rydgård c9bab212a3 Make Read_Instruction safer 2025-05-14 15:14:08 +02:00
Henrik Rydgård ff37cbe184 Minor memory safety fixes 2025-05-14 09:39:09 +02:00
Henrik Rydgård 8f262df4fe Improve (?) handling of invalid addresses in Memset to avoid a crash 2025-04-30 11:50:43 +02:00
Henrik Rydgård 088a02bfdb Cleanup a lot of the bootup state management. 2025-03-30 14:02:29 +02:00
Henrik Rydgård 2edc3085a5 PSPPointer<>: Replace some fiddly memsets with use of a new FillWithZero function. 2025-01-05 23:43:41 +01:00
Henrik Rydgård c91169e702 Restore removed <algorithm> includes.
Turns out these were needed after all. For some reason, on Windows and
Mac, <algorithm> gets auto-included by something else so I don't notice
when it's missing, and MSVC's include dependency tracker doesn't see it
either.
2024-12-19 09:53:07 +01:00
Henrik Rydgård 3e198c53b2 More include cleanup 2024-12-18 13:57:26 +01:00
Henrik Rydgård ffe05bdf58 Memmap error message improvements 2024-11-15 15:59:16 +01:00
Henrik Rydgård e01ca5b057 Logging API change (refactor) (#19324)
* Rename LogType to Log

* Explicitly use the Log:: enum when logging. Allows for autocomplete when editing.

* Mac/ARM64 buildfix

* Do the same with the hle result log macros

* Rename the log names to mixed case while at it.

* iOS buildfix

* Qt buildfix attempt, ARM32 buildfix
2024-07-14 14:42:59 +02:00
Henrik Rydgård 2853b2f6db Fix very old typo in memmap table, for the unusual "kernel+uncached" combination 2023-09-08 12:02:56 +02:00
M4xw 5b6bc0cea7 [MemArena] Honor MV_MIRROR_PREVIOUS on ReleaseView
Allows for clean teardown of the Memory Map for Switch
2023-06-22 00:01:38 +02:00
Henrik Rydgård 0bc7854062 Android: Don't assert on failed Find4GBBase 2023-01-12 01:18:52 +01:00
Unknown W. Brackets 0496ca32ff Global: Cleanup some minor includes and typos. 2022-12-27 08:33:07 -08:00
Unknown W. Brackets e49668eea7 SaveState: Correct missing switch case warnings. 2022-12-04 07:57:30 -08:00
Unknown W. Brackets 3a372aa615 HLE: Remove misc usage of WriteStruct().
Prefer PSPPointer and notifying.
2022-09-03 10:44:11 -07:00
Henrik Rydgård e6403d7157 Split GetPointer into two versions, to help with const correctness 2022-07-24 13:26:19 +02:00
Unknown W. Brackets b8ab7f39df jit: Lock around changes to the jit pointer. 2021-11-28 10:04:22 -08:00
Henrik Rydgård 6c51dabe9a Somewhat improved error checking in MemArena. 2021-07-07 19:01:42 +02:00
Henrik Rydgård 3be5c7bd9a Make the minimum items per thread explicit. Found some bugs, optional arguments are evil. 2021-06-12 21:21:28 +02:00
Henrik Rydgård 73871b9b7e Implement new thread manager, port stuff to it. 2021-06-12 13:03:53 +02:00
Unknown W. Brackets f987c715aa MemMap: Map 0xC0000000 into virtual memory.
Technically, it should be 0xA0000000, but that causes problems for how we
manage 32-bit address space.  This at least makes things consistent.
2021-04-23 23:21:51 -07:00
Unknown W. Brackets 32ea8734fb MemMap: Cleanup memory mirror pointers. 2021-04-23 22:43:21 -07:00
Unknown W. Brackets 4f96169357 Core: Init memory on multiple threads.
Also init volatile at the same time for consistency.
2021-04-16 00:53:50 -07:00
Unknown W. Brackets b2f3f06768 Common: Set a min size on threadpool work chunks.
This should avoid slicing loops, etc. into too many chunks.  Generalize
the memcpy a bit.
2021-04-15 23:59:02 -07:00
Unknown W. Brackets b2d5f19e5e SaveState: Use memmove for the copy. 2021-04-12 18:16:57 -07:00
Unknown W. Brackets c5729bbd5e SaveState: Use SIMD to copy RAM faster.
We know its size and base are typically aligned, so abuse those facts.
2021-04-12 17:37:48 -07:00
Unknown W. Brackets 3400e6e517 SaveState: Copy RAM using threads. 2021-04-12 17:37:48 -07:00
Henrik Rydgård 797cc41a1c Remove std::string from memblockinfo 2021-03-13 17:12:30 +01:00
Unknown W. Brackets 5119d79082 Build: Remove IOS define. 2021-03-02 21:04:03 -08:00
Unknown W. Brackets 88e2b9b740 Debugger: Notate memset tags directly. 2021-02-15 15:01:23 -08:00
Unknown W. Brackets f7740edc6d Debugger: Add more metadata for memory usage. 2021-02-15 15:01:21 -08:00
Henrik Rydgård dd7983c8dd Fix a bad check, causing masked memory to fail on non-32-bit platforms even if desired. 2020-11-02 23:11:44 +01:00
Unknown W. Brackets 2714d59ceb Core: Fix memory size check.
It can be 93 MB, just not larger.
2020-09-27 12:54:34 -07:00
Unknown W. Brackets b8342fb8ec SaveState: Rename ChunkFile files to Serialize.
Makes more sense and less weird than ChunkFileDoMap, etc.
2020-08-10 08:04:05 +00:00
Unknown W. Brackets 4b4e3432cd SaveState: Split Do() into a separate header. 2020-08-10 08:03:41 +00:00
Henrik Rydgård 0829543987 Third part of getting rid of PanicAlert 2020-07-19 20:34:02 +02:00
Henrik Rydgård c5e0b799d9 Remove category from _assert_msg_ functions. We don't filter these by category anyway.
Fixes the inconsistency where we _assert_ didn't take a category but
_assert_msg_ did.
2020-07-19 20:33:25 +02:00
Henrik Rydgård 626d173d10 Split the fault handling from MemMap.cpp to MemFault.cpp. 2020-07-15 12:12:57 +02:00
Henrik Rydgård cb1e0438f9 Fix 2020-07-14 14:39:19 +02:00
Henrik Rydgård 056999a691 Refactor MachineContext.h to reduce ifdefs elsewhere.
Also fixes Windows on ARM64 (at least the build).
2020-07-14 13:47:25 +02:00
Henrik Rydgård f62df94ab2 There's no sigcontext on 64-bit iOS either, apparently. 2020-07-14 11:39:31 +02:00
Henrik Rydgård 893aa29191 Yet another iOS buildfix attempt 2020-07-14 10:34:40 +02:00
Henrik Rydgård f6cc45a96a Another iOS buildfix attempt 2020-07-14 09:31:58 +02:00
Henrik Rydgård 6f97c3d422 Various platform buildfixes 2020-07-14 09:25:59 +02:00
Henrik Rydgård a56f391713 Make fastmem memory exceptions report the exceptions to Core correctly. 2020-07-14 09:25:45 +02:00