Questions tagged [systrace]

The systrace tool helps analyze the performance of an Android application.

The systrace tool helps analyze the performance of your application by capturing and displaying execution times of your applications processes and other Android system processes.

The tool combines data from the Android kernel such as the CPU scheduler, disk activity and application threads to generate an HTML report that shows an overall picture of an Android device’s system processes for a given period of time.

More info at the android developers help page.

153 questions
3
votes
0 answers

Hook ALL system calls in Linux

The goal is to add a hook to all system calls in Linux, that is, the hook function should get called before any of those 300 Linux system calls are invoked. There are sys_call_table hacks (e.g. [here]), which however only allow to hook one or few…
Richard
  • 14,642
  • 18
  • 56
  • 77
3
votes
2 answers

Error when trying to use Android systrace.py on Linux Ubuntu

I am trying to run Systrace but I get an error when I run the command. user1@PC1:~/Android/Sdk/platform-tools/systrace$ python Python 2.7.6 (default, Mar 22 2014, 22:59:56) [GCC 4.8.2] on linux2 Type "help", "copyright", "credits" or "license" for…
Zythyr
  • 1,142
  • 4
  • 20
  • 33
3
votes
3 answers

Is logging Android systrace events directly from native code possible, without JNI?

The Android systrace logging system is fantastic, but it only works in the Java portion of the code, through Trace.beginSection() and Trace.endSection(). In a C/C++ NDK (native) portion of the code it can only be used through JNI, which is slow or…
Mihai B
  • 133
  • 1
  • 9
3
votes
0 answers

Displaying textview settext very slow performance with long text

I try to display a long text with TextView in Android app (maximally about 300 KB) and performance on Nexus 7 is terrible (something around 10 seconds). Text is scrollable so we divided it into smaller pieces and tried to display them in ListView…
Andrzej Dąbrowski
  • 1,159
  • 11
  • 14
3
votes
0 answers

Error when trying to use android systrace.py line 135

New to android and wanted to do a little debugging with the systrace tool however I am unable to run the tool on the emulator (tried running the python script with python 2.0.1, 2.7.x, 3.x) as well as using ADT. However they all produce different…
reubenjohn
  • 1,351
  • 1
  • 18
  • 43
3
votes
1 answer

Make Systrace work with 4.1.2 device on Mac

I have been struggling a long time to just use systrace. My device runs 4.1.2 (LT28i) and I'm on a Mac. I am bouncing SO questions with similar issues none of whom have a clear answer. I want let's say to trace views and graphics Method 1,…
Diolor
  • 13,181
  • 30
  • 111
  • 179
3
votes
2 answers

Systrace gives no such option error for --set-tags

I'm following the instructions here to use systrace for my application but I keep getting the following error whenever I try to set the tags for systrace: systrace.py: error: no such option: --set-tags This seems to be a rather new issue that just…
Kurtis Nusbaum
  • 30,445
  • 13
  • 78
  • 102
3
votes
1 answer

Systrace on Android 4.3

I'm trying to measure performance attributes of my app through systrace by using the new Trace API introduced in JB 4.3. The idea is similar to the use of traceview method profiling, i.e. you can measure a specific code section using…
luuts
  • 652
  • 4
  • 12
3
votes
1 answer

Systrace on android emulator

I am trying to use systrace on an android 4.2 (avd 17) emulator I have enabled usb debuggimg and activated webview in the tracing options and folloed this guide here http://www.youtube.com/watch?feature=player_embedded&v=Q8m9sHdyXnE#t=31m15s But…
gheese
  • 1,170
  • 1
  • 11
  • 17
2
votes
2 answers

Oboe Systrace are non full buffers considered as underruns or not?

I am using oboe library to make a music app. There I produce music by writing PCM float values to the given pointer. I rarely have underruns which I can hearwhich. I also verify this with the following oboe APIs: managedStream->getXRunCount(); The…
cs guy
  • 926
  • 2
  • 13
  • 33
2
votes
3 answers

Systrace custom events not showing in release build of app

I am using systrace/perfetto to capture traces. I am following below way to add custom events from my code - https://developer.android.com/topic/performance/tracing/custom-events I can see custom events in debug build but cant see in release…
Rishi
  • 21
  • 4
2
votes
0 answers

Using Android systrace to get statistic frames data

I want to get information about average FPS, number of dropped frames, average RAM usage in a text form, so that I can compare two apps and see which one is smoother when scrolling a list. But I need hard data for this (it's for diploma…
2
votes
0 answers

Systrace not generating html report or collecting output, exception getting results from atrace

I have recently started to research systrace, but have not succeded in running a trace that produces an html report as it should. I have tried tracing on two different units: Samsung Galaxy A3 - Android 7.0 Samsung Xcover 3 - Android 5.1 The…
Esben86
  • 483
  • 8
  • 21
2
votes
1 answer

How to measure layout performance effectively and easily?

Due to this article Hierarchy Viewer is deprecated. Now you can use Layout Inspector for analyzing your layout. But Layout Inspector does not measure. You can look for alerts due to layout performance by using systrace but it does not show you how…
2
votes
0 answers

Systrace command line tool on windows doesn't work

I'm trying to start systrace.py on the windows 10 but got the following error File "C:\Users\smityukh\AppData\Local\Android\sdk\platform-tools\systrace\catapult\systrace\systrace....\devil\devil\utils\cmd_helper.py", line 97, in…
Viacheslav Smityukh
  • 5,652
  • 4
  • 24
  • 42