Skip to content

Commit

Permalink
sm9/bn256: arm64 curvePointDoubleComplete fix issue
Browse files Browse the repository at this point in the history
  • Loading branch information
emmansun authored Jul 25, 2023
1 parent 6280543 commit 1ecdb1a
Showing 1 changed file with 6 additions and 3 deletions.
9 changes: 6 additions & 3 deletions sm9/bn256/gfp2_g1_arm64.s
Original file line number Diff line number Diff line change
Expand Up @@ -734,22 +734,25 @@ TEXT ·curvePointDoubleComplete(SB),NOSPLIT,$168-16
CALL gfpMulInternal(SB) // Y3 := t0 * Y3
LDx (x3t)
gfpAddInline // Y3 := X3 + Y3
STx (y2in)
STx (y3t)

LDx (y1in)
LDy (z1in)
CALL gfpMulInternal(SB) // t1 := YZ
LDx (z3t)
CALL gfpMulInternal(SB) // Z3 := t1 * Z3
STy (z2in)
STy (z2in) // Store Z3

LDx (x1in)
LDy (y1in)
CALL gfpMulInternal(SB) // t1 := XY
LDx (tmp0)
CALL gfpMulInternal(SB) // X3 := t0 * t1
gfpMulBy2Inline // X3 := X3 + X3
STx (x2in)
STx (x2in) // Store X3
// Store Y3
LDx (y3t)
STx (y2in)

RET

Expand Down

0 comments on commit 1ecdb1a

Please sign in to comment.