IOS Crash Analysis (article III)-Symbolic crash log
The unsigned crash log is like a book of heavenly books, not understood, let alone analyze the cause of the crash. So before we analyze the logs, we need to translate the logs into words that we can read. This step we call symbolic.
There are two ways to symbolize in iOS crash Analysis (article I):
1. Use Xcode to symbolize 2. Using Symbolicatecrash scripting notation
In fact, both of these analysis methods use the same tool symbolized: ***atos***.
Atos is an apple-provided symbolic tool that is installed by default on Mac OS systems.
Using ***atos*** notation requires dsym files. dSYM files are generated when the project is compiled, and all archived application files can be found under the Archives tab bar of Xcode organizer. It holds detailed information about the compilation process, including symbolic information.
Note: You must keep both the app binaries and the. dsym file in order to fully symbolize the crash log. Every build that is submitted to itunes Connect must be archived.. dsym files and binaries are specific bindings for each build and subsequent build, and even from the same source code files, each build is different from other constructs and cannot be replaced with each other. If you use the build and Archive commands, these files are automatically placed in place. If you are not using the build and archive commands, place them in a location that spotlight can search (such as the home directory).
below we use ***atos*** to symbolize a crash or see the following example:
# # # 1. Process Information # # #Incident Identifier:e4201f10-6f5f-40f9-b938-bb3da8ed7d50crashreporter key:todohardware Model:iphon E4,1process:taobao4iphone [3538]path:/var/mobile/applications/e3b51e77-d44d-4b3e-8767-b7dc2008d138/ta Obao4iphone.app/taobao4iphoneidentifier:com.taobao.taobao4iphoneversion:4.8.1code type:armparent Pro Cess:launchd [1]### 2. Basic Information # # #Date/time:2014-09-16 21:39:30 +0000os version:iphone OS 7.1.2 (11d257) Report version:104### 3. Exception Information # # #Exception type:sigsegvexception codes:segv_accerr at 0xa2400db3crashed thread:0### 4. Thread backtracking # # #Thread 0 name:dispatch queue:com.apple.main-thread### 5.Crash Call Stack # # #Thread 0 crashed:0 LIBOBJC. A.dylib 0x3838760c 0x38375000 + 752761 taobao4iphone 0x012c03e1 0x66000 + 1924 40012 taobao4iphone 0x012c054f 0x66000 + 192443673 Foundation 0x2e4de16 3 0x2e419000 + 8072674 corefoundation 0x2dac9167 0x2da2a000 + 6516235 corefoundation 0x2dac8d7f 0x2da2a000 + 6506236 Corefoundation 0x2dac711b 0x2da2a000 + 6433557 corefoundation 0x2da31ebf 0x2d a2a000 + 324478 corefoundation 0x2da31ca3 0x2da2a000 + 319079 graphicsservices 0x3298b663 0x32982000 + 3849910 UIKit 0x3037e14d 0x30310000 + 45089311 Taobao4iphone 0x0006b349 0x66000 + 2132112 taobao4iphone 0x0006a5e8 0x66000 + 17896Thread 1:0 Libsystem_kernel.dylib 0x38928808 0x38928000 + 20561 libdispatch.dylib 0x38869e03 0x3885 f000 + 44547### 5. Dynamic Library Information # # #Binary images:0x66000-0x19cdfff +taobao4iphone armv7 <43EBE409980F31FD9BE165A64B002AF 5>/var/mobile/applications/e3b51e77-d44d-4b3e-8767-b7dc2008d138/taobao4iphone.app/taobao4iphone 0x9fa9000- 0X9FB4FFF Quickspeak ARMv7 <Eda7aee380373fad88f17971512f2777>/system/library/accessibilitybundles/quickspeak.bundle/ QUICKSPEAK0X2C667000-0X2C669FFF axspeechimplementation armv7 <fceb6d31f58d3c41afa9ace822d266a7>/system/ Library/accessibilitybundles/axspeechimplementation.bundle/axspeechimplementation
I select a call to symbolize:
1 Taobao4iPhone 0x012c03e1 0x66000 + 19244001
Use the following command to symbolize:
atos -arch armv7 -o "Taobao4iPhone.app.dSYM" -l 0x66000 0x012c03e1
Results:
1 Taobao4iPhone 0x012c03e1 -[TBSNSPagesContainerView subviewLayoutPage:] (in Taobao4iPhone) (TBSNSPagesContainer.m:227)
You can see that the crash class is Tbsnspagescontainerview, the function is subviewlayoutpage, the file name is TBSNSPAGESCONTAINER.M, and the row count is 227 rows.
Let's go back and look at the Atos usage:
atos -o dysm文件路径 -l 模块load地址 -arch cpu指令集种类 调用方法的地址
dysm file path : Available in Xcode All archived application files are found under the Archives tab bar of the organizer. It holds detailed information about the compilation process, including symbolic information.
module load address : module load base Address, can be in the log of * * * Dynamic Library information * * * The base address of the corresponding module is found in the Here is 0x66000
0x66000-0x19cdfff +taobao4iphone armv7 <43ebe409980f31fd9be165a64b002af5>/var/mobile/ Applications/e3b51e77-d44d-4b3e-8767-b7dc2008d138/taobao4iphone.app/taobao4iphone
Then the CPU instruction set of the Taobao4iphone module is ARMV7
address of the calling method : This is 0x012c03e1, explained in IOS Crash Analysis (Text II)
IOS Crash Analysis (article III)-Symbolic crash log