@@ -22,16 +22,16 @@ fd_epoch_stakes_new( void * shmem, ulong slot_max ) {
2222
2323 FD_SCRATCH_ALLOC_INIT ( l , shmem );
2424 fd_epoch_stakes_t * epoch_stakes = FD_SCRATCH_ALLOC_APPEND ( l , alignof(fd_epoch_stakes_t ), sizeof (fd_epoch_stakes_t ) );
25- void * voter_stake_map = FD_SCRATCH_ALLOC_APPEND ( l , fd_voter_stake_map_align (), fd_voter_stake_map_footprint ( FD_VOTER_MAX * slot_max ) );
25+ void * voter_stake_map = FD_SCRATCH_ALLOC_APPEND ( l , fd_voter_stake_map_align (), fd_voter_stake_map_footprint ( FD_VOTER_MAX * slot_max ) );
2626 void * voter_stake_pool = FD_SCRATCH_ALLOC_APPEND ( l , fd_voter_stake_pool_align (), fd_voter_stake_pool_footprint ( FD_VOTER_MAX * slot_max ) );
2727 void * epoch_stakes_slot_map = FD_SCRATCH_ALLOC_APPEND ( l , fd_epoch_stakes_slot_map_align (), fd_epoch_stakes_slot_map_footprint ( lg_slot_cnt ) );
2828 void * used_acc_scratch = FD_SCRATCH_ALLOC_APPEND ( l , fd_used_acc_scratch_align (), fd_used_acc_scratch_footprint ( FD_VOTER_MAX * slot_max ) );
29- FD_LOG_NOTICE (( " layout l: %lu, shmem: %lu, footprint: %lu" , _l , (ulong )shmem , footprint ) );
30- //FD_TEST( FD_SCRATCH_ALLOC_FINI( l, fd_epoch_stakes_align() ) == (ulong)shmem + footprint );
31- epoch_stakes -> voter_stake_map = fd_voter_stake_map_join ( fd_voter_stake_map_new ( voter_stake_map , FD_VOTER_MAX * slot_max , 0 ) );
32- epoch_stakes -> voter_stake_pool = fd_voter_stake_pool_join ( fd_voter_stake_pool_new ( voter_stake_pool , FD_VOTER_MAX * slot_max ) );
29+ FD_TEST ( FD_SCRATCH_ALLOC_FINI ( l , fd_epoch_stakes_align () ) == (ulong )shmem + footprint );
30+
31+ epoch_stakes -> voter_stake_map = fd_voter_stake_map_join ( fd_voter_stake_map_new ( voter_stake_map , FD_VOTER_MAX * slot_max , 0 ) );
32+ epoch_stakes -> voter_stake_pool = fd_voter_stake_pool_join ( fd_voter_stake_pool_new ( voter_stake_pool , FD_VOTER_MAX * slot_max ) );
3333 epoch_stakes -> slot_stakes_map = fd_epoch_stakes_slot_map_join ( fd_epoch_stakes_slot_map_new ( epoch_stakes_slot_map , lg_slot_cnt ) );
34- epoch_stakes -> used_acc_scratch = fd_used_acc_scratch_join ( fd_used_acc_scratch_new ( used_acc_scratch , FD_VOTER_MAX * slot_max ) );
34+ epoch_stakes -> used_acc_scratch = fd_used_acc_scratch_join ( fd_used_acc_scratch_new ( used_acc_scratch , FD_VOTER_MAX * slot_max ) );
3535 return shmem ;
3636}
3737
0 commit comments