constantine
constantine copied to clipboard
Constantine: modular, high-performance, zero-dependency cryptography stack for proof systems and blockchain protocols.
The CMOV instruction that is used for conditional copy is likely optimal for 4~6 limbs. From Agner Fog tables  https://www.agner.org/optimize/instruction_tables.pdf The throughput is 0.5 hence 2 independent CMOV can...
The GLV-SAC paper introduces an alternative scalar multiplication for a fixed base. For example signing is always done using the generator point as a fixed base - Efficient and Secure...
Currently the coverage of assembly backend introduced in #69 is inequal. Some of the CI VMs supports ADX and BMI2 and some do not. We need to properly test both...
Glossary: - We talk about scalar multiplication for additive groups G1 (over Fp) and G2 (over Fp2 thanks to a sextic twist) - We talk about exponentiation for multiplicative group...
From Patrick Longa's PhD Thesis Appendix:  ---------------- Note: Jacobian coordinates do not have a complete exception-free addition formula, they require special casing adding infinity, the same number or its...
It is often needed to compute scalar multiplication in parallel via ``` R
Computing 2P+Q may be useful for alternative scalar multiplications based on double-and-always-add. For example Joye's ladder: - https://tel.archives-ouvertes.fr/tel-00733004/document - https://www.iacr.org/archive/ches2007/47270135/47270135.pdf   Computation cost according to Joye, 2007  Papers...
The library currently implements generic routine for odd field moduli. > This is motivated by the initial focus on pairing-friendly curves like BN (Barreto-Naerig) and BLS (Barreto-Lynn-Scott) as they are...
Merkle tree hashing is a significant bottleneck in blockchains. In most (all?) blockchains and in particular Ethereum, efficient storage/retrieval/update as well as integrity guarantees of data is implemented through a...
# Optimization of square roots Tonelli-Shanks, with pre-computed dlog tables Fixes #236 Notes about the approach : - https://ihagopian.com/posts/tonelli-shanks-with-precomputed-dlog-tables - https://hackmd.io/@jsign/bandersnatch-optimized-sqrt-notes Reference Implementation from Gottfried in `gnark` https://github.com/GottfriedHerold/Bandersnatch/blob/f665f90b64892b9c4c89cff3219e70456bb431e5/bandersnatch/fieldElements/field_element_square_root.go #### Currently...