summaryrefslogtreecommitdiff
path: root/indra/llcommon
diff options
context:
space:
mode:
authorBrad Payne (Vir Linden) <vir@lindenlab.com>2019-10-16 22:24:03 +0100
committerBrad Payne (Vir Linden) <vir@lindenlab.com>2019-10-16 22:24:03 +0100
commitc7747d2a1bba6ac62e9b540a283ae2c9f4bfd221 (patch)
tree8c6b6b564b80a0f2b0ad774f64f9fc9a1c50b7d5 /indra/llcommon
parentcc3cf17e5e335b6e78d86755e015161ab92c50db (diff)
parent33821bd599d1d9171cc93c38a2bc6c4ab6772c9a (diff)
merge
Diffstat (limited to 'indra/llcommon')
-rw-r--r--indra/llcommon/llfasttimer.h10
-rw-r--r--indra/llcommon/llmortician.cpp36
-rw-r--r--indra/llcommon/llmortician.h2
3 files changed, 41 insertions, 7 deletions
diff --git a/indra/llcommon/llfasttimer.h b/indra/llcommon/llfasttimer.h
index 2024d707da..d463fc9d65 100644
--- a/indra/llcommon/llfasttimer.h
+++ b/indra/llcommon/llfasttimer.h
@@ -199,14 +199,10 @@ private:
friend BlockTimer timeThisBlock(BlockTimerStatHandle&);
BlockTimer(BlockTimerStatHandle& timer);
-#if !defined(MSC_VER) || MSC_VER < 1700
- // Visual Studio 2010 has a bug where capturing an object returned by value
- // into a local reference requires access to the copy constructor at the call site.
- // This appears to be fixed in 2012.
-public:
-#endif
+
// no-copy
- BlockTimer(const BlockTimer& other) {};
+ BlockTimer(const BlockTimer& other);
+ BlockTimer& operator=(const BlockTimer& other);
private:
U64 mStartTime;
diff --git a/indra/llcommon/llmortician.cpp b/indra/llcommon/llmortician.cpp
index 287f096eae..93c7d520f2 100644
--- a/indra/llcommon/llmortician.cpp
+++ b/indra/llcommon/llmortician.cpp
@@ -37,6 +37,42 @@ LLMortician::~LLMortician()
sGraveyard.remove(this);
}
+U32 LLMortician::logClass(std::stringstream &str)
+{
+ U32 size = sGraveyard.size();
+ str << "Mortician graveyard count: " << size;
+ str << " Zealous: " << (sDestroyImmediate ? "True" : "False");
+ if (size == 0)
+ {
+ return size;
+ }
+ str << " Output:\n";
+ std::list<LLMortician*>::iterator iter = sGraveyard.begin();
+ std::list<LLMortician*>::iterator end = sGraveyard.end();
+ while (iter!=end)
+ {
+ LLMortician* dead = *iter;
+ iter++;
+ // Be as detailed and safe as possible to figure out issues
+ str << "Pointer: " << dead;
+ if (dead)
+ {
+ try
+ {
+ str << " Is dead: " << (dead->isDead() ? "True" : "False");
+ str << " Name: " << typeid(*dead).name();
+ }
+ catch (...)
+ {
+
+ }
+ }
+ str << "\n";
+ }
+ str << "--------------------------------------------";
+ return size;
+}
+
void LLMortician::updateClass()
{
while (!sGraveyard.empty())
diff --git a/indra/llcommon/llmortician.h b/indra/llcommon/llmortician.h
index 9517e2db5e..41cb49fab1 100644
--- a/indra/llcommon/llmortician.h
+++ b/indra/llcommon/llmortician.h
@@ -34,6 +34,8 @@ class LL_COMMON_API LLMortician
{
public:
LLMortician() { mIsDead = FALSE; }
+ static U32 graveyardCount() { return sGraveyard.size(); };
+ static U32 logClass(std::stringstream &str);
static void updateClass();
virtual ~LLMortician();
void die();