Skip to content

Commit ae84717

Browse files
authored
[flang][cuda] Fix descriptor sync in data transfer (#129333)
The destination descriptor on the device needs to be sync with the destination descriptor on the host, not the src one.
1 parent b3e05d5 commit ae84717

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

flang-rt/lib/cuda/memory.cpp

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -147,7 +147,7 @@ void RTDECL(CUFDataTransferGlobalDescDesc)(Descriptor *dstDesc,
147147
void *deviceAddr{
148148
RTNAME(CUFGetDeviceAddress)((void *)dstDesc, sourceFile, sourceLine)};
149149
RTNAME(CUFDescriptorSync)
150-
((Descriptor *)deviceAddr, srcDesc, sourceFile, sourceLine);
150+
((Descriptor *)deviceAddr, dstDesc, sourceFile, sourceLine);
151151
}
152152
}
153153
}

0 commit comments

Comments
 (0)