@@ -1789,14 +1789,14 @@ int mca_spml_ucx_team_get_config(shmem_team_t team, long config_mask,
1789
1789
}
1790
1790
1791
1791
static inline int mca_spml_ucx_is_pe_in_strided_team (int src_pe , int start ,
1792
- int stride , int size )
1792
+ int stride , int size )
1793
1793
{
1794
1794
return (src_pe >= start ) && (src_pe < start + size * stride )
1795
1795
&& ((src_pe - start ) % stride == 0 );
1796
1796
}
1797
1797
1798
1798
int mca_spml_ucx_team_translate_pe (shmem_team_t src_team , int src_pe ,
1799
- shmem_team_t dest_team )
1799
+ shmem_team_t dest_team )
1800
1800
{
1801
1801
mca_spml_ucx_team_t * ucx_src_team = (mca_spml_ucx_team_t * ) src_team ;
1802
1802
mca_spml_ucx_team_t * ucx_dest_team = (mca_spml_ucx_team_t * ) dest_team ;
@@ -1831,7 +1831,8 @@ int mca_spml_ucx_team_split_strided(shmem_team_t parent_team, int start, int
1831
1831
int parent_stride ;
1832
1832
int my_pe ;
1833
1833
1834
- SPML_UCX_ASSERT (((start + size * stride ) <= oshmem_num_procs ()) && (start < size ) && (stride > 0 ) && (size > 0 ));
1834
+ SPML_UCX_ASSERT (((start + size * stride ) <= oshmem_num_procs ()) &&
1835
+ (stride > 0 ) && (size > 0 ));
1835
1836
1836
1837
if (parent_team == SHMEM_TEAM_WORLD ) {
1837
1838
parent_pe = shmem_my_pe ();
@@ -1855,7 +1856,7 @@ int mca_spml_ucx_team_split_strided(shmem_team_t parent_team, int start, int
1855
1856
/* In order to simplify pe translations start and stride are calculated with respect to
1856
1857
* world_team */
1857
1858
ucx_new_team = (mca_spml_ucx_team_t * )malloc (sizeof (mca_spml_ucx_team_t ));
1858
- ucx_new_team -> start = parent_start + start ;
1859
+ ucx_new_team -> start = parent_start + ( start * parent_stride ) ;
1859
1860
ucx_new_team -> stride = parent_stride * stride ;
1860
1861
1861
1862
ucx_new_team -> n_pes = size ;
@@ -1867,7 +1868,6 @@ int mca_spml_ucx_team_split_strided(shmem_team_t parent_team, int start, int
1867
1868
memcpy (& ucx_new_team -> config -> super , config , sizeof (shmem_team_config_t ));
1868
1869
}
1869
1870
1870
- ucx_new_team -> config = (mca_spml_ucx_team_config_t * )config ;
1871
1871
ucx_new_team -> parent_team = (mca_spml_ucx_team_t * )parent_team ;
1872
1872
1873
1873
* new_team = (shmem_team_t )ucx_new_team ;
0 commit comments