https://gcc.gnu.org/bugzilla/show_bug.cgi?id=104954
--- Comment #3 from David Malcolm <dmalcolm at gcc dot gnu.org> --- I'm also seeing states with dozens of bindings for touched regions for __UNIQUE_ID_ddebugN for various N: VVVVVVVVVVVVVVVVVVVVVVVVVVVVVVVVVVVVVVVVVVVVVVVVVVVVVVVVVVVVVVVVVVVVVVVVVVVV clusters within :: {, region: {__UNIQUE_ID_ddebug277, value: CONJURED(D.56070 = bw_int_to_fixed_nonconst (value_4(D));, __UNIQUE_ID_ddebug277) (ESCAPED) (TOUCHED)}, region: {__UNIQUE_ID_ddebug278, value: CONJURED(D.56070 = bw_int_to_fixed_nonconst (value_4(D));, __UNIQUE_ID_ddebug278) (ESCAPED) (TOUCHED)}, region: {__UNIQUE_ID_ddebug279, value: CONJURED(D.56070 = bw_int_to_fixed_nonconst (value_4(D));, __UNIQUE_ID_ddebug279) (ESCAPED) (TOUCHED)}, region: {__UNIQUE_ID_ddebug280, value: CONJURED(D.56070 = bw_int_to_fixed_nonconst (value_4(D));, __UNIQUE_ID_ddebug280) (ESCAPED) (TOUCHED)}, region: {__UNIQUE_ID_ddebug281, value: CONJURED(D.56070 = bw_int_to_fixed_nonconst (value_4(D));, __UNIQUE_ID_ddebug281) (ESCAPED) (TOUCHED)}, region: {__UNIQUE_ID_ddebug282, value: CONJURED(D.56070 = bw_int_to_fixed_nonconst (value_4(D));, __UNIQUE_ID_ddebug282) (ESCAPED) (TOUCHED)}, region: {__UNIQUE_ID_ddebug283, value: CONJURED(D.56070 = bw_int_to_fixed_nonconst (value_4(D));, __UNIQUE_ID_ddebug283) (ESCAPED) (TOUCHED)}, region: {__UNIQUE_ID_ddebug284, value: CONJURED(D.56070 = bw_int_to_fixed_nonconst (value_4(D));, __UNIQUE_ID_ddebug284) (ESCAPED) (TOUCHED)}, region: {__UNIQUE_ID_ddebug285, value: CONJURED(D.56070 = bw_int_to_fixed_nonconst (value_4(D));, __UNIQUE_ID_ddebug285) (ESCAPED) (TOUCHED)}, region: {__UNIQUE_ID_ddebug286, value: CONJURED(D.56070 = bw_int_to_fixed_nonconst (value_4(D));, __UNIQUE_ID_ddebug286) (ESCAPED) (TOUCHED)}, region: {__UNIQUE_ID_ddebug287, value: CONJURED(D.56070 = bw_int_to_fixed_nonconst (value_4(D));, __UNIQUE_ID_ddebug287) (ESCAPED) (TOUCHED)}, region: {__UNIQUE_ID_ddebug288, value: CONJURED(D.56070 = bw_int_to_fixed_nonconst (value_4(D));, __UNIQUE_ID_ddebug288) (ESCAPED) (TOUCHED)}, region: {__UNIQUE_ID_ddebug289, value: CONJURED(D.56070 = bw_int_to_fixed_nonconst (value_4(D));, __UNIQUE_ID_ddebug289) (ESCAPED) (TOUCHED)}, region: {__UNIQUE_ID_ddebug290, value: CONJURED(D.56070 = bw_int_to_fixed_nonconst (value_4(D));, __UNIQUE_ID_ddebug290) (ESCAPED) (TOUCHED)}, region: {__UNIQUE_ID_ddebug291, value: CONJURED(D.56070 = bw_int_to_fixed_nonconst (value_4(D));, __UNIQUE_ID_ddebug291) (ESCAPED) (TOUCHED)}, region: {__UNIQUE_ID_ddebug292, value: CONJURED(D.56070 = bw_int_to_fixed_nonconst (value_4(D));, __UNIQUE_ID_ddebug292) (ESCAPED) (TOUCHED)}, region: {__UNIQUE_ID_ddebug293, value: CONJURED(D.56070 = bw_int_to_fixed_nonconst (value_4(D));, __UNIQUE_ID_ddebug293) (ESCAPED) (TOUCHED)}, region: {__UNIQUE_ID_ddebug294, value: CONJURED(D.56070 = bw_int_to_fixed_nonconst (value_4(D));, __UNIQUE_ID_ddebug294) (ESCAPED) (TOUCHED)}, region: {__UNIQUE_ID_ddebug295, value: CONJURED(D.56070 = bw_int_to_fixed_nonconst (value_4(D));, __UNIQUE_ID_ddebug295) (ESCAPED) (TOUCHED)}, region: {__UNIQUE_ID_ddebug296, value: CONJURED(D.56070 = bw_int_to_fixed_nonconst (value_4(D));, __UNIQUE_ID_ddebug296) (ESCAPED) (TOUCHED)}, region: {__UNIQUE_ID_ddebug297, value: CONJURED(D.56070 = bw_int_to_fixed_nonconst (value_4(D));, __UNIQUE_ID_ddebug297) (ESCAPED) (TOUCHED)}, region: {__UNIQUE_ID_ddebug298, value: CONJURED(D.56070 = bw_int_to_fixed_nonconst (value_4(D));, __UNIQUE_ID_ddebug298) (ESCAPED) (TOUCHED)}, region: {__UNIQUE_ID_ddebug299, value: CONJURED(D.56070 = bw_int_to_fixed_nonconst (value_4(D));, __UNIQUE_ID_ddebug299) (ESCAPED) (TOUCHED)}, region: {__UNIQUE_ID_ddebug300, value: CONJURED(D.56070 = bw_int_to_fixed_nonconst (value_4(D));, __UNIQUE_ID_ddebug300) (ESCAPED) (TOUCHED)}, region: {__UNIQUE_ID_ddebug301, value: CONJURED(D.56070 = bw_int_to_fixed_nonconst (value_4(D));, __UNIQUE_ID_ddebug301) (ESCAPED) (TOUCHED)}, region: {__UNIQUE_ID_ddebug302, value: CONJURED(D.56070 = bw_int_to_fixed_nonconst (value_4(D));, __UNIQUE_ID_ddebug302) (ESCAPED) (TOUCHED)}, region: {__UNIQUE_ID_ddebug303, value: CONJURED(D.56070 = bw_int_to_fixed_nonconst (value_4(D));, __UNIQUE_ID_ddebug303) (ESCAPED) (TOUCHED)}, region: {__UNIQUE_ID_ddebug304, value: CONJURED(D.56070 = bw_int_to_fixed_nonconst (value_4(D));, __UNIQUE_ID_ddebug304) (ESCAPED) (TOUCHED)}, region: {__UNIQUE_ID_ddebug305, value: CONJURED(D.56070 = bw_int_to_fixed_nonconst (value_4(D));, __UNIQUE_ID_ddebug305) (ESCAPED) (TOUCHED)}, region: {__UNIQUE_ID_ddebug306, value: CONJURED(D.56070 = bw_int_to_fixed_nonconst (value_4(D));, __UNIQUE_ID_ddebug306) (ESCAPED) (TOUCHED)}, region: {__UNIQUE_ID_ddebug307, value: CONJURED(D.56070 = bw_int_to_fixed_nonconst ( ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ where these seem to be coming from macro expansions of debug logging like this: VVVVVVVVVVVVVVVVVVVVVVVVVVVVVVVVVVVVVVVVVVVVVVVVVVVVVVVVVVVVVVVVVVVVVVVVVVVV static void print_bw_calcs_dceip(struct dc_context *ctx, const struct bw_calcs_dceip *dceip) { do { static struct _ddebug __attribute__((__aligned__(8))) __attribute__((__section__("__dyndbg"))) __UNIQUE_ID_ddebug277 = { .modname = "amdgpu", .function = __func__, .filename = "drivers/gpu/drm/amd/amdgpu/../display/dc/calcs/calcs_logger.h", .format = ("[BANDWIDTH_CALCS]:" "###########################################################" "##########"), .lineno = 33, .flags = 0, .key.dd_key_false = ((struct static_key_false){ .key = {.enabled = {0}, {.entries = (void *)0UL}}, })}; if (({ bool branch; if (__builtin_types_compatible_p( typeof(*&__UNIQUE_ID_ddebug277.key.dd_key_false), struct static_key_true)) branch = arch_static_branch_jump( &(&__UNIQUE_ID_ddebug277.key.dd_key_false)->key, false); else if (__builtin_types_compatible_p( typeof(*&__UNIQUE_ID_ddebug277.key.dd_key_false), struct static_key_false)) branch = arch_static_branch( &(&__UNIQUE_ID_ddebug277.key.dd_key_false)->key, false); else branch = ____wrong_branch_error(); __builtin_expect(!!(branch), 0); })) __dynamic_pr_debug(&__UNIQUE_ID_ddebug277, "[BANDWIDTH_CALCS]:" "#####################################################" "################"); } while (0); ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ and there are a *lot* of these. Each of these calls to __dynamic_pr_debug escapes the region, so each of these escaped regions gets clobbered by every unknown function. VVVVVVVVVVVVVVVVVVVVVVVVVVVVVVVVVVVVVVVVVVVVVVVVVVVVVVVVVVVVVVVVVVVVVVVVVVVV extern __attribute__((__format__(printf, 2, 3))) void __dynamic_pr_debug(struct _ddebug *descriptor, const char *fmt, ...); ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ (should this take a const descriptor???) We're effectively accumulating the set of all of these that have ever escaped, and combining that with the set of unknown functions that have been called, and generating a complicated matrix of values, none of which we care about; the contents are completely uninteresting. I've experimented with fixing this by simply not bothering to track regions for decls with a non-NULL DECL_SECTION_NAME, which eliminates the bindings above, but it doesn't seem to help much with the timing (still seeing lots of the comment #2 material).