field_4x64_asm.go raw

   1  //go:build amd64 && !purego
   2  
   3  package p256k1
   4  
   5  // Assembly function declarations for 4x64 field operations.
   6  // These are implemented in field_4x64_amd64.s using BMI2 instructions (MULX).
   7  
   8  // field4x64MulAsm computes r = a * b (mod p) using BMI2 MULX.
   9  // All pointers must be aligned and point to valid [4]uint64 arrays.
  10  //
  11  //go:noescape
  12  func field4x64MulAsm(r, a, b *[4]uint64)
  13  
  14  // field4x64SqrAsm computes r = a^2 (mod p) using BMI2 MULX.
  15  // All pointers must be aligned and point to valid [4]uint64 arrays.
  16  //
  17  //go:noescape
  18  func field4x64SqrAsm(r, a *[4]uint64)
  19