[Bf-blender-cvs] [75cca8360f6] master: Outliner: Add commented out benchmarking calls for tree rebuilding
Julian Eisel
noreply at git.blender.org
Thu Aug 18 20:23:16 CEST 2022
Commit: 75cca8360f611f6b79b65228d18fd6597267417f
Author: Julian Eisel
Date: Thu Aug 18 19:18:55 2022 +0200
Branches: master
https://developer.blender.org/rB75cca8360f611f6b79b65228d18fd6597267417f
Outliner: Add commented out benchmarking calls for tree rebuilding
This way you can benchmark the tree rebuilding by simply commenting out
a single line. Not that it was difficult before, but this makes it as
easy as it gets, with basically no knowledge of existing benchmarking
tools required.
===================================================================
M source/blender/editors/space_outliner/outliner_tree.cc
===================================================================
diff --git a/source/blender/editors/space_outliner/outliner_tree.cc b/source/blender/editors/space_outliner/outliner_tree.cc
index 040bbb26be1..b3b2bb59e20 100644
--- a/source/blender/editors/space_outliner/outliner_tree.cc
+++ b/source/blender/editors/space_outliner/outliner_tree.cc
@@ -41,6 +41,7 @@
#include "BLI_fnmatch.h"
#include "BLI_listbase.h"
#include "BLI_mempool.h"
+#include "BLI_timeit.hh"
#include "BLI_utildefines.h"
#include "BLT_translation.h"
@@ -1698,6 +1699,10 @@ void outliner_build_tree(Main *mainvar,
return;
}
+ /* Enable for benchmarking. Starts a timer, results will be printed on function exit. */
+ // SCOPED_TIMER("Outliner Rebuild");
+ // SCOPED_TIMER_AVERAGED("Outliner Rebuild");
+
OutlinerTreeElementFocus focus;
outliner_store_scrolling_position(space_outliner, region, &focus);
More information about the Bf-blender-cvs
mailing list