Skip to main content

Precompiles

What are Precompiles?

A precompile refers to a set of special, pre-defined functions built into the native blockchain client software. In other words, precompiles are native smart contracts.

Precompiles are accessible at specific addresses on the blockchain and are designed to perform complex cryptographic operations such as hashing, digital signature verification, and mathematical operations more efficiently.

Blockchains deploy precompiled contracts for two main reasons. First, if the contracts are integral to the functioning of the blockchain itself, then it is vital that every instance of the blockchain contains these smart contracts. Secondly, precompiled contracts are far more efficient for certain operations.

Interacting With Precompiles

To interact with a precompile contract, simply treat the precompile contract as if it was any other smart contract. Stability has their own precompile contracts on our network to manage permissioned validators, as well as standard Ethereum Virtual Machine (EVM) precompiles.

Stability Native Precompiles

AddressNameInputOutputDescriptionSource
0x801supportedTokensManagerdatadataA precompile that stores and manages the ATM gas and ATM tokens.Code
0x802FeeTokenSelectordatadataA precompile that allows users to set their fee token.Code
0x803ValidatorFeeTokenSelectordatadataA precompile that allows Validators that select which tokens to accept.Code
0x805ValidatorControllerdatadataA precompile that enables Stability to manage validator addresses.Code
0x806UpgradeRuntimeControllerPrecompiledatadataA precompile that enables Stability to manage runtime upgrades.Code
0x807FeeRewardsVaultControllerdatadataA precompile that enables fee-sharing logic for the ATM.Code