android systrace下载,Android Systrace Trace File Format

本文探讨了Android系统中使用adb通过atrace工具生成的追踪文件格式。内容涉及atrace与Linux ftrace工具的区别,如atrace不使用System.Map文件,而是在追踪文件中包含所有信息,以及Android特有的B|E条目。文章还提到了追踪文件格式与Linux Perf Tool的关联性,但指出两者输出格式不同。示例追踪日志显示了进程调度、唤醒和休眠等系统活动。

摘要生成于 C知道 ,由 DeepSeek-R1 满血版支持, 前往体验 >

Android systrace tool, calls atrace tool via ADB. However, I don't understand very well the format of the traces file. Apparently it is very similar to linux ftrace tool with some differences. The main difference is that is doesn't uses a System.Map file but it includes all that information into the trace file. Also, there are new B|E entries that are android specific.

However, in that documentation we can read that the format belongs to Linux Perf Tool. I don't think so, linux perf gives as an output a very different format... (unless some special configuration is active...)

My question is: Does anybody know where can I found an official documentation about android trace files generated with atrace tool from adb?

Is this format familiar to you ? # tracer: nop # # entries-in-buffer/entries-written: 66427/66427 #P:2 # # _-----=> irqs-off # / _----=> need-resched # | / _---=> hardirq/softirq # || / _--=> preempt-depth # ||| / delay # TASK-PID CPU# |||| TIMESTAMP FUNCTION # | | | |||| | | atrace-1724 [000] d..3 14186.680000: sched_switch: prev_comm=atrace prev_pid=1724 prev_prio=120 prev_state=S ==> next_comm=swapper/0 next_pid=0 next_prio=120 -0 [000] d.h7 14186.690000: sched_wakeup: comm=tfm_b6bcf800 pid=1714 prio=35 success=1 target_cpu=000 -0 [000] d..3 14186.690000: sched_switch: prev_comm=swapper/0 prev_pid=0 prev_prio=120 prev_state=R ==> next_comm=tfm_b6bcf800 next_pid=1714 next_prio=35 tfm_b6bcf800-1714 [000] d..3 14186.690000: sched_switch: prev_comm=tfm_b6bcf800 prev_pid=1714 prev_prio=35 prev_state=D|W ==> next_comm=swapper/0 next_pid=0 next_prio=120 -0 [001] d.h3 14186.690000: sched_wakeup: comm=Player Aud Mixe pid=146 prio=35 success=1 target_cpu=001 -0 [001] d..3 14186.690000: sched_switch: prev_comm=swapper/1 prev_pid=0 prev_prio=120 prev_state=R ==> next_comm=Player Aud Mixe next_pid=146 next_prio=35 Player Aud Mixe-146 [001] d..3 14186.690000: sched_switch: prev_comm=Player Aud Mixe prev_pid=146 prev_prio=35 prev_state=D ==> next_comm=swapper/1 next_pid=0 next_prio=120 -0 [001] d.h3 14186.690000: sched_wakeup: comm=Player Aud Mixe pid=146 prio=35 success=1 target_cpu=001 -0 [001] d..3 14186.690000: sched_switch: prev_comm=swapper/1 prev_pid=0 prev_prio=120 prev_state=R ==> next_comm=Player Aud Mixe next_pid=146 next_prio=35 Player Aud Mixe-146 [001] d..3 14186.690000: sched_switch: prev_comm=Player Aud Mixe prev_pid=146 prev_prio=35 prev_state=S ==> next_comm=swapper/1 next_pid=0 next_prio=120 -0 [001] d.h3 14186.700000: sched_wakeup: comm=Player Aud Mixe pid=146 prio=35 success=1 target_cpu=001 -0 [001] d..3 14186.700000: sched_switch: prev_comm=swapper/1 prev_pid=0 prev_prio=120 prev_state=R ==> next_comm=Player Aud Mixe next_pid=146 next_prio=35 EventThread-110 [001] d..5 14190.100000: sched_wakeup: comm=SurfaceFlinger pid=103 prio=112 success=1 target_cpu=001 EventThread-110 [001] d..3 14190.100000: sched_switch: prev_comm=EventThread prev_pid=110 prev_prio=111 prev_state=S ==> next_comm=SurfaceFlinger next_pid=103 next_prio=112 SurfaceFlinger-103 [001] ...1 14190.100000: tracing_mark_write: B|96|onMessageReceived SurfaceFlinger-103 [001] ...1 14190.100000: tracing_mark_write: B|96|handleTransaction SurfaceFlinger-103 [001] ...1 14190.100000: tracing_mark_write: B|96|doTransaction SurfaceFlinger-103 [001] ...1 14190.100000: tracing_mark_write: E SurfaceFlinger-103 [001] ...1 14190.100000: tracing_mark_write: E SurfaceFlinger-103 [001] ...1 14190.100000: tracing_mark_write: B|96|handleMessageInvalidate SurfaceFlinger-103 [001] ...1 14190.100000: tracing_mark_write: E SurfaceFlinger-103 [001] ...1 14190.100000: tracing_mark_write: E SurfaceFlinger-103 [001] ...1 14190.100000: tracing_mark_write: B|96|onMessageReceived SurfaceFlinger-103 [001] ...1 14190.100000: tracing_mark_write: B|96|handleMessageRefresh SurfaceFlinger-103 [001] ...1 14190.100000: tracing_mark_write: B|96|rebuildLayerStacks SurfaceFlinger-103 [001] ...1 14190.100000: tracing_mark_write: B|96|computeVisibleRegions SurfaceFlinger-103 [001] ...1 14190.100000: tracing_mark_write: E SurfaceFlinger-103 [001] ...1 14190.100000: tracing_mark_write: E SurfaceFlinger-103 [001] ...1 14190.100000: tracing_mark_write: B|96|doComposition SurfaceFlinger-103 [001] d.h4 14190.100000: sched_wakeup: comm=surfaceflinger pid=96 prio=120 success=1 target_cpu=001 SurfaceFlinger-103 [001] d..3 14190.100000: sched_switch: prev_comm=SurfaceFlinger prev_pid=103 prev_prio=112 prev_state=R ==> next_comm=surfaceflinger next_pid=96 next_prio=120

Thanks in advance !

评论
添加红包

请填写红包祝福语或标题

红包个数最小为10个

红包金额最低5元

当前余额3.43前往充值 >
需支付:10.00
成就一亿技术人!
领取后你会自动成为博主和红包主的粉丝 规则
hope_wisdom
发出的红包
实付
使用余额支付
点击重新获取
扫码支付
钱包余额 0

抵扣说明:

1.余额是钱包充值的虚拟货币,按照1:1的比例进行支付金额的抵扣。
2.余额无法直接购买下载,可以购买VIP、付费专栏及课程。

余额充值