Handle async cuda copy

This commit is contained in:
William S. Moses 2021-12-29 02:49:40 -05:00 committed by William Moses
parent 8a879a4e8c
commit c689e8b21b
1 changed files with 4 additions and 1 deletions

View File

@ -2234,6 +2234,7 @@ ValueCategory MLIRScanner::VisitCallExpr(clang::CallExpr *expr) {
} }
if (sr->getDecl()->getIdentifier() && if (sr->getDecl()->getIdentifier() &&
(sr->getDecl()->getName() == "cudaMemcpy" || (sr->getDecl()->getName() == "cudaMemcpy" ||
sr->getDecl()->getName() == "cudaMemcpyAsync" ||
sr->getDecl()->getName() == "cudaMemcpyToSymbol" || sr->getDecl()->getName() == "cudaMemcpyToSymbol" ||
sr->getDecl()->getName() == "memcpy" || sr->getDecl()->getName() == "memcpy" ||
sr->getDecl()->getName() == "__builtin_memcpy")) { sr->getDecl()->getName() == "__builtin_memcpy")) {
@ -2586,13 +2587,15 @@ ValueCategory MLIRScanner::VisitCallExpr(clang::CallExpr *expr) {
"calloc", "calloc",
"free", "free",
"fgets", "fgets",
"__erno_location", "__errno_location",
"__assert_fail", "__assert_fail",
"cudaEventElapsedTime", "cudaEventElapsedTime",
"cudaEventSynchronize", "cudaEventSynchronize",
"cudaDeviceGetAttribute", "cudaDeviceGetAttribute",
"cudaFuncGetAttributes", "cudaFuncGetAttributes",
"cudaGetDevice", "cudaGetDevice",
"cudaGetDeviceCount",
"clock_gettime",
"cudaOccupancyMaxActiveBlocksPerMultiprocessor", "cudaOccupancyMaxActiveBlocksPerMultiprocessor",
"cudaOccupancyMaxActiveBlocksPerMultiprocessorWithFlags", "cudaOccupancyMaxActiveBlocksPerMultiprocessorWithFlags",
"cudaEventRecord"}; "cudaEventRecord"};