BLS12_MAP_FP_TO_G1
Elliptic curve
Map a base field element to a point in G1.
| Address | 0x0000000000000000000000000000000000000010 |
|---|---|
| Name | BLS12_MAP_FP_TO_G1 |
| Minimum gas | 5,500 |
| Input | 64 bytes |
| Output | 128 bytes |
| Available since | Prague |
Input
| Offset | Length | Field | Description |
|---|---|---|---|
| 0 | 64 | fp | A base field element; the top 16 bytes must be zero. |
Output
The resulting 128-byte G1 point.
Gas
5500
Failure behaviour
- Reverts if the input is not exactly 64 bytes or the field element is non-canonical.
Calling it
Precompiles have no ABI and no function selector: the input is raw bytes at the exact offsets above. Call with staticcall.
// BLS12_MAP_FP_TO_G1 at 0x10(bool ok, bytes memory out) = address(0x10).staticcall(input);require(ok, "BLS12_MAP_FP_TO_G1 reverted");Specification
- EIP-2537: Precompile for BLS12-381 curve operations