From 2cb09dd4a828756dce6180505c63851aa9875187 Mon Sep 17 00:00:00 2001 From: Nat Goodspeed Date: Thu, 7 Oct 2021 11:53:45 -0400 Subject: SL-16024: Return shared_ptr from LLInstanceTracker::getInstance(). It feels wrong to return a dumb LLInstanceTracker subclass* from getInstance() when we use std::shared_ptr and std::weak_ptr internally. But tweak consumers to use 'auto' or LLInstanceTracker::ptr_t in case we later revisit this decision. We did add a couple get() calls where it's important to obtain a dumb pointer. --- indra/llxml/llcontrol.h | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) (limited to 'indra/llxml') diff --git a/indra/llxml/llcontrol.h b/indra/llxml/llcontrol.h index 19508becc3..5da13f5010 100644 --- a/indra/llxml/llcontrol.h +++ b/indra/llxml/llcontrol.h @@ -405,8 +405,8 @@ public: const T& default_value, const std::string& comment = "Declared In Code") { - mCachedControlPtr = LLControlCache::getInstance(name); - if (mCachedControlPtr.isNull()) + mCachedControlPtr = LLControlCache::getInstance(name).get(); + if (! mCachedControlPtr) { mCachedControlPtr = new LLControlCache(group, name, default_value, comment); } @@ -415,8 +415,8 @@ public: LLCachedControl(LLControlGroup& group, const std::string& name) { - mCachedControlPtr = LLControlCache::getInstance(name); - if (mCachedControlPtr.isNull()) + mCachedControlPtr = LLControlCache::getInstance(name).get(); + if (! mCachedControlPtr) { mCachedControlPtr = new LLControlCache(group, name); } -- cgit v1.2.3 From 28f9fb06a9f4cb9edccb2ff8132c7f6a9b27c060 Mon Sep 17 00:00:00 2001 From: Dave Parks Date: Sat, 20 Nov 2021 18:49:19 +0000 Subject: SL-16289 Rigged mesh rendering overhaul --- indra/llxml/llcontrol.h | 1 + 1 file changed, 1 insertion(+) (limited to 'indra/llxml') diff --git a/indra/llxml/llcontrol.h b/indra/llxml/llcontrol.h index 5da13f5010..088502c017 100644 --- a/indra/llxml/llcontrol.h +++ b/indra/llxml/llcontrol.h @@ -247,6 +247,7 @@ public: // generic getter template T get(const std::string& name) { + LL_PROFILE_ZONE_SCOPED; LLControlVariable* control = getControl(name); LLSD value; eControlType type = TYPE_COUNT; -- cgit v1.2.3 From 3a9ce9f22667cf3e0a1d6def9c478a66310ef0ad Mon Sep 17 00:00:00 2001 From: Ptolemy Date: Thu, 13 Jan 2022 12:19:23 -0800 Subject: SL-16606: Add profiler category LLSD --- indra/llxml/llcontrol.h | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) (limited to 'indra/llxml') diff --git a/indra/llxml/llcontrol.h b/indra/llxml/llcontrol.h index 088502c017..0839c02c50 100644 --- a/indra/llxml/llcontrol.h +++ b/indra/llxml/llcontrol.h @@ -247,7 +247,7 @@ public: // generic getter template T get(const std::string& name) { - LL_PROFILE_ZONE_SCOPED; + LL_PROFILE_ZONE_SCOPED_CATEGORY_LLSD; LLControlVariable* control = getControl(name); LLSD value; eControlType type = TYPE_COUNT; -- cgit v1.2.3