LPsLux Proposals
Precompiles
LP-4320

BLAKE2b Hash Precompile (EIP-152)

Draft

Native EVM precompile for the BLAKE2b cryptographic hash function compression function, per Ethereum EIP-152 (BLAKE2 F precompile at address 0x09).

Category
Core
Created
2026-05-18

Abstract

BLAKE2b is the 64-bit-optimized variant of the BLAKE2 hash family (Aumasson, Neves, Wilcox-O'Hearn, Winnerlein 2013), standardized as RFC 7693. Ethereum mainnet exposes the BLAKE2b compression function (F) as precompile 0x09 under EIP-152 to enable trust-minimized Zcash / Equihash header verification on-chain. This LP pins the Lux network's BLAKE2b F precompile at the same address 0x09 for full Ethereum tooling parity (Geth / Erigon test vectors apply unmodified), gas cost (12 * rounds per EIP-152), and full-message hashing variants (BLAKE2b-256, BLAKE2b-512) via the luxfi/crypto/hash/blake2b library. For higher throughput on modern hardware prefer BLAKE3 (LP-4310); for EVM-cross-chain compatibility use BLAKE2b.

Reference implementation

  • Primitive: golang.org/x/crypto/blake2b (stdlib-adjacent)
  • Precompile address: 0x09 (EIP-152 F compression function)
  • Gas cost: 12 * rounds (EIP-152)
  • Standards: EIP-152, RFC 7693

Copyright and related rights waived via CC0.