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

--- Comment #5 from Alan Modra <amodra at gmail dot com> ---
Right, the problem is
 .set    _Z8test_barv.localalias.0,_Z8test_barv

or really, using that alias here (-O2 -fpic)
        .globl  _Z8test_foov
        .type   _Z8test_foov, @function
_Z8test_foov:
.LFB5:
        .cfi_startproc
        jmp     _Z8test_barv.localalias.0
        .cfi_endproc
.LFE5:
        .size   _Z8test_foov, .-_Z8test_foov

You shouldn't be using the alias for a call where TARGET_BINDS_LOCAL_P (see
gcc/doc/tm.texi, varasm.c:default_binds_local_p) is not true.

Reply via email to