Skip to content

Commit 9ba7ec8

Browse files
committed
airlift frankendancer poh tile across
1 parent 78301c1 commit 9ba7ec8

File tree

12 files changed

+2449
-1620
lines changed

12 files changed

+2449
-1620
lines changed

src/app/firedancer-dev/main.c

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -87,7 +87,7 @@ extern fd_topo_run_tile_t fd_tile_replay;
8787
extern fd_topo_run_tile_t fd_tile_execor;
8888
extern fd_topo_run_tile_t fd_tile_writer;
8989
extern fd_topo_run_tile_t fd_tile_batch;
90-
extern fd_topo_run_tile_t fd_tile_pohi;
90+
extern fd_topo_run_tile_t fd_tile_poh;
9191
extern fd_topo_run_tile_t fd_tile_sender;
9292
extern fd_topo_run_tile_t fd_tile_eqvoc;
9393
extern fd_topo_run_tile_t fd_tile_rpcserv;
@@ -126,7 +126,7 @@ fd_topo_run_tile_t * TILES[] = {
126126
&fd_tile_execor,
127127
&fd_tile_writer,
128128
&fd_tile_batch,
129-
&fd_tile_pohi,
129+
&fd_tile_poh,
130130
&fd_tile_sender,
131131
&fd_tile_eqvoc,
132132
&fd_tile_rpcserv,

src/app/firedancer/main.c

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -74,7 +74,7 @@ extern fd_topo_run_tile_t fd_tile_replay;
7474
extern fd_topo_run_tile_t fd_tile_execor;
7575
extern fd_topo_run_tile_t fd_tile_writer;
7676
extern fd_topo_run_tile_t fd_tile_batch;
77-
extern fd_topo_run_tile_t fd_tile_pohi;
77+
extern fd_topo_run_tile_t fd_tile_poh;
7878
extern fd_topo_run_tile_t fd_tile_sender;
7979
extern fd_topo_run_tile_t fd_tile_eqvoc;
8080
extern fd_topo_run_tile_t fd_tile_rpcserv;
@@ -102,7 +102,7 @@ fd_topo_run_tile_t * TILES[] = {
102102
&fd_tile_execor,
103103
&fd_tile_writer,
104104
&fd_tile_batch,
105-
&fd_tile_pohi,
105+
&fd_tile_poh,
106106
&fd_tile_sender,
107107
&fd_tile_eqvoc,
108108
&fd_tile_rpcserv,

src/app/firedancer/topology.c

Lines changed: 8 additions & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -299,7 +299,7 @@ fd_topo_initialize( config_t * config ) {
299299
fd_topob_wksp( topo, "writer" );
300300
fd_topob_wksp( topo, "bstore" );
301301
fd_topob_wksp( topo, "tcache" );
302-
fd_topob_wksp( topo, "pohi" );
302+
fd_topob_wksp( topo, "poh" );
303303
fd_topob_wksp( topo, "voter" );
304304
fd_topob_wksp( topo, "poh_slot" );
305305
fd_topob_wksp( topo, "turb_slot" );
@@ -438,7 +438,7 @@ fd_topo_initialize( config_t * config ) {
438438
/**/ fd_topob_tile( topo, "sign", "sign", "metric_in", tile_to_cpu[ topo->tile_cnt ], 0, 1 );
439439
/**/ fd_topob_tile( topo, "metric", "metric", "metric_in", tile_to_cpu[ topo->tile_cnt ], 0, 0 );
440440
fd_topo_tile_t * pack_tile = fd_topob_tile( topo, "pack", "pack", "metric_in", tile_to_cpu[ topo->tile_cnt ], 0, 0 );
441-
/**/ fd_topob_tile( topo, "pohi", "pohi", "metric_in", tile_to_cpu[ topo->tile_cnt ], 0, 0 );
441+
/**/ fd_topob_tile( topo, "poh", "poh", "metric_in", tile_to_cpu[ topo->tile_cnt ], 0, 1 );
442442
/**/ fd_topob_tile( topo, "gossip", "gossip", "metric_in", tile_to_cpu[ topo->tile_cnt ], 0, 0 );
443443
fd_topo_tile_t * repair_tile = fd_topob_tile( topo, "repair", "repair", "metric_in", tile_to_cpu[ topo->tile_cnt ], 0, 0 );
444444
/**/ fd_topob_tile( topo, "sender", "voter", "metric_in", tile_to_cpu[ topo->tile_cnt ], 0, 0 );
@@ -689,12 +689,12 @@ fd_topo_initialize( config_t * config ) {
689689
/**/ fd_topob_tile_in( topo, "pack", 0UL, "metric_in", "dedup_pack", 0UL, FD_TOPOB_RELIABLE, FD_TOPOB_POLLED ); /* No reliable consumers of networking fragments, may be dropped or overrun */
690690
/**/ fd_topob_tile_in( topo, "pack", 0UL, "metric_in", "poh_pack", 0UL, FD_TOPOB_UNRELIABLE, FD_TOPOB_POLLED );
691691
/**/ fd_topob_tile_out( topo, "pack", 0UL, "pack_replay", 0UL );
692-
FOR(bank_tile_cnt) fd_topob_tile_in( topo, "pohi", 0UL, "metric_in", "replay_poh", i, FD_TOPOB_UNRELIABLE, FD_TOPOB_POLLED ); /* No reliable consumers of networking fragments, may be dropped or overrun */
693-
/**/ fd_topob_tile_in( topo, "pohi", 0UL, "metric_in", "stake_out", 0UL, FD_TOPOB_UNRELIABLE, FD_TOPOB_POLLED ); /* No reliable consumers of networking fragments, may be dropped or overrun */
694-
/**/ fd_topob_tile_out( topo, "pohi", 0UL, "poh_shred", 0UL );
692+
FOR(bank_tile_cnt) fd_topob_tile_in( topo, "poh", 0UL, "metric_in", "replay_poh", i, FD_TOPOB_UNRELIABLE, FD_TOPOB_POLLED ); /* No reliable consumers of networking fragments, may be dropped or overrun */
693+
/**/ fd_topob_tile_in( topo, "poh", 0UL, "metric_in", "stake_out", 0UL, FD_TOPOB_UNRELIABLE, FD_TOPOB_POLLED ); /* No reliable consumers of networking fragments, may be dropped or overrun */
694+
/**/ fd_topob_tile_out( topo, "poh", 0UL, "poh_shred", 0UL );
695695

696-
/**/ fd_topob_tile_in( topo, "pohi", 0UL, "metric_in", "pack_replay", 0UL, FD_TOPOB_RELIABLE, FD_TOPOB_POLLED );
697-
fd_topob_tile_out( topo, "pohi", 0UL, "poh_pack", 0UL );
696+
/**/ fd_topob_tile_in( topo, "poh", 0UL, "metric_in", "pack_replay", 0UL, FD_TOPOB_RELIABLE, FD_TOPOB_POLLED );
697+
fd_topob_tile_out( topo, "poh", 0UL, "poh_pack", 0UL );
698698

699699
/**/ fd_topob_tile_in( topo, "sign", 0UL, "metric_in", "repair_sign", 0UL, FD_TOPOB_UNRELIABLE, FD_TOPOB_POLLED );
700700
/**/ fd_topob_tile_out( topo, "repair", 0UL, "repair_sign", 0UL );
@@ -911,7 +911,7 @@ fd_topo_initialize( config_t * config ) {
911911
tile->pack.larger_shred_limits_per_block = config->development.bench.larger_shred_limits_per_block;
912912
tile->pack.use_consumed_cus = config->tiles.pack.use_consumed_cus;
913913
if( FD_UNLIKELY( tile->pack.use_consumed_cus ) ) FD_LOG_ERR(( "Firedancer does not support CU rebating yet. [tiles.pack.use_consumed_cus] must be false" ));
914-
} else if( FD_UNLIKELY( !strcmp( tile->name, "pohi" ) ) ) {
914+
} else if( FD_UNLIKELY( !strcmp( tile->name, "poh" ) ) ) {
915915
strncpy( tile->poh.identity_key_path, config->paths.identity_key, sizeof(tile->poh.identity_key_path) );
916916

917917
tile->poh.bank_cnt = config->layout.bank_tile_count;

src/disco/topo/fd_topo.c

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -206,7 +206,7 @@ fd_topo_tile_extra_normal_pages( fd_topo_tile_t const * tile ) {
206206

207207
!strcmp( tile->name, "gossip" ) ||
208208
!strcmp( tile->name, "repair" ) ||
209-
!strcmp( tile->name, "pohi" ) ||
209+
!strcmp( tile->name, "poh" ) ||
210210
!strcmp( tile->name, "storei" ) ) ) {
211211
/* Certain tiles using fd_keyload_load need normal pages to hold
212212
key material. */

src/disco/topo/fd_topob.c

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -357,7 +357,7 @@ fd_topob_auto_layout( fd_topo_t * topo,
357357
"pack",
358358
"bank", /* FRANK only */
359359
"poh", /* FRANK only */
360-
"pohi", /* FIREDANCER only */
360+
"poh", /* FIREDANCER only */
361361
"shred",
362362
"store", /* FRANK only */
363363
"storei", /* FIREDANCER only */

src/discof/bank/fd_bank_abi.c

Lines changed: 33 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -59,3 +59,36 @@ fd_bank_abi_resolve_address_lookup_tables( void const * bank FD_PARAM_UNUSED
5959
void fd_ext_bank_release( void const * bank FD_PARAM_UNUSED) {
6060
FD_LOG_ERR(("nope"));
6161
}
62+
63+
int
64+
fd_ext_admin_rpc_set_identity( uchar const * identity_keypair FD_PARAM_UNUSED,
65+
int require_tower FD_PARAM_UNUSED) {
66+
FD_LOG_ERR(("nope"));
67+
return 0;
68+
}
69+
70+
void
71+
fd_ext_bank_acquire( void const * bank FD_PARAM_UNUSED) {
72+
FD_LOG_ERR(("nope"));
73+
}
74+
75+
int
76+
fd_ext_bank_load_account( void const * bank FD_PARAM_UNUSED,
77+
int fixed_root FD_PARAM_UNUSED,
78+
uchar const * addr FD_PARAM_UNUSED,
79+
uchar * owner FD_PARAM_UNUSED,
80+
uchar * data FD_PARAM_UNUSED,
81+
ulong * data_sz FD_PARAM_UNUSED) {
82+
FD_LOG_ERR(("nope"));
83+
return 0;
84+
}
85+
86+
void
87+
fd_ext_poh_register_tick( void const * bank FD_PARAM_UNUSED, uchar const * hash FD_PARAM_UNUSED) {
88+
FD_LOG_ERR(("nope"));
89+
}
90+
91+
void
92+
fd_ext_poh_signal_leader_change( void * sender FD_PARAM_UNUSED) {
93+
FD_LOG_ERR(("nope"));
94+
}

src/discof/bank/fd_bank_abi.h

Lines changed: 21 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -39,6 +39,27 @@ fd_bank_abi_resolve_address_lookup_tables( void const * bank,
3939

4040
void fd_ext_bank_release( void const * bank );
4141

42+
int
43+
fd_ext_admin_rpc_set_identity( uchar const * identity_keypair,
44+
int require_tower );
45+
46+
void
47+
fd_ext_bank_acquire( void const * bank );
48+
49+
int
50+
fd_ext_bank_load_account( void const * bank,
51+
int fixed_root,
52+
uchar const * addr,
53+
uchar * owner,
54+
uchar * data,
55+
ulong * data_sz );
56+
57+
void
58+
fd_ext_poh_register_tick( void const * bank, uchar const * hash );
59+
60+
void
61+
fd_ext_poh_signal_leader_change( void * sender );
62+
4263
FD_PROTOTYPES_END
4364

4465
#endif

src/discof/poh/Local.mk

Lines changed: 1 addition & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -1,10 +1,3 @@
1-
ifdef FD_HAS_HOSTED
2-
ifdef FD_HAS_LINUX
3-
ifdef FD_HAS_INT128
41
ifdef FD_HAS_SSE
5-
$(call add-hdrs,fd_poh.h)
6-
$(call add-objs,fd_pohi_tile fd_poh,fd_discof)
7-
endif
8-
endif
9-
endif
2+
$(call add-objs,fd_poh_tile,fd_discof)
103
endif

0 commit comments

Comments
 (0)