From 5f76370121ca43b4bbfcbf4ffc93554488835e0c Mon Sep 17 00:00:00 2001 From: Edward Li Date: Mon, 10 Aug 2020 02:02:07 +0800 Subject: [PATCH] [Xcode] Ignore EXC_BAD_ACCESS in debug mode. Bypass SIGBUS signal in lldb using Breakpoint Action --- .../emulator-osx/emulator-osx/osx-main.mm | 2 +- .../xcdebugger/Breakpoints_v2.xcbkptlist | 40 +++++++++++++++++++ 2 files changed, 41 insertions(+), 1 deletion(-) create mode 100644 shell/apple/reicast.xcworkspace/xcshareddata/xcdebugger/Breakpoints_v2.xcbkptlist diff --git a/shell/apple/emulator-osx/emulator-osx/osx-main.mm b/shell/apple/emulator-osx/emulator-osx/osx-main.mm index 63d652e20..e11a8d356 100644 --- a/shell/apple/emulator-osx/emulator-osx/osx-main.mm +++ b/shell/apple/emulator-osx/emulator-osx/osx-main.mm @@ -61,7 +61,7 @@ void UpdateInputState(u32 port) { } void os_CreateWindow() { -#if 0 +#ifdef DEBUG int ret = task_set_exception_ports( mach_task_self(), EXC_MASK_BAD_ACCESS, diff --git a/shell/apple/reicast.xcworkspace/xcshareddata/xcdebugger/Breakpoints_v2.xcbkptlist b/shell/apple/reicast.xcworkspace/xcshareddata/xcdebugger/Breakpoints_v2.xcbkptlist new file mode 100644 index 000000000..9abc04fbb --- /dev/null +++ b/shell/apple/reicast.xcworkspace/xcshareddata/xcdebugger/Breakpoints_v2.xcbkptlist @@ -0,0 +1,40 @@ + + + + + + + + + + + + + + + + + + +