Make the flag thread-local to ensure that the handler doesn't reenter.
In theory it shouldn't be needed, since we should never crash in the
handler, but bugs can happen...
Fixes lockup when running the application from an external drive,
and it is disconnected while running.
Still crashes, but at least it doesn't lock up at 100% CPU.
Reduce duplication, only reload the active game when its settings are
changed, not any game.
NOTE: Changing from not having an ini to having one (i.e. setting the
first setting) is currently broken.
Prevent register writes from clearing the bit, which means a OTC at the
end of memory would trigger a DMA error even though the actual clear is
forced to be negative.
Fixes missing every-other-frame/flicker in Prism Land Story.
Ignore the metadata PT_LOAD segment emitted by PS1 linker scripts and
validate loadable segment ranges before invoking the loader callback.
Fixes kernel crash when loading.
Emit rwatch, watch, or awatch stop fields for the matching client and
preserve that complete stop reply for later '?' queries, while falling
back to a generic trap for unrelated breakpoints.
Pass the actual breakpoint type to callbacks, let their return value
control whether the breakpoint is retained, and then follow the normal
breakpoint pause path. This makes callback-backed execute and memory
breakpoints observable without bypassing the instruction-completion
behavior used by watchpoints.
Interpret Z2/Z3/Z4 kind values as byte lengths and represent each
watched byte with an owned CPU breakpoint. Validate MIPS
execute-breakpoint kinds, reject zero, overflowing, or excessively
large watch ranges, and avoid invasive changes to the CPU
memory-access dispatcher.
Represent protocol breakpoint types with a scoped enum and track each
client's logical breakpoints separately from a shared reference-counted
CPU breakpoint registry. Disconnects now remove only breakpoints
created by GDB, preserve pre-existing UI breakpoints, and keep
breakpoints alive while another GDB client still references them.