Skip to content

Commit

Permalink
debug 2, #19
Browse files Browse the repository at this point in the history
  • Loading branch information
emmansun authored Oct 17, 2024
1 parent 14c05d4 commit 8928e54
Showing 1 changed file with 9 additions and 8 deletions.
17 changes: 9 additions & 8 deletions base64_s390x.s
Original file line number Diff line number Diff line change
Expand Up @@ -49,6 +49,7 @@ TEXT ·encodeAsm(SB),NOSPLIT,$0
VREPIB $0x19, RANGE0_END
VZERO ZERO

MOVD $0, R4
loop:
VL (R2), X0
VPERM X0, X0, RESHUFFLE_MASK, X0
Expand All @@ -58,8 +59,8 @@ loop:
VMLHW X2, MULLO_CONST, X2
VO X1, X2, X0

//VSB RANGE1_END, X0, X1
//VMXB ZERO, X1, X1
VSB RANGE1_END, X0, X1
VMXB ZERO, X1, X1

//VLR V0, V2
//VECLB RANGE0_END, X2
Expand All @@ -69,16 +70,16 @@ loop:
//VPERM LUT, LUT, X1, X2
//VAB X2, X0, X0

VPERM X0, X0, REV_BYTES, X0
VST X0, (R1)
//VPERM X0, X0, REV_BYTES, X0
VST X1, 0(R1)(R4*1)

LAY 12(R1), R1
LAY 16(R2), R2
SUB $16, R3
ADD $16, R4
LAY 12(R2), R2
SUB $12, R3
CMPBGE R3, $16, loop

done:
MOVD R3, ret+56(FP)
MOVD R4, ret+56(FP)
RET

#undef RESHUFFLE_MASK
Expand Down

0 comments on commit 8928e54

Please sign in to comment.