LCOV - code coverage report
Current view: top level - app/firedancer-dev - main.c (source / functions) Hit Total Coverage
Test: cov.lcov Lines: 3 3 100.0 %
Date: 2025-08-05 05:04:49 Functions: 1 1 100.0 %

          Line data    Source code
       1             : #include "main.h"
       2             : #include "../firedancer/topology.h"
       3             : #include "../firedancer/config.h"
       4             : #include "../shared_dev/boot/fd_dev_boot.h"
       5             : #include "../shared/fd_action.h"
       6             : #include "../shared/commands/configure/configure.h"
       7             : 
       8             : char const * FD_APP_NAME    = "Firedancer";
       9             : char const * FD_BINARY_NAME = "firedancer-dev";
      10             : 
      11             : extern fd_topo_obj_callbacks_t fd_obj_cb_mcache;
      12             : extern fd_topo_obj_callbacks_t fd_obj_cb_dcache;
      13             : extern fd_topo_obj_callbacks_t fd_obj_cb_fseq;
      14             : extern fd_topo_obj_callbacks_t fd_obj_cb_metrics;
      15             : extern fd_topo_obj_callbacks_t fd_obj_cb_opaque;
      16             : extern fd_topo_obj_callbacks_t fd_obj_cb_dbl_buf;
      17             : extern fd_topo_obj_callbacks_t fd_obj_cb_neigh4_hmap;
      18             : extern fd_topo_obj_callbacks_t fd_obj_cb_fib4;
      19             : extern fd_topo_obj_callbacks_t fd_obj_cb_keyswitch;
      20             : extern fd_topo_obj_callbacks_t fd_obj_cb_tile;
      21             : extern fd_topo_obj_callbacks_t fd_obj_cb_runtime_pub;
      22             : extern fd_topo_obj_callbacks_t fd_obj_cb_store;
      23             : extern fd_topo_obj_callbacks_t fd_obj_cb_fec_sets;
      24             : extern fd_topo_obj_callbacks_t fd_obj_cb_txncache;
      25             : extern fd_topo_obj_callbacks_t fd_obj_cb_exec_spad;
      26             : extern fd_topo_obj_callbacks_t fd_obj_cb_banks;
      27             : extern fd_topo_obj_callbacks_t fd_obj_cb_funk;
      28             : extern fd_topo_obj_callbacks_t fd_obj_cb_bank_hash_cmp;
      29             : 
      30             : fd_topo_obj_callbacks_t * CALLBACKS[] = {
      31             :   &fd_obj_cb_mcache,
      32             :   &fd_obj_cb_dcache,
      33             :   &fd_obj_cb_fseq,
      34             :   &fd_obj_cb_metrics,
      35             :   &fd_obj_cb_opaque,
      36             :   &fd_obj_cb_dbl_buf,
      37             :   &fd_obj_cb_neigh4_hmap,
      38             :   &fd_obj_cb_fib4,
      39             :   &fd_obj_cb_keyswitch,
      40             :   &fd_obj_cb_tile,
      41             :   &fd_obj_cb_runtime_pub,
      42             :   &fd_obj_cb_store,
      43             :   &fd_obj_cb_fec_sets,
      44             :   &fd_obj_cb_txncache,
      45             :   &fd_obj_cb_exec_spad,
      46             :   &fd_obj_cb_banks,
      47             :   &fd_obj_cb_funk,
      48             :   &fd_obj_cb_bank_hash_cmp,
      49             :   NULL,
      50             : };
      51             : 
      52             : configure_stage_t * STAGES[] = {
      53             :   &fd_cfg_stage_kill,
      54             :   &fd_cfg_stage_netns,
      55             :   &fd_cfg_stage_hugetlbfs,
      56             :   &fd_cfg_stage_normalpage,
      57             :   &fd_cfg_stage_sysctl,
      58             :   &fd_cfg_stage_hyperthreads,
      59             :   &fd_cfg_stage_ethtool_channels,
      60             :   &fd_cfg_stage_ethtool_gro,
      61             :   &fd_cfg_stage_ethtool_loopback,
      62             :   &fd_cfg_stage_keys,
      63             :   &fd_cfg_stage_genesis,
      64             :   &fd_cfg_stage_snapshots,
      65             :   NULL,
      66             : };
      67             : 
      68             : 
      69             : extern fd_topo_run_tile_t fd_tile_net;
      70             : extern fd_topo_run_tile_t fd_tile_netlnk;
      71             : extern fd_topo_run_tile_t fd_tile_sock;
      72             : extern fd_topo_run_tile_t fd_tile_quic;
      73             : extern fd_topo_run_tile_t fd_tile_verify;
      74             : extern fd_topo_run_tile_t fd_tile_dedup;
      75             : extern fd_topo_run_tile_t fd_tile_pack;
      76             : extern fd_topo_run_tile_t fd_tile_resolv;
      77             : extern fd_topo_run_tile_t fd_tile_shred;
      78             : extern fd_topo_run_tile_t fd_tile_sign;
      79             : extern fd_topo_run_tile_t fd_tile_metric;
      80             : extern fd_topo_run_tile_t fd_tile_cswtch;
      81             : extern fd_topo_run_tile_t fd_tile_gui;
      82             : extern fd_topo_run_tile_t fd_tile_plugin;
      83             : extern fd_topo_run_tile_t fd_tile_bencho;
      84             : extern fd_topo_run_tile_t fd_tile_benchg;
      85             : extern fd_topo_run_tile_t fd_tile_benchs;
      86             : extern fd_topo_run_tile_t fd_tile_bundle;
      87             : extern fd_topo_run_tile_t fd_tile_pktgen;
      88             : extern fd_topo_run_tile_t fd_tile_udpecho;
      89             : 
      90             : extern fd_topo_run_tile_t fd_tile_gossip;
      91             : extern fd_topo_run_tile_t fd_tile_repair;
      92             : extern fd_topo_run_tile_t fd_tile_replay;
      93             : extern fd_topo_run_tile_t fd_tile_execor;
      94             : extern fd_topo_run_tile_t fd_tile_writer;
      95             : extern fd_topo_run_tile_t fd_tile_poh;
      96             : extern fd_topo_run_tile_t fd_tile_send;
      97             : extern fd_topo_run_tile_t fd_tile_tower;
      98             : extern fd_topo_run_tile_t fd_tile_rpcserv;
      99             : extern fd_topo_run_tile_t fd_tile_backtest;
     100             : extern fd_topo_run_tile_t fd_tile_archiver_feeder;
     101             : extern fd_topo_run_tile_t fd_tile_archiver_writer;
     102             : extern fd_topo_run_tile_t fd_tile_archiver_playback;
     103             : extern fd_topo_run_tile_t fd_tile_shredcap;
     104             : 
     105             : extern fd_topo_run_tile_t fd_tile_snaprd;
     106             : extern fd_topo_run_tile_t fd_tile_snapdc;
     107             : extern fd_topo_run_tile_t fd_tile_snapin;
     108             : 
     109             : fd_topo_run_tile_t * TILES[] = {
     110             :   &fd_tile_net,
     111             :   &fd_tile_netlnk,
     112             :   &fd_tile_sock,
     113             :   &fd_tile_quic,
     114             :   &fd_tile_verify,
     115             :   &fd_tile_dedup,
     116             :   &fd_tile_pack,
     117             :   &fd_tile_resolv,
     118             :   &fd_tile_shred,
     119             :   &fd_tile_sign,
     120             :   &fd_tile_metric,
     121             :   &fd_tile_cswtch,
     122             :   &fd_tile_gui,
     123             :   &fd_tile_plugin,
     124             :   &fd_tile_bencho,
     125             :   &fd_tile_benchg,
     126             :   &fd_tile_benchs,
     127             :   &fd_tile_bundle,
     128             :   &fd_tile_gossip,
     129             :   &fd_tile_repair,
     130             :   &fd_tile_replay,
     131             :   &fd_tile_execor,
     132             :   &fd_tile_writer,
     133             :   &fd_tile_poh,
     134             :   &fd_tile_send,
     135             :   &fd_tile_tower,
     136             :   &fd_tile_rpcserv,
     137             :   &fd_tile_archiver_feeder,
     138             :   &fd_tile_archiver_writer,
     139             :   &fd_tile_archiver_playback,
     140             :   &fd_tile_shredcap,
     141             : #if FD_HAS_ROCKSDB
     142             :   &fd_tile_backtest,
     143             : #endif
     144             :   &fd_tile_bencho,
     145             :   &fd_tile_benchg,
     146             :   &fd_tile_benchs,
     147             :   &fd_tile_pktgen,
     148             :   &fd_tile_udpecho,
     149             :   &fd_tile_snaprd,
     150             :   &fd_tile_snapdc,
     151             :   &fd_tile_snapin,
     152             :   NULL,
     153             : };
     154             : 
     155             : extern action_t fd_action_run;
     156             : extern action_t fd_action_run1;
     157             : extern action_t fd_action_configure;
     158             : extern action_t fd_action_monitor;
     159             : extern action_t fd_action_keys;
     160             : extern action_t fd_action_ready;
     161             : extern action_t fd_action_mem;
     162             : extern action_t fd_action_netconf;
     163             : extern action_t fd_action_set_identity;
     164             : extern action_t fd_action_version;
     165             : extern action_t fd_action_bench;
     166             : extern action_t fd_action_bundle_client;
     167             : extern action_t fd_action_dev;
     168             : extern action_t fd_action_dump;
     169             : extern action_t fd_action_flame;
     170             : extern action_t fd_action_help;
     171             : extern action_t fd_action_load;
     172             : extern action_t fd_action_pktgen;
     173             : extern action_t fd_action_quic_trace;
     174             : extern action_t fd_action_txn;
     175             : extern action_t fd_action_udpecho;
     176             : extern action_t fd_action_wksp;
     177             : extern action_t fd_action_gossip;
     178             : extern action_t fd_action_sim;
     179             : extern action_t fd_action_backtest;
     180             : extern action_t fd_action_snapshot_load;
     181             : extern action_t fd_action_repair;
     182             : 
     183             : action_t * ACTIONS[] = {
     184             :   &fd_action_run,
     185             :   &fd_action_run1,
     186             :   &fd_action_configure,
     187             :   &fd_action_monitor,
     188             :   &fd_action_keys,
     189             :   &fd_action_ready,
     190             :   &fd_action_mem,
     191             :   &fd_action_netconf,
     192             :   &fd_action_set_identity,
     193             :   &fd_action_help,
     194             :   &fd_action_version,
     195             :   &fd_action_bench,
     196             :   &fd_action_bundle_client,
     197             :   &fd_action_dev,
     198             :   &fd_action_dump,
     199             :   &fd_action_flame,
     200             :   &fd_action_load,
     201             :   &fd_action_pktgen,
     202             :   &fd_action_quic_trace,
     203             :   &fd_action_txn,
     204             :   &fd_action_udpecho,
     205             :   &fd_action_wksp,
     206             :   &fd_action_gossip,
     207             :   &fd_action_sim,
     208             :   &fd_action_backtest,
     209             :   &fd_action_snapshot_load,
     210             :   &fd_action_repair,
     211             :   NULL,
     212             : };
     213             : 
     214             : int
     215             : main( int     argc,
     216          12 :       char ** argv ) {
     217          12 :   return fd_dev_main( argc, argv, 1, (char const *)firedancer_default_config, firedancer_default_config_sz, fd_topo_initialize );
     218          12 : }

Generated by: LCOV version 1.14