diff --git a/src/app/fdctl/topology.c b/src/app/fdctl/topology.c index b10ba36f896..15aa8ebb2ed 100644 --- a/src/app/fdctl/topology.c +++ b/src/app/fdctl/topology.c @@ -95,7 +95,7 @@ fd_topo_initialize( config_t * config ) { /**/ fd_topob_link( topo, "dedup_resolv", "dedup_resolv", 65536UL, FD_TPU_PARSED_MTU, 1UL ); FOR(resolv_tile_cnt) fd_topob_link( topo, "resolv_pack", "resolv_pack", 65536UL, FD_TPU_RESOLVED_MTU, 1UL ); /**/ fd_topob_link( topo, "stake_out", "stake_out", 128UL, FD_STAKE_OUT_MTU, 1UL ); - /* pack_bank is shared across all banks, so if one bank stalls due to complex transactions, the buffer neeeds to be large so that + /* pack_bank is shared across all banks, so if one bank stalls due to complex transactions, the buffer needs to be large so that other banks can keep proceeding. */ /**/ fd_topob_link( topo, "pack_bank", "pack_bank", 65536UL, USHORT_MAX, 1UL ); /**/ fd_topob_link( topo, "pack_poh", "pack_poh", 65536UL, sizeof(fd_done_packing_t), 1UL ); diff --git a/src/app/firedancer/topology.c b/src/app/firedancer/topology.c index dfe4ed248dd..167183882a3 100644 --- a/src/app/firedancer/topology.c +++ b/src/app/firedancer/topology.c @@ -382,7 +382,7 @@ fd_topo_initialize( config_t * config ) { /**/ fd_topob_link( topo, "replay_stake", "replay_stake", 128UL, FD_STAKE_OUT_MTU, 1UL ); /* TODO: This should be 2 but requires fixing STEM_BURST */ /**/ fd_topob_link( topo, "replay_out", "replay_out", 8192UL, sizeof(fd_replay_message_t), 1UL ); /**/ fd_topob_link( topo, "pack_poh", "pack_poh", 128UL, sizeof(fd_done_packing_t), 1UL ); - /* pack_bank is shared across all banks, so if one bank stalls due to complex transactions, the buffer neeeds to be large so that + /* pack_bank is shared across all banks, so if one bank stalls due to complex transactions, the buffer needs to be large so that other banks can keep proceeding. */ /**/ fd_topob_link( topo, "pack_bank", "pack_bank", 65536UL, USHORT_MAX, 1UL ); FOR(bank_tile_cnt) fd_topob_link( topo, "bank_poh", "bank_poh", 16384UL, USHORT_MAX, 1UL ); diff --git a/src/ballet/bn254/fd_bn254_field_ext.c b/src/ballet/bn254/fd_bn254_field_ext.c index 2eb8a3e7474..d3c96481bf8 100644 --- a/src/ballet/bn254/fd_bn254_field_ext.c +++ b/src/ballet/bn254/fd_bn254_field_ext.c @@ -92,7 +92,7 @@ fd_bn254_fp2_tobytes_be_nm( uchar buf[64], return buf; } -/* fd_bn254_fp2_is_neg_nm checks wheather x < 0 in Fp2. +/* fd_bn254_fp2_is_neg_nm checks whether x < 0 in Fp2. Note: x is NON Montgomery. Returns 1 if x < 0, 0 otherwise. */ static inline int @@ -103,7 +103,7 @@ fd_bn254_fp2_is_neg_nm( fd_bn254_fp2_t * x ) { return fd_bn254_fp_is_neg_nm( &x->el[1] ); } -/* fd_bn254_fp2_is_minus_one checks wheather a == -1 in Fp2. +/* fd_bn254_fp2_is_minus_one checks whether a == -1 in Fp2. Returns 1 if a==-1, 0 otherwise. */ static inline int fd_bn254_fp2_is_minus_one( fd_bn254_fp2_t const * a ) { @@ -111,7 +111,7 @@ fd_bn254_fp2_is_minus_one( fd_bn254_fp2_t const * a ) { && fd_uint256_eq( &a->el[1], fd_bn254_const_zero ); } -/* fd_bn254_fp2_eq checks wheather a == b in Fp2. +/* fd_bn254_fp2_eq checks whether a == b in Fp2. Returns 1 if a == b, 0 otherwise. */ static inline int fd_bn254_fp2_eq( fd_bn254_fp2_t const * a, diff --git a/src/ballet/sbpf/fd_sbpf_loader.c b/src/ballet/sbpf/fd_sbpf_loader.c index 94d4fcd044c..fe7ff0286ef 100644 --- a/src/ballet/sbpf/fd_sbpf_loader.c +++ b/src/ballet/sbpf/fd_sbpf_loader.c @@ -131,7 +131,7 @@ ulong fd_sbpf_program_footprint( fd_sbpf_elf_info_t const * info ) { FD_COMPILER_UNPREDICTABLE( info ); /* Make this appear as FD_FN_PURE (e.g. footprint might depened on info contents in future) */ if( FD_UNLIKELY( fd_sbpf_enable_stricter_elf_headers_enabled( info->sbpf_version ) ) ) { - /* SBPF v3+ no longer neeeds calldests bitmap */ + /* SBPF v3+ no longer needs calldests bitmap */ return FD_LAYOUT_FINI( FD_LAYOUT_APPEND( FD_LAYOUT_INIT, alignof(fd_sbpf_program_t), sizeof(fd_sbpf_program_t) ), alignof(fd_sbpf_program_t) ); diff --git a/src/ballet/sbpf/fd_sbpf_loader.h b/src/ballet/sbpf/fd_sbpf_loader.h index eb412e3075b..bca9057e1aa 100644 --- a/src/ballet/sbpf/fd_sbpf_loader.h +++ b/src/ballet/sbpf/fd_sbpf_loader.h @@ -88,7 +88,7 @@ #include "../../util/tmpl/fd_set_dynamic.c" /* fd_sbpf_syscall_func_t is a callback implementing an sBPF syscall. - vm is a handle to the running VM. Returns 0 on suceess or an integer + vm is a handle to the running VM. Returns 0 on success or an integer error code on failure. IMPORTANT SAFETY TIP! See notes in diff --git a/src/ballet/sha256/fd_sha256_constants.h b/src/ballet/sha256/fd_sha256_constants.h index 23f88dfc987..8f6286b63bf 100644 --- a/src/ballet/sha256/fd_sha256_constants.h +++ b/src/ballet/sha256/fd_sha256_constants.h @@ -2,7 +2,7 @@ #define HEADER_fd_src_ballet_sha256_constants_h /* We don't want to use FD_IMPORT_BINARY here, because we want to make - the values available to the compiler for constant propogation. Using + the values available to the compiler for constant propagation. Using FD_IMPORT_BINARY means they wouldn't be available until link-time. */ static uint const fd_sha256_K[64] __attribute__((aligned(64))) = { 0x428a2f98U, 0x71374491U, 0xb5c0fbcfU, 0xe9b5dba5U, 0x3956c25bU, 0x59f111f1U, 0x923f82a4U, 0xab1c5ed5U, diff --git a/src/ballet/shred/fd_shred.h b/src/ballet/shred/fd_shred.h index 15e81db03c1..72d7c0175d1 100644 --- a/src/ballet/shred/fd_shred.h +++ b/src/ballet/shred/fd_shred.h @@ -365,7 +365,7 @@ FD_FN_CONST static inline uchar fd_shred_is_data( ulong type ) { return (type & FD_FN_CONST static inline uchar fd_shred_is_code( ulong type ) { return (type & 0xC0UL)==0x40UL; } /* fd_shred_swap_type: changes data into code or vice versa without - affecting leagacy, merkle, chained, or resigned status. For example, + affecting legacy, merkle, chained, or resigned status. For example, fd_shred_swap_type( chained resigned data ) == chained resigned code. fd_shred_swap_type( merkle code ) == merkle data. */ FD_FN_CONST static inline uchar diff --git a/src/ballet/wsample/fd_wsample.c b/src/ballet/wsample/fd_wsample.c index efdf38bcaf9..35e545b4a26 100644 --- a/src/ballet/wsample/fd_wsample.c +++ b/src/ballet/wsample/fd_wsample.c @@ -140,7 +140,7 @@ struct __attribute__((aligned(64UL))) fd_wsample_private { but before any deletion so that restoring deleted elements can be implemented as a memcpy. - The tree iteself is surrounded by two dummy elements, dummy, and + The tree itself is surrounded by two dummy elements, dummy, and tree[internal_node_cnt], that aren't actually used. This is because searching the tree branchlessly involves some out of bounds reads, and although the value is immediately discarded, it's better diff --git a/src/ballet/x509/fd_x509_mock.c b/src/ballet/x509/fd_x509_mock.c index efd4102a008..b968d79c908 100644 --- a/src/ballet/x509/fd_x509_mock.c +++ b/src/ballet/x509/fd_x509_mock.c @@ -105,7 +105,7 @@ fd_x509_mock_tpl[ FD_X509_MOCK_CERT_SZ ] = { }; /* Agave v1.18 uses a different template. It is less - determistic due to a variable length serial number, so we match the + deterministic due to a variable length serial number, so we match the prefix before the public key. */ static uchar const