Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Crash when saving preferences on MacOS #136

Closed
Joebeazelman opened this issue Mar 27, 2023 · 17 comments
Closed

Crash when saving preferences on MacOS #136

Joebeazelman opened this issue Mar 27, 2023 · 17 comments

Comments

@Joebeazelman
Copy link

Joebeazelman commented Mar 27, 2023

The MacOS build crashes whenever I tried to save the preferences i\

@Joebeazelman Joebeazelman changed the title Crash when saving preferences Crash when saving preferences on MacOS Mar 27, 2023
@epasveer
Copy link
Owner

epasveer commented Mar 27, 2023

Hi,

Can you run seer from gdb to get a traceback?

$ gdb seergdb
(gdb) run

Then attempt to change and save the preferences. Include the traceback in this task. It might help me where to focus in the code.

Thanks.

@Joebeazelman
Copy link
Author

There's a generated MacOS one. I'll include both.

@Joebeazelman
Copy link
Author

Here's the crash log:


Translated Report (Full Report Below)

Process: seergdb [3954]
Path: /usr/local/bin/seergdb
Identifier: seergdb
Version: ???
Code Type: X86-64 (Native)
Parent Process: zsh [586]
Responsible: Terminal [482]
User ID: 501

Date/Time: 2023-03-27 14:55:19.8720 -0400
OS Version: macOS 12.6.3 (21G419)
Report Version: 12
Anonymous UUID: 3DF976FD-1CDE-1EB0-E24D-65CBB3114204

Time Awake Since Boot: 7300 seconds

System Integrity Protection: disabled

Crashed Thread: 0 Dispatch queue: com.apple.main-thread

Exception Type: EXC_BAD_ACCESS (SIGSEGV)
Exception Codes: KERN_INVALID_ADDRESS at 0x0000000000000010
Exception Codes: 0x0000000000000001, 0x0000000000000010
Exception Note: EXC_CORPSE_NOTIFY

Termination Reason: Namespace SIGNAL, Code 11 Segmentation fault: 11
Terminating Process: exc handler [3954]

VM Region Info: 0x10 is not in any region. Bytes before following region: 140737488220144
REGION TYPE START - END [ VSIZE] PRT/MAX SHRMOD REGION DETAIL
UNUSED SPACE AT START
--->
VM_ALLOCATE 7ffffffdf000-7ffffffe0000 [ 4K] r-x/r-x SM=ALI

Thread 0 Crashed:: Dispatch queue: com.apple.main-thread
0 libc++abi.dylib 0x7ff8157326e4 __cxxabiv1::__si_class_type_info::has_unambiguous_public_base(__cxxabiv1::__dynamic_cast_info*, void*, int) const + 4

Thread 1:: Dispatch queue: com.apple.SkyLight.UpdateManager.SerialSema
0 libsystem_kernel.dylib 0x7ff8157399b6 semaphore_wait_trap + 10
1 SkyLight 0x7ff81a7a033f invocation function for block in (anonymous namespace)::InterprocessSerialSemaphore::asyncWait(void (int) block_pointer) + 35
2 libdispatch.dylib 0x7ff8155be0cc _dispatch_call_block_and_release + 12
3 libdispatch.dylib 0x7ff8155bf317 _dispatch_client_callout + 8
4 libdispatch.dylib 0x7ff8155c5317 _dispatch_lane_serial_drain + 672
5 libdispatch.dylib 0x7ff8155c5dfd _dispatch_lane_invoke + 366
6 libdispatch.dylib 0x7ff8155cfeee _dispatch_workloop_worker_thread + 753
7 libsystem_pthread.dylib 0x7ff815772fd0 _pthread_wqthread + 326
8 libsystem_pthread.dylib 0x7ff815771f57 start_wqthread + 15

Thread 2:: com.apple.NSEventThread
0 libsystem_kernel.dylib 0x7ff81573997a mach_msg_trap + 10
1 libsystem_kernel.dylib 0x7ff815739ce8 mach_msg + 56
2 CoreFoundation 0x7ff81583d36d __CFRunLoopServiceMachPort + 319
3 CoreFoundation 0x7ff81583b9f8 __CFRunLoopRun + 1276
4 CoreFoundation 0x7ff81583ae3c CFRunLoopRunSpecific + 562
5 AppKit 0x7ff8183e29ce _NSEventThread + 132
6 libsystem_pthread.dylib 0x7ff8157764e1 _pthread_start + 125
7 libsystem_pthread.dylib 0x7ff815771f6b thread_start + 15

Thread 3:
0 libsystem_pthread.dylib 0x7ff815771f48 start_wqthread + 0

Thread 4:: Dispatch queue: NSCGSDisableUpdates
0 libsystem_kernel.dylib 0x7ff8157399ce semaphore_timedwait_trap + 10
1 libdispatch.dylib 0x7ff8155bf848 _dispatch_sema4_timedwait + 72
2 libdispatch.dylib 0x7ff8155bfc75 _dispatch_semaphore_wait_slow + 58
3 SkyLight 0x7ff81a7a012e CGSUpdateManager::enable_updates_common() + 1038
4 SkyLight 0x7ff81a7a0b7e SLSReenableUpdateTokenWithSeed + 130
5 libdispatch.dylib 0x7ff8155be0cc _dispatch_call_block_and_release + 12
6 libdispatch.dylib 0x7ff8155bf317 _dispatch_client_callout + 8
7 libdispatch.dylib 0x7ff8155c5317 _dispatch_lane_serial_drain + 672
8 libdispatch.dylib 0x7ff8155c5dfd _dispatch_lane_invoke + 366
9 libdispatch.dylib 0x7ff8155cfeee _dispatch_workloop_worker_thread + 753
10 libsystem_pthread.dylib 0x7ff815772fd0 _pthread_wqthread + 326
11 libsystem_pthread.dylib 0x7ff815771f57 start_wqthread + 15

Thread 0 crashed with X86 Thread State (64-bit):
rax: 0x00007ff85547c448 rbx: 0x000060000113c270 rcx: 0x00000001069bc3a8 rdx: 0x0000000000000006
rdi: 0x00000001069bc3a8 rsi: 0x0000000000000000 rbp: 0x00007ff7ba80db70 rsp: 0x00007ff7ba80db70
r8: 0x000060000113c270 r9: 0x00000001069b22d8 r10: 0x0000000000000000 r11: 0x0000000000000025
r12: 0x00000001069bc3a8 r13: 0x00000001069b22d8 r14: 0x000000010cfbe600 r15: 0x0000000000000003
rip: 0x00007ff8157326e4 rfl: 0x0000000000010246 cr2: 0x0000000000000010

Logical CPU: 0
Error Code: 0x00000004 (no mapping for user data read)
Trap Number: 14

Thread 0 instruction stream:
eb 09 83 7e 30 02 75 03-89 4e 30 5d c3 90 55 48 ...~0.u..N0]..UH
89 e5 48 8b 46 10 48 8b-7f 08 48 3b 78 08 74 02 ..H.F.H...H;x.t.
5d c3 48 8b 46 20 48 85-c0 74 15 48 39 d0 74 20 ].H.F H..t.H9.t
ff 46 3c c7 46 30 02 00-00 00 c6 46 4e 01 eb e0 .F<.F0.....FN...
48 89 56 20 89 4e 30 c7-46 3c 01 00 00 00 eb d0 H.V .N0.F<......
83 7e 30 02 75 ca 89 4e-30 eb c5 90 55 48 89 e5 .~0.u..N0...UH..
[4c]8b 46 10 48 8b 47 08-49 3b 40 08 74 0e 48 8b L.F.H.G.I;@.t.H. <==
7f 10 48 8b 07 48 8b 40-38 5d ff e0 48 8b 46 20 ..H..H.@8]..H.F
48 85 c0 74 15 48 39 d0-74 20 ff 46 3c c7 46 30 H..t.H9.t .F<.F0
02 00 00 00 c6 46 4e 01-eb 19 48 89 56 20 89 4e .....FN...H.V .N
30 c7 46 3c 01 00 00 00-eb 09 83 7e 30 02 75 03 0.F<.......~0.u.
89 4e 30 5d c3 90 55 48-89 e5 4c 8b 47 08 48 85 .N0]..UH..L.G.H.

Binary Images:
0x7ff815722000 - 0x7ff815737fff libc++abi.dylib () /usr/lib/libc++abi.dylib
0x7ff815738000 - 0x7ff81576ffff libsystem_kernel.dylib (
) /usr/lib/system/libsystem_kernel.dylib
0x7ff81a741000 - 0x7ff81aadffff com.apple.SkyLight (1.600.0) <6563e632-526d-3c88-8035-049fcca8ca93> /System/Library/PrivateFrameworks/SkyLight.framework/Versions/A/SkyLight
0x7ff8155bc000 - 0x7ff815602fff libdispatch.dylib () <1a04b380-76e4-3e4b-b0fc-9837533d021d> /usr/lib/system/libdispatch.dylib
0x7ff815770000 - 0x7ff81577bfff libsystem_pthread.dylib (
) /usr/lib/system/libsystem_pthread.dylib
0x7ff8157bd000 - 0x7ff815cbffff com.apple.CoreFoundation (6.9) <93c48919-68af-367e-9a67-db4159bc962c> /System/Library/Frameworks/CoreFoundation.framework/Versions/A/CoreFoundation
0x7ff818236000 - 0x7ff8190c5fff com.apple.AppKit (6.9) <11be8778-f5e5-3ccb-bcc3-10ffea3bf44b> /System/Library/Frameworks/AppKit.framework/Versions/C/AppKit
0x0 - 0xffffffffffffffff ??? (*) <00000000-0000-0000-0000-000000000000> ???

External Modification Summary:
Calls made by other processes targeting this process:
task_for_pid: 0
thread_create: 0
thread_set_state: 0
Calls made by this process:
task_for_pid: 0
thread_create: 0
thread_set_state: 0
Calls made by all processes on this machine:
task_for_pid: 0
thread_create: 0
thread_set_state: 0

VM Region Summary:
ReadOnly portion of Libraries: Total=943.1M resident=0K(0%) swapped_out_or_unallocated=943.1M(100%)
Writable regions: Total=627.6M written=0K(0%) resident=0K(0%) swapped_out=0K(0%) unallocated=627.6M(100%)

                            VIRTUAL   REGION 

REGION TYPE SIZE COUNT (non-coalesced)
=========== ======= =======
Accelerate framework 512K 4
Activity Tracing 256K 1
CG backing stores 3344K 12
CG image 532K 22
ColorSync 236K 28
CoreAnimation 1324K 22
CoreGraphics 20K 4
CoreUI image data 1652K 25
Foundation 16K 1
Kernel Alloc Once 8K 1
MALLOC 227.1M 93
MALLOC guard page 32K 7
MALLOC_NANO (reserved) 384.0M 1 reserved VM address space (unallocated)
ObjC additional data 15K 1
STACK GUARD 56.0M 5
Stack 10.0M 5
VM_ALLOCATE 656K 48
__CTF 756 1
__DATA 22.1M 385
__DATA_CONST 15.7M 220
__DATA_DIRTY 753K 115
__FONT_DATA 4K 1
__LINKEDIT 653.2M 49
__TEXT 289.9M 406
__UNICODE 592K 1
dyld private memory 1024K 1
mapped file 920.5M 380
shared memory 768K 15
=========== ======= =======
TOTAL 2.5G 1854
TOTAL, minus reserved VM space 2.2G 1854


Full Report

{"app_name":"seergdb","timestamp":"2023-03-27 14:55:27.00 -0400","app_version":"","slice_uuid":"e0ea9120-1395-3a08-b340-a06d00419da9","build_version":"","platform":1,"share_with_app_devs":0,"is_first_party":1,"bug_type":"309","os_version":"macOS 12.6.3 (21G419)","incident_id":"2D974C14-713A-4C50-BFB4-57EF2E965757","name":"seergdb"}
{
"uptime" : 7300,
"procLaunch" : "2023-03-27 14:55:01.2653 -0400",
"procRole" : "Foreground",
"version" : 2,
"userID" : 501,
"deployVersion" : 210,
"modelCode" : "MacBookPro11,4",
"procStartAbsTime" : 7332256701568,
"coalitionID" : 447,
"osVersion" : {
"train" : "macOS 12.6.3",
"build" : "21G419",
"releaseType" : "User"
},
"captureTime" : "2023-03-27 14:55:19.8720 -0400",
"incident" : "2D974C14-713A-4C50-BFB4-57EF2E965757",
"bug_type" : "309",
"pid" : 3954,
"procExitAbsTime" : 7350862900886,
"cpuType" : "X86-64",
"procName" : "seergdb",
"procPath" : "/usr/local/bin/seergdb",
"parentProc" : "zsh",
"parentPid" : 586,
"coalitionName" : "com.apple.Terminal",
"crashReporterKey" : "3DF976FD-1CDE-1EB0-E24D-65CBB3114204",
"responsiblePid" : 482,
"responsibleProc" : "Terminal",
"sip" : "disabled",
"vmRegionInfo" : "0x10 is not in any region. Bytes before following region: 140737488220144\n REGION TYPE START - END [ VSIZE] PRT/MAX SHRMOD REGION DETAIL\n UNUSED SPACE AT START\n---> \n VM_ALLOCATE 7ffffffdf000-7ffffffe0000 [ 4K] r-x/r-x SM=ALI ",
"isCorpse" : 1,
"exception" : {"codes":"0x0000000000000001, 0x0000000000000010","rawCodes":[1,16],"type":"EXC_BAD_ACCESS","signal":"SIGSEGV","subtype":"KERN_INVALID_ADDRESS at 0x0000000000000010"},
"termination" : {"flags":0,"code":11,"namespace":"SIGNAL","indicator":"Segmentation fault: 11","byProc":"exc handler","byPid":3954},
"vmregioninfo" : "0x10 is not in any region. Bytes before following region: 140737488220144\n REGION TYPE START - END [ VSIZE] PRT/MAX SHRMOD REGION DETAIL\n UNUSED SPACE AT START\n---> \n VM_ALLOCATE 7ffffffdf000-7ffffffe0000 [ 4K] r-x/r-x SM=ALI ",
"extMods" : {"caller":{"thread_create":0,"thread_set_state":0,"task_for_pid":0},"system":{"thread_create":0,"thread_set_state":0,"task_for_pid":0},"targeted":{"thread_create":0,"thread_set_state":0,"task_for_pid":0},"warnings":0},
"faultingThread" : 0,
"threads" : [{"triggered":true,"id":77833,"instructionState":{"instructionStream":{"bytes":[235,9,131,126,48,2,117,3,137,78,48,93,195,144,85,72,137,229,72,139,70,16,72,139,127,8,72,59,120,8,116,2,93,195,72,139,70,32,72,133,192,116,21,72,57,208,116,32,255,70,60,199,70,48,2,0,0,0,198,70,78,1,235,224,72,137,86,32,137,78,48,199,70,60,1,0,0,0,235,208,131,126,48,2,117,202,137,78,48,235,197,144,85,72,137,229,76,139,70,16,72,139,71,8,73,59,64,8,116,14,72,139,127,16,72,139,7,72,139,64,56,93,255,224,72,139,70,32,72,133,192,116,21,72,57,208,116,32,255,70,60,199,70,48,2,0,0,0,198,70,78,1,235,25,72,137,86,32,137,78,48,199,70,60,1,0,0,0,235,9,131,126,48,2,117,3,137,78,48,93,195,144,85,72,137,229,76,139,71,8,72,133],"offset":96}},"threadState":{"r13":{"value":4405797592,"symbolLocation":0,"symbol":"typeinfo for QWidget"},"rax":{"value":140704559383624,"symbolLocation":16,"symbol":"vtable for __cxxabiv1::__si_class_type_info"},"rflags":{"value":66118},"cpu":{"value":0},"r14":{"value":4512802304,"symbolLocation":0,"symbol":"_main_thread"},"rsi":{"value":0},"r8":{"value":105553134338672},"cr2":{"value":16},"rdx":{"value":6},"r10":{"value":0},"r9":{"value":4405797592,"symbolLocation":0,"symbol":"typeinfo for QWidget"},"r15":{"value":3},"rbx":{"value":105553134338672},"trap":{"value":14,"description":"(no mapping for user data read)"},"err":{"value":4},"r11":{"value":37},"rip":{"value":140703488485092,"matchesCrashFrame":1},"rbp":{"value":140701962656624},"rsp":{"value":140701962656624},"r12":{"value":4405838760,"symbolLocation":0,"symbol":"typeinfo for QKeySequenceEdit"},"rcx":{"value":4405838760,"symbolLocation":0,"symbol":"typeinfo for QKeySequenceEdit"},"flavor":"x86_THREAD_STATE","rdi":{"value":4405838760,"symbolLocation":0,"symbol":"typeinfo for QKeySequenceEdit"}},"queue":"com.apple.main-thread","frames":[{"imageOffset":67300,"symbol":"__cxxabiv1::__si_class_type_info::has_unambiguous_public_base(__cxxabiv1::__dynamic_cast_info*, void*, int) const","symbolLocation":4,"imageIndex":0}]},{"id":77840,"queue":"com.apple.SkyLight.UpdateManager.SerialSema","frames":[{"imageOffset":6582,"symbol":"semaphore_wait_trap","symbolLocation":10,"imageIndex":1},{"imageOffset":389951,"symbol":"invocation function for block in (anonymous namespace)::InterprocessSerialSemaphore::asyncWait(void (int) block_pointer)","symbolLocation":35,"imageIndex":2},{"imageOffset":8396,"symbol":"_dispatch_call_block_and_release","symbolLocation":12,"imageIndex":3},{"imageOffset":13079,"symbol":"_dispatch_client_callout","symbolLocation":8,"imageIndex":3},{"imageOffset":37655,"symbol":"_dispatch_lane_serial_drain","symbolLocation":672,"imageIndex":3},{"imageOffset":40445,"symbol":"_dispatch_lane_invoke","symbolLocation":366,"imageIndex":3},{"imageOffset":81646,"symbol":"_dispatch_workloop_worker_thread","symbolLocation":753,"imageIndex":3},{"imageOffset":12240,"symbol":"_pthread_wqthread","symbolLocation":326,"imageIndex":4},{"imageOffset":8023,"symbol":"start_wqthread","symbolLocation":15,"imageIndex":4}]},{"id":77870,"name":"com.apple.NSEventThread","frames":[{"imageOffset":6522,"symbol":"mach_msg_trap","symbolLocation":10,"imageIndex":1},{"imageOffset":7400,"symbol":"mach_msg","symbolLocation":56,"imageIndex":1},{"imageOffset":525165,"symbol":"__CFRunLoopServiceMachPort","symbolLocation":319,"imageIndex":5},{"imageOffset":518648,"symbol":"__CFRunLoopRun","symbolLocation":1276,"imageIndex":5},{"imageOffset":515644,"symbol":"CFRunLoopRunSpecific","symbolLocation":562,"imageIndex":5},{"imageOffset":1755598,"symbol":"_NSEventThread","symbolLocation":132,"imageIndex":6},{"imageOffset":25825,"symbol":"_pthread_start","symbolLocation":125,"imageIndex":4},{"imageOffset":8043,"symbol":"thread_start","symbolLocation":15,"imageIndex":4}]},{"id":77871,"frames":[{"imageOffset":8008,"symbol":"start_wqthread","symbolLocation":0,"imageIndex":4}]},{"id":77877,"queue":"NSCGSDisableUpdates","frames":[{"imageOffset":6606,"symbol":"semaphore_timedwait_trap","symbolLocation":10,"imageIndex":1},{"imageOffset":14408,"symbol":"_dispatch_sema4_timedwait","symbolLocation":72,"imageIndex":3},{"imageOffset":15477,"symbol":"_dispatch_semaphore_wait_slow","symbolLocation":58,"imageIndex":3},{"imageOffset":389422,"symbol":"CGSUpdateManager::enable_updates_common()","symbolLocation":1038,"imageIndex":2},{"imageOffset":392062,"symbol":"SLSReenableUpdateTokenWithSeed","symbolLocation":130,"imageIndex":2},{"imageOffset":8396,"symbol":"_dispatch_call_block_and_release","symbolLocation":12,"imageIndex":3},{"imageOffset":13079,"symbol":"_dispatch_client_callout","symbolLocation":8,"imageIndex":3},{"imageOffset":37655,"symbol":"_dispatch_lane_serial_drain","symbolLocation":672,"imageIndex":3},{"imageOffset":40445,"symbol":"_dispatch_lane_invoke","symbolLocation":366,"imageIndex":3},{"imageOffset":81646,"symbol":"_dispatch_workloop_worker_thread","symbolLocation":753,"imageIndex":3},{"imageOffset":12240,"symbol":"_pthread_wqthread","symbolLocation":326,"imageIndex":4},{"imageOffset":8023,"symbol":"start_wqthread","symbolLocation":15,"imageIndex":4}]}],
"usedImages" : [
{
"source" : "P",
"arch" : "x86_64",
"base" : 140703488417792,
"size" : 90112,
"uuid" : "a99f1fb2-fd31-3cf4-be4d-a9fccf219974",
"path" : "/usr/lib/libc++abi.dylib",
"name" : "libc++abi.dylib"
},
{
"source" : "P",
"arch" : "x86_64",
"base" : 140703488507904,
"size" : 229376,
"uuid" : "e2477724-bccf-3a8c-9c75-c774c569f36e",
"path" : "/usr/lib/system/libsystem_kernel.dylib",
"name" : "libsystem_kernel.dylib"
},
{
"source" : "P",
"arch" : "x86_64",
"base" : 140703572430848,
"CFBundleShortVersionString" : "1.600.0",
"CFBundleIdentifier" : "com.apple.SkyLight",
"size" : 3796992,
"uuid" : "6563e632-526d-3c88-8035-049fcca8ca93",
"path" : "/System/Library/PrivateFrameworks/SkyLight.framework/Versions/A/SkyLight",
"name" : "SkyLight"
},
{
"source" : "P",
"arch" : "x86_64",
"base" : 140703486951424,
"size" : 290816,
"uuid" : "1a04b380-76e4-3e4b-b0fc-9837533d021d",
"path" : "/usr/lib/system/libdispatch.dylib",
"name" : "libdispatch.dylib"
},
{
"source" : "P",
"arch" : "x86_64",
"base" : 140703488737280,
"size" : 49152,
"uuid" : "b5454e27-e8c7-3fdb-b77f-714f1e82e70b",
"path" : "/usr/lib/system/libsystem_pthread.dylib",
"name" : "libsystem_pthread.dylib"
},
{
"source" : "P",
"arch" : "x86_64h",
"base" : 140703489052672,
"CFBundleShortVersionString" : "6.9",
"CFBundleIdentifier" : "com.apple.CoreFoundation",
"size" : 5255168,
"uuid" : "93c48919-68af-367e-9a67-db4159bc962c",
"path" : "/System/Library/Frameworks/CoreFoundation.framework/Versions/A/CoreFoundation",
"name" : "CoreFoundation",
"CFBundleVersion" : "1866"
},
{
"source" : "P",
"arch" : "x86_64",
"base" : 140703533588480,
"CFBundleShortVersionString" : "6.9",
"CFBundleIdentifier" : "com.apple.AppKit",
"size" : 15269888,
"uuid" : "11be8778-f5e5-3ccb-bcc3-10ffea3bf44b",
"path" : "/System/Library/Frameworks/AppKit.framework/Versions/C/AppKit",
"name" : "AppKit",
"CFBundleVersion" : "2113.60.148"
},
{
"size" : 0,
"source" : "A",
"base" : 0,
"uuid" : "00000000-0000-0000-0000-000000000000"
}
],
"sharedCache" : {
"base" : 140703485480960,
"size" : 19331678208,
"uuid" : "b6d97ead-9d19-3228-adaa-cca8452c02d2"
},
"vmSummary" : "ReadOnly portion of Libraries: Total=943.1M resident=0K(0%) swapped_out_or_unallocated=943.1M(100%)\nWritable regions: Total=627.6M written=0K(0%) resident=0K(0%) swapped_out=0K(0%) unallocated=627.6M(100%)\n\n VIRTUAL REGION \nREGION TYPE SIZE COUNT (non-coalesced) \n=========== ======= ======= \nAccelerate framework 512K 4 \nActivity Tracing 256K 1 \nCG backing stores 3344K 12 \nCG image 532K 22 \nColorSync 236K 28 \nCoreAnimation 1324K 22 \nCoreGraphics 20K 4 \nCoreUI image data 1652K 25 \nFoundation 16K 1 \nKernel Alloc Once 8K 1 \nMALLOC 227.1M 93 \nMALLOC guard page 32K 7 \nMALLOC_NANO (reserved) 384.0M 1 reserved VM address space (unallocated)\nObjC additional data 15K 1 \nSTACK GUARD 56.0M 5 \nStack 10.0M 5 \nVM_ALLOCATE 656K 48 \n__CTF 756 1 \n__DATA 22.1M 385 \n__DATA_CONST 15.7M 220 \n__DATA_DIRTY 753K 115 \n__FONT_DATA 4K 1 \n__LINKEDIT 653.2M 49 \n__TEXT 289.9M 406 \n__UNICODE 592K 1 \ndyld private memory 1024K 1 \nmapped file 920.5M 380 \nshared memory 768K 15 \n=========== ======= ======= \nTOTAL 2.5G 1854 \nTOTAL, minus reserved VM space 2.2G 1854 \n",
"legacyInfo" : {
"threadTriggered" : {
"queue" : "com.apple.main-thread"
}
},
"trialInfo" : {
"rollouts" : [
{
"rolloutId" : "5f72dc58705eff005a46b3a9",
"factorPackIds" : {

  },
  "deploymentId" : 240000015
},
{
  "rolloutId" : "61af99aeda72d16a4beb7756",
  "factorPackIds" : {
    "SIRI_DIALOG_ASSETS" : "629fe54ebc762c0b6f758b6b"
  },
  "deploymentId" : 240000409
}

],
"experiments" : [

]
}
}

Model: MacBookPro11,4, BootROM 476.0.0.0.0, 4 processors, Quad-Core Intel Core i7, 2.2 GHz, 16 GB, SMC 2.29f24
Graphics: Intel Iris Pro, Intel Iris Pro, Built-In
Display: Color LCD, 2880 x 1800 Retina, MirrorOff, Online
Display: DELL U2412M, 1920 x 1200 (WUXGA - Widescreen Ultra eXtended Graphics Array), Main, MirrorOff, Online
Display: DELL 2408WFP, 1200 x 1920, MirrorOff, Online
Memory Module: BANK 0/DIMM0, 8 GB, DDR3, 1600 MHz, 0x80AD, 0x484D54343147533642465238412D50422020
Memory Module: BANK 1/DIMM0, 8 GB, DDR3, 1600 MHz, 0x80AD, 0x484D54343147533642465238412D50422020
AirPort: spairport_wireless_card_type_wifi (0x14E4, 0x152), Broadcom BCM43xx 1.0 (7.77.111.1 AirPortDriverBrcmNIC-1710.4)
AirPort:
Bluetooth: Version (null), 0 services, 0 devices, 0 incoming serial ports
Network Service: Wi-Fi, AirPort, en0
USB Device: USB30Bus
USB Device: USB3.1 Hub
USB Device: USB 10/100/1000 LAN
USB Device: Apple Internal Keyboard / Trackpad
USB Device: BRCM20702 Hub
USB Device: Bluetooth USB Host Controller
USB Device: USB2.0 Hub
USB Device: hub_device
USB Device: PS2/USB KVM
USB Device: hub_device
USB Device: USB-PS/2 Optical Mouse
USB Device: SparkFun Pro Micro
USB Device: Black Magic Probe (ST-Link/v2) v1.9.0-rc1-33-g302c8b53d-dirty
Thunderbolt Bus: MacBook Pro, Apple Inc., 27.1

@epasveer
Copy link
Owner

Hi.

That crash dump shows a SEGV. An address of 0x10 seems odd. Probably an unitialized variable on my part.
Exception Type: EXC_BAD_ACCESS (SIGSEGV) Exception Codes: KERN_INVALID_ADDRESS at 0x0000000000000010

However, I'm not seeing a traceback ... unless it's being truncated somehow.

Can you run it this way through gdb?

$ gdb seergdb
(gdb) run
<change config settings>
<segv should occur>
(gdb) bt
<include this bt in the task>

@Joebeazelman
Copy link
Author

Joebeazelman commented Mar 27, 2023

I'm not a GDB user, otherwise, I wouldn't be interested in this program. I would put GDB and all of UNIXdom out of their miserable existence if it was up to me. That said, give me clear and specific instructions. Here's the dump after I typed bt.

Thread 3 received signal SIGSEGV, Segmentation fault.
0x00007ff8157326e4 in ?? ()
(gdb) bt
#0 0x00007ff8157326e4 in ?? ()
#1 0x0000000000000000 in ?? ()
(gdb)

@epasveer
Copy link
Owner

Hmmm. That backtrace is very brief.

I have a buddy that uses MacOS. I'll see if I can work with him.

Can you give me the details of your system? What level of MacOS. What compiler are you using? What Qt library versions are you using.

Meanwhile, I'll correct the cmake errors using your suggestions (the other task).

@Joebeazelman
Copy link
Author

All the information is in the dump I posted, specifically the beginning (OS) and the end (Mac model). I installed Qt5.

You might want to look at some sample QT5 MacOS preferences code for how to implement it. It's non-standard in that the storage is more like an ini file that the OS manages for you. Apple doesn't make it easy unfortunately.

@Joebeazelman
Copy link
Author

Hmmm. That backtrace is very brief.

I have a buddy that uses MacOS. I'll see if I can work with him.

Can you give me the details of your system? What level of MacOS. What compiler are you using? What Qt library versions are you using.

Meanwhile, I'll correct the cmake errors using your suggestions (the other task).

Is it possible to release a build to make sure everyone is building properly?

@epasveer
Copy link
Owner

You might want to look at some sample QT5 MacOS preferences code for how to implement it. It's non-standard in that the storage is more like an ini file that the OS manages for you. Apple doesn't make it easy unfortunately.

Will do. Qt is usually pretty good at handling the settings. But I'll check some MacOS examples.

@epasveer
Copy link
Owner

Is it possible to release a build to make sure everyone is building properly?

Yes, it is. I'll test it on my existing hardware first (OpenSuse, debian, Ubunto, gentoo, freebsd) before committing it, though.

@Joebeazelman
Copy link
Author

Here's what I've been able to find using LLDB debugger attached to VSCode. At first, I thought the error was related to IO. I figured the error occurred when it was trying to either create or write to the configuration file due to permissions or some IO issue. It crashes, however, immediately after assigning to keySequenceEdit. It's QT related, but I would expect the crash also happens on other platforms.

SeerKeySettings SeerKeysConfigPage::keySettings() const {

    SeerKeySettings settings;

    for (int r=0; r<keysTableWidget->rowCount(); r++) {

        // Get the key (label) for this row.
        QString key = keysTableWidget->verticalHeaderItem(r)->text();

        // Get widgets for this row. Error happens
-->  **immediately here on MacOS**
        QKeySequenceEdit* keySequenceEdit  = dynamic_cast<QKeySequenceEdit*>(keysTableWidget->cellWidget(r,0));
        QLabel*           descriptionLabel = dynamic_cast<QLabel*>(keysTableWidget->cellWidget(r,1));

        // Create key setting.
        SeerKeySetting setting(key, keySequenceEdit->keySequence(), descriptionLabel->text());

        // Add the setting to our settings.
        settings.add(key, setting);
    }

    return settings;
}

In the meantime, I will need to modify the configuration to use the arm-eabi-gdb for Ada. Where are the configuration settings stored? I'm hoping to edit the configuration in the file directly.

@epasveer
Copy link
Owner

Hi Joe,

I wonder if this is a problem with initial installs of seer. I'll do some tests (with valgrind). I can also add a check if the dynamic_cast fails.

The config file, at least on Linux, is :

$ ls -l  ~/.config/seergdb/seergdb.conf

Here's a sane list of key settings. (A subset of seergdb.conf file). I'm hoping MacOS is the same as Linux as far as this file goes.


[shortcuts]
1\action=AlternateDir
1\help=Look for source file in an alternate directory.
1\key=Ctrl+O
10\action=Run
10\help=Run the program again. Do not break in \"main\".
10\key=F1
11\action=SearchText
11\help=Seach for text in the code editor.
11\key=Ctrl+F
12\action=SearchTextNext
12\help=Seach for next text in the code editor.
12\key=Ctrl+G
13\action=SearchTextPrev
13\help=Seach for previous text in the code editor.
13\key=Ctrl+Shift+G
14\action=Start
14\help=Run the program again. Break in \"main\".
14\key=F2
15\action=Step
15\help=Execute the next line. Step into functions.
15\key=F6
16\action=Stepi
16\help=Execute the next instruction. Step into functions.
16\key=Ctrl+F6
2\action=Arguments
2\help=Open the argument dialog.
2\key=Alt+A
3\action=Continue
3\help=Continue execution of the program.
3\key=F8
4\action=Debug
4\help=Open the debug dialog.
4\key=Alt+D
5\action=Finish
5\help=Finish the current function.
5\key=F7
6\action=Interrupt
6\help=Interrupt the executing program.
6\key=Ctrl+I
7\action=Next
7\help=Execute the next line. Step over functions.
7\key=F5
8\action=Nexti
8\help=Execute the next instruction. Step over functions.
8\key=Ctrl+F5
9\action=Quit
9\help=Quit Seer.
9\key=Alt+Q
size=16

@epasveer
Copy link
Owner

If you clone the latest, I've put a check in the KeyConfigPage if the table isn't fully populated. Not sure if it will fix things but give it a try.

@epasveer
Copy link
Owner

Hi,

Just wondering if you were able to try the fix I put into KeyConfigPage?

Thanks.

@Joebeazelman
Copy link
Author

Yes. It appears to be fixed.

@Joebeazelman
Copy link
Author

It turns out in order to build Seer for MacOS, you need to set the cmake qt5 environment variable manually. You might want to make a note of it in the build instructions with an example:

In order for find_package to be successful, Qt 5 must be found below the CMAKE_PREFIX_PATH, or the Qt5_DIR must be set in the CMake cache to the location of the Qt5Config.cmake file. The easiest way to use CMake is to set the CMAKE_PREFIX_PATH environment variable to the install prefix of Qt 5.

@epasveer
Copy link
Owner

Thanks for the tip. I'll add it to the build instructions.

Closing this task.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants