如何使用atos手动符号化崩溃日志 [英] How to manually symbolicate a crash log with atos

查看:317
本文介绍了如何使用atos手动符号化崩溃日志的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

在互联网上搜寻了一种方法来象征我从Apple收到的崩溃日志之后,我终于弄清楚了如何在终端中使用atos命令来象征崩溃日志.我在同一个文件夹中有dSYM文件,.app文件和崩溃日志,并且使用atos -arch armv7 -o APPNAME我已经能够输入内存地址,有时(但很少有)出现一个方法名.老实说,我对终端或崩溃日志没有太多经验.不幸的是,尝试用符号表示来自Xcode组织者的崩溃日志并没有做任何事情,并且尝试在Xcode软件包内容中使用symbolicatecrash文件也失败了.因此,这里就是我所知道的唯一其他选择.

After searching all over the internet to find a way to symbolicate my crash logs I received from Apple, I finally figured out how to use the atos command in terminal to symbolicate the crash logs. I have the dSYM file, the .app file and the crash logs in the same folder, and using atos -arch armv7 -o APPNAME I have been able to enter memory addresses, and sometimes (but quite rarely) a method name has come up. To be perfectly honest, I don't have much experience with terminal, or crash logs. Attempting to symbolicate the crash logs from Xcode's organiser has unfortunately done absolutely nothing, and trying to use the symbolicatecrash file within Xcode's package contents has also failed. So here I am, left with the only other option I know of.

现在,我的问题是:如何使这些存储地址成正反方向?我必须输入哪些地址才能到达应用崩溃的地步?我90%都在那儿,我只是不知道哪个地址会给我有价值的信息,或者哪个没用.此处是崩溃日志的图片:

Now, my question is this: how does one go about making heads or tails of these memory addresses? Which addresses must I enter to arrive at the point at which the app crashed? I am 90% of the way there, I just don't know which addresses will give me valuable information or which are useless. Attached here is a picture of a crash log:

非常感谢您的帮助.

推荐答案

我的猜测是,您看到了包含atos信息的Stackoverflow问题(就像我一样),但是没有正确计算要放入atos的地址.看到这里:

My guess is that you saw the Stackoverflow question with the atos information in it (like I did), but are not calculating the address correctly to put into atos. See here:

iOS崩溃报告:Atos无法正常工作

符号地址=幻灯片+堆栈地址-加载地址

symbol address = slide + stack address - load address

使用otool获取幻灯片的地址(通常为0x001000)

Use otool to get your slide address (usually 0x001000)

otool -arch ARCHITECTURE -l "APP_BUNDLE/APP_EXECUTABLE" | grep -B 3 -A 8 -m 2 "__TEXT"

滚动到崩溃日志的底部,以从二进制映像部分(二进制映像下的列表中的第一个地址)获取堆栈地址.

Scroll to the bottom of your crash log to get your stack address from the binary images section (first address in the list under Binary Images).

然后使用Mac随附的HEX计算器将其添加(使用程序员视图).最后,从崩溃日志中的堆栈跟踪中减去您的加载地址(在您的情况下,看起来像0x00012efe).

Then add it up using the HEX calculator that comes with your mac (use programmer view). Lastly subtract your load address from the stack trace in your crash log (in your case it looks like 0x00012efe).

将其放入atos中以获取导致崩溃的行:

Put this in atos to get the line that causes the crash:

atos -arch armv7 -o YOURAPP.app'/'yourapp' 0xADDRESSFROMABOVE

这篇关于如何使用atos手动符号化崩溃日志的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆