Documentation bug reported, as FB14929037.
Yes - the offset from the string is quite large, but I just want useful output such as "ThisFunctionWasInvolved" from "ThisFunctionCausedAPanic.cpp, line 455".
Symbolicate the other frames you've got. This is a quick way to differentiate between "something is wrong with THIS symbol" vs "something systemic is wrong".
Yes, this is a “something systemic is wrong” situation. I was trying to reduce the amount of information for readers to wade through, but I am not getting useful results for any efforts at symbolicating the addresses on the back trace or the PC (program counter).
” dwarfdump" will print the contents of a dsym file, which will either show that the symbols
dwarfdump works on dSYM files, but apparently not on debug-builds-with-symbols-in-the-binary. As such, I rebuilt with separating the symbols into a dSYM file. dwarfdump provides what appears to be correct information for the symbols, but for a sanity check here is a blurb from the start of the dump:
KEXT_NAME.kext.dSYM/Contents/Resources/DWARF/KEXT_NAME(arm64e): file format Mach-O arm64
.debug_info contents:
0x00000000: Compile Unit: length = 0x000001f9, format = DWARF32, version = 0x0004, abbr_offset = 0x0000, addr_size = 0x08 (next unit at 0x000001fd)
0x0000000b: DW_TAG_compile_unit
DW_AT_producer ("Apple clang version 13.1.6 (clang-1316.0.21.2.5)")
DW_AT_language (DW_LANG_C99)
DW_AT_name ("/Users/username/Library/Developer/Xcode/DerivedData/KEXT_NAME-stuff/ArchiveIntermediates/KEXT_NAME/IntermediateBuildFilesPath/KEXT_NAME.build/Release/KEXT_NAME.build/DerivedSources/KEXT_NAME_info.c")
DW_AT_LLVM_sysroot ("/Applications/Xcode.app/Contents/Developer/Platforms/MacOSX.platform/Developer/SDKs/MacOSX12.3.sdk")
DW_AT_APPLE_sdk ("MacOSX12.3.sdk")
DW_AT_stmt_list (0x00000000)
DW_AT_comp_dir ("/Users/username/sandbox/codedirectory")
DW_AT_APPLE_optimized (true)
Since the binary is different, I triggered a new panic to work with:
Apple Silicon Panic log (sanitized)
The command line utility atos should be helpful as well, but here’s an example of what I get as output from that, when using full dSYM file information:
zsh_prompt% atos -arch arm64e -o KEXT_NAME.kext.dSYM/Contents/Resources/DWARF/KEXT_NAME -l 0xfffffe0015423fd0 0xfffffe0015426e2c
0x00002e5c (in KEXT_NAME)
If I manually look up the 0x2e5c offset in the output from dwarfdump, I can see the following:
0x00002e5c: DW_TAG_formal_parameter
DW_AT_type (0x0000000000009408 "const IOService *")
DW_AT_artificial (true)
But that's definitely not conveying the one-step-to-symbolication that atos is supposed to be able to perform. It does not appear that I am using it incorrectly, but I am definitely not getting helpful results from it.
Following the idea that perhaps the kernel slide is not being properly dealt with, I followed this link ( https://lists.apple.com/archives/darwin-kernel/2014/Jan/msg00011.html ) for advice on how to deal with kernel slide (below is all commands listed, and lack of useful information provided):
lldb commands and log for dealing with kext slide
So to answer all of the questions:
Systemic issue, I am having trouble interpreting a kernel panic log and getting valid symbols as a result of address lookup for Apple Silicon
dSYM file appears to be built properly
atos is not providing helpful information, despite having proper dSYM file
lldb commands to load images and deal with kernel slides does not yield helpful information
Topic:
App & System Services
SubTopic:
Drivers
Tags: