libEGL: Add initialization tracing
The first call to eglGetDisplay() loads drivers and initializes
dispatch tables. This currently takes significant time (85-100 ms),
and can must be done before the first frame of an app can be shown.
This change adds systrace markers for the major parts of this process,
as a precursor to optimizing them.
Bug: 34404021
Test: manual systrace of calculator app startup on bullhead
Change-Id: If1ecb5a81f9d33daf72c6f3e5b403972f8529b2d
diff --git a/opengl/libs/EGL/eglApi.cpp b/opengl/libs/EGL/eglApi.cpp
index a42b3f1..f8e25b4 100644
--- a/opengl/libs/EGL/eglApi.cpp
+++ b/opengl/libs/EGL/eglApi.cpp
@@ -267,6 +267,7 @@
EGLDisplay eglGetDisplay(EGLNativeDisplayType display)
{
+ ATRACE_CALL();
clearError();
uintptr_t index = reinterpret_cast<uintptr_t>(display);