[HIPIFY][#1490][fix] Populate the list of supported device atomic functions

+ Update hipify-perl accordingly
+ Add atomics.cu test on all atomics


[ROCm/hip commit: b5f17e8ff0]
This commit is contained in:
Evgeny Mankov
2019-10-01 13:57:46 +03:00
parent 34e20b8568
commit 3652d77965
3 changed files with 324 additions and 18 deletions
@@ -599,9 +599,21 @@ const std::map<llvm::StringRef, hipCounter> CUDA_DEVICE_FUNC_MAP{
{"h2exp10", {"", "", CONV_DEVICE_FUNC, API_RUNTIME}},
{"h2cos", {"", "", CONV_DEVICE_FUNC, API_RUNTIME}},
{"h2sin", {"", "", CONV_DEVICE_FUNC, API_RUNTIME}},
{"__shfl_sync", {"", "", CONV_DEVICE_FUNC, API_RUNTIME, UNSUPPORTED}},
{"__shfl_up_sync", {"", "", CONV_DEVICE_FUNC, API_RUNTIME, UNSUPPORTED}},
{"__shfl_down_sync",{"", "", CONV_DEVICE_FUNC, API_RUNTIME, UNSUPPORTED}},
{"__shfl_xor_sync", {"", "", CONV_DEVICE_FUNC, API_RUNTIME, UNSUPPORTED}},
{"atomicAdd", {"", "", CONV_DEVICE_FUNC, API_RUNTIME, UNSUPPORTED}},
{"__shfl_sync", {"", "", CONV_DEVICE_FUNC, API_RUNTIME, UNSUPPORTED}},
{"__shfl_up_sync", {"", "", CONV_DEVICE_FUNC, API_RUNTIME, UNSUPPORTED}},
{"__shfl_down_sync", {"", "", CONV_DEVICE_FUNC, API_RUNTIME, UNSUPPORTED}},
{"__shfl_xor_sync", {"", "", CONV_DEVICE_FUNC, API_RUNTIME, UNSUPPORTED}},
// atomic functions
{"atomicAdd", {"", "", CONV_DEVICE_FUNC, API_RUNTIME}},
{"atomicSub", {"", "", CONV_DEVICE_FUNC, API_RUNTIME}},
{"atomicExch", {"", "", CONV_DEVICE_FUNC, API_RUNTIME}},
{"atomicMin", {"", "", CONV_DEVICE_FUNC, API_RUNTIME}},
{"atomicMax", {"", "", CONV_DEVICE_FUNC, API_RUNTIME}},
{"atomicInc", {"", "", CONV_DEVICE_FUNC, API_RUNTIME}},
{"atomicDec", {"", "", CONV_DEVICE_FUNC, API_RUNTIME}},
{"atomicDec", {"", "", CONV_DEVICE_FUNC, API_RUNTIME}},
{"atomicAnd", {"", "", CONV_DEVICE_FUNC, API_RUNTIME}},
{"atomicOr", {"", "", CONV_DEVICE_FUNC, API_RUNTIME}},
{"atomicXor", {"", "", CONV_DEVICE_FUNC, API_RUNTIME}},
{"atomicCAS", {"", "", CONV_DEVICE_FUNC, API_RUNTIME}},
};