summaryrefslogtreecommitdiff
path: root/indra/newview/lldrawable.cpp
diff options
context:
space:
mode:
authorDave Parks <davep@lindenlab.com>2009-12-16 09:26:53 -0600
committerDave Parks <davep@lindenlab.com>2009-12-16 09:26:53 -0600
commitc6aaf115ade4b335df9ca479992b08e028ffd910 (patch)
tree3a126f9f3af41fd21ee326669e60922c333f55ad /indra/newview/lldrawable.cpp
parentb6af8aae5b0cccfb6653d84e2020557c2be945ce (diff)
Quick 'n dirty prioritization scheme for mesh loading.
Sprinkling of fast timers in areas that are likely to stall.
Diffstat (limited to 'indra/newview/lldrawable.cpp')
-rw-r--r--indra/newview/lldrawable.cpp22
1 files changed, 16 insertions, 6 deletions
diff --git a/indra/newview/lldrawable.cpp b/indra/newview/lldrawable.cpp
index d60330024a..9a3be975cd 100644
--- a/indra/newview/lldrawable.cpp
+++ b/indra/newview/lldrawable.cpp
@@ -189,20 +189,30 @@ BOOL LLDrawable::isLight() const
}
}
+static LLFastTimer::DeclareTimer FTM_CLEANUP_DRAWABLE("Cleanup Drawable");
+static LLFastTimer::DeclareTimer FTM_DEREF_DRAWABLE("Deref");
+static LLFastTimer::DeclareTimer FTM_DELETE_FACES("Faces");
+
void LLDrawable::cleanupReferences()
{
- LLFastTimer t(FTM_PIPELINE);
+ LLFastTimer t(FTM_CLEANUP_DRAWABLE);
- std::for_each(mFaces.begin(), mFaces.end(), DeletePointer());
- mFaces.clear();
+ {
+ LLFastTimer t(FTM_DELETE_FACES);
+ std::for_each(mFaces.begin(), mFaces.end(), DeletePointer());
+ mFaces.clear();
+ }
gObjectList.removeDrawable(this);
gPipeline.unlinkDrawable(this);
- // Cleanup references to other objects
- mVObjp = NULL;
- mParent = NULL;
+ {
+ LLFastTimer t(FTM_DEREF_DRAWABLE);
+ // Cleanup references to other objects
+ mVObjp = NULL;
+ mParent = NULL;
+ }
}
void LLDrawable::cleanupDeadDrawables()