19 if ((blockIdx.x | blockIdx.y | blockIdx.z | threadIdx.x | threadIdx.y | threadIdx.z) == 0)
20 printf(
"=== RUN %s\n", __func__);
34 for (
int i=0; pass && i<100; i++) {
62 if (!pass || (blockIdx.x | blockIdx.y | blockIdx.z | threadIdx.x | threadIdx.y | threadIdx.z) == 0)
64 printf(
"%ld tests\n", count);
__device__ __host__ void fr_zero(fr_t &z)
Sets the value of z to zero.
__device__ __host__ void fr_one(fr_t &z)
Sets the value of z to one.
uint64_t fr_t[4]
Subgroup element stored as a 256-bit array (a 4-element little-endian array of uint64_t)....
__device__ void fr_add(fr_t &z, const fr_t &x)
Computes the sum of two residues x and z modulo r and stores it in z. Device only function.
__device__ __host__ void g1p_inf(g1p_t &p)
Set p to the point-at-infinity (0,1,0)
__device__ bool g1p_neq(const g1p_t &p, const g1p_t &q)
Compares two projective points, returns true when not equal. This function compares if both parameter...
__device__ void g1p_add(g1p_t &p, const g1p_t &q)
Computes the sum of two points q into p, using projective coordinates. and stores in p.
__device__ __host__ void g1p_gen(g1p_t &p)
Sets p to the generator point G1 of bls12_381.
__device__ void g1p_mul(g1p_t &p, const fr_t &x)
p ← k·p Point multiplication by scalar, in projective coordinates. That result is stored back into p.
__global__ void G1TestFibonacci(testval_t *)
Test addition and multiplication using a fibonacci sequence (cascading data dependency)
G1 point in projective coordinates.