Barretenberg
The ZK-SNARK library at the core of Aztec
|
Go to the source code of this file.
Macros | |
#define | CLEAR_FLAGS(empty_reg) "xorq " empty_reg ", " empty_reg " \n\t" |
#define | LOAD_FIELD_ELEMENT(a, lolo, lohi, hilo, hihi) |
#define | STORE_FIELD_ELEMENT(r, lolo, lohi, hilo, hihi) |
#define | ADD(b) |
#define | SUB(b) |
#define | ADD_REDUCE(b, modulus_0, modulus_1, modulus_2, modulus_3) |
#define | REDUCE_FIELD_ELEMENT(neg_modulus_0, neg_modulus_1, neg_modulus_2, neg_modulus_3) |
#define | SQR(a) |
#define | MUL(a1, a2, a3, a4, b) |
#define | MUL_256(a, b, r) |
#define ADD | ( | b | ) |
Take a 4-limb field element, in (r12, r13, r14, r15), and add 4-limb field element pointed to by a
Definition at line 42 of file asm_macros.hpp.
#define ADD_REDUCE | ( | b, | |
modulus_0, | |||
modulus_1, | |||
modulus_2, | |||
modulus_3 | |||
) |
Take a 4-limb field element, in (r12, r13, r14, r15), add 4-limb field element pointed to by b, and reduce modulo p
Definition at line 63 of file asm_macros.hpp.
#define CLEAR_FLAGS | ( | empty_reg | ) | "xorq " empty_reg ", " empty_reg " \n\t" |
Definition at line 13 of file asm_macros.hpp.
#define LOAD_FIELD_ELEMENT | ( | a, | |
lolo, | |||
lohi, | |||
hilo, | |||
hihi | |||
) |
Load 4-limb field element, pointed to by a, into registers (lolo, lohi, hilo, hihi)
Definition at line 20 of file asm_macros.hpp.
#define MUL | ( | a1, | |
a2, | |||
a3, | |||
a4, | |||
b | |||
) |
Compute Montgomery multiplication of a, b. Result is stored, in (%r12, %r13, %r14, %r15), in preparation for being stored in "r"
Definition at line 241 of file asm_macros.hpp.
Compute 256-bit multiplication of a, b. Result is stored, r. // in (%r12, %r13, %r14, %r15), in preparation for being stored in "r"
Definition at line 400 of file asm_macros.hpp.
#define REDUCE_FIELD_ELEMENT | ( | neg_modulus_0, | |
neg_modulus_1, | |||
neg_modulus_2, | |||
neg_modulus_3 | |||
) |
Take a 4-limb integer, r, in (r12, r13, r14, r15) and conditionally subtract modulus, if r > p.
Definition at line 87 of file asm_macros.hpp.
#define SQR | ( | a | ) |
Compute Montgomery squaring of a Result is stored, in (%r12, %r13, %r14, %r15), in preparation for being stored in "r"
Definition at line 109 of file asm_macros.hpp.
#define STORE_FIELD_ELEMENT | ( | r, | |
lolo, | |||
lohi, | |||
hilo, | |||
hihi | |||
) |
Store 4-limb field element located in registers (lolo, lohi, hilo, hihi), into memory pointed to by r
Definition at line 31 of file asm_macros.hpp.