Loading services/surfaceflinger/SurfaceFlinger.cpp +11 −2 Original line number Diff line number Diff line Loading @@ -1679,8 +1679,6 @@ void SurfaceFlinger::calculateWorkingSet() { mDrawingState.colorMatrixChanged = false; for (const auto& [token, display] : mDisplays) { getBE().mCompositionInfo[token].clear(); for (auto& layer : display->getVisibleLayersSortedByZ()) { const auto displayId = display->getId(); layer->getBE().compositionInfo.compositionType = layer->getCompositionType(displayId); Loading Loading @@ -1964,6 +1962,17 @@ void SurfaceFlinger::rebuildLayerStacks() { ATRACE_CALL(); ALOGV("rebuildLayerStacks"); // We need to clear these out now as these may be holding on to a // HWC2::Layer reference at the same time as the LayerBE::HWCInfo structure // also holds a reference. When the set of visible layers is recomputed, // some layers may be destroyed if the only thing keeping them alive was // that list of visible layers associated with each display. The layer // destruction code asserts that the HWC2::Layer is properly destroyed, but // that doesn't happen if SurfaceFlingerBE::mCompositionInfo keeps it alive. for (const auto& [token, display] : mDisplays) { getBE().mCompositionInfo[token].clear(); } // rebuild the visible layer list per screen if (CC_UNLIKELY(mVisibleRegionsDirty)) { ATRACE_NAME("rebuildLayerStacks VR Dirty"); Loading Loading
services/surfaceflinger/SurfaceFlinger.cpp +11 −2 Original line number Diff line number Diff line Loading @@ -1679,8 +1679,6 @@ void SurfaceFlinger::calculateWorkingSet() { mDrawingState.colorMatrixChanged = false; for (const auto& [token, display] : mDisplays) { getBE().mCompositionInfo[token].clear(); for (auto& layer : display->getVisibleLayersSortedByZ()) { const auto displayId = display->getId(); layer->getBE().compositionInfo.compositionType = layer->getCompositionType(displayId); Loading Loading @@ -1964,6 +1962,17 @@ void SurfaceFlinger::rebuildLayerStacks() { ATRACE_CALL(); ALOGV("rebuildLayerStacks"); // We need to clear these out now as these may be holding on to a // HWC2::Layer reference at the same time as the LayerBE::HWCInfo structure // also holds a reference. When the set of visible layers is recomputed, // some layers may be destroyed if the only thing keeping them alive was // that list of visible layers associated with each display. The layer // destruction code asserts that the HWC2::Layer is properly destroyed, but // that doesn't happen if SurfaceFlingerBE::mCompositionInfo keeps it alive. for (const auto& [token, display] : mDisplays) { getBE().mCompositionInfo[token].clear(); } // rebuild the visible layer list per screen if (CC_UNLIKELY(mVisibleRegionsDirty)) { ATRACE_NAME("rebuildLayerStacks VR Dirty"); Loading