https://gcc.gnu.org/bugzilla/show_bug.cgi?id=114043

Richard Biener <rguenth at gcc dot gnu.org> changed:

           What    |Removed                     |Added
----------------------------------------------------------------------------
     Ever confirmed|0                           |1
                 CC|                            |hubicka at gcc dot gnu.org
   Last reconfirmed|                            |2024-02-22
             Status|UNCONFIRMED                 |NEW

--- Comment #1 from Richard Biener <rguenth at gcc dot gnu.org> ---
Confirmed.  Doesn't happen w/o -fstrict-enums (huh).

(gdb) p debug_tree (t)
 <function_decl 0x7ffff71c0600 __ct_comp 
    type <method_type 0x7ffff71bdf18
        type <void_type 0x7ffff702ff18 void VOID
            align:8 warn_if_not_align:0 symtab:0 alias-set -1 canonical-type
0x7ffff702ff18
            pointer_to_this <pointer_type 0x7ffff7036000>>
        QI
        size <integer_cst 0x7ffff70292b8 constant 8>
        unit-size <integer_cst 0x7ffff70292d0 constant 1>
        align:8 warn_if_not_align:0 symtab:0 alias-set -1 canonical-type
0x7ffff71bdf18 method basetype <record_type 0x7ffff71bdbd0 OverflowSafeInt>
        arg-types <tree_list 0x7ffff71b7de8 value <pointer_type 0x7ffff71da9d8>
            chain <tree_list 0x7ffff71b7dc0 value <integer_type 0x7ffff702f738
long int>
                chain <tree_list 0x7ffff7024d98 value <void_type 0x7ffff702ff18
void>>>>
        pointer_to_this <pointer_type 0x7ffff71da540>>
    addressable used nothrow public static weak autoinline decl_5 QI t.ii:3:3
align:16 warn_if_not_align:0 context <translation_unit_decl 0x7ffff7018168
t.ii> initial <error_mark 0x7ffff70291b0> chain <type_decl 0x7ffff703ec78
OverflowSafeInt>>

that's the OverflowSafeInt(long) {} CTOR.  We have cgraph_node::get
(t)->definition == 0.

It might be the --param disables some important cgraph initialization
(edges rebuild?).  But not sure where -fstric-enums comes into play.

Reply via email to