Loading libs/hwui/renderthread/HintSessionWrapper.cpp +4 −3 Original line number Diff line number Diff line Loading @@ -72,6 +72,7 @@ void HintSessionWrapper::destroy() { mSessionValid = true; mHintSession = nullptr; } mResetsSinceLastReport = 0; } bool HintSessionWrapper::init() { Loading Loading @@ -111,10 +112,10 @@ bool HintSessionWrapper::init() { // Use a placeholder target value to initialize, // this will always be replaced elsewhere before it gets used int64_t defaultTargetDurationNanos = 16666667; int64_t targetDurationNanos = mLastTargetWorkDuration == 0 ? kDefaultTargetDuration : mLastTargetWorkDuration; mHintSessionFuture = CommonPool::async([=, this, tids = std::move(tids)] { return mBinding->createSession(manager, tids.data(), tids.size(), defaultTargetDurationNanos); return mBinding->createSession(manager, tids.data(), tids.size(), targetDurationNanos); }); return false; } Loading libs/hwui/renderthread/HintSessionWrapper.h +1 −0 Original line number Diff line number Diff line Loading @@ -65,6 +65,7 @@ private: static constexpr nsecs_t kResetHintTimeout = 100_ms; static constexpr int64_t kSanityCheckLowerBound = 100_us; static constexpr int64_t kSanityCheckUpperBound = 10_s; static constexpr int64_t kDefaultTargetDuration = 16666667; // Allows easier stub when testing class HintSessionBinding { Loading Loading
libs/hwui/renderthread/HintSessionWrapper.cpp +4 −3 Original line number Diff line number Diff line Loading @@ -72,6 +72,7 @@ void HintSessionWrapper::destroy() { mSessionValid = true; mHintSession = nullptr; } mResetsSinceLastReport = 0; } bool HintSessionWrapper::init() { Loading Loading @@ -111,10 +112,10 @@ bool HintSessionWrapper::init() { // Use a placeholder target value to initialize, // this will always be replaced elsewhere before it gets used int64_t defaultTargetDurationNanos = 16666667; int64_t targetDurationNanos = mLastTargetWorkDuration == 0 ? kDefaultTargetDuration : mLastTargetWorkDuration; mHintSessionFuture = CommonPool::async([=, this, tids = std::move(tids)] { return mBinding->createSession(manager, tids.data(), tids.size(), defaultTargetDurationNanos); return mBinding->createSession(manager, tids.data(), tids.size(), targetDurationNanos); }); return false; } Loading
libs/hwui/renderthread/HintSessionWrapper.h +1 −0 Original line number Diff line number Diff line Loading @@ -65,6 +65,7 @@ private: static constexpr nsecs_t kResetHintTimeout = 100_ms; static constexpr int64_t kSanityCheckLowerBound = 100_us; static constexpr int64_t kSanityCheckUpperBound = 10_s; static constexpr int64_t kDefaultTargetDuration = 16666667; // Allows easier stub when testing class HintSessionBinding { Loading