@@ -736,28 +736,21 @@ 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` */
747741
748742 status = proto -> progress [UCP_PROTO_STAGE_START ](self );
749743 if (ucs_unlikely (UCS_STATUS_IS_ERR (status ))) {
744+ /* NOTE: This function is only called when `progress_wrapper_enabled`
745+ * is `false`, which means that it won't be called when the log level
746+ * is TRACE_REQ or higher. Because of this, `ucs_trace` is used here
747+ * instead of `ucp_trace_req` */
750748 ucs_trace ("progress protocol %s returned: %s lane %d" , proto -> name ,
751749 ucs_status_string (status ), req -> send .lane );
752750 return status ;
753751 }
754752
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- }
753+ ++ proto_config -> selections ;
761754
762755 return UCS_OK ;
763756}
@@ -768,8 +761,6 @@ ucs_status_t ucp_request_progress_wrapper(uct_pending_req_t *self)
768761 ucp_proto_config_t * conf = ucs_const_cast (ucp_proto_config_t * ,
769762 req -> send .proto_config );
770763 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 ;
773764 uct_pending_callback_t progress_cb ;
774765 ucs_status_t status ;
775766
@@ -789,8 +780,7 @@ ucs_status_t ucp_request_progress_wrapper(uct_pending_req_t *self)
789780 ucp_trace_req (req , "progress protocol %s returned: %s lane %d" ,
790781 proto -> name , ucs_status_string (status ), req -> send .lane );
791782 } else {
792- if (req -> send .proto_stage == UCP_PROTO_STAGE_START &&
793- conf -> selections < proto_usage_count_max ) {
783+ if (req -> send .proto_stage == UCP_PROTO_STAGE_START ) {
794784 ++ conf -> selections ;
795785 }
796786
0 commit comments