summaryrefslogtreecommitdiff
path: root/indra
diff options
context:
space:
mode:
authorAndrey Kleshchev <andreykproductengine@lindenlab.com>2025-03-19 17:57:50 +0200
committerAndrey Kleshchev <117672381+akleshchev@users.noreply.github.com>2025-03-19 19:13:20 +0200
commitb6bf32e00e25de773b6403b716c655f64b6092c9 (patch)
tree060b003166e3a0be0b1a21500e893cfef9051153 /indra
parentb39e281767151f41fb9fec8cbf6eb1acac6ab72f (diff)
#3488 Prelock mutexes
Main thread has priority, it shouldn't be relocking on each loadMeshLOD
Diffstat (limited to 'indra')
-rw-r--r--indra/newview/llmeshrepository.cpp2
1 files changed, 2 insertions, 0 deletions
diff --git a/indra/newview/llmeshrepository.cpp b/indra/newview/llmeshrepository.cpp
index e1fa84b4d8..a8c6f69425 100644
--- a/indra/newview/llmeshrepository.cpp
+++ b/indra/newview/llmeshrepository.cpp
@@ -4573,6 +4573,8 @@ void LLMeshRepository::notifyLoadedMeshes()
std::partial_sort(mPendingRequests.begin(), mPendingRequests.begin() + push_count,
mPendingRequests.end(), PendingRequestBase::CompareScoreGreater());
}
+ LLMutexTrylock lock3(mThread->mHeaderMutex);
+ LLMutexTrylock lock4(mThread->mPendingMutex);
while (!mPendingRequests.empty() && push_count > 0)
{
std::unique_ptr<PendingRequestBase>& req_p = mPendingRequests.front();