private void configurePrecompileCaching() {
    // enable precompile caching:
    AbstractPrecompiledContract.setPrecompileCaching(enablePrecompileCaching);
    // separately set KZG precompile caching, it does not extend AbstractPrecompiledContract:
    KZGPointEvalPrecompiledContract.setPrecompileCaching(enablePrecompileCaching);
    // separately set BLS precompiles caching, they do not extend AbstractPrecompiledContract:
    AbstractBLS12PrecompiledContract.setPrecompileCaching(enablePrecompileCaching);

    // set a metric logger
    final var precompileCounter =
        getMetricsSystem()
            .createLabelledCounter(
                BesuMetricCategory.BLOCK_PROCESSING,
                "precompile_cache",
                "precompile cache labeled counter",
                "precompile_name",
                "event");

    // set a cache event consumer which logs a metrics event
    AbstractPrecompiledContract.setCacheEventConsumer(
        cacheEvent ->
            precompileCounter
                .labels(cacheEvent.precompile(), cacheEvent.cacheMetric().name())
                .inc());
  }
Used by Dagger to parse all options into a commandline instance.
app/src/main/java/org/hyperledger/besu/cli/BesuCommand.java