store<i32>(h_ptr, h9, 36)
}
-/**
- * Negate the values of a FieldElement and store the result.
- *
- * @param {usize} h pointer to FieldElement result destination
- * @param {usize} f pointer to FieldElement operand source
- */
-//@ts-expect-error
-@inline
-export function fe_memneg (h: usize, f: usize): void {
- v128.store(h, v128.neg<i32>(v128.load(f)))
- v128.store(h, v128.neg<i32>(v128.load(f, 16)), 16)
- v128.store_lane<i64>(h, v128.neg<i32>(v128.load(f, 32)), 0, 32)
-}
-
/**
* Negate the values of a FieldElement and store the result.
*
//@ts-expect-error
@inline
export function fe_neg (h: FieldElement, f: FieldElement): void {
- fe_memneg(changetype<usize>(h), changetype<usize>(f))
+ const h_ptr = changetype<usize>(h)
+ const f_ptr = changetype<usize>(f)
+ v128.store(h_ptr, v128.neg<i32>(v128.load(f_ptr)))
+ v128.store(h_ptr, v128.neg<i32>(v128.load(f_ptr, 16)), 16)
+ v128.store_lane<i64>(h_ptr, v128.neg<i32>(v128.load(f_ptr, 32)), 0, 32)
}
const fe_pow22523_t0: FieldElement = fe()