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

Segher Boessenkool <segher at gcc dot gnu.org> changed:

           What    |Removed                     |Added
----------------------------------------------------------------------------
             Status|NEW                         |RESOLVED
         Resolution|---                         |FIXED

--- Comment #3 from Segher Boessenkool <segher at gcc dot gnu.org> ---
After the fix for PR66217, this now is


foo:
        rldicl 4,4,0,32
        blr

bar:
0:      addis 2,12,.TOC.-0b@ha
        addi 2,2,.TOC.-0b@l
        .localentry     bar,.-bar
        mflr 0
        std 0,16(1)
        stdu 1,-64(1)
        bl foo
        addi 1,1,64
        ld 0,16(1)
        rldicl 4,4,0,32
        mtlr 0
        blr


which is sort of optimal (you could argue that the do-not-care parts of r4 do
not need to be cleared, after which it can tail-call).

I'm closing the bug.

Reply via email to