diff options
| author | Dianne Hackborn <hackbod@google.com> | 2012-03-16 11:55:05 -0700 |
|---|---|---|
| committer | Android Git Automerger <android-git-automerger@android.com> | 2012-03-16 11:55:05 -0700 |
| commit | c032a73b511d4006e083a646b7dd23d54ed373ac (patch) | |
| tree | e2455e95c160534c644a277121da7e7f525e6b4c /cmds/dumpstate/dumpstate.c | |
| parent | c8e83aa73e174be163649bb80989b9099fbb74cf (diff) | |
| parent | ce06c000b4133c63414c3244c3325e25315ab179 (diff) | |
| download | frameworks_base-c032a73b511d4006e083a646b7dd23d54ed373ac.zip frameworks_base-c032a73b511d4006e083a646b7dd23d54ed373ac.tar.gz frameworks_base-c032a73b511d4006e083a646b7dd23d54ed373ac.tar.bz2 | |
am ce06c000: Merge "Debugging code for #6169553: Make Phone launch faster" into ics-mr1
* commit 'ce06c000b4133c63414c3244c3325e25315ab179':
Debugging code for #6169553: Make Phone launch faster
Diffstat (limited to 'cmds/dumpstate/dumpstate.c')
| -rw-r--r-- | cmds/dumpstate/dumpstate.c | 18 |
1 files changed, 18 insertions, 0 deletions
diff --git a/cmds/dumpstate/dumpstate.c b/cmds/dumpstate/dumpstate.c index afa4f4d..3613101 100644 --- a/cmds/dumpstate/dumpstate.c +++ b/cmds/dumpstate/dumpstate.c @@ -108,6 +108,24 @@ static void dumpstate() { dump_file("VM TRACES AT LAST ANR", anr_traces_path); } + /* slow traces for slow operations */ + if (anr_traces_path[0] != 0) { + int tail = strlen(anr_traces_path)-1; + while (tail > 0 && anr_traces_path[tail] != '/') { + tail--; + } + int i = 0; + while (1) { + sprintf(anr_traces_path+tail+1, "slow%02d.txt", i); + if (stat(anr_traces_path, &st)) { + // No traces file at this index, done with the files. + break; + } + dump_file("VM TRACES WHEN SLOW", anr_traces_path); + i++; + } + } + // dump_file("EVENT LOG TAGS", "/etc/event-log-tags"); run_command("EVENT LOG", 20, "logcat", "-b", "events", "-v", "threadtime", "-d", "*:v", NULL); run_command("RADIO LOG", 20, "logcat", "-b", "radio", "-v", "threadtime", "-d", "*:v", NULL); |
