Skip to content

[BUG] Stack spill in broadcast_lane (shufflev2) on SVE/2 #2166

@SadiinsoSnowfall

Description

@SadiinsoSnowfall

Codegen for has_equal_in on a pair of u16x4 (GCC15, SVE2-256):

test(eve::arm_sve256_v0::wide<unsigned short, eve::fixed<4l>>, eve::arm_sve256_v0::wide<unsigned short, eve::fixed<4l>>):
        sub     sp, sp, #720
        ptrue   p3.b, vl32
        mov     z3.d, d1
        add     x0, sp, 288
        st1h    z3.h, p3, [x0]
        ptrue   p0.h, vl4
        add     x0, sp, 672
        ldp     q30, q31, [sp, 288]
        stp     q30, q31, [sp, 672]
        ld1h    z2.h, p3/z, [x0]
        add     x0, sp, 432
        st1h    z2.h, p3, [x0]
        add     x0, sp, 672
        ldp     q30, q31, [sp, 432]
        stp     q30, q31, [sp, 672]
        ld1h    z1.h, p3/z, [x0]
        match   p0.h, p0/z, z0.h, z1.h
        add     sp, sp, 720
        ret

same thing but replacing the call to broadcast_lane with a call to shuffle (v1):

test(eve::arm_sve256_v0::wide<unsigned short, eve::fixed<4l>>, eve::arm_sve256_v0::wide<unsigned short, eve::fixed<4l>>):
        mov     z1.d, d1
        ptrue   p0.h, vl4
        match   p0.h, p0/z, z0.h, z1.h
        ret

Might be related to tuple manipulation again

Metadata

Metadata

Assignees

No one assigned

    Labels

    bugSomething isn't working

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions