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

Commit bfb3be12 authored by Vishnu Nair's avatar Vishnu Nair Committed by Android (Google) Code Review
Browse files

Merge "SF Tracing: Provide a valid starting bounds" into tm-dev

parents 27dbab9b f6f56952
Loading
Loading
Loading
Loading
+7 −0
Original line number Diff line number Diff line
@@ -2603,6 +2603,13 @@ FloatRect SurfaceFlinger::getMaxDisplayBounds() {
    // Find the largest width and height among all the displays.
    int32_t maxDisplayWidth = 0;
    int32_t maxDisplayHeight = 0;

    // If there are no displays, set a valid display bounds so we can still compute a valid layer
    // bounds.
    if (ON_MAIN_THREAD(mDisplays.size()) == 0) {
        maxDisplayWidth = maxDisplayHeight = 5000;
    }

    for (const auto& pair : ON_MAIN_THREAD(mDisplays)) {
        const auto& displayDevice = pair.second;
        int32_t width = displayDevice->getWidth();
+1 −2
Original line number Diff line number Diff line
@@ -204,8 +204,7 @@ bool LayerTraceGenerator::generate(const proto::TransactionTraceFile& traceFile,
    mFlinger.setupComposer(std::unique_ptr<Hwc2::Composer>(mComposer));
    mFlinger.mutableMaxRenderTargetSize() = 16384;

    flinger->setLayerTracingFlags(LayerTracing::TRACE_BUFFERS | LayerTracing::TRACE_INPUT |
                                  LayerTracing::TRACE_BUFFERS);
    flinger->setLayerTracingFlags(LayerTracing::TRACE_INPUT | LayerTracing::TRACE_BUFFERS);
    flinger->startLayerTracing(traceFile.entry(0).elapsed_realtime_nanos());
    std::unique_ptr<TraceGenFlingerDataMapper> mapper =
            std::make_unique<TraceGenFlingerDataMapper>();