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

--- Comment #1 from Andrew Pinski <pinskia at gcc dot gnu.org> ---
LLVM trunk produces the similar code as GCC trunk:
LLVM:
        stp     x29, x30, [sp, #-16]!
        mov     x29, sp
        adrp    x8, :got:f1
        ldr     x8, [x8, :got_lo12:f1]
        blr     x8
        adrp    x8, :got:f2
        ldr     x8, [x8, :got_lo12:f2]

vs GCC
        stp     x29, x30, [sp, -16]!
        adrp    x0, _GLOBAL_OFFSET_TABLE_
        mov     x29, sp
        ldr     x0, [x0, #:gotpage_lo15:f1]
        blr     x0
        adrp    x0, _GLOBAL_OFFSET_TABLE_
        ldr     x0, [x0, #:gotpage_lo15:f2]
        blr     x0

Reply via email to