Unknown W. Brackets
9cebfc31b3
Debugger: Avoid unaligned reads in expressions.
...
Potentially, a watch or break condition could crash if it was unaligned
between mirrors. This might happen if it's not the condition you wanted,
especially. Play it safe.
2023-04-12 01:14:30 -07:00
Henrik Rydgård
e1a48d74c4
A bit more GetPointer cleanup.
...
Probably not worth it for performance reasons, but some semantic cleanup
is good, especially the accidental GetPointer -> writable casts without
using GetPointerWrite.
Using Unchecked on already checked pointers, or when we'd crash anyway
if it returned nullptr, is good for clarity.
2023-01-10 12:13:47 +01:00
Henrik Rydgård
91b7bf986e
Can do an unchecked GetPointer here
2023-01-01 20:48:03 +01:00
Henrik Rydgård
a4d3e0ead8
Add range checks in replaced memcpy/memset functions. ( #16693 )
...
* Add range checks in replaced memcpy/memset functions.
Keep seeing especially Replace_memcpy as a semi-rare crash in the
reports. Hopefully this will take care of it, though if games hit this,
they're probably on their way to failing somehow anyway.
* Alternate approach, correctly causing memory exceptions if not ignoring
2023-01-01 18:25:40 +00:00
Henrik Rydgård
65c016d154
Fix dialog rendering (PPGe). Fixes #15954
...
Was caused by 867eb99
, part of #15950 .
2022-09-04 00:42:14 +02:00
Unknown W. Brackets
ccd4e92184
Kernel: Use PSPPointer for status objects.
...
Code makes more sense when reading ->size rather than offset 0.
2022-09-03 10:44:12 -07: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
2479d52202
Global: Reduce includes of common headers.
...
In many places, string, map, or Common.h were included but not needed.
2022-01-30 16:35:33 -08:00
Unknown W. Brackets
32ea8734fb
MemMap: Cleanup memory mirror pointers.
2021-04-23 22:43:21 -07:00
Unknown W. Brackets
744d17e13c
Core: Correct ValidSize outside scratchpad.
...
And simplify all the scratchpad valid checks.
2021-04-21 19:32:22 -07:00
Unknown W. Brackets
124774fecb
Debugger: Provide memory mapping ranges.
...
Most of these are entirely static, but introspection is good for APIs.
2021-04-04 21:27:30 -07:00
Unknown W. Brackets
bab9581901
Core: Unbreak ValidSize limits.
...
Broken in bdd2029
.
2021-03-28 19:42:29 -07:00
aliaspider
9a3e5879bb
Global: Correct many endian types and casts.
2021-02-18 22:25:24 -08:00
Henrik Rydgård
5ed5947804
Merge pull request #13943 from unknownbrackets/dialog
...
Dialog: Simulate volatile memory lock behavior
2021-02-15 16:47:06 +01:00
Gleb Mazovetskiy
0fb42e07a6
CMake: Rename USE_ADDRESS_SANITIZER to USE_ASAN
...
For consistency with USE_UBSAN
2021-01-29 23:10:22 +00:00
Unknown W. Brackets
e42dac2fb4
Dialog: Simulate volatile memory lock behavior.
...
Also simply clear to zero, which isn't exactly correct but should be
fairly close. See #8288 (NBA Live 08 hang.)
2021-01-18 11:07:21 -08:00
Henrik Rydgård
ad2ec61c98
Retry the masked memory experiment on iOS. Turns out it was the shader generator bug that broke things.
2020-11-03 21:04:03 +01:00
Henrik Rydgård
f429c97392
Disable masked memory on iOS again. The cure was worse than the disease apparently.
...
Needs more investigation before we re-enable.
See #13616
2020-11-03 15:46:21 +01:00
Henrik Rydgård
f050d51973
Enable masked memory addressing on iOS
...
(removes the need for functioning memory mirrors)
I have a theory that this is related to the iOS 14 problems: #13451
2020-11-03 00:20:19 +01:00
Henrik Rydgård
ee11c796a1
Revert "Try my theory about memory mirrors on iOS 14. See #13451 "
...
This reverts commit 0f647684a3
.
2020-10-23 06:57:56 +02:00
Henrik Rydgård
0f647684a3
Try my theory about memory mirrors on iOS 14. See #13451
2020-10-22 10:12:21 +02:00
Henrik Rydgård
b8e8325888
Fix text issue in God Eater Burst. Forgot that games can allocate texture in volatile memory too.
...
We considered any texture from kernel memory "reliable", which is wrong
since games can allocate out of the upper half of kernel RAM, which is
called "volatile" memory.
Fixes issue #13511
2020-10-14 00:09:08 +02:00
Henrik Rydgård
3e3a40da8c
Mark the PPGe font texture as reliable to avoid hashing it.
2020-09-22 21:13:30 +02:00
Henrik Rydgård
a22181df1c
Partially fix Katamari (flicker due to choice of the wrong depth buffer still happening).
2020-09-01 22:54:36 +02:00
Henrik Rydgård
92bbe974cd
Prevent reporting a bad memory access just because Tekken creates a mutex with a null name.
2020-07-20 10:01:22 +02:00
Henrik Rydgård
0829543987
Third part of getting rid of PanicAlert
2020-07-19 20:34:02 +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
c3016fe6a5
Mac/Linux buildfixes
2020-07-14 09:25:45 +02:00
Henrik Rydgard
1fce6de8b1
Simple exception handler so we can ignore accesses that happen within the PSP memory space.
2020-07-14 09:25:45 +02:00
Henrik Rydgård
7208cf6900
Some code reformatting/renaming
2020-07-12 15:25:21 +02:00
Henrik Rydgård
c739d4e164
Revert "Repeat of the experimental commit, was too fast for the build bot."
...
This reverts commit d8992a6ae3
.
2020-06-03 11:55:14 +02:00
Henrik Rydgård
d8992a6ae3
Repeat of the experimental commit, was too fast for the build bot.
2020-06-03 10:34:21 +02:00
Henrik Rydgård
20afef4c35
Revert "Experimental commit: Bump up scratchpad size so that Android will act like Windows in #10196 (Spider-Man 3)"
...
This reverts commit 1d9d15a1d7
.
2020-06-03 09:19:38 +02:00
Henrik Rydgård
1d9d15a1d7
Experimental commit: Bump up scratchpad size so that Android will act like Windows in #10196 (Spider-Man 3)
2020-06-03 09:19:22 +02:00
Unknown W. Brackets
bdd2029623
Core: Fix memory range guard check.
...
Was allowing sizes with the high bits set, which could cause all kinds of
weird issues and crashes.
2019-09-28 08:40:41 -07:00
Henrik Rydgård
2f26297062
Clean up some more ifdefs
2019-05-10 23:25:57 +02:00
Henrik Rydgård
67b8c4527d
b.sh: Add a build option for address sanitizer. When enabled, we turn on some compatibility options to make it work right.
2018-01-31 14:29:23 +01:00
Henrik Rydgård
6a1fa728d8
Remove Globals.h
2017-08-31 17:15:22 +02:00
Henrik Rydgard
ff2b6b3fca
Assorted cleanup, UWP memory map fixes. PSPFlower runs in both 32-bit and 64-bit.
2017-03-23 10:02:28 +01:00
Henrik Rydgård
193b5f3094
By skipping kernel mappings, I got things to fit in the iOS 64-bit address space. However, something is still a bit broken with JIT...
2017-01-25 18:35:09 +01:00
Henrik Rydgard
73a2a1bc0f
The MemArena code has way too many ifdefs. Split it up by platform.
2017-01-25 16:20:21 +01:00
Henrik Rydgard
4e1f562f47
Remove the "low" memory mappings, we have no use for them
2017-01-25 15:15:17 +01:00
Florent Castelli
8c3552de74
cmake: Detect features at compile time
...
Instead of relying on manually passed down flags from CMake,
we now have ppsspp_config.h file to create the platform defines for us.
This improves support for multiplatform builds (such as iOS).
2016-10-19 12:31:19 +02:00
Florent Castelli
4145b60a0e
symbian: Remove!
2016-10-11 18:49:08 +02:00
Unknown W. Brackets
eee98966f4
Add Memory utility to detect shutdown.
2016-05-19 21:17:17 -07:00
Henrik Rydgard
1a2edc67d0
Add support for float store/load
2016-05-08 02:03:11 +02:00
Unknown W. Brackets
0c46d7c081
Correct scratchpad memory range checks.
2015-12-27 14:29:12 -08:00
Henrik Rydgard
b07b002040
Introduce "Compatibility Flags".
...
These should be used very restrictively, see comment in Compatibility.h.
Should help #8004 , by disabling depth rounding in Fight Night round 3.
2015-09-27 01:23:20 +02:00
Henrik Rydgard
0f4df6c67b
Add some missing _ARCH_32 and _ARCH_64 definitions to MSVC project files.
...
Fixes obscure crash in Moppi PSP Flower homebrew.
2015-09-23 19:30:14 +02:00