Skip to content

Commit 988f724

Browse files
committed
osc/rdma: Don't pad the amount, pad the total_size
Signed-off-by: Joseph Schuchart <[email protected]>
1 parent e0bec07 commit 988f724

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

ompi/mca/osc/rdma/osc_rdma_component.c

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -640,7 +640,6 @@ static int allocate_state_shared (ompi_osc_rdma_module_t *module, void **base, s
640640
/* ensure proper alignment */
641641
if (MPI_WIN_FLAVOR_ALLOCATE == module->flavor) {
642642
data_base += OPAL_ALIGN_PAD_AMOUNT(data_base, memory_alignment);
643-
size += OPAL_ALIGN_PAD_AMOUNT(size, memory_alignment);
644643
}
645644

646645
do {
@@ -868,6 +867,7 @@ static int allocate_state_shared (ompi_osc_rdma_module_t *module, void **base, s
868867
peer->flags |= OMPI_OSC_RDMA_PEER_CPU_ATOMICS;
869868
}
870869
offset += temp[i].size;
870+
offset += OPAL_ALIGN_PAD_AMOUNT(offset, memory_alignment);
871871
} else {
872872
ex_peer->super.base = peer_region->base;
873873

0 commit comments

Comments
 (0)