LCOV - code coverage report
Current view: top level - flamenco/runtime/context - fd_capture_ctx.h (source / functions) Hit Total Coverage
Test: cov.lcov Lines: 0 3 0.0 %
Date: 2025-07-01 05:00:49 Functions: 0 0 -

          Line data    Source code
       1             : #ifndef HEADER_fd_src_flamenco_runtime_context_fd_capture_ctx_h
       2             : #define HEADER_fd_src_flamenco_runtime_context_fd_capture_ctx_h
       3             : 
       4             : #include "../../capture/fd_solcap_writer.h"
       5             : #include "../../../funk/fd_funk_base.h"
       6             : 
       7             : /* Context needed to do solcap capture during execution of transactions */
       8           0 : #define FD_CAPTURE_CTX_ALIGN (8UL)
       9             : struct __attribute__((aligned(FD_CAPTURE_CTX_ALIGN))) fd_capture_ctx {
      10             :   ulong magic; /* ==FD_CAPTURE_CTX_MAGIC */
      11             : 
      12             :   /* Solcap */
      13             :   ulong                    solcap_start_slot;
      14             :   int                      trace_dirfd;
      15             :   int                      trace_mode;
      16             :   fd_solcap_writer_t *     capture;
      17             :   int                      capture_txns; /* Capturing txns can add significant time */
      18             : 
      19             :   /* Checkpointing */
      20             :   ulong                    checkpt_freq;    /* Must be a rooted slot */
      21             :   char const *             checkpt_path;    /* Wksp checkpoint format */
      22             :   char const *             checkpt_archive; /* Funk archive format */
      23             : 
      24             :   /*======== PROTOBUF ========*/
      25             :   char const *             dump_proto_output_dir;
      26             :   char const *             dump_proto_sig_filter;
      27             :   ulong                    dump_proto_start_slot;
      28             : 
      29             :   /* Instruction Capture */
      30             :   int                      dump_instr_to_pb;
      31             : 
      32             :   /* Transaction Capture */
      33             :   int                      dump_txn_to_pb;
      34             : 
      35             :   /* Block Capture */
      36             :   int                      dump_block_to_pb;
      37             : 
      38             :   /* Syscall Capture */
      39             :   int                      dump_syscall_to_pb;
      40             : 
      41             :   /* ELF Capture */
      42             :   int                      dump_elf_to_pb;
      43             : };
      44             : typedef struct fd_capture_ctx fd_capture_ctx_t;
      45           0 : #define FD_CAPTURE_CTX_FOOTPRINT ( sizeof(fd_capture_ctx_t) + fd_solcap_writer_footprint() )
      46           0 : #define FD_CAPTURE_CTX_MAGIC (0x193ECD2A6C395195UL) /* random */
      47             : 
      48             : FD_PROTOTYPES_BEGIN
      49             : 
      50             : void *
      51             : fd_capture_ctx_new( void * mem );
      52             : 
      53             : fd_capture_ctx_t *
      54             : fd_capture_ctx_join( void * mem );
      55             : 
      56             : void *
      57             : fd_capture_ctx_leave( fd_capture_ctx_t * ctx );
      58             : 
      59             : void *
      60             : fd_capture_ctx_delete( void * mem );
      61             : 
      62             : /* Temporary locks to protect the blockstore txn_map. See comment in
      63             :    fd_runtime_write_transaction_status. */
      64             : void
      65             : fd_capture_ctx_txn_status_start_read( void );
      66             : 
      67             : void
      68             : fd_capture_ctx_txn_status_end_read( void );
      69             : 
      70             : void
      71             : fd_capture_ctx_txn_status_start_write( void );
      72             : 
      73             : void
      74             : fd_capture_ctx_txn_status_end_write( void );
      75             : 
      76             : FD_PROTOTYPES_END
      77             : 
      78             : #endif /* HEADER_fd_src_flamenco_runtime_context_fd_capture_ctx_h */

Generated by: LCOV version 1.14