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

--- Comment #4 from GCC Commits <cvs-commit at gcc dot gnu.org> ---
The master branch has been updated by Nathaniel Shead <nsh...@gcc.gnu.org>:

https://gcc.gnu.org/g:4a8fd4a8ee3f83c330deb0dd494b27f66a748fb5

commit r16-2559-g4a8fd4a8ee3f83c330deb0dd494b27f66a748fb5
Author: Nathaniel Shead <nathanielosh...@gmail.com>
Date:   Thu Jul 24 09:41:00 2025 +1000

    Prevent mixups of IDENTIFIER_TRANSPARENT_ALIAS and IDENTIFIER_INTERNAL_P
better [PR120855]

    The assertion failure on ASM_OUTPUT_WEAKREF targets since my r16-1738
    was caused because the 'TREE_CHAIN (id)' check in assemble_name_resolve
    no longer implies that ID is a transparent alias, since internal
    identifiers can have a TREE_CHAIN as well.

    I still don't think it's possible for a transparent alias to be an
    internal identifier in the sense added, so this patch simply constrains
    the assertion better so that it doesn't fail spuriously.  I also added a
    couple of other assertions to help validate this assumption.

            PR middle-end/120855

    gcc/ChangeLog:

            * cgraphunit.cc (symbol_table::compile): Assert a transparent
            alias is not an internal identifier.
            * symtab.cc (symbol_table::change_decl_assembler_name):
            Likewise.
            * varasm.cc (assemble_name_resolve): Check for
            IDENTIFIER_TRANSPARENT_ALIAS instead of just TREE_CHAIN.

    Signed-off-by: Nathaniel Shead <nathanielosh...@gmail.com>
    Reviewed-by: Jason Merrill <ja...@redhat.com>
  • [Bug middle-end/120855] [16 Reg... cvs-commit at gcc dot gnu.org via Gcc-bugs

Reply via email to