#include "CUDA2HIP.h" // Map of all functions const std::map CUDA_RAND_FUNCTION_MAP{ // RAND Host functions {"curandCreateGenerator", {"hiprandCreateGenerator", CONV_MATH_FUNC, API_RAND}}, {"curandCreateGeneratorHost", {"hiprandCreateGeneratorHost", CONV_MATH_FUNC, API_RAND}}, {"curandCreatePoissonDistribution", {"hiprandCreatePoissonDistribution", CONV_MATH_FUNC, API_RAND}}, {"curandDestroyDistribution", {"hiprandDestroyDistribution", CONV_MATH_FUNC, API_RAND}}, {"curandDestroyGenerator", {"hiprandDestroyGenerator", CONV_MATH_FUNC, API_RAND}}, {"curandGenerate", {"hiprandGenerate", CONV_MATH_FUNC, API_RAND}}, {"curandGenerateLogNormal", {"hiprandGenerateLogNormal", CONV_MATH_FUNC, API_RAND}}, {"curandGenerateLogNormalDouble", {"hiprandGenerateLogNormalDouble", CONV_MATH_FUNC, API_RAND}}, {"curandGenerateLongLong", {"hiprandGenerateLongLong", CONV_MATH_FUNC, API_RAND, HIP_UNSUPPORTED}}, {"curandGenerateNormal", {"hiprandGenerateNormal", CONV_MATH_FUNC, API_RAND}}, {"curandGenerateNormalDouble", {"hiprandGenerateNormalDouble", CONV_MATH_FUNC, API_RAND}}, {"curandGeneratePoisson", {"hiprandGeneratePoisson", CONV_MATH_FUNC, API_RAND}}, {"curandGenerateSeeds", {"hiprandGenerateSeeds", CONV_MATH_FUNC, API_RAND}}, {"curandGenerateUniform", {"hiprandGenerateUniform", CONV_MATH_FUNC, API_RAND}}, {"curandGenerateUniformDouble", {"hiprandGenerateUniformDouble", CONV_MATH_FUNC, API_RAND}}, {"curandGetDirectionVectors32", {"hiprandGetDirectionVectors32", CONV_MATH_FUNC, API_RAND, HIP_UNSUPPORTED}}, {"curandGetDirectionVectors64", {"hiprandGetDirectionVectors64", CONV_MATH_FUNC, API_RAND, HIP_UNSUPPORTED}}, {"curandGetProperty", {"hiprandGetProperty", CONV_MATH_FUNC, API_RAND, HIP_UNSUPPORTED}}, {"curandGetScrambleConstants32", {"hiprandGetScrambleConstants32", CONV_MATH_FUNC, API_RAND, HIP_UNSUPPORTED}}, {"curandGetScrambleConstants64", {"hiprandGetScrambleConstants64", CONV_MATH_FUNC, API_RAND, HIP_UNSUPPORTED}}, {"curandGetVersion", {"hiprandGetVersion", CONV_MATH_FUNC, API_RAND}}, {"curandSetGeneratorOffset", {"hiprandSetGeneratorOffset", CONV_MATH_FUNC, API_RAND}}, {"curandSetGeneratorOrdering", {"hiprandSetGeneratorOrdering", CONV_MATH_FUNC, API_RAND, HIP_UNSUPPORTED}}, {"curandSetPseudoRandomGeneratorSeed", {"hiprandSetPseudoRandomGeneratorSeed", CONV_MATH_FUNC, API_RAND}}, {"curandSetQuasiRandomGeneratorDimensions", {"hiprandSetQuasiRandomGeneratorDimensions", CONV_MATH_FUNC, API_RAND}}, {"curandSetStream", {"hiprandSetStream", CONV_MATH_FUNC, API_RAND}}, // RAND Device functions {"curand", {"hiprand", CONV_DEVICE_FUNC, API_RAND}}, {"curand_init", {"hiprand_init", CONV_DEVICE_FUNC, API_RAND}}, {"curand_log_normal", {"hiprand_log_normal", CONV_DEVICE_FUNC, API_RAND}}, {"curand_log_normal_double", {"hiprand_log_normal_double", CONV_DEVICE_FUNC, API_RAND}}, {"curand_log_normal2", {"hiprand_log_normal2", CONV_DEVICE_FUNC, API_RAND}}, {"curand_log_normal2_double", {"hiprand_log_normal2_double", CONV_DEVICE_FUNC, API_RAND}}, {"curand_log_normal4", {"hiprand_log_normal4", CONV_DEVICE_FUNC, API_RAND}}, {"curand_log_normal4_double", {"hiprand_log_normal4_double", CONV_DEVICE_FUNC, API_RAND}}, {"curand_mtgp32_single", {"hiprand_mtgp32_single", CONV_DEVICE_FUNC, API_RAND, HIP_UNSUPPORTED}}, {"curand_mtgp32_single_specific", {"hiprand_mtgp32_single_specific", CONV_DEVICE_FUNC, API_RAND, HIP_UNSUPPORTED}}, {"curand_mtgp32_specific", {"hiprand_mtgp32_specific", CONV_DEVICE_FUNC, API_RAND, HIP_UNSUPPORTED}}, {"curand_normal", {"hiprand_normal", CONV_DEVICE_FUNC, API_RAND}}, {"curand_normal_double", {"hiprand_normal_double", CONV_DEVICE_FUNC, API_RAND}}, {"curand_normal2", {"hiprand_normal2", CONV_DEVICE_FUNC, API_RAND}}, {"curand_normal2_double", {"hiprand_normal2_double", CONV_DEVICE_FUNC, API_RAND}}, {"curand_normal4", {"hiprand_normal4", CONV_DEVICE_FUNC, API_RAND}}, {"curand_normal4_double", {"hiprand_normal4_double", CONV_DEVICE_FUNC, API_RAND}}, {"curand_uniform", {"hiprand_uniform", CONV_DEVICE_FUNC, API_RAND}}, {"curand_uniform_double", {"hiprand_uniform_double", CONV_DEVICE_FUNC, API_RAND}}, {"curand_uniform2_double", {"hiprand_uniform2_double", CONV_DEVICE_FUNC, API_RAND}}, {"curand_uniform4", {"hiprand_uniform4", CONV_DEVICE_FUNC, API_RAND}}, {"curand_uniform4_double", {"hiprand_uniform4_double", CONV_DEVICE_FUNC, API_RAND}}, {"curand_discrete", {"hiprand_discrete", CONV_DEVICE_FUNC, API_RAND}}, {"curand_discrete4", {"hiprand_discrete4", CONV_DEVICE_FUNC, API_RAND}}, {"curand_poisson", {"hiprand_poisson", CONV_DEVICE_FUNC, API_RAND}}, {"curand_poisson4", {"hiprand_poisson4", CONV_DEVICE_FUNC, API_RAND}}, {"curand_Philox4x32_10", {"hiprand_Philox4x32_10", CONV_DEVICE_FUNC, API_RAND, HIP_UNSUPPORTED}}, // unchanged function names: skipahead, skipahead_sequence, skipahead_subsequence };