diff options
author | Sergey Sharybin <sergey.vfx@gmail.com> | 2018-03-12 19:31:46 +0300 |
---|---|---|
committer | Sergey Sharybin <sergey.vfx@gmail.com> | 2018-03-12 19:31:46 +0300 |
commit | 733b9e4f99e8a0e7df8157284808a67cd901c4b6 (patch) | |
tree | eef6d6dbe9ddf73887702bcb31f6b855f12aa36b | |
parent | 8f4579affd3809aa7e21a8985b2c45ee2a655695 (diff) | |
parent | 629d44e0492ac63fda9533d1fba349813a0e49f2 (diff) |
Merge branch 'master' into blender2.8
-rw-r--r-- | source/blender/blenkernel/BKE_global.h | 16 | ||||
-rw-r--r-- | source/blender/blenloader/intern/readfile.c | 1 | ||||
-rw-r--r-- | source/blender/depsgraph/intern/eval/deg_eval.cc | 3 | ||||
-rw-r--r-- | source/blender/python/intern/bpy_app.c | 1 | ||||
-rw-r--r-- | source/creator/creator_args.c | 4 |
5 files changed, 18 insertions, 7 deletions
diff --git a/source/blender/blenkernel/BKE_global.h b/source/blender/blenkernel/BKE_global.h index 78d8271458d..2b670cdf9dd 100644 --- a/source/blender/blenkernel/BKE_global.h +++ b/source/blender/blenkernel/BKE_global.h @@ -125,13 +125,17 @@ enum { G_DEBUG_DEPSGRAPH_BUILD = (1 << 8), /* depsgraph construction messages */ G_DEBUG_DEPSGRAPH_EVAL = (1 << 9), /* depsgraph evaluation messages */ G_DEBUG_DEPSGRAPH_TAG = (1 << 10), /* depsgraph tagging messages */ - G_DEBUG_DEPSGRAPH_NO_THREADS = (1 << 11), /* single threaded depsgraph */ - G_DEBUG_DEPSGRAPH = (G_DEBUG_DEPSGRAPH_BUILD | G_DEBUG_DEPSGRAPH_EVAL | G_DEBUG_DEPSGRAPH_TAG), - G_DEBUG_SIMDATA = (1 << 12), /* sim debug data display */ - G_DEBUG_GPU_MEM = (1 << 13), /* gpu memory in status bar */ - G_DEBUG_GPU = (1 << 14), /* gpu debug */ + G_DEBUG_DEPSGRAPH_TIME = (1 << 11), /* depsgraph timing statistics and messages */ + G_DEBUG_DEPSGRAPH_NO_THREADS = (1 << 12), /* single threaded depsgraph */ + G_DEBUG_DEPSGRAPH = (G_DEBUG_DEPSGRAPH_BUILD | + G_DEBUG_DEPSGRAPH_EVAL | + G_DEBUG_DEPSGRAPH_TAG | + G_DEBUG_DEPSGRAPH_TIME), + G_DEBUG_SIMDATA = (1 << 13), /* sim debug data display */ + G_DEBUG_GPU_MEM = (1 << 14), /* gpu memory in status bar */ + G_DEBUG_GPU = (1 << 15), /* gpu debug */ G_DEBUG_IO = (1 << 13), /* IO Debugging (for Collada, ...)*/ - G_DEBUG_GPU_SHADERS = (1 << 15), /* GLSL shaders */ + G_DEBUG_GPU_SHADERS = (1 << 16), /* GLSL shaders */ }; #define G_DEBUG_ALL (G_DEBUG | G_DEBUG_FFMPEG | G_DEBUG_PYTHON | G_DEBUG_EVENTS | G_DEBUG_WM | G_DEBUG_JOBS | \ diff --git a/source/blender/blenloader/intern/readfile.c b/source/blender/blenloader/intern/readfile.c index af97aeb8fc0..21eccaff168 100644 --- a/source/blender/blenloader/intern/readfile.c +++ b/source/blender/blenloader/intern/readfile.c @@ -8524,6 +8524,7 @@ static BHead *read_libblock(FileData *fd, Main *main, BHead *bhead, const short id->icon_id = 0; id->newid = NULL; /* Needed because .blend may have been saved with crap value here... */ id->orig_id = NULL; + id->recalc = 0; /* this case cannot be direct_linked: it's just the ID part */ if (bhead->code == ID_ID) { diff --git a/source/blender/depsgraph/intern/eval/deg_eval.cc b/source/blender/depsgraph/intern/eval/deg_eval.cc index c3aa84943d3..a8fa73654a4 100644 --- a/source/blender/depsgraph/intern/eval/deg_eval.cc +++ b/source/blender/depsgraph/intern/eval/deg_eval.cc @@ -234,6 +234,7 @@ void deg_evaluate_on_refresh(EvaluationContext *eval_ctx, if (BLI_gset_len(graph->entry_tags) == 0) { return; } + const bool do_time_debug = ((G.debug & G_DEBUG_DEPSGRAPH_TIME) != 0); /* Set time for the current graph evaluation context. */ TimeSourceDepsNode *time_src = graph->find_time_source(); eval_ctx->depsgraph = (::Depsgraph *)graph; @@ -243,7 +244,7 @@ void deg_evaluate_on_refresh(EvaluationContext *eval_ctx, DepsgraphEvalState state; state.eval_ctx = eval_ctx; state.graph = graph; - state.do_stats = (G.debug_value != 0); + state.do_stats = do_time_debug; /* Set up task scheduler and pull for threaded evaluation. */ TaskScheduler *task_scheduler; bool need_free_scheduler; diff --git a/source/blender/python/intern/bpy_app.c b/source/blender/python/intern/bpy_app.c index c5ff2592746..ec77dc07ba7 100644 --- a/source/blender/python/intern/bpy_app.c +++ b/source/blender/python/intern/bpy_app.c @@ -360,6 +360,7 @@ static PyGetSetDef bpy_app_getsets[] = { {(char *)"debug_depsgraph_build", bpy_app_debug_get, bpy_app_debug_set, (char *)bpy_app_debug_doc, (void *)G_DEBUG_DEPSGRAPH_BUILD}, {(char *)"debug_depsgraph_eval", bpy_app_debug_get, bpy_app_debug_set, (char *)bpy_app_debug_doc, (void *)G_DEBUG_DEPSGRAPH_EVAL}, {(char *)"debug_depsgraph_tag", bpy_app_debug_get, bpy_app_debug_set, (char *)bpy_app_debug_doc, (void *)G_DEBUG_DEPSGRAPH_TAG}, + {(char *)"debug_depsgraph_time", bpy_app_debug_get, bpy_app_debug_set, (char *)bpy_app_debug_doc, (void *)G_DEBUG_DEPSGRAPH_TIME}, {(char *)"debug_simdata", bpy_app_debug_get, bpy_app_debug_set, (char *)bpy_app_debug_doc, (void *)G_DEBUG_SIMDATA}, {(char *)"debug_gpumem", bpy_app_debug_get, bpy_app_debug_set, (char *)bpy_app_debug_doc, (void *)G_DEBUG_GPU_MEM}, diff --git a/source/creator/creator_args.c b/source/creator/creator_args.c index 6106f55c212..f5ec13fc0df 100644 --- a/source/creator/creator_args.c +++ b/source/creator/creator_args.c @@ -753,6 +753,8 @@ static const char arg_handle_debug_mode_generic_set_doc_depsgraph_build[] = "\n\tEnable debug messages from dependency graph related on graph construction."; static const char arg_handle_debug_mode_generic_set_doc_depsgraph_tag[] = "\n\tEnable debug messages from dependency graph related on tagging."; +static const char arg_handle_debug_mode_generic_set_doc_depsgraph_time[] = +"\n\tEnable debug messages from dependency graph related on timing."; static const char arg_handle_debug_mode_generic_set_doc_depsgraph_eval[] = "\n\tEnable debug messages from dependency graph related on evaluation."; static const char arg_handle_debug_mode_generic_set_doc_depsgraph_no_threads[] = @@ -1848,6 +1850,8 @@ void main_args_setup(bContext *C, bArgs *ba, SYS_SystemHandle *syshandle) CB_EX(arg_handle_debug_mode_generic_set, depsgraph_eval), (void *)G_DEBUG_DEPSGRAPH_EVAL); BLI_argsAdd(ba, 1, NULL, "--debug-depsgraph-tag", CB_EX(arg_handle_debug_mode_generic_set, depsgraph_tag), (void *)G_DEBUG_DEPSGRAPH_TAG); + BLI_argsAdd(ba, 1, NULL, "--debug-depsgraph-time", + CB_EX(arg_handle_debug_mode_generic_set, depsgraph_time), (void *)G_DEBUG_DEPSGRAPH_TIME); BLI_argsAdd(ba, 1, NULL, "--debug-depsgraph-no-threads", CB_EX(arg_handle_debug_mode_generic_set, depsgraph_no_threads), (void *)G_DEBUG_DEPSGRAPH_NO_THREADS); BLI_argsAdd(ba, 1, NULL, "--debug-gpumem", |