Inconsistency in maximum rank
It looks to me as if there is an inconsistency in how UCC determines the maximum rank within a team. On the one hand, there's this code in src/utils/ucc_datastruct.h that says the maximum rank is UINT32_MAX - 1 (4,294,967,295):
https://github.com/openucx/ucc/blob/56df2df8dfb5e9d87130149962d4bd0fd52072e0/src/utils/ucc_datastruct.h#L14-L15
On the other hand, within the UCP TL, this code seems to only handle a maximum of 24 bits (16,777,216):
https://github.com/openucx/ucc/blob/56df2df8dfb5e9d87130149962d4bd0fd52072e0/src/components/tl/ucp/tl_ucp_tag.h#L9-L22
I don't think it's likely that either maximum is being hit right now, but it would probably be good to be consistent. Particularly as different TLs could potentially support different maximum sizes.
you are right. probably need to add a TL iface to query max size and in runtime disqualify TLs if user team size exceeds max supported. While UCC_RANK_MAX is internal max for any TL.