pipeline: only maintain breadcrumb for debug builds

This ensures we only add a static_breadcrumb pointer to every
CoglPipeline when build with debugging enabled. Since applications may
allocate a lot of pipelines we want to keep the basic size of pipelines
(ignoring optional sparse state) down to a minimum.

Reviewed-by: Neil Roberts <neil@linux.intel.com>

(cherry picked from commit 4716312e14bc253cd174a22b3db9d2c9cf031fa1)
This commit is contained in:
Robert Bragg
2013-05-30 15:42:35 +01:00
parent d264b30090
commit 2d24248a3c
3 changed files with 18 additions and 1 deletions

View File

@ -158,7 +158,12 @@ dump_pipeline_cb (CoglNode *node, void *user_data)
pipeline,
COGL_OBJECT (pipeline)->ref_count,
pipeline->has_static_breadcrumb ?
pipeline->static_breadcrumb : "NULL");
#ifdef COGL_DEBUG_ENABLED
pipeline->static_breadcrumb : "NULL"
#else
"NULL"
#endif
);
changes_label = g_string_new ("");
g_string_append_printf (changes_label,