Cargo Features

[dependencies]
radix-engine = { version = "1.3.0", default-features = false, features = ["std", "alloc", "cpu_ram_metrics", "moka", "lru", "resource_tracker", "db_checker", "fuzzing", "radix_engine_tests", "test_utils", "full_wasm_benchmarks", "coverage", "flamegraph"] }
default = moka, std

You should enable either std or alloc

std default cpu_ram_metrics?

Enables std of wasmi =0.39.1

WASM execution
- Wasmi is a WASM interpreter that supports WebAssembly MVP

and std of radix-blueprint-schema-init, radix-common-derive, radix-engine-interface, radix-native-sdk, radix-rust, radix-substate-store-interface, radix-transactions, radix-wasm-instrument, and sbor

radix-wasm-instrument:

WASM instrumentation

Affects transaction_receipt::FlamegraphError, panics::catch_unwind_system_panic_transformer, kernel::resources_tracker

alloc

Enables alloc of radix-blueprint-schema-init, radix-common-derive, radix-engine-interface, radix-native-sdk, radix-rust, radix-substate-store-interface, radix-transactions, and sbor, hashbrown of optional lru ^0.8.1

cpu_ram_metrics = perfcnt, std

Enables heap memory and CPU cycles resource tracing - available only for Linux OS on x86 arch.
Requires CAP_PERFMON capability for the process (sudo setcap cap_perfmon=eip <exec_file>).

Enables ram_metrics of radix-engine-profiling

Affects kernel::resources_tracker

moka default

Two features for the two possible libraries to use for caching. Moka is not WASM friendly while LRU is. One of these two features must be enabled.

Enables moka ^0.9.9

lru

Enables lru ^0.8.1

resource_tracker

Enables resource_tracker of radix-common, radix-engine-profiling, and radix-engine-profiling-derive

db_checker

System/Application Database Checker

Affects system::checkers

fuzzing

This flag is set by fuzz-tests framework and it disables cache in wasm_instrumenter/wasmi to prevent non-determinism when fuzzing

Enables fuzzing of radix-common, radix-engine-interface, radix-rust, radix-transactions, and sbor

radix_engine_tests

This flag enables code parts used only for testing. Using "test" config option is not enough in cases,
when external crate is used for tests (eg. radix-engine-tests)

test_utils

This flag includes test utilities which may be useful in different testing libraries

Enables walkdir

full_wasm_benchmarks
coverage

This flag disables package size limit, memory size limit and fee limit

Enables coverage of radix-common

Affects blueprint::MAX_TOTAL_BLOB_SIZE_PER_INVOCATION, coverage::save_coverage_data

flamegraph

This feature flag adds the ability for flamegraphs to be generated for the costing in the receipt.

Enables inferno ^0.11.19

Features from optional dependencies

In crates that don't use the dep: syntax, optional dependencies automatically become Cargo features. These features may have been created by mistake, and this functionality may be removed in the future.

perfcnt cpu_ram_metrics?