Skip to content

Commit 0dd3f39

Browse files
clementvalPhilippRados
authored andcommitted
[flang][cuda] Fix not declared terminator (llvm#114866)
1 parent a91cb0a commit 0dd3f39

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

flang/runtime/CUDA/memory.cpp

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -112,14 +112,14 @@ void RTDEF(CUFDataTransferPtrDesc)(void *addr, Descriptor *desc,
112112
void RTDECL(CUFDataTransferDescDesc)(Descriptor *dstDesc, Descriptor *srcDesc,
113113
unsigned mode, const char *sourceFile, int sourceLine) {
114114
MemmoveFct memmoveFct;
115+
Terminator terminator{sourceFile, sourceLine};
115116
if (mode == kHostToDevice) {
116117
memmoveFct = &MemmoveHostToDevice;
117118
} else if (mode == kDeviceToHost) {
118119
memmoveFct = &MemmoveDeviceToHost;
119120
} else if (mode == kDeviceToDevice) {
120121
memmoveFct = &MemmoveDeviceToDevice;
121122
} else {
122-
Terminator terminator{sourceFile, sourceLine};
123123
terminator.Crash("host to host copy not supported");
124124
}
125125
Fortran::runtime::Assign(

0 commit comments

Comments
 (0)