Donate to e Foundation | Murena handsets with /e/OS | Own a part of Murena! Learn more

Commit d27455b7 authored by Nataniel Borges's avatar Nataniel Borges
Browse files

Increase default Wm buffer size

Since WM will not be used in the always-on tracing it doesn't need to
have such small buffer sizes. Moreover, the current buffer size don't
record much information (last 10sec max) causing issues when traces are
included in user bugs.

Test: atest FlickerLibTest FlickerTests WMShellFlickerTests
Bug: 207387612
Change-Id: I260435cb5e64279e9d0fe38d5195300e514e18c5
parent d6fb3434
Loading
Loading
Loading
Loading
+4 −4
Original line number Diff line number Diff line
@@ -48,12 +48,12 @@ import java.io.PrintWriter;
class WindowTracing {

    /**
     * Maximum buffer size, currently defined as 512 KB
     * Maximum buffer size, currently defined as 5 MB
     * Size was experimentally defined to fit between 100 to 150 elements.
     */
    private static final int BUFFER_CAPACITY_CRITICAL = 512 * 1024;
    private static final int BUFFER_CAPACITY_TRIM = 2048 * 1024;
    private static final int BUFFER_CAPACITY_ALL = 4096 * 1024;
    private static final int BUFFER_CAPACITY_CRITICAL = 5120 * 1024; // 5 MB
    private static final int BUFFER_CAPACITY_TRIM = 10240 * 1024; // 10 MB
    private static final int BUFFER_CAPACITY_ALL = 20480 * 1024; // 20 MB
    static final String WINSCOPE_EXT = ".winscope";
    private static final String TRACE_FILENAME = "/data/misc/wmtrace/wm_trace" + WINSCOPE_EXT;
    private static final String TAG = "WindowTracing";