@@ -303,15 +303,15 @@ int ompi_spc_register_params()
303303 & ompi_mpi_spc_p2p_message_boundary );
304304
305305 ompi_mpi_spc_collective_message_boundary = 12288 ;
306- (void ) mca_base_var_register ("ompi" , "mpi" , NULL , "spc_message_boundary " ,
306+ (void ) mca_base_var_register ("ompi" , "mpi" , NULL , "spc_collective_message_boundary " ,
307307 "An integer value for determining the boundary for whether a message is small/large for collective bin counters (<= this value is small)." ,
308308 MCA_BASE_VAR_TYPE_INT , NULL , 0 , 0 ,
309309 OPAL_INFO_LVL_4 ,
310310 MCA_BASE_VAR_SCOPE_READONLY ,
311311 & ompi_mpi_spc_collective_message_boundary );
312312
313313 ompi_mpi_spc_collective_comm_boundary = 64 ;
314- (void ) mca_base_var_register ("ompi" , "mpi" , NULL , "spc_comm_boundary " ,
314+ (void ) mca_base_var_register ("ompi" , "mpi" , NULL , "spc_collective_comm_boundary " ,
315315 "An integer value for determining the boundary for whether a communicator is small/large for collective bin counters (<= this value is small)." ,
316316 MCA_BASE_VAR_TYPE_INT , NULL , 0 , 0 ,
317317 OPAL_INFO_LVL_4 ,
@@ -918,24 +918,26 @@ void ompi_spc_init(void)
918918 * ###################### Initialize Bin Counters Here ####################
919919 * ########################################################################
920920 */
921+ /* NOTE: These should be initialized even if they aren't currently turned on.
922+ * This is just in case they are turned on mid-run through MPI_T.
923+ */
924+ /* STEP 3a: Regular bin counters initialized here. */
921925 int * rules = NULL ;
922926 ompi_spc_value_t * bins = NULL ;
923927
924- if (IS_SPC_BIT_SET (ompi_spc_attached_event ,OMPI_SPC_P2P_MESSAGE_SIZE )) {
925- rules = (int * )(ompi_spc_events + ompi_spc_offsets [OMPI_SPC_P2P_MESSAGE_SIZE ].rules_offset );
926- bins = (ompi_spc_value_t * )(ompi_spc_events + ompi_spc_offsets [OMPI_SPC_P2P_MESSAGE_SIZE ].bins_offset );
928+ rules = (int * )(ompi_spc_events + ompi_spc_offsets [OMPI_SPC_P2P_MESSAGE_SIZE ].rules_offset );
929+ bins = (ompi_spc_value_t * )(ompi_spc_events + ompi_spc_offsets [OMPI_SPC_P2P_MESSAGE_SIZE ].bins_offset );
927930
928- bins [0 ] = bins [1 ] = 0 ;
931+ bins [0 ] = bins [1 ] = 0 ;
929932
930- rules [0 ] = 2 ; /* The number of bins */
931- rules [1 ] = ompi_mpi_spc_p2p_message_boundary ; /* The number after which counters go in the second bin */
932- }
933+ rules [0 ] = 2 ; /* The number of bins */
934+ rules [1 ] = ompi_mpi_spc_p2p_message_boundary ; /* The number after which counters go in the second bin */
933935
934936 /* Initialize Collective Bin Counters Here */
935937 int num_bins = 4 ; /* This can be expanded to be more flexible */
936938
937939 for (i = 0 ; i < OMPI_SPC_NUM_COUNTERS ; i ++ ) {
938- if (IS_SPC_BIT_SET (ompi_spc_attached_event , i ) && IS_SPC_BIT_SET ( ompi_spc_collective_bin_event ,i )) {
940+ if (IS_SPC_BIT_SET (ompi_spc_collective_bin_event ,i )) {
939941 rules = (int * )(ompi_spc_events + ompi_spc_offsets [i ].rules_offset );
940942 bins = (ompi_spc_value_t * )(ompi_spc_events + ompi_spc_offsets [i ].bins_offset );
941943
0 commit comments