@@ -736,28 +736,20 @@ ucs_status_t ucp_request_progress_counter(uct_pending_req_t *self)
736736 ucp_proto_config_t * proto_config = ucs_const_cast (ucp_proto_config_t * ,
737737 req -> send .proto_config );
738738 const ucp_proto_t * proto = proto_config -> proto ;
739- unsigned proto_usage_count_max =
740- req -> send .ep -> worker -> context -> config .ext .proto_usage_count_max ;
741739 ucs_status_t status ;
742740
743- /* NOTE: This function is only called when `progress_wrapper_enabled` is
744- `false`, which means that it won't be called when the log level is
745- TRACE_REQ or higher.
746- Because of this, `ucs_trace` is used here instead of `ucp_trace_req` */
747-
748741 status = proto -> progress [UCP_PROTO_STAGE_START ](self );
749742 if (ucs_unlikely (UCS_STATUS_IS_ERR (status ))) {
743+ /* NOTE: This function is only called when `progress_wrapper_enabled`
744+ * is `false`, which means that it won't be called when the log level
745+ * is TRACE_REQ or higher. Because of this, `ucs_trace` is used here
746+ * instead of `ucp_trace_req` */
750747 ucs_trace ("progress protocol %s returned: %s lane %d" , proto -> name ,
751748 ucs_status_string (status ), req -> send .lane );
752749 return status ;
753750 }
754751
755- if (ucs_unlikely (++ proto_config -> selections == proto_usage_count_max )) {
756- ucs_trace ("protocol %s was selected %u times, stop tracing" ,
757- proto -> name , proto_config -> selections );
758- memcpy (proto_config -> progress_wrapper , proto -> progress ,
759- sizeof (proto_config -> progress_wrapper ));
760- }
752+ ++ proto_config -> selections ;
761753
762754 return UCS_OK ;
763755}
@@ -768,8 +760,6 @@ ucs_status_t ucp_request_progress_wrapper(uct_pending_req_t *self)
768760 ucp_proto_config_t * conf = ucs_const_cast (ucp_proto_config_t * ,
769761 req -> send .proto_config );
770762 const ucp_proto_t * proto = conf -> proto ;
771- unsigned proto_usage_count_max =
772- req -> send .ep -> worker -> context -> config .ext .proto_usage_count_max ;
773763 uct_pending_callback_t progress_cb ;
774764 ucs_status_t status ;
775765
@@ -789,8 +779,7 @@ ucs_status_t ucp_request_progress_wrapper(uct_pending_req_t *self)
789779 ucp_trace_req (req , "progress protocol %s returned: %s lane %d" ,
790780 proto -> name , ucs_status_string (status ), req -> send .lane );
791781 } else {
792- if (req -> send .proto_stage == UCP_PROTO_STAGE_START &&
793- conf -> selections < proto_usage_count_max ) {
782+ if (req -> send .proto_stage == UCP_PROTO_STAGE_START ) {
794783 ++ conf -> selections ;
795784 }
796785
0 commit comments