Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
i#3044 AArch64 SVE codec: fix scalar+immediate LD/ST offsets (#6390)
All SVE scalar+immediate LD[1234]/ST[1234] have a signed 4-bit immediate value that encodes a vector index offset from the base register. This value was being used directly in the IR for instructions, however base+disp memory operands should always use a byte displacement. This changes the codec to use byte displacements in the IR and updates the codec unit tests accordingly. The following instructions are updated: LD1B { <Zt>.B }, <Pg>/Z, [<Xn|SP>{, #<simm>, MUL VL}] LD1B { <Zt>.H }, <Pg>/Z, [<Xn|SP>{, #<simm>, MUL VL}] LD1B { <Zt>.S }, <Pg>/Z, [<Xn|SP>{, #<simm>, MUL VL}] LD1B { <Zt>.D }, <Pg>/Z, [<Xn|SP>{, #<simm>, MUL VL}] LD1D { <Zt>.D }, <Pg>/Z, [<Xn|SP>{, #<simm>, MUL VL}] LD1H { <Zt>.H }, <Pg>/Z, [<Xn|SP>{, #<simm>, MUL VL}] LD1H { <Zt>.S }, <Pg>/Z, [<Xn|SP>{, #<simm>, MUL VL}] LD1H { <Zt>.D }, <Pg>/Z, [<Xn|SP>{, #<simm>, MUL VL}] LD1SB { <Zt>.D }, <Pg>/Z, [<Xn|SP>{, #<simm>, MUL VL}] LD1SB { <Zt>.S }, <Pg>/Z, [<Xn|SP>{, #<simm>, MUL VL}] LD1SB { <Zt>.H }, <Pg>/Z, [<Xn|SP>{, #<simm>, MUL VL}] LD1SH { <Zt>.D }, <Pg>/Z, [<Xn|SP>{, #<simm>, MUL VL}] LD1SH { <Zt>.S }, <Pg>/Z, [<Xn|SP>{, #<simm>, MUL VL}] LD1SW { <Zt>.D }, <Pg>/Z, [<Xn|SP>{, #<simm>, MUL VL}] LD1W { <Zt>.S }, <Pg>/Z, [<Xn|SP>{, #<simm>, MUL VL}] LD1W { <Zt>.D }, <Pg>/Z, [<Xn|SP>{, #<simm>, MUL VL}] LD2B { <Zt1>.B, <Zt2>.B }, <Pg>/Z, [<Xn|SP>{, #<simm>, MUL VL}] LD2D { <Zt1>.D, <Zt2>.D }, <Pg>/Z, [<Xn|SP>{, #<simm>, MUL VL}] LD2H { <Zt1>.H, <Zt2>.H }, <Pg>/Z, [<Xn|SP>{, #<simm>, MUL VL}] LD2W { <Zt1>.S, <Zt2>.S }, <Pg>/Z, [<Xn|SP>{, #<simm>, MUL VL}] LD3B { <Zt1>.B, <Zt2>.B, <Zt3>.B }, <Pg>/Z, [<Xn|SP>{, #<simm>, MUL VL}] LD3D { <Zt1>.D, <Zt2>.D, <Zt3>.D }, <Pg>/Z, [<Xn|SP>{, #<simm>, MUL VL}] LD3H { <Zt1>.H, <Zt2>.H, <Zt3>.H }, <Pg>/Z, [<Xn|SP>{, #<simm>, MUL VL}] LD3W { <Zt1>.S, <Zt2>.S, <Zt3>.S }, <Pg>/Z, [<Xn|SP>{, #<simm>, MUL VL}] LD4B { <Zt1>.B, <Zt2>.B, <Zt3>.B, <Zt4>.B }, <Pg>/Z, [<Xn|SP>{, #<simm>, MUL VL}] LD4D { <Zt1>.D, <Zt2>.D, <Zt3>.D, <Zt4>.D }, <Pg>/Z, [<Xn|SP>{, #<simm>, MUL VL}] LD4H { <Zt1>.H, <Zt2>.H, <Zt3>.H, <Zt4>.H }, <Pg>/Z, [<Xn|SP>{, #<simm>, MUL VL}] LD4W { <Zt1>.S, <Zt2>.S, <Zt3>.S, <Zt4>.S }, <Pg>/Z, [<Xn|SP>{, #<simm>, MUL VL}] LDNF1B { <Zt>.B }, <Pg>/Z, [<Xn|SP>{, #<simm>, MUL VL}] LDNF1B { <Zt>.H }, <Pg>/Z, [<Xn|SP>{, #<simm>, MUL VL}] LDNF1B { <Zt>.S }, <Pg>/Z, [<Xn|SP>{, #<simm>, MUL VL}] LDNF1B { <Zt>.D }, <Pg>/Z, [<Xn|SP>{, #<simm>, MUL VL}] LDNF1D { <Zt>.D }, <Pg>/Z, [<Xn|SP>{, #<simm>, MUL VL}] LDNF1H { <Zt>.H }, <Pg>/Z, [<Xn|SP>{, #<simm>, MUL VL}] LDNF1H { <Zt>.S }, <Pg>/Z, [<Xn|SP>{, #<simm>, MUL VL}] LDNF1H { <Zt>.D }, <Pg>/Z, [<Xn|SP>{, #<simm>, MUL VL}] LDNF1SB { <Zt>.D }, <Pg>/Z, [<Xn|SP>{, #<simm>, MUL VL}] LDNF1SB { <Zt>.S }, <Pg>/Z, [<Xn|SP>{, #<simm>, MUL VL}] LDNF1SB { <Zt>.H }, <Pg>/Z, [<Xn|SP>{, #<simm>, MUL VL}] LDNF1SH { <Zt>.D }, <Pg>/Z, [<Xn|SP>{, #<simm>, MUL VL}] LDNF1SH { <Zt>.S }, <Pg>/Z, [<Xn|SP>{, #<simm>, MUL VL}] LDNF1SW { <Zt>.D }, <Pg>/Z, [<Xn|SP>{, #<simm>, MUL VL}] LDNF1W { <Zt>.S }, <Pg>/Z, [<Xn|SP>{, #<simm>, MUL VL}] LDNF1W { <Zt>.D }, <Pg>/Z, [<Xn|SP>{, #<simm>, MUL VL}] LDNT1B { <Zt>.B }, <Pg>/Z, [<Xn|SP>{, #<simm>, MUL VL}] LDNT1D { <Zt>.D }, <Pg>/Z, [<Xn|SP>{, #<simm>, MUL VL}] LDNT1H { <Zt>.H }, <Pg>/Z, [<Xn|SP>{, #<simm>, MUL VL}] LDNT1W { <Zt>.S }, <Pg>/Z, [<Xn|SP>{, #<simm>, MUL VL}] ST1B { <Zt>.<T> }, <Pg>, [<Xn|SP>{, #<simm>, MUL VL}] ST1D { <Zt>.D }, <Pg>, [<Xn|SP>{, #<simm>, MUL VL}] ST1H { <Zt>.<T> }, <Pg>, [<Xn|SP>{, #<simm>, MUL VL}] ST1W { <Zt>.<T> }, <Pg>, [<Xn|SP>{, #<simm>, MUL VL}] ST2B { <Zt1>.B, <Zt2>.B }, <Pg>, [<Xn|SP>{, #<simm>, MUL VL}] ST2D { <Zt1>.D, <Zt2>.D }, <Pg>, [<Xn|SP>{, #<simm>, MUL VL}] ST2H { <Zt1>.H, <Zt2>.H }, <Pg>, [<Xn|SP>{, #<simm>, MUL VL}] ST2W { <Zt1>.S, <Zt2>.S }, <Pg>, [<Xn|SP>{, #<simm>, MUL VL}] ST3B { <Zt1>.B, <Zt2>.B, <Zt3>.B }, <Pg>, [<Xn|SP>{, #<simm>, MUL VL}] ST3D { <Zt1>.D, <Zt2>.D, <Zt3>.D }, <Pg>, [<Xn|SP>{, #<simm>, MUL VL}] ST3H { <Zt1>.H, <Zt2>.H, <Zt3>.H }, <Pg>, [<Xn|SP>{, #<simm>, MUL VL}] ST3W { <Zt1>.S, <Zt2>.S, <Zt3>.S }, <Pg>, [<Xn|SP>{, #<simm>, MUL VL}] ST4B { <Zt1>.B, <Zt2>.B, <Zt3>.B, <Zt4>.B }, <Pg>, [<Xn|SP>{, #<simm>, MUL VL}] ST4D { <Zt1>.D, <Zt2>.D, <Zt3>.D, <Zt4>.D }, <Pg>, [<Xn|SP>{, #<simm>, MUL VL}] ST4H { <Zt1>.H, <Zt2>.H, <Zt3>.H, <Zt4>.H }, <Pg>, [<Xn|SP>{, #<simm>, MUL VL}] ST4W { <Zt1>.S, <Zt2>.S, <Zt3>.S, <Zt4>.S }, <Pg>, [<Xn|SP>{, #<simm>, MUL VL}] STNT1B { <Zt>.B }, <Pg>, [<Xn|SP>{, #<simm>, MUL VL}] STNT1D { <Zt>.D }, <Pg>, [<Xn|SP>{, #<simm>, MUL VL}] STNT1H { <Zt>.H }, <Pg>, [<Xn|SP>{, #<simm>, MUL VL}] STNT1W { <Zt>.S }, <Pg>, [<Xn|SP>{, #<simm>, MUL VL}] Issue: #3044
- Loading branch information