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

Commit 942d768f authored by Michael Krehan's avatar Michael Krehan Committed by Android (Google) Code Review
Browse files

Merge "Moved the Perfetto flag check into SurfaceFlinger." into main

parents 7749c638 74479d2c
Loading
Loading
Loading
Loading
+0 −1
Original line number Diff line number Diff line
@@ -43,7 +43,6 @@ cc_library_shared {
        "libbase",
        "libcutils",
        "libperfetto_c",
        "android.os.flags-aconfig-cc-host",
    ],

    host_supported: true,
+0 −5
Original line number Diff line number Diff line
@@ -47,7 +47,6 @@
#include <atomic>
#include <mutex>

#include <android_os.h>
#include <android-base/properties.h>
#include <cutils/trace.h>
#include <inttypes.h>
@@ -228,10 +227,6 @@ struct PerfettoTeCategory* toPerfettoCategory(uint64_t category) {
}

void registerWithPerfetto(bool test) {
  if (!android::os::perfetto_sdk_tracing()) {
    return;
  }

  static std::once_flag registration;
  std::call_once(registration, [test]() {
    struct PerfettoProducerInitArgs args = PERFETTO_PRODUCER_INIT_ARGS_INIT();
+1 −0
Original line number Diff line number Diff line
@@ -67,6 +67,7 @@ cc_defaults {
        "android.hardware.graphics.composer@2.2",
        "android.hardware.graphics.composer@2.3",
        "android.hardware.graphics.composer@2.4",
        "android.os.flags-aconfig-cc-host",
        "libbase",
        "libbinder",
        "libbinder_ndk",
+5 −1
Original line number Diff line number Diff line
@@ -37,6 +37,7 @@
#include <android/hardware/configstore/1.1/types.h>
#include <android/native_window.h>
#include <android/os/IInputFlinger.h>
#include <android_os.h>
#include <binder/IPCThreadState.h>
#include <binder/IServiceManager.h>
#include <binder/PermissionCache.h>
@@ -741,7 +742,10 @@ void SurfaceFlinger::bootFinished() {
    mBootFinished = true;
    FlagManager::getMutableInstance().markBootCompleted();

    if (android::os::perfetto_sdk_tracing()) {
        ::tracing_perfetto::registerWithPerfetto();
    }

    mInitBootPropsFuture.wait();
    mRenderEnginePrimeCacheFuture.wait();