From 4d7b8ce2d67511de0903041a5fd7ea4abbda73d3 Mon Sep 17 00:00:00 2001 From: Stanley Tsang Date: Wed, 19 Dec 2018 12:21:02 -0500 Subject: [PATCH 01/16] Adding support in the hipify-perl tool for the HIP_SYMBOL macro, which is required for hip API calls involving a device symbol. Added more explicit mention of the HIP_SYMBOL macro in the porting guide. [ROCm/hip commit: 6531262126d68844b70f9659e41316b753c81d8e] --- projects/hip/bin/hipify-perl | 7 ++++--- projects/hip/docs/markdown/hip_porting_guide.md | 2 ++ 2 files changed, 6 insertions(+), 3 deletions(-) diff --git a/projects/hip/bin/hipify-perl b/projects/hip/bin/hipify-perl index 792bf86d94..191d845ed3 100755 --- a/projects/hip/bin/hipify-perl +++ b/projects/hip/bin/hipify-perl @@ -269,7 +269,8 @@ while (@ARGV) { $ft{'mem'} += s/\bcudaMemcpyDeviceToHost\b/hipMemcpyDeviceToHost/g; $ft{'mem'} += s/\bcudaMemcpyDeviceToDevice\b/hipMemcpyDeviceToDevice/g; $ft{'mem'} += s/\bcudaMemcpyDefault\b/hipMemcpyDefault/g; - $ft{'mem'} += s/\bcudaMemcpyToSymbol\b/hipMemcpyToSymbol/g; + $ft{'mem'} += s/\bcudaMemcpyToSymbol\s*\(\s*(\w+)\b/hipMemcpyToSymbol\(HIP_SYMBOL\($1\)/g; + $ft{'mem'} += s/\bcudaMemcpyFromSymbol\s*\(\s*(.+?)\s*,\s*(.+?)\b/hipMemcpyFromSymbol\($1, HIP_SYMBOL\($2\)/g; $ft{'mem'} += s/\bcudaMemset\b/hipMemset/g; $ft{'mem'} += s/\bcudaMemsetAsync\b/hipMemsetAsync/g; @@ -287,8 +288,8 @@ while (@ARGV) { $ft{'mem'} += s/\bcudaMemcpy2DToArray\b/hipMemcpy2DToArray/g; $ft{'mem'} += s/\bcudaMemcpyToArray\b/hipMemcpyToArray/g; - $ft{'mem'} += s/\bcudaGetSymbolAddress\b/hipGetSymbolAddress/g; - $ft{'mem'} += s/\bcudaGetSymbolSize\b/hipGetSymbolSize/g; + $ft{'mem'} += s/\bcudaGetSymbolAddress\s*\(\s*(.+?)\s*,\s*(.+?)\b/hipGetSymbolAddress\($1, HIP_SYMBOL\($2\)/g; + $ft{'mem'} += s/\bcudaGetSymbolSize\s*\(\s*&(\w+)\s*,\s*(.+?)\b/hipGetSymbolSize(&$1, HIP_SYMBOL\($2\)/g; #-------- # Memory management: diff --git a/projects/hip/docs/markdown/hip_porting_guide.md b/projects/hip/docs/markdown/hip_porting_guide.md index 6fa0b958a8..90854c3a46 100644 --- a/projects/hip/docs/markdown/hip_porting_guide.md +++ b/projects/hip/docs/markdown/hip_porting_guide.md @@ -418,6 +418,8 @@ HIP support for hipMemcpyToSymbol is complete. This feature allows a kernel to define a device-side data symbol which can be accessed on the host side. The symbol can be in __constant or device space. +Note that the symbol name needs to be encased in the HIP_SYMBOL macro, as shown in the code example below. This also applies to hipMemcpyFromSymbol, hipGetSymbolAddress, and hipGetSymbolSize. + For example: Device Code: From 5ef42da9256f41c48bb94527294ebffd7441ca70 Mon Sep 17 00:00:00 2001 From: "Yaxun (Sam) Liu" Date: Thu, 31 Jan 2019 15:18:37 -0500 Subject: [PATCH 02/16] Update hip_programming_guide.md [ROCm/hip commit: 56f78897a41884c9e022a8c5c8853baad3b613f1] --- projects/hip/docs/markdown/hip_programming_guide.md | 6 +++++- 1 file changed, 5 insertions(+), 1 deletion(-) diff --git a/projects/hip/docs/markdown/hip_programming_guide.md b/projects/hip/docs/markdown/hip_programming_guide.md index 52d250cab5..b9ab362159 100644 --- a/projects/hip/docs/markdown/hip_programming_guide.md +++ b/projects/hip/docs/markdown/hip_programming_guide.md @@ -109,4 +109,8 @@ freed. The memory are allocated in pages. Users can define macro `__HIP_SIZE_OF_PAGE` for controlling the page size in bytes and macro `__HIP_NUM_PAGES` for controlling the total number of pages that can be -allocated. \ No newline at end of file +allocated. + +## Use of Long Double Type + +In HCC and HIP-Clang, long double type is 80-bit extended precision format for x86_64, which is not supported by AMDGPU. HCC and HIP-Cang treat long double type as IEEE double type for AMDGPU. Using long double type in HIP source code will not cause issue as long as data of long double type is not transferred between host and device. However, long double type should not be used as kernel argument type. From caf2e353ce0f260a784463768df55a6ef7d588b9 Mon Sep 17 00:00:00 2001 From: "Yaxun (Sam) Liu" Date: Thu, 31 Jan 2019 16:26:30 -0500 Subject: [PATCH 03/16] Update hip_programming_guide.md [ROCm/hip commit: c0d7a7ec31f282dce3a6e1af8132be64bf7f0138] --- projects/hip/docs/markdown/hip_programming_guide.md | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/projects/hip/docs/markdown/hip_programming_guide.md b/projects/hip/docs/markdown/hip_programming_guide.md index b9ab362159..8922a7c4b3 100644 --- a/projects/hip/docs/markdown/hip_programming_guide.md +++ b/projects/hip/docs/markdown/hip_programming_guide.md @@ -113,4 +113,4 @@ allocated. ## Use of Long Double Type -In HCC and HIP-Clang, long double type is 80-bit extended precision format for x86_64, which is not supported by AMDGPU. HCC and HIP-Cang treat long double type as IEEE double type for AMDGPU. Using long double type in HIP source code will not cause issue as long as data of long double type is not transferred between host and device. However, long double type should not be used as kernel argument type. +In HCC and HIP-Clang, long double type is 80-bit extended precision format for x86_64, which is not supported by AMDGPU. HCC and HIP-Clang treat long double type as IEEE double type for AMDGPU. Using long double type in HIP source code will not cause issue as long as data of long double type is not transferred between host and device. However, long double type should not be used as kernel argument type. From bb14376f507cb050e33a83521c621da31f6ff4b4 Mon Sep 17 00:00:00 2001 From: Aaron Enye Shi Date: Fri, 1 Feb 2019 16:52:55 +0000 Subject: [PATCH 04/16] hipcc defaults to HIP-Clang if built with HIP-Clang Add HIP_COMPILER to hipConfig, so that HIP packages built with HIP_COMPILER for HIP-Clang will be known during runtime by hipcc. Also add default locations to check for llvm and device-libs. [ROCm/hip commit: 489cef167fdecee667596d5cecd71f4108436fce] --- projects/hip/CMakeLists.txt | 1 + projects/hip/bin/hipcc | 7 ++++--- 2 files changed, 5 insertions(+), 3 deletions(-) diff --git a/projects/hip/CMakeLists.txt b/projects/hip/CMakeLists.txt index 3db80f9e7e..7a0d3e70dc 100644 --- a/projects/hip/CMakeLists.txt +++ b/projects/hip/CMakeLists.txt @@ -71,6 +71,7 @@ if(NOT (HIP_COMPILER STREQUAL "hcc" OR HIP_COMPILER STREQUAL "clang")) message(FATAL_ERROR "Must use HIP_COMPILER as hcc or clang") endif() message(STATUS "HIP Compiler: " ${HIP_COMPILER}) +add_to_config(_buildInfo HIP_COMPILER) # If HIP_PLATFORM is hcc, we need HCC_HOME and HSA_PATH to be defined diff --git a/projects/hip/bin/hipcc b/projects/hip/bin/hipcc index a717a0bf92..bc47287f4a 100755 --- a/projects/hip/bin/hipcc +++ b/projects/hip/bin/hipcc @@ -58,8 +58,8 @@ $HIPCC_LINK_FLAGS_APPEND=$ENV{'HIPCC_LINK_FLAGS_APPEND'}; $HIP_PATH=$ENV{'HIP_PATH'} // dirname (dirname $0); # use parent directory of hipcc $HIP_VDI_HOME=$ENV{'HIP_VDI_HOME'}; -$HIP_CLANG_PATH=$ENV{'HIP_CLANG_PATH'}; -$DEVICE_LIB_PATH=$ENV{'DEVICE_LIB_PATH'}; +$HIP_CLANG_PATH=$ENV{'HIP_CLANG_PATH'} // "/opt/rocm/llvm/bin"; +$DEVICE_LIB_PATH=$ENV{'DEVICE_LIB_PATH'} // "/opt/rocm/lib"; $HIP_CLANG_HCC_COMPAT_MODE=$ENV{'HIP_CLANG_HCC_COMPAT_MODE'}; # HCC compatibility mode #--- @@ -93,6 +93,7 @@ sub delete_temp_dirs { $HIP_PLATFORM= `$HIP_PATH/bin/hipconfig --platform` // "hcc"; $HIP_VERSION= `$HIP_PATH/bin/hipconfig --version`; ($HIP_VERSION_MAJOR, $HIP_VERSION_MINOR, $HIP_VERSION_PATCH) = split(/\./, $HIP_VERSION); +$HIP_COMPILER=$hipConfig{'HIP_COMPILER'}; if (defined $HIP_VDI_HOME) { my $bits = ""; @@ -110,7 +111,7 @@ if (defined $HIP_VDI_HOME) { $HIP_LIB_PATH = "$HIP_VDI_HOME/lib" . $bits; } -if (defined $HIP_CLANG_PATH) { +if ($HIP_COMPILER eq "clang") { $HIP_PLATFORM = "clang" } From f051cd1b713b34ce9a1c80ff7574e6126f2b8d75 Mon Sep 17 00:00:00 2001 From: Aaron Enye Shi Date: Fri, 1 Feb 2019 19:44:26 +0000 Subject: [PATCH 05/16] Add HIP_RUNTIME for HCC or VDI [ROCm/hip commit: 479d2d093fd5d7e8c0b0d9c50ca4e2f36a8751d1] --- projects/hip/CMakeLists.txt | 9 +++++++++ projects/hip/bin/hipcc | 20 ++++++++++++++++---- 2 files changed, 25 insertions(+), 4 deletions(-) diff --git a/projects/hip/CMakeLists.txt b/projects/hip/CMakeLists.txt index 7a0d3e70dc..c826c1a782 100644 --- a/projects/hip/CMakeLists.txt +++ b/projects/hip/CMakeLists.txt @@ -73,6 +73,15 @@ endif() message(STATUS "HIP Compiler: " ${HIP_COMPILER}) add_to_config(_buildInfo HIP_COMPILER) +# Determine HIP_RUNTIME +# Either HCC or VDI; default is HCC +if(NOT DEFINED ENV{HIP_RUNTIME}) + set(HIP_RUNTIME "HCC" CACHE STRING "HIP Runtime") +else() + set(HIP_RUNTIME $ENV{HIP_RUNTIME} CACHE STRING "HIP Runtime") +endif() +add_to_config(_buildInfo HIP_RUNTIME) + # If HIP_PLATFORM is hcc, we need HCC_HOME and HSA_PATH to be defined if(HIP_PLATFORM STREQUAL "hcc") diff --git a/projects/hip/bin/hipcc b/projects/hip/bin/hipcc index bc47287f4a..6557a2e04f 100755 --- a/projects/hip/bin/hipcc +++ b/projects/hip/bin/hipcc @@ -58,8 +58,8 @@ $HIPCC_LINK_FLAGS_APPEND=$ENV{'HIPCC_LINK_FLAGS_APPEND'}; $HIP_PATH=$ENV{'HIP_PATH'} // dirname (dirname $0); # use parent directory of hipcc $HIP_VDI_HOME=$ENV{'HIP_VDI_HOME'}; -$HIP_CLANG_PATH=$ENV{'HIP_CLANG_PATH'} // "/opt/rocm/llvm/bin"; -$DEVICE_LIB_PATH=$ENV{'DEVICE_LIB_PATH'} // "/opt/rocm/lib"; +$HIP_CLANG_PATH=$ENV{'HIP_CLANG_PATH'}; +$DEVICE_LIB_PATH=$ENV{'DEVICE_LIB_PATH'}; $HIP_CLANG_HCC_COMPAT_MODE=$ENV{'HIP_CLANG_HCC_COMPAT_MODE'}; # HCC compatibility mode #--- @@ -93,7 +93,13 @@ sub delete_temp_dirs { $HIP_PLATFORM= `$HIP_PATH/bin/hipconfig --platform` // "hcc"; $HIP_VERSION= `$HIP_PATH/bin/hipconfig --version`; ($HIP_VERSION_MAJOR, $HIP_VERSION_MINOR, $HIP_VERSION_PATCH) = split(/\./, $HIP_VERSION); -$HIP_COMPILER=$hipConfig{'HIP_COMPILER'}; +$HIP_COMPILER= $hipConfig{'HIP_COMPILER'}; +$HIP_RUNTIME= $hipConfig{'HIP_RUNTIME'}; + +# If using VDI runtime, need to find HIP_VDI_HOME +if ($HIP_RUNTIME eq "VDI" and !defined $HIP_VDI_HOME) { + $HIP_VDI_HOME = "/opt/rocm/hip" +} if (defined $HIP_VDI_HOME) { my $bits = ""; @@ -112,7 +118,13 @@ if (defined $HIP_VDI_HOME) { } if ($HIP_COMPILER eq "clang") { - $HIP_PLATFORM = "clang" + $HIP_PLATFORM = "clang"; + if (!defined $HIP_CLANG_PATH) { + $HIP_CLANG_PATH = "/opt/rocm/llvm/bin"; + } + if (!defined $DEVICE_LIB_PATH) { + $DEVICE_LIB_PATH = "/opt/rocm/lib"; + } } if ($verbose & 0x2) { From f20cd64d6afbdcb73f95656bd41f70c45c5c098b Mon Sep 17 00:00:00 2001 From: David Rohr Date: Mon, 4 Feb 2019 15:07:06 +0100 Subject: [PATCH 06/16] Use -isystem instead of -I to suppress warnings in HIP headers [ROCm/hip commit: e04e391f3a3cf557cddaed78bc753b42507a4f68] --- projects/hip/bin/hipcc | 14 +++++++------- 1 file changed, 7 insertions(+), 7 deletions(-) diff --git a/projects/hip/bin/hipcc b/projects/hip/bin/hipcc index a717a0bf92..cecd184708 100755 --- a/projects/hip/bin/hipcc +++ b/projects/hip/bin/hipcc @@ -193,7 +193,7 @@ if ($HIP_PLATFORM eq "clang") { # HCC* may be used to compile src/hip_hcc.o (and also feed the HIPCXXFLAGS below) $HCC = "$HCC_HOME/bin/hcc"; - $HCCFLAGS = "-hc -D__HIPCC__ -I$HCC_HOME/include "; + $HCCFLAGS = "-hc -D__HIPCC__ -isystem $HCC_HOME/include "; $HIPCC=$HCC; $HIPCXXFLAGS = $HCCFLAGS; @@ -215,7 +215,7 @@ if ($HIP_PLATFORM eq "clang") { # That's because HCC already uses libstdc++ by default if a newer g++/libstdc++ is available # Cent OS 7 and RHEL 7.4 cannot use libstdc++ for compilation, default to libc++ if (${GCC_CUR_VER} eq ${GPP_CUR_VER} and $GPP_VER_FIELDS[0] < 5 and ($HOST_OSNAME ne "\"centos\"") and ($HOST_OSNAME ne "\"rhel\"")) { - $HCC_WA_FLAGS .= " -stdlib=libstdc++ -I/usr/include/x86_64-linux-gnu -I/usr/include/x86_64-linux-gnu/c++/${GCC_CUR_VER} -I/usr/include/c++/${GCC_CUR_VER} "; + $HCC_WA_FLAGS .= " -stdlib=libstdc++ -isystem /usr/include/x86_64-linux-gnu -isystem /usr/include/x86_64-linux-gnu/c++/${GCC_CUR_VER} -isystem /usr/include/c++/${GCC_CUR_VER} "; # Add C++ libs for GCC. $HIPLDFLAGS .= " -lstdc++"; } @@ -228,8 +228,8 @@ if ($HIP_PLATFORM eq "clang") { $setStdLib = 1; } - $HIPCXXFLAGS .= " -I$HIP_PATH/include/hip/hcc_detail/cuda"; - $HIPCXXFLAGS .= " -I$HSA_PATH/include"; + $HIPCXXFLAGS .= " -isystem $HIP_PATH/include/hip/hcc_detail/cuda"; + $HIPCXXFLAGS .= " -isystem $HSA_PATH/include"; $HIPCXXFLAGS .= " -Wno-deprecated-register"; $HIPLDFLAGS .= " -L$HSA_PATH/lib -L$ROCM_PATH/lib -lhsa-runtime64 -lhc_am "; @@ -240,7 +240,7 @@ if ($HIP_PLATFORM eq "clang") { if ($HIP_ATP_MARKER) { $marker_inc_path = "$marker_path/include"; if (-e $marker_inc_path) { - $HIPCXXFLAGS .= " -I$marker_inc_path"; + $HIPCXXFLAGS .= " -isystem $marker_inc_path"; } } @@ -265,7 +265,7 @@ if ($HIP_PLATFORM eq "clang") { $HIPCC="$CUDA_PATH/bin/nvcc"; $HIPCXXFLAGS .= " -Wno-deprecated-gpu-targets "; - $HIPCXXFLAGS .= " -I$CUDA_PATH/include"; + $HIPCXXFLAGS .= " -isystem $CUDA_PATH/include"; $HIPLDFLAGS = " -Wno-deprecated-gpu-targets -lcuda -lcudart -L$CUDA_PATH/lib64"; } else { @@ -274,7 +274,7 @@ if ($HIP_PLATFORM eq "clang") { } # Add paths to common HIP includes: -$HIPCXXFLAGS .= " -I$HIP_INCLUDE_PATH -DHIP_VERSION_MAJOR=$HIP_VERSION_MAJOR -DHIP_VERSION_MINOR=$HIP_VERSION_MINOR -DHIP_VERSION_PATCH=$HIP_VERSION_PATCH" ; +$HIPCXXFLAGS .= " -isystem $HIP_INCLUDE_PATH -DHIP_VERSION_MAJOR=$HIP_VERSION_MAJOR -DHIP_VERSION_MINOR=$HIP_VERSION_MINOR -DHIP_VERSION_PATCH=$HIP_VERSION_PATCH" ; my $compileOnly = 0; my $needCXXFLAGS = 0; # need to add CXX flags to compile step From 44e082db66d572008e011aedb076045fe563a9a8 Mon Sep 17 00:00:00 2001 From: Rahul Garg Date: Tue, 5 Feb 2019 06:30:57 +0530 Subject: [PATCH 07/16] Fix error codes in P2P sample test [ROCm/hip commit: e8cf9cba6bea05e048c3bfc1dc0ce98ac10dfdcc] --- projects/hip/samples/2_Cookbook/8_peer2peer/peer2peer.cpp | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/projects/hip/samples/2_Cookbook/8_peer2peer/peer2peer.cpp b/projects/hip/samples/2_Cookbook/8_peer2peer/peer2peer.cpp index ecdcad4bd2..8e011b1281 100644 --- a/projects/hip/samples/2_Cookbook/8_peer2peer/peer2peer.cpp +++ b/projects/hip/samples/2_Cookbook/8_peer2peer/peer2peer.cpp @@ -43,7 +43,8 @@ using namespace std; #define HIPCHECK(error) \ { \ hipError_t localError = error; \ - if ((localError != hipSuccess)||(localError != hipErrorPeerAccessAlreadyEnabled)) { \ + if ((localError != hipSuccess)&& (localError != hipErrorPeerAccessAlreadyEnabled)&& \ + (localError != hipErrorPeerAccessNotEnabled )) { \ printf("%serror: '%s'(%d) from %s at %s:%d%s\n", KRED, hipGetErrorString(localError), \ localError, #error, __FILE__, __LINE__, KNRM); \ failed("API returned error code."); \ From 089077a8b75525758ed8b9307e66d40c209eedf6 Mon Sep 17 00:00:00 2001 From: Rahul Garg Date: Mon, 4 Feb 2019 22:45:13 -0800 Subject: [PATCH 08/16] Revert "Fixed issue of GPU device losing access to host pinned memory" [ROCm/hip commit: 3120db15e46c13699098fc909007b0f26dc316f8] --- projects/hip/src/hip_peer.cpp | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/projects/hip/src/hip_peer.cpp b/projects/hip/src/hip_peer.cpp index 12a047e94f..cffb895c57 100644 --- a/projects/hip/src/hip_peer.cpp +++ b/projects/hip/src/hip_peer.cpp @@ -129,7 +129,7 @@ hipError_t ihipEnablePeerAccess(hipCtx_t peerCtx, unsigned int flags) { LockedAccessor_CtxCrit_t peerCrit(peerCtx->criticalData()); // Add thisCtx to peerCtx's access list so that new allocations on peer will be made // visible to this device: - bool isNewPeer = peerCrit->addPeerWatcher(thisCtx, peerCtx); + bool isNewPeer = peerCrit->addPeerWatcher(peerCtx, thisCtx); if (isNewPeer) { tprintf(DB_MEM, "device=%s can now see all memory allocated on peer=%s\n", thisCtx->toString().c_str(), peerCtx->toString().c_str()); From f724c69c4e44bac3dcbe08c8c2e18fea243b5296 Mon Sep 17 00:00:00 2001 From: Yaxun Sam Liu Date: Tue, 5 Feb 2019 12:21:10 -0500 Subject: [PATCH 09/16] Fix build failure on windows due to vector type [ROCm/hip commit: 43c144fe68358402a2baddc6e4a403fb180eacf3] --- projects/hip/include/hip/hcc_detail/hip_vector_types.h | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/projects/hip/include/hip/hcc_detail/hip_vector_types.h b/projects/hip/include/hip/hcc_detail/hip_vector_types.h index 924498583d..acfb16423f 100644 --- a/projects/hip/include/hip/hcc_detail/hip_vector_types.h +++ b/projects/hip/include/hip/hcc_detail/hip_vector_types.h @@ -34,7 +34,7 @@ THE SOFTWARE. #include "hip/hcc_detail/host_defines.h" -#if !defined(_MSC_VER) +#if !defined(_MSC_VER) || __HIP_DEVICE_COMPILE__ #if defined(__clang__) #define __NATIVE_VECTOR__(n, ...) __attribute__((ext_vector_type(n))) #elif defined(__GNUC__) // N.B.: GCC does not support .xyzw syntax. From df3b7c22a4de1320687b4611ff31a5e323fcd1ee Mon Sep 17 00:00:00 2001 From: Yaxun Sam Liu Date: Tue, 5 Feb 2019 14:27:57 -0500 Subject: [PATCH 10/16] Add windows specific compilation options [ROCm/hip commit: 52df98a5d181a800fbc416bcc02df3380f7de631] --- projects/hip/bin/hipcc | 5 +++++ 1 file changed, 5 insertions(+) diff --git a/projects/hip/bin/hipcc b/projects/hip/bin/hipcc index a717a0bf92..54324951a7 100755 --- a/projects/hip/bin/hipcc +++ b/projects/hip/bin/hipcc @@ -750,6 +750,11 @@ if ($HIP_PLATFORM eq "clang") { $HIPLDFLAGS .= " -lgcc_s -lgcc -lpthread -lm"; } +# Windows specific options +if ($^O eq 'MSWin32' and $HIP_PLATFORM eq "clang") { + $HIPCXXFLAGS .= " -std=c++14 -fms-extensions -fms-compatibility" +} + if ($HIPCC_COMPILE_FLAGS_APPEND) { $HIPCXXFLAGS .= " $HIPCC_COMPILE_FLAGS_APPEND"; } From 1bbb9d455beacf3574b042f73f95727379ad76db Mon Sep 17 00:00:00 2001 From: Laurent Morichetti Date: Tue, 5 Feb 2019 14:43:26 -0800 Subject: [PATCH 11/16] Add code-object-v3 support for the HIP-Clang path. [ROCm/hip commit: 6ab8711f02100ed2498302c64db28c2b8a84b324] --- projects/hip/src/hip_clang.cpp | 8 ++++++-- 1 file changed, 6 insertions(+), 2 deletions(-) diff --git a/projects/hip/src/hip_clang.cpp b/projects/hip/src/hip_clang.cpp index ef8d456103..0d210e2b8c 100644 --- a/projects/hip/src/hip_clang.cpp +++ b/projects/hip/src/hip_clang.cpp @@ -132,8 +132,12 @@ extern "C" void __hipRegisterFunction( assert(modules && modules->size() >= g_deviceCnt); for (int deviceId = 0; deviceId < g_deviceCnt; ++deviceId) { hipFunction_t function; - if (hipSuccess == hipModuleGetFunction(&function, modules->at(deviceId), deviceName) && - function != nullptr) { + if ((hipSuccess == hipModuleGetFunction(&function, modules->at(deviceId), deviceName) || + // With code-object-v3, we need to match the kernel descriptor symbol name + (hipSuccess == hipModuleGetFunction( + &function, modules->at(deviceId), + (std::string(deviceName) + std::string(".kd")).c_str() + ))) && function != nullptr) { functions[deviceId] = function; } else { From af1b0a2834db2408bc0b4391594c2121bbc4b433 Mon Sep 17 00:00:00 2001 From: Evgeny Mankov Date: Wed, 6 Feb 2019 18:47:21 +0300 Subject: [PATCH 12/16] [HIPIFY][BLAS] Support of hipifying cuBLAS to rocBLAS [ROCm/hip commit: 389807095e28e1a9be22d1ed278501ac2a1b30ef] --- .../markdown/CUBLAS_API_supported_by_HIP.md | 16 +- .../src/CUDA2HIP_BLAS_API_functions.cpp | 908 +++++++++--------- .../src/CUDA2HIP_BLAS_API_types.cpp | 201 ++-- 3 files changed, 560 insertions(+), 565 deletions(-) diff --git a/projects/hip/docs/markdown/CUBLAS_API_supported_by_HIP.md b/projects/hip/docs/markdown/CUBLAS_API_supported_by_HIP.md index 750703f4e1..388b86d8ef 100644 --- a/projects/hip/docs/markdown/CUBLAS_API_supported_by_HIP.md +++ b/projects/hip/docs/markdown/CUBLAS_API_supported_by_HIP.md @@ -99,13 +99,13 @@ |`cublasGetVersion_v2` | | |`cublasGetProperty` | | |`cublasGetStream` |`hipblasGetStream` | -|`cublasGetStream_v2` |`hipblasGetStream_v2` | +|`cublasGetStream_v2` |`hipblasGetStream` | |`cublasSetStream` |`hipblasSetStream` | -|`cublasSetStream_v2` |`hipblasSetStream_v2` | +|`cublasSetStream_v2` |`hipblasSetStream` | |`cublasGetPointerMode` |`hipblasGetPointerMode` | -|`cublasGetPointerMode_v2` |`hipblasGetPointerMode_v2` | +|`cublasGetPointerMode_v2` |`hipblasGetPointerMode` | |`cublasSetPointerMode` |`hipblasSetPointerMode` | -|`cublasSetPointerMode_v2` |`hipblasSetPointerMode_v2` | +|`cublasSetPointerMode_v2` |`hipblasSetPointerMode` | |`cublasGetAtomicsMode` | | |`cublasSetAtomicsMode` | | |`cublasGetMathMode` | | @@ -382,8 +382,8 @@ |`cublasSgemm_v2` |`hipblasSgemm` | |`cublasDgemm` |`hipblasDgemm` | |`cublasDgemm_v2` |`hipblasDgemm` | -|`cublasCgemm` |`hipblasCgemm` | -|`cublasCgemm_v2` |`hipblasCgemm` | +|`cublasCgemm` | | +|`cublasCgemm_v2` | | |`cublasCgemm3m` | | |`cublasCgemm3mEx` | | |`cublasZgemm` | | @@ -464,8 +464,8 @@ |`cublasZgemmBatched` | | |`cublasGemmBatchedEx` | | |`cublasGemmStridedBatchedEx` | | -|`cublasSgemmStridedBatched` | | -|`cublasDgemmStridedBatched` | | +|`cublasSgemmStridedBatched` |`hipblasSgemmStridedBatched` | +|`cublasDgemmStridedBatched` |`hipblasDgemmStridedBatched` | |`cublasCgemmStridedBatched` | | |`cublasCgemm3mStridedBatched` | | |`cublasZgemmStridedBatched` | | diff --git a/projects/hip/hipify-clang/src/CUDA2HIP_BLAS_API_functions.cpp b/projects/hip/hipify-clang/src/CUDA2HIP_BLAS_API_functions.cpp index e6f5033038..b6bdf4ebe9 100644 --- a/projects/hip/hipify-clang/src/CUDA2HIP_BLAS_API_functions.cpp +++ b/projects/hip/hipify-clang/src/CUDA2HIP_BLAS_API_functions.cpp @@ -26,659 +26,659 @@ THE SOFTWARE. const std::map CUDA_BLAS_FUNCTION_MAP{ // Blas management functions - {"cublasInit", {"hipblasInit", "", CONV_LIB_FUNC, API_BLAS, HIP_UNSUPPORTED}}, - {"cublasShutdown", {"hipblasShutdown", "", CONV_LIB_FUNC, API_BLAS, HIP_UNSUPPORTED}}, - {"cublasGetVersion", {"hipblasGetVersion", "", CONV_LIB_FUNC, API_BLAS, HIP_UNSUPPORTED}}, - {"cublasGetError", {"hipblasGetError", "", CONV_LIB_FUNC, API_BLAS, HIP_UNSUPPORTED}}, - {"cublasAlloc", {"hipblasAlloc", "", CONV_LIB_FUNC, API_BLAS, HIP_UNSUPPORTED}}, - {"cublasFree", {"hipblasFree", "", CONV_LIB_FUNC, API_BLAS, HIP_UNSUPPORTED}}, - {"cublasSetKernelStream", {"hipblasSetKernelStream", "", CONV_LIB_FUNC, API_BLAS, HIP_UNSUPPORTED}}, - {"cublasGetAtomicsMode", {"hipblasGetAtomicsMode", "", CONV_LIB_FUNC, API_BLAS, HIP_UNSUPPORTED}}, - {"cublasSetAtomicsMode", {"hipblasSetAtomicsMode", "", CONV_LIB_FUNC, API_BLAS, HIP_UNSUPPORTED}}, - {"cublasGetMathMode", {"hipblasGetMathMode", "", CONV_LIB_FUNC, API_BLAS, HIP_UNSUPPORTED}}, - {"cublasSetMathMode", {"hipblasSetMathMode", "", CONV_LIB_FUNC, API_BLAS, HIP_UNSUPPORTED}}, + {"cublasInit", {"hipblasInit", "", CONV_LIB_FUNC, API_BLAS, UNSUPPORTED}}, + {"cublasShutdown", {"hipblasShutdown", "", CONV_LIB_FUNC, API_BLAS, UNSUPPORTED}}, + {"cublasGetVersion", {"hipblasGetVersion", "", CONV_LIB_FUNC, API_BLAS, UNSUPPORTED}}, + {"cublasGetError", {"hipblasGetError", "", CONV_LIB_FUNC, API_BLAS, UNSUPPORTED}}, + {"cublasAlloc", {"hipblasAlloc", "", CONV_LIB_FUNC, API_BLAS, UNSUPPORTED}}, + {"cublasFree", {"hipblasFree", "", CONV_LIB_FUNC, API_BLAS, UNSUPPORTED}}, + {"cublasSetKernelStream", {"hipblasSetKernelStream", "", CONV_LIB_FUNC, API_BLAS, UNSUPPORTED}}, + {"cublasGetAtomicsMode", {"hipblasGetAtomicsMode", "", CONV_LIB_FUNC, API_BLAS, UNSUPPORTED}}, + {"cublasSetAtomicsMode", {"hipblasSetAtomicsMode", "", CONV_LIB_FUNC, API_BLAS, UNSUPPORTED}}, + {"cublasGetMathMode", {"hipblasGetMathMode", "", CONV_LIB_FUNC, API_BLAS, UNSUPPORTED}}, + {"cublasSetMathMode", {"hipblasSetMathMode", "", CONV_LIB_FUNC, API_BLAS, UNSUPPORTED}}, // Blas logging - {"cublasLogCallback", {"hipblasLogCallback", "", CONV_LIB_FUNC, API_BLAS, HIP_UNSUPPORTED}}, - {"cublasLoggerConfigure", {"hipblasLoggerConfigure", "", CONV_LIB_FUNC, API_BLAS, HIP_UNSUPPORTED}}, - {"cublasSetLoggerCallback", {"hipblasSetLoggerCallback", "", CONV_LIB_FUNC, API_BLAS, HIP_UNSUPPORTED}}, - {"cublasGetLoggerCallback", {"hipblasGetLoggerCallback", "", CONV_LIB_FUNC, API_BLAS, HIP_UNSUPPORTED}}, + {"cublasLogCallback", {"hipblasLogCallback", "", CONV_LIB_FUNC, API_BLAS, UNSUPPORTED}}, + {"cublasLoggerConfigure", {"hipblasLoggerConfigure", "", CONV_LIB_FUNC, API_BLAS, UNSUPPORTED}}, + {"cublasSetLoggerCallback", {"hipblasSetLoggerCallback", "", CONV_LIB_FUNC, API_BLAS, UNSUPPORTED}}, + {"cublasGetLoggerCallback", {"hipblasGetLoggerCallback", "", CONV_LIB_FUNC, API_BLAS, UNSUPPORTED}}, // Blas1 (v1) Routines - {"cublasCreate", {"hipblasCreate", "", CONV_LIB_FUNC, API_BLAS}}, - {"cublasDestroy", {"hipblasDestroy", "", CONV_LIB_FUNC, API_BLAS}}, - {"cublasSetStream", {"hipblasSetStream", "", CONV_LIB_FUNC, API_BLAS}}, - {"cublasGetStream", {"hipblasGetStream", "", CONV_LIB_FUNC, API_BLAS}}, - {"cublasGetPointerMode", {"hipblasGetPointerMode", "", CONV_LIB_FUNC, API_BLAS}}, - {"cublasSetPointerMode", {"hipblasSetPointerMode", "", CONV_LIB_FUNC, API_BLAS}}, - {"cublasSetVector", {"hipblasSetVector", "", CONV_LIB_FUNC, API_BLAS}}, - {"cublasGetVector", {"hipblasGetVector", "", CONV_LIB_FUNC, API_BLAS}}, - {"cublasSetVectorAsync", {"hipblasSetVectorAsync", "", CONV_LIB_FUNC, API_BLAS, HIP_UNSUPPORTED}}, - {"cublasGetVectorAsync", {"hipblasGetVectorAsync", "", CONV_LIB_FUNC, API_BLAS, HIP_UNSUPPORTED}}, - {"cublasSetMatrix", {"hipblasSetMatrix", "", CONV_LIB_FUNC, API_BLAS}}, - {"cublasGetMatrix", {"hipblasGetMatrix", "", CONV_LIB_FUNC, API_BLAS}}, - {"cublasGetMatrixAsync", {"hipblasGetMatrixAsync", "", CONV_LIB_FUNC, API_BLAS, HIP_UNSUPPORTED}}, - {"cublasSetMatrixAsync", {"hipblasSetMatrixAsync", "", CONV_LIB_FUNC, API_BLAS, HIP_UNSUPPORTED}}, - {"cublasXerbla", {"hipblasXerbla", "", CONV_LIB_FUNC, API_BLAS, HIP_UNSUPPORTED}}, + {"cublasCreate", {"hipblasCreate", "rocblas_create_handle", CONV_LIB_FUNC, API_BLAS}}, + {"cublasDestroy", {"hipblasDestroy", "rocblas_destroy_handle", CONV_LIB_FUNC, API_BLAS}}, + {"cublasSetStream", {"hipblasSetStream", "rocblas_set_stream", CONV_LIB_FUNC, API_BLAS}}, + {"cublasGetStream", {"hipblasGetStream", "rocblas_get_stream", CONV_LIB_FUNC, API_BLAS}}, + {"cublasSetPointerMode", {"hipblasSetPointerMode", "rocblas_set_pointer_mode", CONV_LIB_FUNC, API_BLAS}}, + {"cublasGetPointerMode", {"hipblasGetPointerMode", "rocblas_get_pointer_mode", CONV_LIB_FUNC, API_BLAS}}, + {"cublasSetVector", {"hipblasSetVector", "rocblas_set_vector", CONV_LIB_FUNC, API_BLAS}}, + {"cublasGetVector", {"hipblasGetVector", "rocblas_get_vector", CONV_LIB_FUNC, API_BLAS}}, + {"cublasSetVectorAsync", {"hipblasSetVectorAsync", "", CONV_LIB_FUNC, API_BLAS, UNSUPPORTED}}, + {"cublasGetVectorAsync", {"hipblasGetVectorAsync", "", CONV_LIB_FUNC, API_BLAS, UNSUPPORTED}}, + {"cublasSetMatrix", {"hipblasSetMatrix", "rocblas_set_matrix", CONV_LIB_FUNC, API_BLAS}}, + {"cublasGetMatrix", {"hipblasGetMatrix", "rocblas_get_matrix", CONV_LIB_FUNC, API_BLAS}}, + {"cublasSetMatrixAsync", {"hipblasSetMatrixAsync", "", CONV_LIB_FUNC, API_BLAS, UNSUPPORTED}}, + {"cublasGetMatrixAsync", {"hipblasGetMatrixAsync", "", CONV_LIB_FUNC, API_BLAS, UNSUPPORTED}}, + {"cublasXerbla", {"hipblasXerbla", "", CONV_LIB_FUNC, API_BLAS, UNSUPPORTED}}, // NRM2 - {"cublasSnrm2", {"hipblasSnrm2", "", CONV_LIB_FUNC, API_BLAS}}, - {"cublasDnrm2", {"hipblasDnrm2", "", CONV_LIB_FUNC, API_BLAS}}, - {"cublasScnrm2", {"hipblasScnrm2", "", CONV_LIB_FUNC, API_BLAS, HIP_UNSUPPORTED}}, - {"cublasDznrm2", {"hipblasDznrm2", "", CONV_LIB_FUNC, API_BLAS, HIP_UNSUPPORTED}}, - {"cublasNrm2Ex", {"hipblasNrm2Ex", "", CONV_LIB_FUNC, API_BLAS, HIP_UNSUPPORTED}}, + {"cublasSnrm2", {"hipblasSnrm2", "rocblas_snrm2", CONV_LIB_FUNC, API_BLAS}}, + {"cublasDnrm2", {"hipblasDnrm2", "rocblas_dnrm2", CONV_LIB_FUNC, API_BLAS}}, + {"cublasScnrm2", {"hipblasScnrm2", "", CONV_LIB_FUNC, API_BLAS, UNSUPPORTED}}, + {"cublasDznrm2", {"hipblasDznrm2", "", CONV_LIB_FUNC, API_BLAS, UNSUPPORTED}}, + {"cublasNrm2Ex", {"hipblasNrm2Ex", "", CONV_LIB_FUNC, API_BLAS, UNSUPPORTED}}, // DOT - {"cublasSdot", {"hipblasSdot", "", CONV_LIB_FUNC, API_BLAS}}, - // there is no such a function in CUDA - {"cublasSdotBatched", {"hipblasSdotBatched", "", CONV_LIB_FUNC, API_BLAS}}, - {"cublasDdot", {"hipblasDdot", "", CONV_LIB_FUNC, API_BLAS}}, - // there is no such a function in CUDA - {"cublasDdotBatched", {"hipblasDdotBatched", "", CONV_LIB_FUNC, API_BLAS}}, - {"cublasCdotu", {"hipblasCdotu", "", CONV_LIB_FUNC, API_BLAS, HIP_UNSUPPORTED}}, - {"cublasCdotc", {"hipblasCdotc", "", CONV_LIB_FUNC, API_BLAS, HIP_UNSUPPORTED}}, - {"cublasZdotu", {"hipblasZdotu", "", CONV_LIB_FUNC, API_BLAS, HIP_UNSUPPORTED}}, - {"cublasZdotc", {"hipblasZdotc", "", CONV_LIB_FUNC, API_BLAS, HIP_UNSUPPORTED}}, + {"cublasSdot", {"hipblasSdot", "rocblas_sdot", CONV_LIB_FUNC, API_BLAS}}, + // NOTE: there is no such a function in CUDA + {"cublasSdotBatched", {"hipblasSdotBatched", "", CONV_LIB_FUNC, API_BLAS, UNSUPPORTED}}, + {"cublasDdot", {"hipblasDdot", "rocblas_ddot", CONV_LIB_FUNC, API_BLAS}}, + // NOTE: there is no such a function in CUDA + {"cublasDdotBatched", {"hipblasDdotBatched", "", CONV_LIB_FUNC, API_BLAS, UNSUPPORTED}}, + {"cublasCdotu", {"hipblasCdotu", "", CONV_LIB_FUNC, API_BLAS, UNSUPPORTED}}, + {"cublasCdotc", {"hipblasCdotc", "", CONV_LIB_FUNC, API_BLAS, UNSUPPORTED}}, + {"cublasZdotu", {"hipblasZdotu", "", CONV_LIB_FUNC, API_BLAS, UNSUPPORTED}}, + {"cublasZdotc", {"hipblasZdotc", "", CONV_LIB_FUNC, API_BLAS, UNSUPPORTED}}, // SCAL - {"cublasSscal", {"hipblasSscal", "", CONV_LIB_FUNC, API_BLAS}}, - // there is no such a function in CUDA - {"cublasSscalBatched", {"hipblasSscalBatched", "", CONV_LIB_FUNC, API_BLAS}}, - {"cublasDscal", {"hipblasDscal", "", CONV_LIB_FUNC, API_BLAS}}, - // there is no such a function in CUDA - {"cublasDscalBatched", {"hipblasDscalBatched", "", CONV_LIB_FUNC, API_BLAS}}, - {"cublasCscal", {"hipblasCscal", "", CONV_LIB_FUNC, API_BLAS, HIP_UNSUPPORTED}}, - {"cublasCsscal", {"hipblasCsscal", "", CONV_LIB_FUNC, API_BLAS, HIP_UNSUPPORTED}}, - {"cublasZscal", {"hipblasZscal", "", CONV_LIB_FUNC, API_BLAS, HIP_UNSUPPORTED}}, - {"cublasZdscal", {"hipblasZdscal", "", CONV_LIB_FUNC, API_BLAS, HIP_UNSUPPORTED}}, + {"cublasSscal", {"hipblasSscal", "rocblas_sscal", CONV_LIB_FUNC, API_BLAS}}, + // NOTE: there is no such a function in CUDA + {"cublasSscalBatched", {"hipblasSscalBatched", "", CONV_LIB_FUNC, API_BLAS, UNSUPPORTED}}, + {"cublasDscal", {"hipblasDscal", "rocblas_dscal", CONV_LIB_FUNC, API_BLAS}}, + // NOTE: there is no such a function in CUDA + {"cublasDscalBatched", {"hipblasDscalBatched", "", CONV_LIB_FUNC, API_BLAS, UNSUPPORTED}}, + {"cublasCscal", {"hipblasCscal", "", CONV_LIB_FUNC, API_BLAS, UNSUPPORTED}}, + {"cublasCsscal", {"hipblasCsscal", "", CONV_LIB_FUNC, API_BLAS, UNSUPPORTED}}, + {"cublasZscal", {"hipblasZscal", "", CONV_LIB_FUNC, API_BLAS, UNSUPPORTED}}, + {"cublasZdscal", {"hipblasZdscal", "", CONV_LIB_FUNC, API_BLAS, UNSUPPORTED}}, // AXPY - {"cublasSaxpy", {"hipblasSaxpy", "", CONV_LIB_FUNC, API_BLAS}}, - {"cublasSaxpyBatched", {"hipblasSaxpyBatched", "", CONV_LIB_FUNC, API_BLAS}}, - {"cublasDaxpy", {"hipblasDaxpy", "", CONV_LIB_FUNC, API_BLAS}}, - {"cublasCaxpy", {"hipblasCaxpy", "", CONV_LIB_FUNC, API_BLAS, HIP_UNSUPPORTED}}, - {"cublasZaxpy", {"hipblasZaxpy", "", CONV_LIB_FUNC, API_BLAS, HIP_UNSUPPORTED}}, + {"cublasSaxpy", {"hipblasSaxpy", "rocblas_saxpy", CONV_LIB_FUNC, API_BLAS}}, + {"cublasSaxpyBatched", {"hipblasSaxpyBatched", "", CONV_LIB_FUNC, API_BLAS, UNSUPPORTED}}, + {"cublasDaxpy", {"hipblasDaxpy", "rocblas_daxpy", CONV_LIB_FUNC, API_BLAS}}, + {"cublasCaxpy", {"hipblasCaxpy", "", CONV_LIB_FUNC, API_BLAS, UNSUPPORTED}}, + {"cublasZaxpy", {"hipblasZaxpy", "", CONV_LIB_FUNC, API_BLAS, UNSUPPORTED}}, // COPY - {"cublasScopy", {"hipblasScopy", "", CONV_LIB_FUNC, API_BLAS}}, - // there is no such a function in CUDA - {"cublasScopyBatched", {"hipblasScopyBatched", "", CONV_LIB_FUNC, API_BLAS}}, - {"cublasDcopy", {"hipblasDcopy", "", CONV_LIB_FUNC, API_BLAS}}, - // there is no such a function in CUDA - {"cublasDcopyBatched", {"hipblasDcopyBatched", "", CONV_LIB_FUNC, API_BLAS}}, - {"cublasCcopy", {"hipblasCcopy", "", CONV_LIB_FUNC, API_BLAS, HIP_UNSUPPORTED}}, - {"cublasZcopy", {"hipblasZcopy", "", CONV_LIB_FUNC, API_BLAS, HIP_UNSUPPORTED}}, + {"cublasScopy", {"hipblasScopy", "rocblas_scopy", CONV_LIB_FUNC, API_BLAS}}, + // NOTE: there is no such a function in CUDA + {"cublasScopyBatched", {"hipblasScopyBatched", "", CONV_LIB_FUNC, API_BLAS, UNSUPPORTED}}, + {"cublasDcopy", {"hipblasDcopy", "rocblas_dcopy", CONV_LIB_FUNC, API_BLAS}}, + // NOTE: there is no such a function in CUDA + {"cublasDcopyBatched", {"hipblasDcopyBatched", "", CONV_LIB_FUNC, API_BLAS, UNSUPPORTED}}, + {"cublasCcopy", {"hipblasCcopy", "", CONV_LIB_FUNC, API_BLAS, UNSUPPORTED}}, + {"cublasZcopy", {"hipblasZcopy", "", CONV_LIB_FUNC, API_BLAS, UNSUPPORTED}}, // SWAP - {"cublasSswap", {"hipblasSswap", "", CONV_LIB_FUNC, API_BLAS, HIP_UNSUPPORTED}}, - {"cublasDswap", {"hipblasDswap", "", CONV_LIB_FUNC, API_BLAS, HIP_UNSUPPORTED}}, - {"cublasCswap", {"hipblasCswap", "", CONV_LIB_FUNC, API_BLAS, HIP_UNSUPPORTED}}, - {"cublasZswap", {"hipblasZswap", "", CONV_LIB_FUNC, API_BLAS, HIP_UNSUPPORTED}}, + {"cublasSswap", {"hipblasSswap", "rocblas_sswap", CONV_LIB_FUNC, API_BLAS, HIP_UNSUPPORTED}}, + {"cublasDswap", {"hipblasDswap", "rocblas_dswap", CONV_LIB_FUNC, API_BLAS, HIP_UNSUPPORTED}}, + {"cublasCswap", {"hipblasCswap", "", CONV_LIB_FUNC, API_BLAS, UNSUPPORTED}}, + {"cublasZswap", {"hipblasZswap", "", CONV_LIB_FUNC, API_BLAS, UNSUPPORTED}}, // AMAX - {"cublasIsamax", {"hipblasIsamax", "", CONV_LIB_FUNC, API_BLAS}}, - {"cublasIdamax", {"hipblasIdamax", "", CONV_LIB_FUNC, API_BLAS}}, - {"cublasIcamax", {"hipblasIcamax", "", CONV_LIB_FUNC, API_BLAS, HIP_UNSUPPORTED}}, - {"cublasIzamax", {"hipblasIzamax", "", CONV_LIB_FUNC, API_BLAS, HIP_UNSUPPORTED}}, + {"cublasIsamax", {"hipblasIsamax", "rocblas_isamax", CONV_LIB_FUNC, API_BLAS}}, + {"cublasIdamax", {"hipblasIdamax", "rocblas_idamax", CONV_LIB_FUNC, API_BLAS}}, + {"cublasIcamax", {"hipblasIcamax", "", CONV_LIB_FUNC, API_BLAS, UNSUPPORTED}}, + {"cublasIzamax", {"hipblasIzamax", "", CONV_LIB_FUNC, API_BLAS, UNSUPPORTED}}, // AMIN - {"cublasIsamin", {"hipblasIsamin", "", CONV_LIB_FUNC, API_BLAS, HIP_UNSUPPORTED}}, - {"cublasIdamin", {"hipblasIdamin", "", CONV_LIB_FUNC, API_BLAS, HIP_UNSUPPORTED}}, - {"cublasIcamin", {"hipblasIcamin", "", CONV_LIB_FUNC, API_BLAS, HIP_UNSUPPORTED}}, - {"cublasIzamin", {"hipblasIzamin", "", CONV_LIB_FUNC, API_BLAS, HIP_UNSUPPORTED}}, + {"cublasIsamin", {"hipblasIsamin", "rocblas_isamin", CONV_LIB_FUNC, API_BLAS, HIP_UNSUPPORTED}}, + {"cublasIdamin", {"hipblasIdamin", "rocblas_idamin", CONV_LIB_FUNC, API_BLAS, HIP_UNSUPPORTED}}, + {"cublasIcamin", {"hipblasIcamin", "", CONV_LIB_FUNC, API_BLAS, UNSUPPORTED}}, + {"cublasIzamin", {"hipblasIzamin", "", CONV_LIB_FUNC, API_BLAS, UNSUPPORTED}}, // ASUM - {"cublasSasum", {"hipblasSasum", "", CONV_LIB_FUNC, API_BLAS}}, - // there is no such a function in CUDA - {"cublasSasumBatched", {"hipblasSasumBatched", "", CONV_LIB_FUNC, API_BLAS}}, - {"cublasDasum", {"hipblasDasum", "", CONV_LIB_FUNC, API_BLAS}}, - // there is no such a function in CUDA - {"cublasDasumBatched", {"hipblasDasumBatched", "", CONV_LIB_FUNC, API_BLAS}}, - {"cublasScasum", {"hipblasScasum", "", CONV_LIB_FUNC, API_BLAS, HIP_UNSUPPORTED}}, - {"cublasDzasum", {"hipblasDzasum", "", CONV_LIB_FUNC, API_BLAS, HIP_UNSUPPORTED}}, + {"cublasSasum", {"hipblasSasum", "rocblas_sasum", CONV_LIB_FUNC, API_BLAS}}, + // NOTE: there is no such a function in CUDA + {"cublasSasumBatched", {"hipblasSasumBatched", "", CONV_LIB_FUNC, API_BLAS, UNSUPPORTED}}, + {"cublasDasum", {"hipblasDasum", "rocblas_dasum", CONV_LIB_FUNC, API_BLAS}}, + // NOTE: there is no such a function in CUDA + {"cublasDasumBatched", {"hipblasDasumBatched", "", CONV_LIB_FUNC, API_BLAS, UNSUPPORTED}}, + {"cublasScasum", {"hipblasScasum", "", CONV_LIB_FUNC, API_BLAS, UNSUPPORTED}}, + {"cublasDzasum", {"hipblasDzasum", "", CONV_LIB_FUNC, API_BLAS, UNSUPPORTED}}, // ROT - {"cublasSrot", {"hipblasSrot", "", CONV_LIB_FUNC, API_BLAS, HIP_UNSUPPORTED}}, - {"cublasDrot", {"hipblasDrot", "", CONV_LIB_FUNC, API_BLAS, HIP_UNSUPPORTED}}, - {"cublasCrot", {"hipblasCrot", "", CONV_LIB_FUNC, API_BLAS, HIP_UNSUPPORTED}}, - {"cublasCsrot", {"hipblasCsrot", "", CONV_LIB_FUNC, API_BLAS, HIP_UNSUPPORTED}}, - {"cublasZrot", {"hipblasZrot", "", CONV_LIB_FUNC, API_BLAS, HIP_UNSUPPORTED}}, - {"cublasZdrot", {"hipblasZdrot", "", CONV_LIB_FUNC, API_BLAS, HIP_UNSUPPORTED}}, + {"cublasSrot", {"hipblasSrot", "", CONV_LIB_FUNC, API_BLAS, UNSUPPORTED}}, + {"cublasDrot", {"hipblasDrot", "", CONV_LIB_FUNC, API_BLAS, UNSUPPORTED}}, + {"cublasCrot", {"hipblasCrot", "", CONV_LIB_FUNC, API_BLAS, UNSUPPORTED}}, + {"cublasCsrot", {"hipblasCsrot", "", CONV_LIB_FUNC, API_BLAS, UNSUPPORTED}}, + {"cublasZrot", {"hipblasZrot", "", CONV_LIB_FUNC, API_BLAS, UNSUPPORTED}}, + {"cublasZdrot", {"hipblasZdrot", "", CONV_LIB_FUNC, API_BLAS, UNSUPPORTED}}, // ROTG - {"cublasSrotg", {"hipblasSrotg", "", CONV_LIB_FUNC, API_BLAS, HIP_UNSUPPORTED}}, - {"cublasDrotg", {"hipblasDrotg", "", CONV_LIB_FUNC, API_BLAS, HIP_UNSUPPORTED}}, - {"cublasCrotg", {"hipblasCrotg", "", CONV_LIB_FUNC, API_BLAS, HIP_UNSUPPORTED}}, - {"cublasZrotg", {"hipblasZrotg", "", CONV_LIB_FUNC, API_BLAS, HIP_UNSUPPORTED}}, + {"cublasSrotg", {"hipblasSrotg", "", CONV_LIB_FUNC, API_BLAS, UNSUPPORTED}}, + {"cublasDrotg", {"hipblasDrotg", "", CONV_LIB_FUNC, API_BLAS, UNSUPPORTED}}, + {"cublasCrotg", {"hipblasCrotg", "", CONV_LIB_FUNC, API_BLAS, UNSUPPORTED}}, + {"cublasZrotg", {"hipblasZrotg", "", CONV_LIB_FUNC, API_BLAS, UNSUPPORTED}}, // ROTM - {"cublasSrotm", {"hipblasSrotm", "", CONV_LIB_FUNC, API_BLAS, HIP_UNSUPPORTED}}, - {"cublasDrotm", {"hipblasDrotm", "", CONV_LIB_FUNC, API_BLAS, HIP_UNSUPPORTED}}, + {"cublasSrotm", {"hipblasSrotm", "", CONV_LIB_FUNC, API_BLAS, UNSUPPORTED}}, + {"cublasDrotm", {"hipblasDrotm", "", CONV_LIB_FUNC, API_BLAS, UNSUPPORTED}}, // ROTMG - {"cublasSrotmg", {"hipblasSrotmg", "", CONV_LIB_FUNC, API_BLAS, HIP_UNSUPPORTED}}, - {"cublasDrotmg", {"hipblasDrotmg", "", CONV_LIB_FUNC, API_BLAS, HIP_UNSUPPORTED}}, + {"cublasSrotmg", {"hipblasSrotmg", "", CONV_LIB_FUNC, API_BLAS, UNSUPPORTED}}, + {"cublasDrotmg", {"hipblasDrotmg", "", CONV_LIB_FUNC, API_BLAS, UNSUPPORTED}}, // GEMV - {"cublasSgemv", {"hipblasSgemv", "", CONV_LIB_FUNC, API_BLAS}}, - // there is no such a function in CUDA - {"cublasSgemvBatched", {"hipblasSgemvBatched", "", CONV_LIB_FUNC, API_BLAS, HIP_UNSUPPORTED}}, - {"cublasDgemv", {"hipblasDgemv", "", CONV_LIB_FUNC, API_BLAS}}, - {"cublasCgemv", {"hipblasCgemv", "", CONV_LIB_FUNC, API_BLAS, HIP_UNSUPPORTED}}, - {"cublasZgemv", {"hipblasZgemv", "", CONV_LIB_FUNC, API_BLAS, HIP_UNSUPPORTED}}, + {"cublasSgemv", {"hipblasSgemv", "rocblas_sgemv", CONV_LIB_FUNC, API_BLAS}}, + // NOTE: there is no such a function in CUDA + {"cublasSgemvBatched", {"hipblasSgemvBatched", "", CONV_LIB_FUNC, API_BLAS, UNSUPPORTED}}, + {"cublasDgemv", {"hipblasDgemv", "rocblas_dgemv", CONV_LIB_FUNC, API_BLAS}}, + {"cublasCgemv", {"hipblasCgemv", "", CONV_LIB_FUNC, API_BLAS, UNSUPPORTED}}, + {"cublasZgemv", {"hipblasZgemv", "", CONV_LIB_FUNC, API_BLAS, UNSUPPORTED}}, // GBMV - {"cublasSgbmv", {"hipblasSgbmv", "", CONV_LIB_FUNC, API_BLAS, HIP_UNSUPPORTED}}, - {"cublasDgbmv", {"hipblasDgbmv", "", CONV_LIB_FUNC, API_BLAS, HIP_UNSUPPORTED}}, - {"cublasCgbmv", {"hipblasCgbmv", "", CONV_LIB_FUNC, API_BLAS, HIP_UNSUPPORTED}}, - {"cublasZgbmv", {"hipblasZgbmv", "", CONV_LIB_FUNC, API_BLAS, HIP_UNSUPPORTED}}, + {"cublasSgbmv", {"hipblasSgbmv", "", CONV_LIB_FUNC, API_BLAS, UNSUPPORTED}}, + {"cublasDgbmv", {"hipblasDgbmv", "", CONV_LIB_FUNC, API_BLAS, UNSUPPORTED}}, + {"cublasCgbmv", {"hipblasCgbmv", "", CONV_LIB_FUNC, API_BLAS, UNSUPPORTED}}, + {"cublasZgbmv", {"hipblasZgbmv", "", CONV_LIB_FUNC, API_BLAS, UNSUPPORTED}}, // TRMV - {"cublasStrmv", {"hipblasStrmv", "", CONV_LIB_FUNC, API_BLAS, HIP_UNSUPPORTED}}, - {"cublasDtrmv", {"hipblasDtrmv", "", CONV_LIB_FUNC, API_BLAS, HIP_UNSUPPORTED}}, - {"cublasCtrmv", {"hipblasCtrmv", "", CONV_LIB_FUNC, API_BLAS, HIP_UNSUPPORTED}}, - {"cublasZtrmv", {"hipblasZtrmv", "", CONV_LIB_FUNC, API_BLAS, HIP_UNSUPPORTED}}, + {"cublasStrmv", {"hipblasStrmv", "", CONV_LIB_FUNC, API_BLAS, UNSUPPORTED}}, + {"cublasDtrmv", {"hipblasDtrmv", "", CONV_LIB_FUNC, API_BLAS, UNSUPPORTED}}, + {"cublasCtrmv", {"hipblasCtrmv", "", CONV_LIB_FUNC, API_BLAS, UNSUPPORTED}}, + {"cublasZtrmv", {"hipblasZtrmv", "", CONV_LIB_FUNC, API_BLAS, UNSUPPORTED}}, // TBMV - {"cublasStbmv", {"hipblasStbmv", "", CONV_LIB_FUNC, API_BLAS, HIP_UNSUPPORTED}}, - {"cublasDtbmv", {"hipblasDtbmv", "", CONV_LIB_FUNC, API_BLAS, HIP_UNSUPPORTED}}, - {"cublasCtbmv", {"hipblasCtbmv", "", CONV_LIB_FUNC, API_BLAS, HIP_UNSUPPORTED}}, - {"cublasZtbmv", {"hipblasZtbmv", "", CONV_LIB_FUNC, API_BLAS, HIP_UNSUPPORTED}}, + {"cublasStbmv", {"hipblasStbmv", "", CONV_LIB_FUNC, API_BLAS, UNSUPPORTED}}, + {"cublasDtbmv", {"hipblasDtbmv", "", CONV_LIB_FUNC, API_BLAS, UNSUPPORTED}}, + {"cublasCtbmv", {"hipblasCtbmv", "", CONV_LIB_FUNC, API_BLAS, UNSUPPORTED}}, + {"cublasZtbmv", {"hipblasZtbmv", "", CONV_LIB_FUNC, API_BLAS, UNSUPPORTED}}, // TPMV - {"cublasStpmv", {"hipblasStpmv", "", CONV_LIB_FUNC, API_BLAS, HIP_UNSUPPORTED}}, - {"cublasDtpmv", {"hipblasDtpmv", "", CONV_LIB_FUNC, API_BLAS, HIP_UNSUPPORTED}}, - {"cublasCtpmv", {"hipblasCtpmv", "", CONV_LIB_FUNC, API_BLAS, HIP_UNSUPPORTED}}, - {"cublasZtpmv", {"hipblasZtpmv", "", CONV_LIB_FUNC, API_BLAS, HIP_UNSUPPORTED}}, + {"cublasStpmv", {"hipblasStpmv", "", CONV_LIB_FUNC, API_BLAS, UNSUPPORTED}}, + {"cublasDtpmv", {"hipblasDtpmv", "", CONV_LIB_FUNC, API_BLAS, UNSUPPORTED}}, + {"cublasCtpmv", {"hipblasCtpmv", "", CONV_LIB_FUNC, API_BLAS, UNSUPPORTED}}, + {"cublasZtpmv", {"hipblasZtpmv", "", CONV_LIB_FUNC, API_BLAS, UNSUPPORTED}}, // TRSV - {"cublasStrsv", {"hipblasStrsv", "", CONV_LIB_FUNC, API_BLAS, HIP_UNSUPPORTED}}, - {"cublasDtrsv", {"hipblasDtrsv", "", CONV_LIB_FUNC, API_BLAS, HIP_UNSUPPORTED}}, - {"cublasCtrsv", {"hipblasCtrsv", "", CONV_LIB_FUNC, API_BLAS, HIP_UNSUPPORTED}}, - {"cublasZtrsv", {"hipblasZtrsv", "", CONV_LIB_FUNC, API_BLAS, HIP_UNSUPPORTED}}, + {"cublasStrsv", {"hipblasStrsv", "rocblas_strsv", CONV_LIB_FUNC, API_BLAS, HIP_UNSUPPORTED}}, + {"cublasDtrsv", {"hipblasDtrsv", "rocblas_dtrsv", CONV_LIB_FUNC, API_BLAS, HIP_UNSUPPORTED}}, + {"cublasCtrsv", {"hipblasCtrsv", "", CONV_LIB_FUNC, API_BLAS, UNSUPPORTED}}, + {"cublasZtrsv", {"hipblasZtrsv", "", CONV_LIB_FUNC, API_BLAS, UNSUPPORTED}}, // TPSV - {"cublasStpsv", {"hipblasStpsv", "", CONV_LIB_FUNC, API_BLAS, HIP_UNSUPPORTED}}, - {"cublasDtpsv", {"hipblasDtpsv", "", CONV_LIB_FUNC, API_BLAS, HIP_UNSUPPORTED}}, - {"cublasCtpsv", {"hipblasCtpsv", "", CONV_LIB_FUNC, API_BLAS, HIP_UNSUPPORTED}}, - {"cublasZtpsv", {"hipblasZtpsv", "", CONV_LIB_FUNC, API_BLAS, HIP_UNSUPPORTED}}, + {"cublasStpsv", {"hipblasStpsv", "", CONV_LIB_FUNC, API_BLAS, UNSUPPORTED}}, + {"cublasDtpsv", {"hipblasDtpsv", "", CONV_LIB_FUNC, API_BLAS, UNSUPPORTED}}, + {"cublasCtpsv", {"hipblasCtpsv", "", CONV_LIB_FUNC, API_BLAS, UNSUPPORTED}}, + {"cublasZtpsv", {"hipblasZtpsv", "", CONV_LIB_FUNC, API_BLAS, UNSUPPORTED}}, // TBSV - {"cublasStbsv", {"hipblasStbsv", "", CONV_LIB_FUNC, API_BLAS, HIP_UNSUPPORTED}}, - {"cublasDtbsv", {"hipblasDtbsv", "", CONV_LIB_FUNC, API_BLAS, HIP_UNSUPPORTED}}, - {"cublasCtbsv", {"hipblasCtbsv", "", CONV_LIB_FUNC, API_BLAS, HIP_UNSUPPORTED}}, - {"cublasZtbsv", {"hipblasZtbsv", "", CONV_LIB_FUNC, API_BLAS, HIP_UNSUPPORTED}}, + {"cublasStbsv", {"hipblasStbsv", "", CONV_LIB_FUNC, API_BLAS, UNSUPPORTED}}, + {"cublasDtbsv", {"hipblasDtbsv", "", CONV_LIB_FUNC, API_BLAS, UNSUPPORTED}}, + {"cublasCtbsv", {"hipblasCtbsv", "", CONV_LIB_FUNC, API_BLAS, UNSUPPORTED}}, + {"cublasZtbsv", {"hipblasZtbsv", "", CONV_LIB_FUNC, API_BLAS, UNSUPPORTED}}, // SYMV/HEMV - {"cublasSsymv", {"hipblasSsymv", "", CONV_LIB_FUNC, API_BLAS, HIP_UNSUPPORTED}}, - {"cublasDsymv", {"hipblasDsymv", "", CONV_LIB_FUNC, API_BLAS, HIP_UNSUPPORTED}}, - {"cublasCsymv", {"hipblasCsymv", "", CONV_LIB_FUNC, API_BLAS, HIP_UNSUPPORTED}}, - {"cublasZsymv", {"hipblasZsymv", "", CONV_LIB_FUNC, API_BLAS, HIP_UNSUPPORTED}}, - {"cublasChemv", {"hipblasChemv", "", CONV_LIB_FUNC, API_BLAS, HIP_UNSUPPORTED}}, - {"cublasZhemv", {"hipblasZhemv", "", CONV_LIB_FUNC, API_BLAS, HIP_UNSUPPORTED}}, + {"cublasSsymv", {"hipblasSsymv", "", CONV_LIB_FUNC, API_BLAS, UNSUPPORTED}}, + {"cublasDsymv", {"hipblasDsymv", "", CONV_LIB_FUNC, API_BLAS, UNSUPPORTED}}, + {"cublasCsymv", {"hipblasCsymv", "", CONV_LIB_FUNC, API_BLAS, UNSUPPORTED}}, + {"cublasZsymv", {"hipblasZsymv", "", CONV_LIB_FUNC, API_BLAS, UNSUPPORTED}}, + {"cublasChemv", {"hipblasChemv", "", CONV_LIB_FUNC, API_BLAS, UNSUPPORTED}}, + {"cublasZhemv", {"hipblasZhemv", "", CONV_LIB_FUNC, API_BLAS, UNSUPPORTED}}, // SBMV/HBMV - {"cublasSsbmv", {"hipblasSsbmv", "", CONV_LIB_FUNC, API_BLAS, HIP_UNSUPPORTED}}, - {"cublasDsbmv", {"hpiblasDsbmv", "", CONV_LIB_FUNC, API_BLAS, HIP_UNSUPPORTED}}, - {"cublasChbmv", {"hipblasChbmv", "", CONV_LIB_FUNC, API_BLAS, HIP_UNSUPPORTED}}, - {"cublasZhbmv", {"hipblasZhbmv", "", CONV_LIB_FUNC, API_BLAS, HIP_UNSUPPORTED}}, + {"cublasSsbmv", {"hipblasSsbmv", "", CONV_LIB_FUNC, API_BLAS, UNSUPPORTED}}, + {"cublasDsbmv", {"hpiblasDsbmv", "", CONV_LIB_FUNC, API_BLAS, UNSUPPORTED}}, + {"cublasChbmv", {"hipblasChbmv", "", CONV_LIB_FUNC, API_BLAS, UNSUPPORTED}}, + {"cublasZhbmv", {"hipblasZhbmv", "", CONV_LIB_FUNC, API_BLAS, UNSUPPORTED}}, // SPMV/HPMV - {"cublasSspmv", {"hipblasSspmv", "", CONV_LIB_FUNC, API_BLAS, HIP_UNSUPPORTED}}, - {"cublasDspmv", {"hipblasDspmv", "", CONV_LIB_FUNC, API_BLAS, HIP_UNSUPPORTED}}, - {"cublasChpmv", {"hipblasChpmv", "", CONV_LIB_FUNC, API_BLAS, HIP_UNSUPPORTED}}, - {"cublasZhpmv", {"hipblasZhpmv", "", CONV_LIB_FUNC, API_BLAS, HIP_UNSUPPORTED}}, + {"cublasSspmv", {"hipblasSspmv", "", CONV_LIB_FUNC, API_BLAS, UNSUPPORTED}}, + {"cublasDspmv", {"hipblasDspmv", "", CONV_LIB_FUNC, API_BLAS, UNSUPPORTED}}, + {"cublasChpmv", {"hipblasChpmv", "", CONV_LIB_FUNC, API_BLAS, UNSUPPORTED}}, + {"cublasZhpmv", {"hipblasZhpmv", "", CONV_LIB_FUNC, API_BLAS, UNSUPPORTED}}, // GER - {"cublasSger", {"hipblasSger", "", CONV_LIB_FUNC, API_BLAS}}, - {"cublasDger", {"hipblasDger", "", CONV_LIB_FUNC, API_BLAS}}, - {"cublasCgeru", {"hipblasCgeru", "", CONV_LIB_FUNC, API_BLAS, HIP_UNSUPPORTED}}, - {"cublasCgerc", {"hipblasCgerc", "", CONV_LIB_FUNC, API_BLAS, HIP_UNSUPPORTED}}, - {"cublasZgeru", {"hipblasZgeru", "", CONV_LIB_FUNC, API_BLAS, HIP_UNSUPPORTED}}, - {"cublasZgerc", {"hipblasZgerc", "", CONV_LIB_FUNC, API_BLAS, HIP_UNSUPPORTED}}, + {"cublasSger", {"hipblasSger", "rocblas_sger", CONV_LIB_FUNC, API_BLAS}}, + {"cublasDger", {"hipblasDger", "rocblas_dger", CONV_LIB_FUNC, API_BLAS}}, + {"cublasCgeru", {"hipblasCgeru", "", CONV_LIB_FUNC, API_BLAS, UNSUPPORTED}}, + {"cublasCgerc", {"hipblasCgerc", "", CONV_LIB_FUNC, API_BLAS, UNSUPPORTED}}, + {"cublasZgeru", {"hipblasZgeru", "", CONV_LIB_FUNC, API_BLAS, UNSUPPORTED}}, + {"cublasZgerc", {"hipblasZgerc", "", CONV_LIB_FUNC, API_BLAS, UNSUPPORTED}}, // SYR/HER - {"cublasSsyr", {"hipblasSsyr", "", CONV_LIB_FUNC, API_BLAS, HIP_UNSUPPORTED}}, - {"cublasDsyr", {"hipblasDsyr", "", CONV_LIB_FUNC, API_BLAS, HIP_UNSUPPORTED}}, - {"cublasCsyr", {"hipblasCsyr", "", CONV_LIB_FUNC, API_BLAS, HIP_UNSUPPORTED}}, - {"cublasZsyr", {"hipblasZsyr", "", CONV_LIB_FUNC, API_BLAS, HIP_UNSUPPORTED}}, - {"cublasCher", {"hipblasCher", "", CONV_LIB_FUNC, API_BLAS, HIP_UNSUPPORTED}}, - {"cublasZher", {"hipblasZher", "", CONV_LIB_FUNC, API_BLAS, HIP_UNSUPPORTED}}, + {"cublasSsyr", {"hipblasSsyr", "rocblas_ssyr", CONV_LIB_FUNC, API_BLAS, HIP_UNSUPPORTED}}, + {"cublasDsyr", {"hipblasDsyr", "rocblas_dsyr", CONV_LIB_FUNC, API_BLAS, HIP_UNSUPPORTED}}, + {"cublasCsyr", {"hipblasCsyr", "", CONV_LIB_FUNC, API_BLAS, UNSUPPORTED}}, + {"cublasZsyr", {"hipblasZsyr", "", CONV_LIB_FUNC, API_BLAS, UNSUPPORTED}}, + {"cublasCher", {"hipblasCher", "", CONV_LIB_FUNC, API_BLAS, UNSUPPORTED}}, + {"cublasZher", {"hipblasZher", "", CONV_LIB_FUNC, API_BLAS, UNSUPPORTED}}, // SPR/HPR - {"cublasSspr", {"hipblasSspr", "", CONV_LIB_FUNC, API_BLAS, HIP_UNSUPPORTED}}, - {"cublasDspr", {"hipblasDspr", "", CONV_LIB_FUNC, API_BLAS, HIP_UNSUPPORTED}}, - {"cublasChpr", {"hipblasChpr", "", CONV_LIB_FUNC, API_BLAS, HIP_UNSUPPORTED}}, - {"cublasZhpr", {"hipblasZhpr", "", CONV_LIB_FUNC, API_BLAS, HIP_UNSUPPORTED}}, + {"cublasSspr", {"hipblasSspr", "", CONV_LIB_FUNC, API_BLAS, UNSUPPORTED}}, + {"cublasDspr", {"hipblasDspr", "", CONV_LIB_FUNC, API_BLAS, UNSUPPORTED}}, + {"cublasChpr", {"hipblasChpr", "", CONV_LIB_FUNC, API_BLAS, UNSUPPORTED}}, + {"cublasZhpr", {"hipblasZhpr", "", CONV_LIB_FUNC, API_BLAS, UNSUPPORTED}}, // SYR2/HER2 - {"cublasSsyr2", {"hipblasSsyr2", "", CONV_LIB_FUNC, API_BLAS, HIP_UNSUPPORTED}}, - {"cublasDsyr2", {"hipblasDsyr2", "", CONV_LIB_FUNC, API_BLAS, HIP_UNSUPPORTED}}, - {"cublasCsyr2", {"hipblasCsyr2", "", CONV_LIB_FUNC, API_BLAS, HIP_UNSUPPORTED}}, - {"cublasZsyr2", {"hipblasZsyr2", "", CONV_LIB_FUNC, API_BLAS, HIP_UNSUPPORTED}}, - {"cublasCher2", {"hipblasCher2", "", CONV_LIB_FUNC, API_BLAS, HIP_UNSUPPORTED}}, - {"cublasZher2", {"hipblasZher2", "", CONV_LIB_FUNC, API_BLAS, HIP_UNSUPPORTED}}, + {"cublasSsyr2", {"hipblasSsyr2", "", CONV_LIB_FUNC, API_BLAS, UNSUPPORTED}}, + {"cublasDsyr2", {"hipblasDsyr2", "", CONV_LIB_FUNC, API_BLAS, UNSUPPORTED}}, + {"cublasCsyr2", {"hipblasCsyr2", "", CONV_LIB_FUNC, API_BLAS, UNSUPPORTED}}, + {"cublasZsyr2", {"hipblasZsyr2", "", CONV_LIB_FUNC, API_BLAS, UNSUPPORTED}}, + {"cublasCher2", {"hipblasCher2", "", CONV_LIB_FUNC, API_BLAS, UNSUPPORTED}}, + {"cublasZher2", {"hipblasZher2", "", CONV_LIB_FUNC, API_BLAS, UNSUPPORTED}}, // SPR2/HPR2 - {"cublasSspr2", {"hipblasSspr2", "", CONV_LIB_FUNC, API_BLAS, HIP_UNSUPPORTED}}, - {"cublasDspr2", {"hipblasDspr2", "", CONV_LIB_FUNC, API_BLAS, HIP_UNSUPPORTED}}, - {"cublasChpr2", {"hipblasChpr2", "", CONV_LIB_FUNC, API_BLAS, HIP_UNSUPPORTED}}, - {"cublasZhpr2", {"hipblasZhpr2", "", CONV_LIB_FUNC, API_BLAS, HIP_UNSUPPORTED}}, + {"cublasSspr2", {"hipblasSspr2", "", CONV_LIB_FUNC, API_BLAS, UNSUPPORTED}}, + {"cublasDspr2", {"hipblasDspr2", "", CONV_LIB_FUNC, API_BLAS, UNSUPPORTED}}, + {"cublasChpr2", {"hipblasChpr2", "", CONV_LIB_FUNC, API_BLAS, UNSUPPORTED}}, + {"cublasZhpr2", {"hipblasZhpr2", "", CONV_LIB_FUNC, API_BLAS, UNSUPPORTED}}, // Blas3 (v1) Routines // GEMM - {"cublasSgemm", {"hipblasSgemm", "", CONV_LIB_FUNC, API_BLAS}}, - {"cublasDgemm", {"hipblasDgemm", "", CONV_LIB_FUNC, API_BLAS}}, - {"cublasCgemm", {"hipblasCgemm", "", CONV_LIB_FUNC, API_BLAS}}, - {"cublasZgemm", {"hipblasZgemm", "", CONV_LIB_FUNC, API_BLAS, HIP_UNSUPPORTED}}, - {"cublasHgemm", {"hipblasHgemm", "", CONV_LIB_FUNC, API_BLAS}}, + {"cublasSgemm", {"hipblasSgemm", "rocblas_sgemm", CONV_LIB_FUNC, API_BLAS}}, + {"cublasDgemm", {"hipblasDgemm", "rocblas_dgemm", CONV_LIB_FUNC, API_BLAS}}, + {"cublasCgemm", {"hipblasCgemm", "", CONV_LIB_FUNC, API_BLAS, UNSUPPORTED}}, + {"cublasZgemm", {"hipblasZgemm", "", CONV_LIB_FUNC, API_BLAS, UNSUPPORTED}}, + {"cublasHgemm", {"hipblasHgemm", "rocblas_hgemm", CONV_LIB_FUNC, API_BLAS}}, // BATCH GEMM - {"cublasSgemmBatched", {"hipblasSgemmBatched", "", CONV_LIB_FUNC, API_BLAS}}, - {"cublasDgemmBatched", {"hipblasDgemmBatched", "", CONV_LIB_FUNC, API_BLAS}}, - {"cublasHgemmBatched", {"hipblasHgemmBatched", "", CONV_LIB_FUNC, API_BLAS, HIP_UNSUPPORTED}}, - {"cublasSgemmStridedBatched", {"hipblasSgemmStridedBatched", "", CONV_LIB_FUNC, API_BLAS, HIP_UNSUPPORTED}}, - {"cublasDgemmStridedBatched", {"hipblasDgemmStridedBatched", "", CONV_LIB_FUNC, API_BLAS, HIP_UNSUPPORTED}}, - {"cublasCgemmBatched", {"hipblasCgemmBatched", "", CONV_LIB_FUNC, API_BLAS, HIP_UNSUPPORTED}}, - {"cublasCgemm3mBatched", {"hipblasCgemm3mBatched", "", CONV_LIB_FUNC, API_BLAS, HIP_UNSUPPORTED}}, - {"cublasZgemmBatched", {"hipblasZgemmBatched", "", CONV_LIB_FUNC, API_BLAS, HIP_UNSUPPORTED}}, - {"cublasCgemmStridedBatched", {"hipblasCgemmStridedBatched", "", CONV_LIB_FUNC, API_BLAS, HIP_UNSUPPORTED}}, - {"cublasCgemm3mStridedBatched", {"hipblasCgemm3mStridedBatched", "", CONV_LIB_FUNC, API_BLAS, HIP_UNSUPPORTED}}, - {"cublasZgemmStridedBatched", {"hipblasZgemmStridedBatched", "", CONV_LIB_FUNC, API_BLAS, HIP_UNSUPPORTED}}, - {"cublasHgemmStridedBatched", {"hipblasHgemmStridedBatched", "", CONV_LIB_FUNC, API_BLAS, HIP_UNSUPPORTED}}, + {"cublasSgemmBatched", {"hipblasSgemmBatched", "", CONV_LIB_FUNC, API_BLAS, ROC_UNSUPPORTED}}, + {"cublasDgemmBatched", {"hipblasDgemmBatched", "", CONV_LIB_FUNC, API_BLAS, ROC_UNSUPPORTED}}, + {"cublasHgemmBatched", {"hipblasHgemmBatched", "", CONV_LIB_FUNC, API_BLAS, UNSUPPORTED}}, + {"cublasSgemmStridedBatched", {"hipblasSgemmStridedBatched", "rocblas_sgemm_strided_batched", CONV_LIB_FUNC, API_BLAS}}, + {"cublasDgemmStridedBatched", {"hipblasDgemmStridedBatched", "rocblas_dgemm_strided_batched", CONV_LIB_FUNC, API_BLAS}}, + {"cublasCgemmBatched", {"hipblasCgemmBatched", "", CONV_LIB_FUNC, API_BLAS, UNSUPPORTED}}, + {"cublasCgemm3mBatched", {"hipblasCgemm3mBatched", "", CONV_LIB_FUNC, API_BLAS, UNSUPPORTED}}, + {"cublasZgemmBatched", {"hipblasZgemmBatched", "", CONV_LIB_FUNC, API_BLAS, UNSUPPORTED}}, + {"cublasCgemmStridedBatched", {"hipblasCgemmStridedBatched", "", CONV_LIB_FUNC, API_BLAS, UNSUPPORTED}}, + {"cublasCgemm3mStridedBatched", {"hipblasCgemm3mStridedBatched", "", CONV_LIB_FUNC, API_BLAS, UNSUPPORTED}}, + {"cublasZgemmStridedBatched", {"hipblasZgemmStridedBatched", "", CONV_LIB_FUNC, API_BLAS, UNSUPPORTED}}, + {"cublasHgemmStridedBatched", {"hipblasHgemmStridedBatched", "rocblas_hgemm_strided_batched", CONV_LIB_FUNC, API_BLAS, HIP_UNSUPPORTED}}, // SYRK - {"cublasSsyrk", {"hipblasSsyrk", "", CONV_LIB_FUNC, API_BLAS, HIP_UNSUPPORTED}}, - {"cublasDsyrk", {"hipblasDsyrk", "", CONV_LIB_FUNC, API_BLAS, HIP_UNSUPPORTED}}, - {"cublasCsyrk", {"hipblasCsyrk", "", CONV_LIB_FUNC, API_BLAS, HIP_UNSUPPORTED}}, - {"cublasZsyrk", {"hipblasZsyrk", "", CONV_LIB_FUNC, API_BLAS, HIP_UNSUPPORTED}}, + {"cublasSsyrk", {"hipblasSsyrk", "", CONV_LIB_FUNC, API_BLAS, UNSUPPORTED}}, + {"cublasDsyrk", {"hipblasDsyrk", "", CONV_LIB_FUNC, API_BLAS, UNSUPPORTED}}, + {"cublasCsyrk", {"hipblasCsyrk", "", CONV_LIB_FUNC, API_BLAS, UNSUPPORTED}}, + {"cublasZsyrk", {"hipblasZsyrk", "", CONV_LIB_FUNC, API_BLAS, UNSUPPORTED}}, // HERK - {"cublasCherk", {"hipblasCherk", "", CONV_LIB_FUNC, API_BLAS, HIP_UNSUPPORTED}}, - {"cublasZherk", {"hipblasZherk", "", CONV_LIB_FUNC, API_BLAS, HIP_UNSUPPORTED}}, + {"cublasCherk", {"hipblasCherk", "", CONV_LIB_FUNC, API_BLAS, UNSUPPORTED}}, + {"cublasZherk", {"hipblasZherk", "", CONV_LIB_FUNC, API_BLAS, UNSUPPORTED}}, // SYR2K - {"cublasSsyr2k", {"hipblasSsyr2k", "", CONV_LIB_FUNC, API_BLAS, HIP_UNSUPPORTED}}, - {"cublasDsyr2k", {"hipblasDsyr2k", "", CONV_LIB_FUNC, API_BLAS, HIP_UNSUPPORTED}}, - {"cublasCsyr2k", {"hipblasCsyr2k", "", CONV_LIB_FUNC, API_BLAS, HIP_UNSUPPORTED}}, - {"cublasZsyr2k", {"hipblasZsyr2k", "", CONV_LIB_FUNC, API_BLAS, HIP_UNSUPPORTED}}, + {"cublasSsyr2k", {"hipblasSsyr2k", "", CONV_LIB_FUNC, API_BLAS, UNSUPPORTED}}, + {"cublasDsyr2k", {"hipblasDsyr2k", "", CONV_LIB_FUNC, API_BLAS, UNSUPPORTED}}, + {"cublasCsyr2k", {"hipblasCsyr2k", "", CONV_LIB_FUNC, API_BLAS, UNSUPPORTED}}, + {"cublasZsyr2k", {"hipblasZsyr2k", "", CONV_LIB_FUNC, API_BLAS, UNSUPPORTED}}, // SYRKX - eXtended SYRK - {"cublasSsyrkx", {"hipblasSsyrkx", "", CONV_LIB_FUNC, API_BLAS, HIP_UNSUPPORTED}}, - {"cublasDsyrkx", {"hipblasDsyrkx", "", CONV_LIB_FUNC, API_BLAS, HIP_UNSUPPORTED}}, - {"cublasCsyrkx", {"hipblasCsyrkx", "", CONV_LIB_FUNC, API_BLAS, HIP_UNSUPPORTED}}, - {"cublasZsyrkx", {"hipblasZsyrkx", "", CONV_LIB_FUNC, API_BLAS, HIP_UNSUPPORTED}}, + {"cublasSsyrkx", {"hipblasSsyrkx", "", CONV_LIB_FUNC, API_BLAS, UNSUPPORTED}}, + {"cublasDsyrkx", {"hipblasDsyrkx", "", CONV_LIB_FUNC, API_BLAS, UNSUPPORTED}}, + {"cublasCsyrkx", {"hipblasCsyrkx", "", CONV_LIB_FUNC, API_BLAS, UNSUPPORTED}}, + {"cublasZsyrkx", {"hipblasZsyrkx", "", CONV_LIB_FUNC, API_BLAS, UNSUPPORTED}}, // HER2K - {"cublasCher2k", {"hipblasCher2k", "", CONV_LIB_FUNC, API_BLAS, HIP_UNSUPPORTED}}, - {"cublasZher2k", {"hipblasZher2k", "", CONV_LIB_FUNC, API_BLAS, HIP_UNSUPPORTED}}, + {"cublasCher2k", {"hipblasCher2k", "", CONV_LIB_FUNC, API_BLAS, UNSUPPORTED}}, + {"cublasZher2k", {"hipblasZher2k", "", CONV_LIB_FUNC, API_BLAS, UNSUPPORTED}}, // HERKX - eXtended HERK - {"cublasCherkx", {"hipblasCherkx", "", CONV_LIB_FUNC, API_BLAS, HIP_UNSUPPORTED}}, - {"cublasZherkx", {"hipblasZherkx", "", CONV_LIB_FUNC, API_BLAS, HIP_UNSUPPORTED}}, + {"cublasCherkx", {"hipblasCherkx", "", CONV_LIB_FUNC, API_BLAS, UNSUPPORTED}}, + {"cublasZherkx", {"hipblasZherkx", "", CONV_LIB_FUNC, API_BLAS, UNSUPPORTED}}, // SYMM - {"cublasSsymm", {"hipblasSsymm", "", CONV_LIB_FUNC, API_BLAS, HIP_UNSUPPORTED}}, - {"cublasDsymm", {"hipblasDsymm", "", CONV_LIB_FUNC, API_BLAS, HIP_UNSUPPORTED}}, - {"cublasCsymm", {"hipblasCsymm", "", CONV_LIB_FUNC, API_BLAS, HIP_UNSUPPORTED}}, - {"cublasZsymm", {"hipblasZsymm", "", CONV_LIB_FUNC, API_BLAS, HIP_UNSUPPORTED}}, + {"cublasSsymm", {"hipblasSsymm", "", CONV_LIB_FUNC, API_BLAS, UNSUPPORTED}}, + {"cublasDsymm", {"hipblasDsymm", "", CONV_LIB_FUNC, API_BLAS, UNSUPPORTED}}, + {"cublasCsymm", {"hipblasCsymm", "", CONV_LIB_FUNC, API_BLAS, UNSUPPORTED}}, + {"cublasZsymm", {"hipblasZsymm", "", CONV_LIB_FUNC, API_BLAS, UNSUPPORTED}}, // HEMM - {"cublasChemm", {"hipblasChemm", "", CONV_LIB_FUNC, API_BLAS, HIP_UNSUPPORTED}}, - {"cublasZhemm", {"hipblasZhemm", "", CONV_LIB_FUNC, API_BLAS, HIP_UNSUPPORTED}}, + {"cublasChemm", {"hipblasChemm", "", CONV_LIB_FUNC, API_BLAS, UNSUPPORTED}}, + {"cublasZhemm", {"hipblasZhemm", "", CONV_LIB_FUNC, API_BLAS, UNSUPPORTED}}, // TRSM - {"cublasStrsm", {"hipblasStrsm", "", CONV_LIB_FUNC, API_BLAS}}, - {"cublasDtrsm", {"hipblasDtrsm", "", CONV_LIB_FUNC, API_BLAS}}, - {"cublasCtrsm", {"hipblasCtrsm", "", CONV_LIB_FUNC, API_BLAS, HIP_UNSUPPORTED}}, - {"cublasZtrsm", {"hipblasZtrsm", "", CONV_LIB_FUNC, API_BLAS, HIP_UNSUPPORTED}}, + {"cublasStrsm", {"hipblasStrsm", "rocblas_strsm", CONV_LIB_FUNC, API_BLAS}}, + {"cublasDtrsm", {"hipblasDtrsm", "rocblas_dtrsm", CONV_LIB_FUNC, API_BLAS}}, + {"cublasCtrsm", {"hipblasCtrsm", "", CONV_LIB_FUNC, API_BLAS, UNSUPPORTED}}, + {"cublasZtrsm", {"hipblasZtrsm", "", CONV_LIB_FUNC, API_BLAS, UNSUPPORTED}}, // TRSM - Batched Triangular Solver - {"cublasStrsmBatched", {"hipblasStrsmBatched", "", CONV_LIB_FUNC, API_BLAS, HIP_UNSUPPORTED}}, - {"cublasDtrsmBatched", {"hipblasDtrsmBatched", "", CONV_LIB_FUNC, API_BLAS, HIP_UNSUPPORTED}}, - {"cublasCtrsmBatched", {"hipblasCtrsmBatched", "", CONV_LIB_FUNC, API_BLAS, HIP_UNSUPPORTED}}, - {"cublasZtrsmBatched", {"hipblasZtrsmBatched", "", CONV_LIB_FUNC, API_BLAS, HIP_UNSUPPORTED}}, + {"cublasStrsmBatched", {"hipblasStrsmBatched", "", CONV_LIB_FUNC, API_BLAS, UNSUPPORTED}}, + {"cublasDtrsmBatched", {"hipblasDtrsmBatched", "", CONV_LIB_FUNC, API_BLAS, UNSUPPORTED}}, + {"cublasCtrsmBatched", {"hipblasCtrsmBatched", "", CONV_LIB_FUNC, API_BLAS, UNSUPPORTED}}, + {"cublasZtrsmBatched", {"hipblasZtrsmBatched", "", CONV_LIB_FUNC, API_BLAS, UNSUPPORTED}}, // TRMM - {"cublasStrmm", {"hipblasStrmm", "", CONV_LIB_FUNC, API_BLAS, HIP_UNSUPPORTED}}, - {"cublasDtrmm", {"hipblasDtrmm", "", CONV_LIB_FUNC, API_BLAS, HIP_UNSUPPORTED}}, - {"cublasCtrmm", {"hipblasCtrmm", "", CONV_LIB_FUNC, API_BLAS, HIP_UNSUPPORTED}}, - {"cublasZtrmm", {"hipblasZtrmm", "", CONV_LIB_FUNC, API_BLAS, HIP_UNSUPPORTED}}, + {"cublasStrmm", {"hipblasStrmm", "", CONV_LIB_FUNC, API_BLAS, UNSUPPORTED}}, + {"cublasDtrmm", {"hipblasDtrmm", "", CONV_LIB_FUNC, API_BLAS, UNSUPPORTED}}, + {"cublasCtrmm", {"hipblasCtrmm", "", CONV_LIB_FUNC, API_BLAS, UNSUPPORTED}}, + {"cublasZtrmm", {"hipblasZtrmm", "", CONV_LIB_FUNC, API_BLAS, UNSUPPORTED}}, // ------------------------ CUBLAS BLAS - like extension (cublas_api.h) // GEAM - {"cublasSgeam", {"hipblasSgeam", "", CONV_LIB_FUNC, API_BLAS}}, - {"cublasDgeam", {"hipblasDgeam", "", CONV_LIB_FUNC, API_BLAS}}, - {"cublasCgeam", {"hipblasCgeam", "", CONV_LIB_FUNC, API_BLAS, HIP_UNSUPPORTED}}, - {"cublasZgeam", {"hipblasZgeam", "", CONV_LIB_FUNC, API_BLAS, HIP_UNSUPPORTED}}, + {"cublasSgeam", {"hipblasSgeam", "rocblas_sgeam", CONV_LIB_FUNC, API_BLAS}}, + {"cublasDgeam", {"hipblasDgeam", "rocblas_dgeam", CONV_LIB_FUNC, API_BLAS}}, + {"cublasCgeam", {"hipblasCgeam", "", CONV_LIB_FUNC, API_BLAS, UNSUPPORTED}}, + {"cublasZgeam", {"hipblasZgeam", "", CONV_LIB_FUNC, API_BLAS, UNSUPPORTED}}, // GETRF - Batched LU - {"cublasSgetrfBatched", {"hipblasSgetrfBatched", "", CONV_LIB_FUNC, API_BLAS, HIP_UNSUPPORTED}}, - {"cublasDgetrfBatched", {"hipblasDgetrfBatched", "", CONV_LIB_FUNC, API_BLAS, HIP_UNSUPPORTED}}, - {"cublasCgetrfBatched", {"hipblasCgetrfBatched", "", CONV_LIB_FUNC, API_BLAS, HIP_UNSUPPORTED}}, - {"cublasZgetrfBatched", {"hipblasZgetrfBatched", "", CONV_LIB_FUNC, API_BLAS, HIP_UNSUPPORTED}}, + {"cublasSgetrfBatched", {"hipblasSgetrfBatched", "", CONV_LIB_FUNC, API_BLAS, UNSUPPORTED}}, + {"cublasDgetrfBatched", {"hipblasDgetrfBatched", "", CONV_LIB_FUNC, API_BLAS, UNSUPPORTED}}, + {"cublasCgetrfBatched", {"hipblasCgetrfBatched", "", CONV_LIB_FUNC, API_BLAS, UNSUPPORTED}}, + {"cublasZgetrfBatched", {"hipblasZgetrfBatched", "", CONV_LIB_FUNC, API_BLAS, UNSUPPORTED}}, // Batched inversion based on LU factorization from getrf - {"cublasSgetriBatched", {"hipblasSgetriBatched", "", CONV_LIB_FUNC, API_BLAS, HIP_UNSUPPORTED}}, - {"cublasDgetriBatched", {"hipblasDgetriBatched", "", CONV_LIB_FUNC, API_BLAS, HIP_UNSUPPORTED}}, - {"cublasCgetriBatched", {"hipblasCgetriBatched", "", CONV_LIB_FUNC, API_BLAS, HIP_UNSUPPORTED}}, - {"cublasZgetriBatched", {"hipblasZgetriBatched", "", CONV_LIB_FUNC, API_BLAS, HIP_UNSUPPORTED}}, + {"cublasSgetriBatched", {"hipblasSgetriBatched", "", CONV_LIB_FUNC, API_BLAS, UNSUPPORTED}}, + {"cublasDgetriBatched", {"hipblasDgetriBatched", "", CONV_LIB_FUNC, API_BLAS, UNSUPPORTED}}, + {"cublasCgetriBatched", {"hipblasCgetriBatched", "", CONV_LIB_FUNC, API_BLAS, UNSUPPORTED}}, + {"cublasZgetriBatched", {"hipblasZgetriBatched", "", CONV_LIB_FUNC, API_BLAS, UNSUPPORTED}}, // Batched solver based on LU factorization from getrf - {"cublasSgetrsBatched", {"hipblasSgetrsBatched", "", CONV_LIB_FUNC, API_BLAS, HIP_UNSUPPORTED}}, - {"cublasDgetrsBatched", {"hipblasDgetrsBatched", "", CONV_LIB_FUNC, API_BLAS, HIP_UNSUPPORTED}}, - {"cublasCgetrsBatched", {"hipblasCgetrsBatched", "", CONV_LIB_FUNC, API_BLAS, HIP_UNSUPPORTED}}, - {"cublasZgetrsBatched", {"hipblasZgetrsBatched", "", CONV_LIB_FUNC, API_BLAS, HIP_UNSUPPORTED}}, + {"cublasSgetrsBatched", {"hipblasSgetrsBatched", "", CONV_LIB_FUNC, API_BLAS, UNSUPPORTED}}, + {"cublasDgetrsBatched", {"hipblasDgetrsBatched", "", CONV_LIB_FUNC, API_BLAS, UNSUPPORTED}}, + {"cublasCgetrsBatched", {"hipblasCgetrsBatched", "", CONV_LIB_FUNC, API_BLAS, UNSUPPORTED}}, + {"cublasZgetrsBatched", {"hipblasZgetrsBatched", "", CONV_LIB_FUNC, API_BLAS, UNSUPPORTED}}, // TRSM - Batched Triangular Solver - {"cublasStrsmBatched", {"hipblasStrsmBatched", "", CONV_LIB_FUNC, API_BLAS, HIP_UNSUPPORTED}}, - {"cublasDtrsmBatched", {"hipblasDtrsmBatched", "", CONV_LIB_FUNC, API_BLAS, HIP_UNSUPPORTED}}, - {"cublasCtrsmBatched", {"hipblasCtrsmBatched", "", CONV_LIB_FUNC, API_BLAS, HIP_UNSUPPORTED}}, - {"cublasZtrsmBatched", {"hipblasZtrsmBatched", "", CONV_LIB_FUNC, API_BLAS, HIP_UNSUPPORTED}}, + {"cublasStrsmBatched", {"hipblasStrsmBatched", "", CONV_LIB_FUNC, API_BLAS, UNSUPPORTED}}, + {"cublasDtrsmBatched", {"hipblasDtrsmBatched", "", CONV_LIB_FUNC, API_BLAS, UNSUPPORTED}}, + {"cublasCtrsmBatched", {"hipblasCtrsmBatched", "", CONV_LIB_FUNC, API_BLAS, UNSUPPORTED}}, + {"cublasZtrsmBatched", {"hipblasZtrsmBatched", "", CONV_LIB_FUNC, API_BLAS, UNSUPPORTED}}, // MATINV - Batched - {"cublasSmatinvBatched", {"hipblasSmatinvBatched", "", CONV_LIB_FUNC, API_BLAS, HIP_UNSUPPORTED}}, - {"cublasDmatinvBatched", {"hipblasDmatinvBatched", "", CONV_LIB_FUNC, API_BLAS, HIP_UNSUPPORTED}}, - {"cublasCmatinvBatched", {"hipblasCmatinvBatched", "", CONV_LIB_FUNC, API_BLAS, HIP_UNSUPPORTED}}, - {"cublasZmatinvBatched", {"hipblasZmatinvBatched", "", CONV_LIB_FUNC, API_BLAS, HIP_UNSUPPORTED}}, + {"cublasSmatinvBatched", {"hipblasSmatinvBatched", "", CONV_LIB_FUNC, API_BLAS, UNSUPPORTED}}, + {"cublasDmatinvBatched", {"hipblasDmatinvBatched", "", CONV_LIB_FUNC, API_BLAS, UNSUPPORTED}}, + {"cublasCmatinvBatched", {"hipblasCmatinvBatched", "", CONV_LIB_FUNC, API_BLAS, UNSUPPORTED}}, + {"cublasZmatinvBatched", {"hipblasZmatinvBatched", "", CONV_LIB_FUNC, API_BLAS, UNSUPPORTED}}, // Batch QR Factorization - {"cublasSgeqrfBatched", {"hipblasSgeqrfBatched", "", CONV_LIB_FUNC, API_BLAS, HIP_UNSUPPORTED}}, - {"cublasDgeqrfBatched", {"hipblasDgeqrfBatched", "", CONV_LIB_FUNC, API_BLAS, HIP_UNSUPPORTED}}, - {"cublasCgeqrfBatched", {"hipblasCgeqrfBatched", "", CONV_LIB_FUNC, API_BLAS, HIP_UNSUPPORTED}}, - {"cublasZgeqrfBatched", {"hipblasZgeqrfBatched", "", CONV_LIB_FUNC, API_BLAS, HIP_UNSUPPORTED}}, + {"cublasSgeqrfBatched", {"hipblasSgeqrfBatched", "", CONV_LIB_FUNC, API_BLAS, UNSUPPORTED}}, + {"cublasDgeqrfBatched", {"hipblasDgeqrfBatched", "", CONV_LIB_FUNC, API_BLAS, UNSUPPORTED}}, + {"cublasCgeqrfBatched", {"hipblasCgeqrfBatched", "", CONV_LIB_FUNC, API_BLAS, UNSUPPORTED}}, + {"cublasZgeqrfBatched", {"hipblasZgeqrfBatched", "", CONV_LIB_FUNC, API_BLAS, UNSUPPORTED}}, // Least Square Min only m >= n and Non-transpose supported - {"cublasSgelsBatched", {"hipblasSgelsBatched", "", CONV_LIB_FUNC, API_BLAS, HIP_UNSUPPORTED}}, - {"cublasDgelsBatched", {"hipblasDgelsBatched", "", CONV_LIB_FUNC, API_BLAS, HIP_UNSUPPORTED}}, - {"cublasCgelsBatched", {"hipblasCgelsBatched", "", CONV_LIB_FUNC, API_BLAS, HIP_UNSUPPORTED}}, - {"cublasZgelsBatched", {"hipblasZgelsBatched", "", CONV_LIB_FUNC, API_BLAS, HIP_UNSUPPORTED}}, + {"cublasSgelsBatched", {"hipblasSgelsBatched", "", CONV_LIB_FUNC, API_BLAS, UNSUPPORTED}}, + {"cublasDgelsBatched", {"hipblasDgelsBatched", "", CONV_LIB_FUNC, API_BLAS, UNSUPPORTED}}, + {"cublasCgelsBatched", {"hipblasCgelsBatched", "", CONV_LIB_FUNC, API_BLAS, UNSUPPORTED}}, + {"cublasZgelsBatched", {"hipblasZgelsBatched", "", CONV_LIB_FUNC, API_BLAS, UNSUPPORTED}}, // DGMM - {"cublasSdgmm", {"hipblasSdgmm", "", CONV_LIB_FUNC, API_BLAS, HIP_UNSUPPORTED}}, - {"cublasDdgmm", {"hipblasDdgmm", "", CONV_LIB_FUNC, API_BLAS, HIP_UNSUPPORTED}}, - {"cublasCdgmm", {"hipblasCdgmm", "", CONV_LIB_FUNC, API_BLAS, HIP_UNSUPPORTED}}, - {"cublasZdgmm", {"hipblasZdgmm", "", CONV_LIB_FUNC, API_BLAS, HIP_UNSUPPORTED}}, + {"cublasSdgmm", {"hipblasSdgmm", "", CONV_LIB_FUNC, API_BLAS, UNSUPPORTED}}, + {"cublasDdgmm", {"hipblasDdgmm", "", CONV_LIB_FUNC, API_BLAS, UNSUPPORTED}}, + {"cublasCdgmm", {"hipblasCdgmm", "", CONV_LIB_FUNC, API_BLAS, UNSUPPORTED}}, + {"cublasZdgmm", {"hipblasZdgmm", "", CONV_LIB_FUNC, API_BLAS, UNSUPPORTED}}, // TPTTR - Triangular Pack format to Triangular format - {"cublasStpttr", {"hipblasStpttr", "", CONV_LIB_FUNC, API_BLAS, HIP_UNSUPPORTED}}, - {"cublasDtpttr", {"hipblasDtpttr", "", CONV_LIB_FUNC, API_BLAS, HIP_UNSUPPORTED}}, - {"cublasCtpttr", {"hipblasCtpttr", "", CONV_LIB_FUNC, API_BLAS, HIP_UNSUPPORTED}}, - {"cublasZtpttr", {"hipblasZtpttr", "", CONV_LIB_FUNC, API_BLAS, HIP_UNSUPPORTED}}, + {"cublasStpttr", {"hipblasStpttr", "", CONV_LIB_FUNC, API_BLAS, UNSUPPORTED}}, + {"cublasDtpttr", {"hipblasDtpttr", "", CONV_LIB_FUNC, API_BLAS, UNSUPPORTED}}, + {"cublasCtpttr", {"hipblasCtpttr", "", CONV_LIB_FUNC, API_BLAS, UNSUPPORTED}}, + {"cublasZtpttr", {"hipblasZtpttr", "", CONV_LIB_FUNC, API_BLAS, UNSUPPORTED}}, // TRTTP - Triangular format to Triangular Pack format - {"cublasStrttp", {"hipblasStrttp", "", CONV_LIB_FUNC, API_BLAS, HIP_UNSUPPORTED}}, - {"cublasDtrttp", {"hipblasDtrttp", "", CONV_LIB_FUNC, API_BLAS, HIP_UNSUPPORTED}}, - {"cublasCtrttp", {"hipblasCtrttp", "", CONV_LIB_FUNC, API_BLAS, HIP_UNSUPPORTED}}, - {"cublasZtrttp", {"hipblasZtrttp", "", CONV_LIB_FUNC, API_BLAS, HIP_UNSUPPORTED}}, + {"cublasStrttp", {"hipblasStrttp", "", CONV_LIB_FUNC, API_BLAS, UNSUPPORTED}}, + {"cublasDtrttp", {"hipblasDtrttp", "", CONV_LIB_FUNC, API_BLAS, UNSUPPORTED}}, + {"cublasCtrttp", {"hipblasCtrttp", "", CONV_LIB_FUNC, API_BLAS, UNSUPPORTED}}, + {"cublasZtrttp", {"hipblasZtrttp", "", CONV_LIB_FUNC, API_BLAS, UNSUPPORTED}}, // Blas2 (v2) Routines - {"cublasCreate_v2", {"hipblasCreate", "", CONV_LIB_FUNC, API_BLAS}}, - {"cublasDestroy_v2", {"hipblasDestroy", "", CONV_LIB_FUNC, API_BLAS}}, - {"cublasGetVersion_v2", {"hipblasGetVersion", "", CONV_LIB_FUNC, API_BLAS, HIP_UNSUPPORTED}}, - {"cublasGetProperty", {"hipblasGetProperty", "", CONV_LIB_FUNC, API_BLAS, HIP_UNSUPPORTED}}, - {"cublasSetStream_v2", {"hipblasSetStream", "", CONV_LIB_FUNC, API_BLAS}}, - {"cublasGetStream_v2", {"hipblasGetStream", "", CONV_LIB_FUNC, API_BLAS}}, - {"cublasGetPointerMode_v2", {"hipblasGetPointerMode", "", CONV_LIB_FUNC, API_BLAS}}, - {"cublasSetPointerMode_v2", {"hipblasSetPointerMode", "", CONV_LIB_FUNC, API_BLAS}}, + {"cublasCreate_v2", {"hipblasCreate", "rocblas_create_handle", CONV_LIB_FUNC, API_BLAS}}, + {"cublasDestroy_v2", {"hipblasDestroy", "rocblas_destroy_handle", CONV_LIB_FUNC, API_BLAS}}, + {"cublasGetVersion_v2", {"hipblasGetVersion", "", CONV_LIB_FUNC, API_BLAS, UNSUPPORTED}}, + {"cublasGetProperty", {"hipblasGetProperty", "", CONV_LIB_FUNC, API_BLAS, UNSUPPORTED}}, + {"cublasSetStream_v2", {"hipblasSetStream", "rocblas_set_stream", CONV_LIB_FUNC, API_BLAS}}, + {"cublasGetStream_v2", {"hipblasGetStream", "rocblas_get_stream", CONV_LIB_FUNC, API_BLAS}}, + {"cublasGetPointerMode_v2", {"hipblasGetPointerMode", "rocblas_set_pointer_mode", CONV_LIB_FUNC, API_BLAS}}, + {"cublasSetPointerMode_v2", {"hipblasSetPointerMode", "rocblas_get_pointer_mode", CONV_LIB_FUNC, API_BLAS}}, // GEMV - {"cublasSgemv_v2", {"hipblasSgemv", "", CONV_LIB_FUNC, API_BLAS}}, - {"cublasDgemv_v2", {"hipblasDgemv", "", CONV_LIB_FUNC, API_BLAS}}, - {"cublasCgemv_v2", {"hipblasCgemv", "", CONV_LIB_FUNC, API_BLAS, HIP_UNSUPPORTED}}, - {"cublasZgemv_v2", {"hipblasZgemv", "", CONV_LIB_FUNC, API_BLAS, HIP_UNSUPPORTED}}, + {"cublasSgemv_v2", {"hipblasSgemv", "rocblas_sgemv", CONV_LIB_FUNC, API_BLAS}}, + {"cublasDgemv_v2", {"hipblasDgemv", "rocblas_dgemv", CONV_LIB_FUNC, API_BLAS}}, + {"cublasCgemv_v2", {"hipblasCgemv", "", CONV_LIB_FUNC, API_BLAS, UNSUPPORTED}}, + {"cublasZgemv_v2", {"hipblasZgemv", "", CONV_LIB_FUNC, API_BLAS, UNSUPPORTED}}, // GBMV - {"cublasSgbmv_v2", {"hipblasSgbmv", "", CONV_LIB_FUNC, API_BLAS, HIP_UNSUPPORTED}}, - {"cublasDgbmv_v2", {"hipblasDgbmv", "", CONV_LIB_FUNC, API_BLAS, HIP_UNSUPPORTED}}, - {"cublasCgbmv_v2", {"hipblasCgbmv", "", CONV_LIB_FUNC, API_BLAS, HIP_UNSUPPORTED}}, - {"cublasZgbmv_v2", {"hipblasZgbmv", "", CONV_LIB_FUNC, API_BLAS, HIP_UNSUPPORTED}}, + {"cublasSgbmv_v2", {"hipblasSgbmv", "", CONV_LIB_FUNC, API_BLAS, UNSUPPORTED}}, + {"cublasDgbmv_v2", {"hipblasDgbmv", "", CONV_LIB_FUNC, API_BLAS, UNSUPPORTED}}, + {"cublasCgbmv_v2", {"hipblasCgbmv", "", CONV_LIB_FUNC, API_BLAS, UNSUPPORTED}}, + {"cublasZgbmv_v2", {"hipblasZgbmv", "", CONV_LIB_FUNC, API_BLAS, UNSUPPORTED}}, // TRMV - {"cublasStrmv_v2", {"hipblasStrmv", "", CONV_LIB_FUNC, API_BLAS, HIP_UNSUPPORTED}}, - {"cublasDtrmv_v2", {"hipblasDtrmv", "", CONV_LIB_FUNC, API_BLAS, HIP_UNSUPPORTED}}, - {"cublasCtrmv_v2", {"hipblasCtrmv", "", CONV_LIB_FUNC, API_BLAS, HIP_UNSUPPORTED}}, - {"cublasZtrmv_v2", {"hipblasZtrmv", "", CONV_LIB_FUNC, API_BLAS, HIP_UNSUPPORTED}}, + {"cublasStrmv_v2", {"hipblasStrmv", "", CONV_LIB_FUNC, API_BLAS, UNSUPPORTED}}, + {"cublasDtrmv_v2", {"hipblasDtrmv", "", CONV_LIB_FUNC, API_BLAS, UNSUPPORTED}}, + {"cublasCtrmv_v2", {"hipblasCtrmv", "", CONV_LIB_FUNC, API_BLAS, UNSUPPORTED}}, + {"cublasZtrmv_v2", {"hipblasZtrmv", "", CONV_LIB_FUNC, API_BLAS, UNSUPPORTED}}, // TBMV - {"cublasStbmv_v2", {"hipblasStbmv", "", CONV_LIB_FUNC, API_BLAS, HIP_UNSUPPORTED}}, - {"cublasDtbmv_v2", {"hipblasDtbmv", "", CONV_LIB_FUNC, API_BLAS, HIP_UNSUPPORTED}}, - {"cublasCtbmv_v2", {"hipblasCtbmv", "", CONV_LIB_FUNC, API_BLAS, HIP_UNSUPPORTED}}, - {"cublasZtbmv_v2", {"hipblasZtbmv", "", CONV_LIB_FUNC, API_BLAS, HIP_UNSUPPORTED}}, + {"cublasStbmv_v2", {"hipblasStbmv", "", CONV_LIB_FUNC, API_BLAS, UNSUPPORTED}}, + {"cublasDtbmv_v2", {"hipblasDtbmv", "", CONV_LIB_FUNC, API_BLAS, UNSUPPORTED}}, + {"cublasCtbmv_v2", {"hipblasCtbmv", "", CONV_LIB_FUNC, API_BLAS, UNSUPPORTED}}, + {"cublasZtbmv_v2", {"hipblasZtbmv", "", CONV_LIB_FUNC, API_BLAS, UNSUPPORTED}}, // TPMV - {"cublasStpmv_v2", {"hipblasStpmv", "", CONV_LIB_FUNC, API_BLAS, HIP_UNSUPPORTED}}, - {"cublasDtpmv_v2", {"hipblasDtpmv", "", CONV_LIB_FUNC, API_BLAS, HIP_UNSUPPORTED}}, - {"cublasCtpmv_v2", {"hipblasCtpmv", "", CONV_LIB_FUNC, API_BLAS, HIP_UNSUPPORTED}}, - {"cublasZtpmv_v2", {"hipblasZtpmv", "", CONV_LIB_FUNC, API_BLAS, HIP_UNSUPPORTED}}, + {"cublasStpmv_v2", {"hipblasStpmv", "", CONV_LIB_FUNC, API_BLAS, UNSUPPORTED}}, + {"cublasDtpmv_v2", {"hipblasDtpmv", "", CONV_LIB_FUNC, API_BLAS, UNSUPPORTED}}, + {"cublasCtpmv_v2", {"hipblasCtpmv", "", CONV_LIB_FUNC, API_BLAS, UNSUPPORTED}}, + {"cublasZtpmv_v2", {"hipblasZtpmv", "", CONV_LIB_FUNC, API_BLAS, UNSUPPORTED}}, // TRSV - {"cublasStrsv_v2", {"hipblasStrsv", "", CONV_LIB_FUNC, API_BLAS, HIP_UNSUPPORTED}}, - {"cublasDtrsv_v2", {"hipblasDtrsv", "", CONV_LIB_FUNC, API_BLAS, HIP_UNSUPPORTED}}, - {"cublasCtrsv_v2", {"hipblasCtrsv", "", CONV_LIB_FUNC, API_BLAS, HIP_UNSUPPORTED}}, - {"cublasZtrsv_v2", {"hipblasZtrsv", "", CONV_LIB_FUNC, API_BLAS, HIP_UNSUPPORTED}}, + {"cublasStrsv_v2", {"hipblasStrsv", "rocblas_strsv", CONV_LIB_FUNC, API_BLAS, HIP_UNSUPPORTED}}, + {"cublasDtrsv_v2", {"hipblasDtrsv", "rocblas_dtrsv", CONV_LIB_FUNC, API_BLAS, HIP_UNSUPPORTED}}, + {"cublasCtrsv_v2", {"hipblasCtrsv", "", CONV_LIB_FUNC, API_BLAS, UNSUPPORTED}}, + {"cublasZtrsv_v2", {"hipblasZtrsv", "", CONV_LIB_FUNC, API_BLAS, UNSUPPORTED}}, // TPSV - {"cublasStpsv_v2", {"hipblasStpsv", "", CONV_LIB_FUNC, API_BLAS, HIP_UNSUPPORTED}}, - {"cublasDtpsv_v2", {"hipblasDtpsv", "", CONV_LIB_FUNC, API_BLAS, HIP_UNSUPPORTED}}, - {"cublasCtpsv_v2", {"hipblasCtpsv", "", CONV_LIB_FUNC, API_BLAS, HIP_UNSUPPORTED}}, - {"cublasZtpsv_v2", {"hipblasZtpsv", "", CONV_LIB_FUNC, API_BLAS, HIP_UNSUPPORTED}}, + {"cublasStpsv_v2", {"hipblasStpsv", "", CONV_LIB_FUNC, API_BLAS, UNSUPPORTED}}, + {"cublasDtpsv_v2", {"hipblasDtpsv", "", CONV_LIB_FUNC, API_BLAS, UNSUPPORTED}}, + {"cublasCtpsv_v2", {"hipblasCtpsv", "", CONV_LIB_FUNC, API_BLAS, UNSUPPORTED}}, + {"cublasZtpsv_v2", {"hipblasZtpsv", "", CONV_LIB_FUNC, API_BLAS, UNSUPPORTED}}, // TBSV - {"cublasStbsv_v2", {"hipblasStbsv", "", CONV_LIB_FUNC, API_BLAS, HIP_UNSUPPORTED}}, - {"cublasDtbsv_v2", {"hipblasDtbsv", "", CONV_LIB_FUNC, API_BLAS, HIP_UNSUPPORTED}}, - {"cublasCtbsv_v2", {"hipblasCtbsv", "", CONV_LIB_FUNC, API_BLAS, HIP_UNSUPPORTED}}, - {"cublasZtbsv_v2", {"hipblasZtbsv", "", CONV_LIB_FUNC, API_BLAS, HIP_UNSUPPORTED}}, + {"cublasStbsv_v2", {"hipblasStbsv", "", CONV_LIB_FUNC, API_BLAS, UNSUPPORTED}}, + {"cublasDtbsv_v2", {"hipblasDtbsv", "", CONV_LIB_FUNC, API_BLAS, UNSUPPORTED}}, + {"cublasCtbsv_v2", {"hipblasCtbsv", "", CONV_LIB_FUNC, API_BLAS, UNSUPPORTED}}, + {"cublasZtbsv_v2", {"hipblasZtbsv", "", CONV_LIB_FUNC, API_BLAS, UNSUPPORTED}}, // SYMV/HEMV - {"cublasSsymv_v2", {"hipblasSsymv", "", CONV_LIB_FUNC, API_BLAS, HIP_UNSUPPORTED}}, - {"cublasDsymv_v2", {"hipblasDsymv", "", CONV_LIB_FUNC, API_BLAS, HIP_UNSUPPORTED}}, - {"cublasCsymv_v2", {"hipblasCsymv", "", CONV_LIB_FUNC, API_BLAS, HIP_UNSUPPORTED}}, - {"cublasZsymv_v2", {"hipblasZsymv", "", CONV_LIB_FUNC, API_BLAS, HIP_UNSUPPORTED}}, - {"cublasChemv_v2", {"hipblasChemv", "", CONV_LIB_FUNC, API_BLAS, HIP_UNSUPPORTED}}, - {"cublasZhemv_v2", {"hipblasZhemv", "", CONV_LIB_FUNC, API_BLAS, HIP_UNSUPPORTED}}, + {"cublasSsymv_v2", {"hipblasSsymv", "", CONV_LIB_FUNC, API_BLAS, UNSUPPORTED}}, + {"cublasDsymv_v2", {"hipblasDsymv", "", CONV_LIB_FUNC, API_BLAS, UNSUPPORTED}}, + {"cublasCsymv_v2", {"hipblasCsymv", "", CONV_LIB_FUNC, API_BLAS, UNSUPPORTED}}, + {"cublasZsymv_v2", {"hipblasZsymv", "", CONV_LIB_FUNC, API_BLAS, UNSUPPORTED}}, + {"cublasChemv_v2", {"hipblasChemv", "", CONV_LIB_FUNC, API_BLAS, UNSUPPORTED}}, + {"cublasZhemv_v2", {"hipblasZhemv", "", CONV_LIB_FUNC, API_BLAS, UNSUPPORTED}}, // SBMV/HBMV - {"cublasSsbmv_v2", {"hipblasSsbmv", "", CONV_LIB_FUNC, API_BLAS, HIP_UNSUPPORTED}}, - {"cublasDsbmv_v2", {"hpiblasDsbmv", "", CONV_LIB_FUNC, API_BLAS, HIP_UNSUPPORTED}}, - {"cublasChbmv_v2", {"hipblasChbmv", "", CONV_LIB_FUNC, API_BLAS, HIP_UNSUPPORTED}}, - {"cublasZhbmv_v2", {"hipblasZhbmv", "", CONV_LIB_FUNC, API_BLAS, HIP_UNSUPPORTED}}, + {"cublasSsbmv_v2", {"hipblasSsbmv", "", CONV_LIB_FUNC, API_BLAS, UNSUPPORTED}}, + {"cublasDsbmv_v2", {"hpiblasDsbmv", "", CONV_LIB_FUNC, API_BLAS, UNSUPPORTED}}, + {"cublasChbmv_v2", {"hipblasChbmv", "", CONV_LIB_FUNC, API_BLAS, UNSUPPORTED}}, + {"cublasZhbmv_v2", {"hipblasZhbmv", "", CONV_LIB_FUNC, API_BLAS, UNSUPPORTED}}, // SPMV/HPMV - {"cublasSspmv_v2", {"hipblasSspmv", "", CONV_LIB_FUNC, API_BLAS, HIP_UNSUPPORTED}}, - {"cublasDspmv_v2", {"hipblasDspmv", "", CONV_LIB_FUNC, API_BLAS, HIP_UNSUPPORTED}}, - {"cublasChpmv_v2", {"hipblasChpmv", "", CONV_LIB_FUNC, API_BLAS, HIP_UNSUPPORTED}}, - {"cublasZhpmv_v2", {"hipblasZhpmv", "", CONV_LIB_FUNC, API_BLAS, HIP_UNSUPPORTED}}, + {"cublasSspmv_v2", {"hipblasSspmv", "", CONV_LIB_FUNC, API_BLAS, UNSUPPORTED}}, + {"cublasDspmv_v2", {"hipblasDspmv", "", CONV_LIB_FUNC, API_BLAS, UNSUPPORTED}}, + {"cublasChpmv_v2", {"hipblasChpmv", "", CONV_LIB_FUNC, API_BLAS, UNSUPPORTED}}, + {"cublasZhpmv_v2", {"hipblasZhpmv", "", CONV_LIB_FUNC, API_BLAS, UNSUPPORTED}}, // GER - {"cublasSger_v2", {"hipblasSger", "", CONV_LIB_FUNC, API_BLAS}}, - {"cublasDger_v2", {"hipblasDger", "", CONV_LIB_FUNC, API_BLAS}}, - {"cublasCgeru_v2", {"hipblasCgeru", "", CONV_LIB_FUNC, API_BLAS, HIP_UNSUPPORTED}}, - {"cublasCgerc_v2", {"hipblasCgerc", "", CONV_LIB_FUNC, API_BLAS, HIP_UNSUPPORTED}}, - {"cublasZgeru_v2", {"hipblasZgeru", "", CONV_LIB_FUNC, API_BLAS, HIP_UNSUPPORTED}}, - {"cublasZgerc_v2", {"hipblasZgerc", "", CONV_LIB_FUNC, API_BLAS, HIP_UNSUPPORTED}}, + {"cublasSger_v2", {"hipblasSger", "rocblas_sger", CONV_LIB_FUNC, API_BLAS}}, + {"cublasDger_v2", {"hipblasDger", "rocblas_dger", CONV_LIB_FUNC, API_BLAS}}, + {"cublasCgeru_v2", {"hipblasCgeru", "", CONV_LIB_FUNC, API_BLAS, UNSUPPORTED}}, + {"cublasCgerc_v2", {"hipblasCgerc", "", CONV_LIB_FUNC, API_BLAS, UNSUPPORTED}}, + {"cublasZgeru_v2", {"hipblasZgeru", "", CONV_LIB_FUNC, API_BLAS, UNSUPPORTED}}, + {"cublasZgerc_v2", {"hipblasZgerc", "", CONV_LIB_FUNC, API_BLAS, UNSUPPORTED}}, // SYR/HER - {"cublasSsyr_v2", {"hipblasSsyr", "", CONV_LIB_FUNC, API_BLAS, HIP_UNSUPPORTED}}, - {"cublasDsyr_v2", {"hipblasDsyr", "", CONV_LIB_FUNC, API_BLAS, HIP_UNSUPPORTED}}, - {"cublasCsyr_v2", {"hipblasCsyr", "", CONV_LIB_FUNC, API_BLAS, HIP_UNSUPPORTED}}, - {"cublasZsyr_v2", {"hipblasZsyr", "", CONV_LIB_FUNC, API_BLAS, HIP_UNSUPPORTED}}, - {"cublasCher_v2", {"hipblasCher", "", CONV_LIB_FUNC, API_BLAS, HIP_UNSUPPORTED}}, - {"cublasZher_v2", {"hipblasZher", "", CONV_LIB_FUNC, API_BLAS, HIP_UNSUPPORTED}}, + {"cublasSsyr_v2", {"hipblasSsyr", "rocblas_ssyr", CONV_LIB_FUNC, API_BLAS, HIP_UNSUPPORTED}}, + {"cublasDsyr_v2", {"hipblasDsyr", "rocblas_dsyr", CONV_LIB_FUNC, API_BLAS, HIP_UNSUPPORTED}}, + {"cublasCsyr_v2", {"hipblasCsyr", "", CONV_LIB_FUNC, API_BLAS, UNSUPPORTED}}, + {"cublasZsyr_v2", {"hipblasZsyr", "", CONV_LIB_FUNC, API_BLAS, UNSUPPORTED}}, + {"cublasCher_v2", {"hipblasCher", "", CONV_LIB_FUNC, API_BLAS, UNSUPPORTED}}, + {"cublasZher_v2", {"hipblasZher", "", CONV_LIB_FUNC, API_BLAS, UNSUPPORTED}}, // SPR/HPR - {"cublasSspr_v2", {"hipblasSspr", "", CONV_LIB_FUNC, API_BLAS, HIP_UNSUPPORTED}}, - {"cublasDspr_v2", {"hipblasDspr", "", CONV_LIB_FUNC, API_BLAS, HIP_UNSUPPORTED}}, - {"cublasChpr_v2", {"hipblasChpr", "", CONV_LIB_FUNC, API_BLAS, HIP_UNSUPPORTED}}, - {"cublasZhpr_v2", {"hipblasZhpr", "", CONV_LIB_FUNC, API_BLAS, HIP_UNSUPPORTED}}, + {"cublasSspr_v2", {"hipblasSspr", "", CONV_LIB_FUNC, API_BLAS, UNSUPPORTED}}, + {"cublasDspr_v2", {"hipblasDspr", "", CONV_LIB_FUNC, API_BLAS, UNSUPPORTED}}, + {"cublasChpr_v2", {"hipblasChpr", "", CONV_LIB_FUNC, API_BLAS, UNSUPPORTED}}, + {"cublasZhpr_v2", {"hipblasZhpr", "", CONV_LIB_FUNC, API_BLAS, UNSUPPORTED}}, // SYR2/HER2 - {"cublasSsyr2_v2", {"hipblasSsyr2", "", CONV_LIB_FUNC, API_BLAS, HIP_UNSUPPORTED}}, - {"cublasDsyr2_v2", {"hipblasDsyr2", "", CONV_LIB_FUNC, API_BLAS, HIP_UNSUPPORTED}}, - {"cublasCsyr2_v2", {"hipblasCsyr2", "", CONV_LIB_FUNC, API_BLAS, HIP_UNSUPPORTED}}, - {"cublasZsyr2_v2", {"hipblasZsyr2", "", CONV_LIB_FUNC, API_BLAS, HIP_UNSUPPORTED}}, - {"cublasCher2_v2", {"hipblasCher2", "", CONV_LIB_FUNC, API_BLAS, HIP_UNSUPPORTED}}, - {"cublasZher2_v2", {"hipblasZher2", "", CONV_LIB_FUNC, API_BLAS, HIP_UNSUPPORTED}}, + {"cublasSsyr2_v2", {"hipblasSsyr2", "", CONV_LIB_FUNC, API_BLAS, UNSUPPORTED}}, + {"cublasDsyr2_v2", {"hipblasDsyr2", "", CONV_LIB_FUNC, API_BLAS, UNSUPPORTED}}, + {"cublasCsyr2_v2", {"hipblasCsyr2", "", CONV_LIB_FUNC, API_BLAS, UNSUPPORTED}}, + {"cublasZsyr2_v2", {"hipblasZsyr2", "", CONV_LIB_FUNC, API_BLAS, UNSUPPORTED}}, + {"cublasCher2_v2", {"hipblasCher2", "", CONV_LIB_FUNC, API_BLAS, UNSUPPORTED}}, + {"cublasZher2_v2", {"hipblasZher2", "", CONV_LIB_FUNC, API_BLAS, UNSUPPORTED}}, // SPR2/HPR2 - {"cublasSspr2_v2", {"hipblasSspr2", "", CONV_LIB_FUNC, API_BLAS, HIP_UNSUPPORTED}}, - {"cublasDspr2_v2", {"hipblasDspr2", "", CONV_LIB_FUNC, API_BLAS, HIP_UNSUPPORTED}}, - {"cublasChpr2_v2", {"hipblasChpr2", "", CONV_LIB_FUNC, API_BLAS, HIP_UNSUPPORTED}}, - {"cublasZhpr2_v2", {"hipblasZhpr2", "", CONV_LIB_FUNC, API_BLAS, HIP_UNSUPPORTED}}, + {"cublasSspr2_v2", {"hipblasSspr2", "", CONV_LIB_FUNC, API_BLAS, UNSUPPORTED}}, + {"cublasDspr2_v2", {"hipblasDspr2", "", CONV_LIB_FUNC, API_BLAS, UNSUPPORTED}}, + {"cublasChpr2_v2", {"hipblasChpr2", "", CONV_LIB_FUNC, API_BLAS, UNSUPPORTED}}, + {"cublasZhpr2_v2", {"hipblasZhpr2", "", CONV_LIB_FUNC, API_BLAS, UNSUPPORTED}}, // Blas3 (v2) Routines // GEMM - {"cublasSgemm_v2", {"hipblasSgemm", "", CONV_LIB_FUNC, API_BLAS}}, - {"cublasDgemm_v2", {"hipblasDgemm", "", CONV_LIB_FUNC, API_BLAS}}, - {"cublasCgemm_v2", {"hipblasCgemm", "", CONV_LIB_FUNC, API_BLAS}}, - {"cublasCgemm3m", {"hipblasCgemm3m", "", CONV_LIB_FUNC, API_BLAS, HIP_UNSUPPORTED}}, - {"cublasCgemm3mEx", {"hipblasCgemm3mEx", "", CONV_LIB_FUNC, API_BLAS, HIP_UNSUPPORTED}}, - {"cublasZgemm_v2", {"hipblasZgemm", "", CONV_LIB_FUNC, API_BLAS, HIP_UNSUPPORTED}}, - {"cublasZgemm3m", {"hipblasZgemm3m", "", CONV_LIB_FUNC, API_BLAS, HIP_UNSUPPORTED}}, + {"cublasSgemm_v2", {"hipblasSgemm", "rocblas_sgemm", CONV_LIB_FUNC, API_BLAS}}, + {"cublasDgemm_v2", {"hipblasDgemm", "rocblas_dgemm", CONV_LIB_FUNC, API_BLAS}}, + {"cublasCgemm_v2", {"hipblasCgemm", "", CONV_LIB_FUNC, API_BLAS, UNSUPPORTED}}, + {"cublasCgemm3m", {"hipblasCgemm3m", "", CONV_LIB_FUNC, API_BLAS, UNSUPPORTED}}, + {"cublasCgemm3mEx", {"hipblasCgemm3mEx", "", CONV_LIB_FUNC, API_BLAS, UNSUPPORTED}}, + {"cublasZgemm_v2", {"hipblasZgemm", "", CONV_LIB_FUNC, API_BLAS, UNSUPPORTED}}, + {"cublasZgemm3m", {"hipblasZgemm3m", "", CONV_LIB_FUNC, API_BLAS, UNSUPPORTED}}, //IO in FP16 / FP32, computation in float - {"cublasSgemmEx", {"hipblasSgemmEx", "", CONV_LIB_FUNC, API_BLAS, HIP_UNSUPPORTED}}, - {"cublasGemmEx", {"hipblasGemmEx", "", CONV_LIB_FUNC, API_BLAS}}, - {"cublasGemmBatchedEx", {"hipblasGemmBatchedEx", "", CONV_LIB_FUNC, API_BLAS, HIP_UNSUPPORTED}}, - {"cublasGemmStridedBatchedEx", {"hipblasGemmStridedBatchedEx", "", CONV_LIB_FUNC, API_BLAS, HIP_UNSUPPORTED}}, + {"cublasSgemmEx", {"hipblasSgemmEx", "", CONV_LIB_FUNC, API_BLAS, UNSUPPORTED}}, + {"cublasGemmEx", {"hipblasGemmEx", "rocblas_gemm_ex", CONV_LIB_FUNC, API_BLAS}}, + {"cublasGemmBatchedEx", {"hipblasGemmBatchedEx", "", CONV_LIB_FUNC, API_BLAS, UNSUPPORTED}}, + {"cublasGemmStridedBatchedEx", {"hipblasGemmStridedBatchedEx", "rocblas_gemm_strided_batched_ex", CONV_LIB_FUNC, API_BLAS, HIP_UNSUPPORTED}}, // IO in Int8 complex/cuComplex, computation in cuComplex - {"cublasCgemmEx", {"hipblasCgemmEx", "", CONV_LIB_FUNC, API_BLAS, HIP_UNSUPPORTED}}, - {"cublasUint8gemmBias", {"hipblasUint8gemmBias", "", CONV_LIB_FUNC, API_BLAS, HIP_UNSUPPORTED}}, + {"cublasCgemmEx", {"hipblasCgemmEx", "", CONV_LIB_FUNC, API_BLAS, UNSUPPORTED}}, + {"cublasUint8gemmBias", {"hipblasUint8gemmBias", "", CONV_LIB_FUNC, API_BLAS, UNSUPPORTED}}, // SYRK - {"cublasSsyrk_v2", {"hipblasSsyrk", "", CONV_LIB_FUNC, API_BLAS, HIP_UNSUPPORTED}}, - {"cublasDsyrk_v2", {"hipblasDsyrk", "", CONV_LIB_FUNC, API_BLAS, HIP_UNSUPPORTED}}, - {"cublasCsyrk_v2", {"hipblasCsyrk", "", CONV_LIB_FUNC, API_BLAS, HIP_UNSUPPORTED}}, - {"cublasZsyrk_v2", {"hipblasZsyrk", "", CONV_LIB_FUNC, API_BLAS, HIP_UNSUPPORTED}}, + {"cublasSsyrk_v2", {"hipblasSsyrk", "", CONV_LIB_FUNC, API_BLAS, UNSUPPORTED}}, + {"cublasDsyrk_v2", {"hipblasDsyrk", "", CONV_LIB_FUNC, API_BLAS, UNSUPPORTED}}, + {"cublasCsyrk_v2", {"hipblasCsyrk", "", CONV_LIB_FUNC, API_BLAS, UNSUPPORTED}}, + {"cublasZsyrk_v2", {"hipblasZsyrk", "", CONV_LIB_FUNC, API_BLAS, UNSUPPORTED}}, // IO in Int8 complex/cuComplex, computation in cuComplex - {"cublasCsyrkEx", {"hipblasCsyrkEx", "", CONV_LIB_FUNC, API_BLAS, HIP_UNSUPPORTED}}, + {"cublasCsyrkEx", {"hipblasCsyrkEx", "", CONV_LIB_FUNC, API_BLAS, UNSUPPORTED}}, // IO in Int8 complex/cuComplex, computation in cuComplex, Gaussian math - {"cublasCsyrk3mEx", {"hipblasCsyrk3mEx", "", CONV_LIB_FUNC, API_BLAS, HIP_UNSUPPORTED}}, + {"cublasCsyrk3mEx", {"hipblasCsyrk3mEx", "", CONV_LIB_FUNC, API_BLAS, UNSUPPORTED}}, // HERK - {"cublasCherk_v2", {"hipblasCherk", "", CONV_LIB_FUNC, API_BLAS, HIP_UNSUPPORTED}}, + {"cublasCherk_v2", {"hipblasCherk", "", CONV_LIB_FUNC, API_BLAS, UNSUPPORTED}}, // IO in Int8 complex/cuComplex, computation in cuComplex - {"cublasCherkEx", {"hipblasCherkEx", "", CONV_LIB_FUNC, API_BLAS, HIP_UNSUPPORTED}}, + {"cublasCherkEx", {"hipblasCherkEx", "", CONV_LIB_FUNC, API_BLAS, UNSUPPORTED}}, // IO in Int8 complex/cuComplex, computation in cuComplex, Gaussian math - {"cublasCherk3mEx", {"hipblasCherk3mEx", "", CONV_LIB_FUNC, API_BLAS, HIP_UNSUPPORTED}}, - {"cublasZherk_v2", {"hipblasZherk", "", CONV_LIB_FUNC, API_BLAS, HIP_UNSUPPORTED}}, + {"cublasCherk3mEx", {"hipblasCherk3mEx", "", CONV_LIB_FUNC, API_BLAS, UNSUPPORTED}}, + {"cublasZherk_v2", {"hipblasZherk", "", CONV_LIB_FUNC, API_BLAS, UNSUPPORTED}}, // SYR2K - {"cublasSsyr2k_v2", {"hipblasSsyr2k", "", CONV_LIB_FUNC, API_BLAS, HIP_UNSUPPORTED}}, - {"cublasDsyr2k_v2", {"hipblasDsyr2k", "", CONV_LIB_FUNC, API_BLAS, HIP_UNSUPPORTED}}, - {"cublasCsyr2k_v2", {"hipblasCsyr2k", "", CONV_LIB_FUNC, API_BLAS, HIP_UNSUPPORTED}}, - {"cublasZsyr2k_v2", {"hipblasZsyr2k", "", CONV_LIB_FUNC, API_BLAS, HIP_UNSUPPORTED}}, + {"cublasSsyr2k_v2", {"hipblasSsyr2k", "", CONV_LIB_FUNC, API_BLAS, UNSUPPORTED}}, + {"cublasDsyr2k_v2", {"hipblasDsyr2k", "", CONV_LIB_FUNC, API_BLAS, UNSUPPORTED}}, + {"cublasCsyr2k_v2", {"hipblasCsyr2k", "", CONV_LIB_FUNC, API_BLAS, UNSUPPORTED}}, + {"cublasZsyr2k_v2", {"hipblasZsyr2k", "", CONV_LIB_FUNC, API_BLAS, UNSUPPORTED}}, // HER2K - {"cublasCher2k_v2", {"hipblasCher2k", "", CONV_LIB_FUNC, API_BLAS, HIP_UNSUPPORTED}}, - {"cublasZher2k_v2", {"hipblasZher2k", "", CONV_LIB_FUNC, API_BLAS, HIP_UNSUPPORTED}}, + {"cublasCher2k_v2", {"hipblasCher2k", "", CONV_LIB_FUNC, API_BLAS, UNSUPPORTED}}, + {"cublasZher2k_v2", {"hipblasZher2k", "", CONV_LIB_FUNC, API_BLAS, UNSUPPORTED}}, // SYMM - {"cublasSsymm_v2", {"hipblasSsymm", "", CONV_LIB_FUNC, API_BLAS, HIP_UNSUPPORTED}}, - {"cublasDsymm_v2", {"hipblasDsymm", "", CONV_LIB_FUNC, API_BLAS, HIP_UNSUPPORTED}}, - {"cublasCsymm_v2", {"hipblasCsymm", "", CONV_LIB_FUNC, API_BLAS, HIP_UNSUPPORTED}}, - {"cublasZsymm_v2", {"hipblasZsymm", "", CONV_LIB_FUNC, API_BLAS, HIP_UNSUPPORTED}}, + {"cublasSsymm_v2", {"hipblasSsymm", "", CONV_LIB_FUNC, API_BLAS, UNSUPPORTED}}, + {"cublasDsymm_v2", {"hipblasDsymm", "", CONV_LIB_FUNC, API_BLAS, UNSUPPORTED}}, + {"cublasCsymm_v2", {"hipblasCsymm", "", CONV_LIB_FUNC, API_BLAS, UNSUPPORTED}}, + {"cublasZsymm_v2", {"hipblasZsymm", "", CONV_LIB_FUNC, API_BLAS, UNSUPPORTED}}, // HEMM - {"cublasChemm_v2", {"hipblasChemm", "", CONV_LIB_FUNC, API_BLAS, HIP_UNSUPPORTED}}, - {"cublasZhemm_v2", {"hipblasZhemm", "", CONV_LIB_FUNC, API_BLAS, HIP_UNSUPPORTED}}, + {"cublasChemm_v2", {"hipblasChemm", "", CONV_LIB_FUNC, API_BLAS, UNSUPPORTED}}, + {"cublasZhemm_v2", {"hipblasZhemm", "", CONV_LIB_FUNC, API_BLAS, UNSUPPORTED}}, // TRSM - {"cublasStrsm_v2", {"hipblasStrsm", "", CONV_LIB_FUNC, API_BLAS}}, - {"cublasDtrsm_v2", {"hipblasDtrsm", "", CONV_LIB_FUNC, API_BLAS}}, - {"cublasCtrsm_v2", {"hipblasCtrsm", "", CONV_LIB_FUNC, API_BLAS, HIP_UNSUPPORTED}}, - {"cublasZtrsm_v2", {"hipblasZtrsm", "", CONV_LIB_FUNC, API_BLAS, HIP_UNSUPPORTED}}, + {"cublasStrsm_v2", {"hipblasStrsm", "rocblas_strsm", CONV_LIB_FUNC, API_BLAS}}, + {"cublasDtrsm_v2", {"hipblasDtrsm", "rocblas_dtrsm", CONV_LIB_FUNC, API_BLAS}}, + {"cublasCtrsm_v2", {"hipblasCtrsm", "", CONV_LIB_FUNC, API_BLAS, UNSUPPORTED}}, + {"cublasZtrsm_v2", {"hipblasZtrsm", "", CONV_LIB_FUNC, API_BLAS, UNSUPPORTED}}, // TRMM - {"cublasStrmm_v2", {"hipblasStrmm", "", CONV_LIB_FUNC, API_BLAS, HIP_UNSUPPORTED}}, - {"cublasDtrmm_v2", {"hipblasDtrmm", "", CONV_LIB_FUNC, API_BLAS, HIP_UNSUPPORTED}}, - {"cublasCtrmm_v2", {"hipblasCtrmm", "", CONV_LIB_FUNC, API_BLAS, HIP_UNSUPPORTED}}, - {"cublasZtrmm_v2", {"hipblasZtrmm", "", CONV_LIB_FUNC, API_BLAS, HIP_UNSUPPORTED}}, + {"cublasStrmm_v2", {"hipblasStrmm", "", CONV_LIB_FUNC, API_BLAS, HIP_UNSUPPORTED}}, + {"cublasDtrmm_v2", {"hipblasDtrmm", "", CONV_LIB_FUNC, API_BLAS, HIP_UNSUPPORTED}}, + {"cublasCtrmm_v2", {"hipblasCtrmm", "", CONV_LIB_FUNC, API_BLAS, HIP_UNSUPPORTED}}, + {"cublasZtrmm_v2", {"hipblasZtrmm", "", CONV_LIB_FUNC, API_BLAS, HIP_UNSUPPORTED}}, // NRM2 - {"cublasSnrm2_v2", {"hipblasSnrm2", "", CONV_LIB_FUNC, API_BLAS}}, - {"cublasDnrm2_v2", {"hipblasDnrm2", "", CONV_LIB_FUNC, API_BLAS}}, - {"cublasScnrm2_v2", {"hipblasScnrm2", "", CONV_LIB_FUNC, API_BLAS, HIP_UNSUPPORTED}}, - {"cublasDznrm2_v2", {"hipblasDznrm2", "", CONV_LIB_FUNC, API_BLAS, HIP_UNSUPPORTED}}, + {"cublasSnrm2_v2", {"hipblasSnrm2", "rocblas_snrm2", CONV_LIB_FUNC, API_BLAS}}, + {"cublasDnrm2_v2", {"hipblasDnrm2", "rocblas_dnrm2", CONV_LIB_FUNC, API_BLAS}}, + {"cublasScnrm2_v2", {"hipblasScnrm2", "", CONV_LIB_FUNC, API_BLAS, UNSUPPORTED}}, + {"cublasDznrm2_v2", {"hipblasDznrm2", "", CONV_LIB_FUNC, API_BLAS, UNSUPPORTED}}, // DOT - {"cublasDotEx", {"hipblasDotEx", "", CONV_LIB_FUNC, API_BLAS, HIP_UNSUPPORTED}}, - {"cublasDotcEx", {"hipblasDotcEx", "", CONV_LIB_FUNC, API_BLAS, HIP_UNSUPPORTED}}, + {"cublasDotEx", {"hipblasDotEx", "", CONV_LIB_FUNC, API_BLAS, UNSUPPORTED}}, + {"cublasDotcEx", {"hipblasDotcEx", "", CONV_LIB_FUNC, API_BLAS, UNSUPPORTED}}, - {"cublasSdot_v2", {"hipblasSdot", "", CONV_LIB_FUNC, API_BLAS}}, - {"cublasDdot_v2", {"hipblasDdot", "", CONV_LIB_FUNC, API_BLAS}}, + {"cublasSdot_v2", {"hipblasSdot", "rocblas_sdot", CONV_LIB_FUNC, API_BLAS}}, + {"cublasDdot_v2", {"hipblasDdot", "rocblas_ddot", CONV_LIB_FUNC, API_BLAS}}, - {"cublasCdotu_v2", {"hipblasCdotu", "", CONV_LIB_FUNC, API_BLAS, HIP_UNSUPPORTED}}, - {"cublasCdotc_v2", {"hipblasCdotc", "", CONV_LIB_FUNC, API_BLAS, HIP_UNSUPPORTED}}, - {"cublasZdotu_v2", {"hipblasZdotu", "", CONV_LIB_FUNC, API_BLAS, HIP_UNSUPPORTED}}, - {"cublasZdotc_v2", {"hipblasZdotc", "", CONV_LIB_FUNC, API_BLAS, HIP_UNSUPPORTED}}, + {"cublasCdotu_v2", {"hipblasCdotu", "", CONV_LIB_FUNC, API_BLAS, UNSUPPORTED}}, + {"cublasCdotc_v2", {"hipblasCdotc", "", CONV_LIB_FUNC, API_BLAS, UNSUPPORTED}}, + {"cublasZdotu_v2", {"hipblasZdotu", "", CONV_LIB_FUNC, API_BLAS, UNSUPPORTED}}, + {"cublasZdotc_v2", {"hipblasZdotc", "", CONV_LIB_FUNC, API_BLAS, UNSUPPORTED}}, // SCAL - {"cublasScalEx", {"hipblasScalEx", "", CONV_LIB_FUNC, API_BLAS, HIP_UNSUPPORTED}}, - {"cublasSscal_v2", {"hipblasSscal", "", CONV_LIB_FUNC, API_BLAS}}, - {"cublasDscal_v2", {"hipblasDscal", "", CONV_LIB_FUNC, API_BLAS}}, - {"cublasCscal_v2", {"hipblasCscal", "", CONV_LIB_FUNC, API_BLAS, HIP_UNSUPPORTED}}, - {"cublasCsscal_v2", {"hipblasCsscal", "", CONV_LIB_FUNC, API_BLAS, HIP_UNSUPPORTED}}, - {"cublasZscal_v2", {"hipblasZscal", "", CONV_LIB_FUNC, API_BLAS, HIP_UNSUPPORTED}}, - {"cublasZdscal_v2", {"hipblasZdscal", "", CONV_LIB_FUNC, API_BLAS, HIP_UNSUPPORTED}}, + {"cublasScalEx", {"hipblasScalEx", "", CONV_LIB_FUNC, API_BLAS, UNSUPPORTED}}, + {"cublasSscal_v2", {"hipblasSscal", "rocblas_sscal", CONV_LIB_FUNC, API_BLAS}}, + {"cublasDscal_v2", {"hipblasDscal", "rocblas_dscal", CONV_LIB_FUNC, API_BLAS}}, + {"cublasCscal_v2", {"hipblasCscal", "", CONV_LIB_FUNC, API_BLAS, UNSUPPORTED}}, + {"cublasCsscal_v2", {"hipblasCsscal", "", CONV_LIB_FUNC, API_BLAS, UNSUPPORTED}}, + {"cublasZscal_v2", {"hipblasZscal", "", CONV_LIB_FUNC, API_BLAS, UNSUPPORTED}}, + {"cublasZdscal_v2", {"hipblasZdscal", "", CONV_LIB_FUNC, API_BLAS, UNSUPPORTED}}, // AXPY - {"cublasAxpyEx", {"hipblasAxpyEx", "", CONV_LIB_FUNC, API_BLAS, HIP_UNSUPPORTED}}, - {"cublasSaxpy_v2", {"hipblasSaxpy", "", CONV_LIB_FUNC, API_BLAS}}, - {"cublasDaxpy_v2", {"hipblasDaxpy", "", CONV_LIB_FUNC, API_BLAS}}, - {"cublasCaxpy_v2", {"hipblasCaxpy", "", CONV_LIB_FUNC, API_BLAS, HIP_UNSUPPORTED}}, - {"cublasZaxpy_v2", {"hipblasZaxpy", "", CONV_LIB_FUNC, API_BLAS, HIP_UNSUPPORTED}}, + {"cublasAxpyEx", {"hipblasAxpyEx", "", CONV_LIB_FUNC, API_BLAS, UNSUPPORTED}}, + {"cublasSaxpy_v2", {"hipblasSaxpy", "rocblas_saxpy", CONV_LIB_FUNC, API_BLAS}}, + {"cublasDaxpy_v2", {"hipblasDaxpy", "rocblas_daxpy", CONV_LIB_FUNC, API_BLAS}}, + {"cublasCaxpy_v2", {"hipblasCaxpy", "", CONV_LIB_FUNC, API_BLAS, UNSUPPORTED}}, + {"cublasZaxpy_v2", {"hipblasZaxpy", "", CONV_LIB_FUNC, API_BLAS, UNSUPPORTED}}, // COPY - {"cublasScopy_v2", {"hipblasScopy", "", CONV_LIB_FUNC, API_BLAS}}, - {"cublasDcopy_v2", {"hipblasDcopy", "", CONV_LIB_FUNC, API_BLAS}}, - {"cublasCcopy_v2", {"hipblasCcopy", "", CONV_LIB_FUNC, API_BLAS, HIP_UNSUPPORTED}}, - {"cublasZcopy_v2", {"hipblasZcopy", "", CONV_LIB_FUNC, API_BLAS, HIP_UNSUPPORTED}}, + {"cublasScopy_v2", {"hipblasScopy", "rocblas_scopy", CONV_LIB_FUNC, API_BLAS}}, + {"cublasDcopy_v2", {"hipblasDcopy", "rocblas_dcopy", CONV_LIB_FUNC, API_BLAS}}, + {"cublasCcopy_v2", {"hipblasCcopy", "", CONV_LIB_FUNC, API_BLAS, UNSUPPORTED}}, + {"cublasZcopy_v2", {"hipblasZcopy", "", CONV_LIB_FUNC, API_BLAS, UNSUPPORTED}}, // SWAP - {"cublasSswap_v2", {"hipblasSswap", "", CONV_LIB_FUNC, API_BLAS, HIP_UNSUPPORTED}}, - {"cublasDswap_v2", {"hipblasDswap", "", CONV_LIB_FUNC, API_BLAS, HIP_UNSUPPORTED}}, - {"cublasCswap_v2", {"hipblasCswap", "", CONV_LIB_FUNC, API_BLAS, HIP_UNSUPPORTED}}, - {"cublasZswap_v2", {"hipblasZswap", "", CONV_LIB_FUNC, API_BLAS, HIP_UNSUPPORTED}}, + {"cublasSswap_v2", {"hipblasSswap", "rocblas_sswap", CONV_LIB_FUNC, API_BLAS, HIP_UNSUPPORTED}}, + {"cublasDswap_v2", {"hipblasDswap", "rocblas_dswap", CONV_LIB_FUNC, API_BLAS, HIP_UNSUPPORTED}}, + {"cublasCswap_v2", {"hipblasCswap", "", CONV_LIB_FUNC, API_BLAS, UNSUPPORTED}}, + {"cublasZswap_v2", {"hipblasZswap", "", CONV_LIB_FUNC, API_BLAS, UNSUPPORTED}}, // AMAX - {"cublasIsamax_v2", {"hipblasIsamax", "", CONV_LIB_FUNC, API_BLAS}}, - {"cublasIdamax_v2", {"hipblasIdamax", "", CONV_LIB_FUNC, API_BLAS}}, - {"cublasIcamax_v2", {"hipblasIcamax", "", CONV_LIB_FUNC, API_BLAS, HIP_UNSUPPORTED}}, - {"cublasIzamax_v2", {"hipblasIzamax", "", CONV_LIB_FUNC, API_BLAS, HIP_UNSUPPORTED}}, + {"cublasIsamax_v2", {"hipblasIsamax", "rocblas_isamax", CONV_LIB_FUNC, API_BLAS}}, + {"cublasIdamax_v2", {"hipblasIdamax", "rocblas_idamax", CONV_LIB_FUNC, API_BLAS}}, + {"cublasIcamax_v2", {"hipblasIcamax", "", CONV_LIB_FUNC, API_BLAS, HIP_UNSUPPORTED}}, + {"cublasIzamax_v2", {"hipblasIzamax", "", CONV_LIB_FUNC, API_BLAS, HIP_UNSUPPORTED}}, // AMIN - {"cublasIsamin_v2", {"hipblasIsamin", "", CONV_LIB_FUNC, API_BLAS, HIP_UNSUPPORTED}}, - {"cublasIdamin_v2", {"hipblasIdamin", "", CONV_LIB_FUNC, API_BLAS, HIP_UNSUPPORTED}}, - {"cublasIcamin_v2", {"hipblasIcamin", "", CONV_LIB_FUNC, API_BLAS, HIP_UNSUPPORTED}}, - {"cublasIzamin_v2", {"hipblasIzamin", "", CONV_LIB_FUNC, API_BLAS, HIP_UNSUPPORTED}}, + {"cublasIsamin_v2", {"hipblasIsamin", "rocblas_isamin", CONV_LIB_FUNC, API_BLAS, HIP_UNSUPPORTED}}, + {"cublasIdamin_v2", {"hipblasIdamin", "rocblas_idamin", CONV_LIB_FUNC, API_BLAS, HIP_UNSUPPORTED}}, + {"cublasIcamin_v2", {"hipblasIcamin", "", CONV_LIB_FUNC, API_BLAS, UNSUPPORTED}}, + {"cublasIzamin_v2", {"hipblasIzamin", "", CONV_LIB_FUNC, API_BLAS, UNSUPPORTED}}, // ASUM - {"cublasSasum_v2", {"hipblasSasum", "", CONV_LIB_FUNC, API_BLAS}}, - {"cublasDasum_v2", {"hipblasDasum", "", CONV_LIB_FUNC, API_BLAS}}, - {"cublasScasum_v2", {"hipblasScasum", "", CONV_LIB_FUNC, API_BLAS, HIP_UNSUPPORTED}}, - {"cublasDzasum_v2", {"hipblasDzasum", "", CONV_LIB_FUNC, API_BLAS, HIP_UNSUPPORTED}}, + {"cublasSasum_v2", {"hipblasSasum", "rocblas_sasum", CONV_LIB_FUNC, API_BLAS}}, + {"cublasDasum_v2", {"hipblasDasum", "rocblas_dasum", CONV_LIB_FUNC, API_BLAS}}, + {"cublasScasum_v2", {"hipblasScasum", "", CONV_LIB_FUNC, API_BLAS, UNSUPPORTED}}, + {"cublasDzasum_v2", {"hipblasDzasum", "", CONV_LIB_FUNC, API_BLAS, UNSUPPORTED}}, // ROT - {"cublasSrot_v2", {"hipblasSrot", "", CONV_LIB_FUNC, API_BLAS, HIP_UNSUPPORTED}}, - {"cublasDrot_v2", {"hipblasDrot", "", CONV_LIB_FUNC, API_BLAS, HIP_UNSUPPORTED}}, - {"cublasCrot_v2", {"hipblasCrot", "", CONV_LIB_FUNC, API_BLAS, HIP_UNSUPPORTED}}, - {"cublasCsrot_v2", {"hipblasCsrot", "", CONV_LIB_FUNC, API_BLAS, HIP_UNSUPPORTED}}, - {"cublasZrot_v2", {"hipblasZrot", "", CONV_LIB_FUNC, API_BLAS, HIP_UNSUPPORTED}}, - {"cublasZdrot_v2", {"hipblasZdrot", "", CONV_LIB_FUNC, API_BLAS, HIP_UNSUPPORTED}}, + {"cublasSrot_v2", {"hipblasSrot", "", CONV_LIB_FUNC, API_BLAS, UNSUPPORTED}}, + {"cublasDrot_v2", {"hipblasDrot", "", CONV_LIB_FUNC, API_BLAS, UNSUPPORTED}}, + {"cublasCrot_v2", {"hipblasCrot", "", CONV_LIB_FUNC, API_BLAS, UNSUPPORTED}}, + {"cublasCsrot_v2", {"hipblasCsrot", "", CONV_LIB_FUNC, API_BLAS, UNSUPPORTED}}, + {"cublasZrot_v2", {"hipblasZrot", "", CONV_LIB_FUNC, API_BLAS, UNSUPPORTED}}, + {"cublasZdrot_v2", {"hipblasZdrot", "", CONV_LIB_FUNC, API_BLAS, UNSUPPORTED}}, // ROTG - {"cublasSrotg_v2", {"hipblasSrotg", "", CONV_LIB_FUNC, API_BLAS, HIP_UNSUPPORTED}}, - {"cublasDrotg_v2", {"hipblasDrotg", "", CONV_LIB_FUNC, API_BLAS, HIP_UNSUPPORTED}}, - {"cublasCrotg_v2", {"hipblasCrotg", "", CONV_LIB_FUNC, API_BLAS, HIP_UNSUPPORTED}}, - {"cublasZrotg_v2", {"hipblasZrotg", "", CONV_LIB_FUNC, API_BLAS, HIP_UNSUPPORTED}}, + {"cublasSrotg_v2", {"hipblasSrotg", "", CONV_LIB_FUNC, API_BLAS, UNSUPPORTED}}, + {"cublasDrotg_v2", {"hipblasDrotg", "", CONV_LIB_FUNC, API_BLAS, UNSUPPORTED}}, + {"cublasCrotg_v2", {"hipblasCrotg", "", CONV_LIB_FUNC, API_BLAS, UNSUPPORTED}}, + {"cublasZrotg_v2", {"hipblasZrotg", "", CONV_LIB_FUNC, API_BLAS, UNSUPPORTED}}, // ROTM - {"cublasSrotm_v2", {"hipblasSrotm", "", CONV_LIB_FUNC, API_BLAS, HIP_UNSUPPORTED}}, - {"cublasDrotm_v2", {"hipblasDrotm", "", CONV_LIB_FUNC, API_BLAS, HIP_UNSUPPORTED}}, + {"cublasSrotm_v2", {"hipblasSrotm", "", CONV_LIB_FUNC, API_BLAS, UNSUPPORTED}}, + {"cublasDrotm_v2", {"hipblasDrotm", "", CONV_LIB_FUNC, API_BLAS, UNSUPPORTED}}, // ROTMG - {"cublasSrotmg_v2", {"hipblasSrotmg", "", CONV_LIB_FUNC, API_BLAS, HIP_UNSUPPORTED}}, - {"cublasDrotmg_v2", {"hipblasDrotmg", "", CONV_LIB_FUNC, API_BLAS, HIP_UNSUPPORTED}}, + {"cublasSrotmg_v2", {"hipblasSrotmg", "", CONV_LIB_FUNC, API_BLAS, UNSUPPORTED}}, + {"cublasDrotmg_v2", {"hipblasDrotmg", "", CONV_LIB_FUNC, API_BLAS, UNSUPPORTED}}, }; diff --git a/projects/hip/hipify-clang/src/CUDA2HIP_BLAS_API_types.cpp b/projects/hip/hipify-clang/src/CUDA2HIP_BLAS_API_types.cpp index 26c42af0a6..6725d6b5a0 100644 --- a/projects/hip/hipify-clang/src/CUDA2HIP_BLAS_API_types.cpp +++ b/projects/hip/hipify-clang/src/CUDA2HIP_BLAS_API_types.cpp @@ -24,130 +24,125 @@ THE SOFTWARE. // Map of all functions const std::map CUDA_BLAS_TYPE_NAME_MAP{ - - ////////////////////// Blas Data Types - // Blas operations - {"cublasOperation_t", {"hipblasOperation_t", "", CONV_TYPE, API_BLAS}}, - {"CUBLAS_OP_N", {"HIPBLAS_OP_N", "", CONV_NUMERIC_LITERAL, API_BLAS}}, - {"CUBLAS_OP_T", {"HIPBLAS_OP_T", "", CONV_NUMERIC_LITERAL, API_BLAS}}, - {"CUBLAS_OP_C", {"HIPBLAS_OP_C", "", CONV_NUMERIC_LITERAL, API_BLAS}}, + {"cublasOperation_t", {"hipblasOperation_t", "rocblas_operation", CONV_TYPE, API_BLAS}}, + {"CUBLAS_OP_N", {"HIPBLAS_OP_N", "rocblas_operation_none", CONV_NUMERIC_LITERAL, API_BLAS}}, + {"CUBLAS_OP_T", {"HIPBLAS_OP_T", "rocblas_operation_transpose", CONV_NUMERIC_LITERAL, API_BLAS}}, + {"CUBLAS_OP_C", {"HIPBLAS_OP_C", "rocblas_operation_conjugate_transpose", CONV_NUMERIC_LITERAL, API_BLAS}}, // Blas statuses - {"cublasStatus", {"hipblasStatus_t", "", CONV_TYPE, API_BLAS}}, - {"cublasStatus_t", {"hipblasStatus_t", "", CONV_TYPE, API_BLAS}}, - {"CUBLAS_STATUS_SUCCESS", {"HIPBLAS_STATUS_SUCCESS", "", CONV_NUMERIC_LITERAL, API_BLAS}}, - {"CUBLAS_STATUS_NOT_INITIALIZED", {"HIPBLAS_STATUS_NOT_INITIALIZED", "", CONV_NUMERIC_LITERAL, API_BLAS}}, - {"CUBLAS_STATUS_ALLOC_FAILED", {"HIPBLAS_STATUS_ALLOC_FAILED", "", CONV_NUMERIC_LITERAL, API_BLAS}}, - {"CUBLAS_STATUS_INVALID_VALUE", {"HIPBLAS_STATUS_INVALID_VALUE", "", CONV_NUMERIC_LITERAL, API_BLAS}}, - {"CUBLAS_STATUS_MAPPING_ERROR", {"HIPBLAS_STATUS_MAPPING_ERROR", "", CONV_NUMERIC_LITERAL, API_BLAS}}, - {"CUBLAS_STATUS_EXECUTION_FAILED", {"HIPBLAS_STATUS_EXECUTION_FAILED", "", CONV_NUMERIC_LITERAL, API_BLAS}}, - {"CUBLAS_STATUS_INTERNAL_ERROR", {"HIPBLAS_STATUS_INTERNAL_ERROR", "", CONV_NUMERIC_LITERAL, API_BLAS}}, - {"CUBLAS_STATUS_NOT_SUPPORTED", {"HIPBLAS_STATUS_NOT_SUPPORTED", "", CONV_NUMERIC_LITERAL, API_BLAS}}, - {"CUBLAS_STATUS_ARCH_MISMATCH", {"HIPBLAS_STATUS_ARCH_MISMATCH", "", CONV_NUMERIC_LITERAL, API_BLAS}}, - {"CUBLAS_STATUS_LICENSE_ERROR", {"HIPBLAS_STATUS_LICENSE_ERROR", "", CONV_NUMERIC_LITERAL, API_BLAS, HIP_UNSUPPORTED}}, + {"cublasStatus", {"hipblasStatus_t", "rocblas_status", CONV_TYPE, API_BLAS}}, + {"cublasStatus_t", {"hipblasStatus_t", "rocblas_status", CONV_TYPE, API_BLAS}}, + {"CUBLAS_STATUS_SUCCESS", {"HIPBLAS_STATUS_SUCCESS", "rocblas_status_success", CONV_NUMERIC_LITERAL, API_BLAS}}, + {"CUBLAS_STATUS_NOT_INITIALIZED", {"HIPBLAS_STATUS_NOT_INITIALIZED", "rocblas_status_invalid_handle", CONV_NUMERIC_LITERAL, API_BLAS}}, + {"CUBLAS_STATUS_ALLOC_FAILED", {"HIPBLAS_STATUS_ALLOC_FAILED", "rocblas_status_memory_error", CONV_NUMERIC_LITERAL, API_BLAS}}, + {"CUBLAS_STATUS_INVALID_VALUE", {"HIPBLAS_STATUS_INVALID_VALUE", "rocblas_status_invalid_pointer", CONV_NUMERIC_LITERAL, API_BLAS}}, + {"CUBLAS_STATUS_MAPPING_ERROR", {"HIPBLAS_STATUS_MAPPING_ERROR", "rocblas_status_internal_error", CONV_NUMERIC_LITERAL, API_BLAS}}, + {"CUBLAS_STATUS_EXECUTION_FAILED", {"HIPBLAS_STATUS_EXECUTION_FAILED", "rocblas_status_internal_error", CONV_NUMERIC_LITERAL, API_BLAS}}, + {"CUBLAS_STATUS_INTERNAL_ERROR", {"HIPBLAS_STATUS_INTERNAL_ERROR", "rocblas_status_internal_error", CONV_NUMERIC_LITERAL, API_BLAS}}, + {"CUBLAS_STATUS_NOT_SUPPORTED", {"HIPBLAS_STATUS_NOT_SUPPORTED", "rocblas_status_not_implemented", CONV_NUMERIC_LITERAL, API_BLAS}}, + {"CUBLAS_STATUS_ARCH_MISMATCH", {"HIPBLAS_STATUS_ARCH_MISMATCH", "rocblas_status_not_implemented", CONV_NUMERIC_LITERAL, API_BLAS}}, + {"CUBLAS_STATUS_LICENSE_ERROR", {"HIPBLAS_STATUS_LICENSE_ERROR", "rocblas_status_not_implemented", CONV_NUMERIC_LITERAL, API_BLAS, UNSUPPORTED}}, // Blas Fill Modes - {"cublasFillMode_t", {"hipblasFillMode_t", "", CONV_TYPE, API_BLAS}}, - {"CUBLAS_FILL_MODE_LOWER", {"HIPBLAS_FILL_MODE_LOWER", "", CONV_NUMERIC_LITERAL, API_BLAS}}, - {"CUBLAS_FILL_MODE_UPPER", {"HIPBLAS_FILL_MODE_UPPER", "", CONV_NUMERIC_LITERAL, API_BLAS}}, + {"cublasFillMode_t", {"hipblasFillMode_t", "rocblas_fill", CONV_TYPE, API_BLAS}}, + {"CUBLAS_FILL_MODE_LOWER", {"HIPBLAS_FILL_MODE_LOWER", "rocblas_fill_lower", CONV_NUMERIC_LITERAL, API_BLAS}}, + {"CUBLAS_FILL_MODE_UPPER", {"HIPBLAS_FILL_MODE_UPPER", "rocblas_fill_upper", CONV_NUMERIC_LITERAL, API_BLAS}}, // Blas Diag Types - {"cublasDiagType_t", {"hipblasDiagType_t", "", CONV_TYPE, API_BLAS}}, - {"CUBLAS_DIAG_NON_UNIT", {"HIPBLAS_DIAG_NON_UNIT", "", CONV_NUMERIC_LITERAL, API_BLAS}}, - {"CUBLAS_DIAG_UNIT", {"HIPBLAS_DIAG_UNIT", "", CONV_NUMERIC_LITERAL, API_BLAS}}, + {"cublasDiagType_t", {"hipblasDiagType_t", "rocblas_diagonal", CONV_TYPE, API_BLAS}}, + {"CUBLAS_DIAG_NON_UNIT", {"HIPBLAS_DIAG_NON_UNIT", "rocblas_diagonal_non_unit", CONV_NUMERIC_LITERAL, API_BLAS}}, + {"CUBLAS_DIAG_UNIT", {"HIPBLAS_DIAG_UNIT", "rocblas_diagonal_unit", CONV_NUMERIC_LITERAL, API_BLAS}}, // Blas Side Modes - {"cublasSideMode_t", {"hipblasSideMode_t", "", CONV_TYPE, API_BLAS}}, - {"CUBLAS_SIDE_LEFT", {"HIPBLAS_SIDE_LEFT", "", CONV_NUMERIC_LITERAL, API_BLAS}}, - {"CUBLAS_SIDE_RIGHT", {"HIPBLAS_SIDE_RIGHT", "", CONV_NUMERIC_LITERAL, API_BLAS}}, + {"cublasSideMode_t", {"hipblasSideMode_t", "rocblas_side", CONV_TYPE, API_BLAS}}, + {"CUBLAS_SIDE_LEFT", {"HIPBLAS_SIDE_LEFT", "rocblas_side_left", CONV_NUMERIC_LITERAL, API_BLAS}}, + {"CUBLAS_SIDE_RIGHT", {"HIPBLAS_SIDE_RIGHT", "rocblas_side_right", CONV_NUMERIC_LITERAL, API_BLAS}}, // Blas Pointer Modes - {"cublasPointerMode_t", {"hipblasPointerMode_t", "", CONV_TYPE, API_BLAS}}, - {"CUBLAS_POINTER_MODE_HOST", {"HIPBLAS_POINTER_MODE_HOST", "", CONV_NUMERIC_LITERAL, API_BLAS}}, - {"CUBLAS_POINTER_MODE_DEVICE", {"HIPBLAS_POINTER_MODE_DEVICE", "", CONV_NUMERIC_LITERAL, API_BLAS}}, + {"cublasPointerMode_t", {"hipblasPointerMode_t", "rocblas_pointer_mode", CONV_TYPE, API_BLAS}}, + {"CUBLAS_POINTER_MODE_HOST", {"HIPBLAS_POINTER_MODE_HOST", "rocblas_pointer_mode_host", CONV_NUMERIC_LITERAL, API_BLAS}}, + {"CUBLAS_POINTER_MODE_DEVICE", {"HIPBLAS_POINTER_MODE_DEVICE", "rocblas_pointer_mode_device", CONV_NUMERIC_LITERAL, API_BLAS}}, // Blas Atomics Modes - {"cublasAtomicsMode_t", {"hipblasAtomicsMode_t", "", CONV_TYPE, API_BLAS, HIP_UNSUPPORTED}}, - {"CUBLAS_ATOMICS_NOT_ALLOWED", {"HIPBLAS_ATOMICS_NOT_ALLOWED", "", CONV_NUMERIC_LITERAL, API_BLAS, HIP_UNSUPPORTED}}, - {"CUBLAS_ATOMICS_ALLOWED", {"HIPBLAS_ATOMICS_ALLOWED", "", CONV_NUMERIC_LITERAL, API_BLAS, HIP_UNSUPPORTED}}, + {"cublasAtomicsMode_t", {"hipblasAtomicsMode_t", "rocblas_atomics_mode", CONV_TYPE, API_BLAS, HIP_UNSUPPORTED}}, + {"CUBLAS_ATOMICS_NOT_ALLOWED", {"HIPBLAS_ATOMICS_NOT_ALLOWED", "rocblas_atomics_not_allowed", CONV_NUMERIC_LITERAL, API_BLAS, HIP_UNSUPPORTED}}, + {"CUBLAS_ATOMICS_ALLOWED", {"HIPBLAS_ATOMICS_ALLOWED", "rocblas_atomics_allowed", CONV_NUMERIC_LITERAL, API_BLAS, HIP_UNSUPPORTED}}, // Blas Data Type - {"cublasDataType_t", {"hipblasDatatype_t", "", CONV_TYPE, API_BLAS}}, + {"cublasDataType_t", {"hipblasDatatype_t", "rocblas_datatype", CONV_TYPE, API_BLAS}}, // Blas Math mode/tensor operation - {"cublasMath_t", {"hipblasMath_t", "", CONV_TYPE, API_BLAS, HIP_UNSUPPORTED}}, - {"CUBLAS_DEFAULT_MATH", {"HIPBLAS_DEFAULT_MATH", "", CONV_NUMERIC_LITERAL, API_BLAS, HIP_UNSUPPORTED}}, - {"CUBLAS_TENSOR_OP_MATH", {"HIPBLAS_TENSOR_OP_MATH", "", CONV_NUMERIC_LITERAL, API_BLAS, HIP_UNSUPPORTED}}, + {"cublasMath_t", {"hipblasMath_t", "", CONV_TYPE, API_BLAS, UNSUPPORTED}}, + {"CUBLAS_DEFAULT_MATH", {"HIPBLAS_DEFAULT_MATH", "", CONV_NUMERIC_LITERAL, API_BLAS, UNSUPPORTED}}, + {"CUBLAS_TENSOR_OP_MATH", {"HIPBLAS_TENSOR_OP_MATH", "", CONV_NUMERIC_LITERAL, API_BLAS, UNSUPPORTED}}, // Blass different GEMM algorithms - {"cublasGemmAlgo_t", {"hipblasGemmAlgo_t", "", CONV_TYPE, API_BLAS}}, - {"CUBLAS_GEMM_DFALT", {"HIPBLAS_GEMM_DEFAULT", "", CONV_NUMERIC_LITERAL, API_BLAS}}, // -1 // 160 - {"CUBLAS_GEMM_DEFAULT", {"HIPBLAS_GEMM_DEFAULT", "", CONV_NUMERIC_LITERAL, API_BLAS}}, // -1 // 160 - {"CUBLAS_GEMM_ALGO0", {"HIPBLAS_GEMM_ALGO0", "", CONV_NUMERIC_LITERAL, API_BLAS, HIP_UNSUPPORTED}}, // 0 - {"CUBLAS_GEMM_ALGO1", {"HIPBLAS_GEMM_ALGO1", "", CONV_NUMERIC_LITERAL, API_BLAS, HIP_UNSUPPORTED}}, // 1 - {"CUBLAS_GEMM_ALGO2", {"HIPBLAS_GEMM_ALGO2", "", CONV_NUMERIC_LITERAL, API_BLAS, HIP_UNSUPPORTED}}, // 2 - {"CUBLAS_GEMM_ALGO3", {"HIPBLAS_GEMM_ALGO3", "", CONV_NUMERIC_LITERAL, API_BLAS, HIP_UNSUPPORTED}}, // 3 - {"CUBLAS_GEMM_ALGO4", {"HIPBLAS_GEMM_ALGO4", "", CONV_NUMERIC_LITERAL, API_BLAS, HIP_UNSUPPORTED}}, // 4 - {"CUBLAS_GEMM_ALGO5", {"HIPBLAS_GEMM_ALGO5", "", CONV_NUMERIC_LITERAL, API_BLAS, HIP_UNSUPPORTED}}, // 5 - {"CUBLAS_GEMM_ALGO6", {"HIPBLAS_GEMM_ALGO6", "", CONV_NUMERIC_LITERAL, API_BLAS, HIP_UNSUPPORTED}}, // 6 - {"CUBLAS_GEMM_ALGO7", {"HIPBLAS_GEMM_ALGO7", "", CONV_NUMERIC_LITERAL, API_BLAS, HIP_UNSUPPORTED}}, // 7 - {"CUBLAS_GEMM_ALGO8", {"HIPBLAS_GEMM_ALGO8", "", CONV_NUMERIC_LITERAL, API_BLAS, HIP_UNSUPPORTED}}, // 8 - {"CUBLAS_GEMM_ALGO9", {"HIPBLAS_GEMM_ALGO9", "", CONV_NUMERIC_LITERAL, API_BLAS, HIP_UNSUPPORTED}}, // 9 - {"CUBLAS_GEMM_ALGO10", {"HIPBLAS_GEMM_ALGO10", "", CONV_NUMERIC_LITERAL, API_BLAS, HIP_UNSUPPORTED}}, // 10 - {"CUBLAS_GEMM_ALGO11", {"HIPBLAS_GEMM_ALGO11", "", CONV_NUMERIC_LITERAL, API_BLAS, HIP_UNSUPPORTED}}, // 11 - {"CUBLAS_GEMM_ALGO12", {"HIPBLAS_GEMM_ALGO12", "", CONV_NUMERIC_LITERAL, API_BLAS, HIP_UNSUPPORTED}}, // 12 - {"CUBLAS_GEMM_ALGO13", {"HIPBLAS_GEMM_ALGO13", "", CONV_NUMERIC_LITERAL, API_BLAS, HIP_UNSUPPORTED}}, // 13 - {"CUBLAS_GEMM_ALGO14", {"HIPBLAS_GEMM_ALGO14", "", CONV_NUMERIC_LITERAL, API_BLAS, HIP_UNSUPPORTED}}, // 14 - {"CUBLAS_GEMM_ALGO15", {"HIPBLAS_GEMM_ALGO15", "", CONV_NUMERIC_LITERAL, API_BLAS, HIP_UNSUPPORTED}}, // 15 - {"CUBLAS_GEMM_ALGO16", {"HIPBLAS_GEMM_ALGO16", "", CONV_NUMERIC_LITERAL, API_BLAS, HIP_UNSUPPORTED}}, // 16 - {"CUBLAS_GEMM_ALGO17", {"HIPBLAS_GEMM_ALGO17", "", CONV_NUMERIC_LITERAL, API_BLAS, HIP_UNSUPPORTED}}, // 17 - {"CUBLAS_GEMM_ALGO18", {"HIPBLAS_GEMM_ALGO18", "", CONV_NUMERIC_LITERAL, API_BLAS, HIP_UNSUPPORTED}}, // 18 - {"CUBLAS_GEMM_ALGO19", {"HIPBLAS_GEMM_ALGO19", "", CONV_NUMERIC_LITERAL, API_BLAS, HIP_UNSUPPORTED}}, // 19 - {"CUBLAS_GEMM_ALGO20", {"HIPBLAS_GEMM_ALGO20", "", CONV_NUMERIC_LITERAL, API_BLAS, HIP_UNSUPPORTED}}, // 20 - {"CUBLAS_GEMM_ALGO21", {"HIPBLAS_GEMM_ALGO21", "", CONV_NUMERIC_LITERAL, API_BLAS, HIP_UNSUPPORTED}}, // 21 - {"CUBLAS_GEMM_ALGO22", {"HIPBLAS_GEMM_ALGO22", "", CONV_NUMERIC_LITERAL, API_BLAS, HIP_UNSUPPORTED}}, // 22 - {"CUBLAS_GEMM_ALGO23", {"HIPBLAS_GEMM_ALGO23", "", CONV_NUMERIC_LITERAL, API_BLAS, HIP_UNSUPPORTED}}, // 23 - {"CUBLAS_GEMM_DEFAULT_TENSOR_OP", {"HIPBLAS_GEMM_DEFAULT_TENSOR_OP", "", CONV_NUMERIC_LITERAL, API_BLAS, HIP_UNSUPPORTED}}, // 99 - {"CUBLAS_GEMM_DFALT_TENSOR_OP", {"HIPBLAS_GEMM_DFALT_TENSOR_OP", "", CONV_NUMERIC_LITERAL, API_BLAS, HIP_UNSUPPORTED}}, // 99 - {"CUBLAS_GEMM_ALGO0_TENSOR_OP", {"HIPBLAS_GEMM_ALGO0_TENSOR_OP", "", CONV_NUMERIC_LITERAL, API_BLAS, HIP_UNSUPPORTED}}, // 100 - {"CUBLAS_GEMM_ALGO1_TENSOR_OP", {"HIPBLAS_GEMM_ALGO1_TENSOR_OP", "", CONV_NUMERIC_LITERAL, API_BLAS, HIP_UNSUPPORTED}}, // 101 - {"CUBLAS_GEMM_ALGO2_TENSOR_OP", {"HIPBLAS_GEMM_ALGO2_TENSOR_OP", "", CONV_NUMERIC_LITERAL, API_BLAS, HIP_UNSUPPORTED}}, // 102 - {"CUBLAS_GEMM_ALGO3_TENSOR_OP", {"HIPBLAS_GEMM_ALGO3_TENSOR_OP", "", CONV_NUMERIC_LITERAL, API_BLAS, HIP_UNSUPPORTED}}, // 103 - {"CUBLAS_GEMM_ALGO4_TENSOR_OP", {"HIPBLAS_GEMM_ALGO4_TENSOR_OP", "", CONV_NUMERIC_LITERAL, API_BLAS, HIP_UNSUPPORTED}}, // 104 - {"CUBLAS_GEMM_ALGO5_TENSOR_OP", {"HIPBLAS_GEMM_ALGO5_TENSOR_OP", "", CONV_NUMERIC_LITERAL, API_BLAS, HIP_UNSUPPORTED}}, // 105 - {"CUBLAS_GEMM_ALGO6_TENSOR_OP", {"HIPBLAS_GEMM_ALGO6_TENSOR_OP", "", CONV_NUMERIC_LITERAL, API_BLAS, HIP_UNSUPPORTED}}, // 106 - {"CUBLAS_GEMM_ALGO7_TENSOR_OP", {"HIPBLAS_GEMM_ALGO7_TENSOR_OP", "", CONV_NUMERIC_LITERAL, API_BLAS, HIP_UNSUPPORTED}}, // 107 - {"CUBLAS_GEMM_ALGO8_TENSOR_OP", {"HIPBLAS_GEMM_ALGO8_TENSOR_OP", "", CONV_NUMERIC_LITERAL, API_BLAS, HIP_UNSUPPORTED}}, // 108 - {"CUBLAS_GEMM_ALGO9_TENSOR_OP", {"HIPBLAS_GEMM_ALGO9_TENSOR_OP", "", CONV_NUMERIC_LITERAL, API_BLAS, HIP_UNSUPPORTED}}, // 109 - {"CUBLAS_GEMM_ALGO10_TENSOR_OP", {"HIPBLAS_GEMM_ALGO10_TENSOR_OP", "", CONV_NUMERIC_LITERAL, API_BLAS, HIP_UNSUPPORTED}}, // 110 - {"CUBLAS_GEMM_ALGO11_TENSOR_OP", {"HIPBLAS_GEMM_ALGO11_TENSOR_OP", "", CONV_NUMERIC_LITERAL, API_BLAS, HIP_UNSUPPORTED}}, // 111 - {"CUBLAS_GEMM_ALGO12_TENSOR_OP", {"HIPBLAS_GEMM_ALGO12_TENSOR_OP", "", CONV_NUMERIC_LITERAL, API_BLAS, HIP_UNSUPPORTED}}, // 112 - {"CUBLAS_GEMM_ALGO13_TENSOR_OP", {"HIPBLAS_GEMM_ALGO13_TENSOR_OP", "", CONV_NUMERIC_LITERAL, API_BLAS, HIP_UNSUPPORTED}}, // 113 - {"CUBLAS_GEMM_ALGO14_TENSOR_OP", {"HIPBLAS_GEMM_ALGO14_TENSOR_OP", "", CONV_NUMERIC_LITERAL, API_BLAS, HIP_UNSUPPORTED}}, // 114 - {"CUBLAS_GEMM_ALGO15_TENSOR_OP", {"HIPBLAS_GEMM_ALGO15_TENSOR_OP", "", CONV_NUMERIC_LITERAL, API_BLAS, HIP_UNSUPPORTED}}, // 115 - + {"cublasGemmAlgo_t", {"hipblasGemmAlgo_t", "rocblas_gemm_algo", CONV_TYPE, API_BLAS}}, + {"CUBLAS_GEMM_DFALT", {"HIPBLAS_GEMM_DEFAULT", "rocblas_gemm_algo_standard", CONV_NUMERIC_LITERAL, API_BLAS}}, // -1 // 160 // 0b0000000000 + {"CUBLAS_GEMM_DEFAULT", {"HIPBLAS_GEMM_DEFAULT", "rocblas_gemm_algo_standard", CONV_NUMERIC_LITERAL, API_BLAS}}, // -1 // 160 // 0b0000000000 + {"CUBLAS_GEMM_ALGO0", {"HIPBLAS_GEMM_ALGO0", "", CONV_NUMERIC_LITERAL, API_BLAS, UNSUPPORTED}}, // 0 + {"CUBLAS_GEMM_ALGO1", {"HIPBLAS_GEMM_ALGO1", "", CONV_NUMERIC_LITERAL, API_BLAS, UNSUPPORTED}}, // 1 + {"CUBLAS_GEMM_ALGO2", {"HIPBLAS_GEMM_ALGO2", "", CONV_NUMERIC_LITERAL, API_BLAS, UNSUPPORTED}}, // 2 + {"CUBLAS_GEMM_ALGO3", {"HIPBLAS_GEMM_ALGO3", "", CONV_NUMERIC_LITERAL, API_BLAS, UNSUPPORTED}}, // 3 + {"CUBLAS_GEMM_ALGO4", {"HIPBLAS_GEMM_ALGO4", "", CONV_NUMERIC_LITERAL, API_BLAS, UNSUPPORTED}}, // 4 + {"CUBLAS_GEMM_ALGO5", {"HIPBLAS_GEMM_ALGO5", "", CONV_NUMERIC_LITERAL, API_BLAS, UNSUPPORTED}}, // 5 + {"CUBLAS_GEMM_ALGO6", {"HIPBLAS_GEMM_ALGO6", "", CONV_NUMERIC_LITERAL, API_BLAS, UNSUPPORTED}}, // 6 + {"CUBLAS_GEMM_ALGO7", {"HIPBLAS_GEMM_ALGO7", "", CONV_NUMERIC_LITERAL, API_BLAS, UNSUPPORTED}}, // 7 + {"CUBLAS_GEMM_ALGO8", {"HIPBLAS_GEMM_ALGO8", "", CONV_NUMERIC_LITERAL, API_BLAS, UNSUPPORTED}}, // 8 + {"CUBLAS_GEMM_ALGO9", {"HIPBLAS_GEMM_ALGO9", "", CONV_NUMERIC_LITERAL, API_BLAS, UNSUPPORTED}}, // 9 + {"CUBLAS_GEMM_ALGO10", {"HIPBLAS_GEMM_ALGO10", "", CONV_NUMERIC_LITERAL, API_BLAS, UNSUPPORTED}}, // 10 + {"CUBLAS_GEMM_ALGO11", {"HIPBLAS_GEMM_ALGO11", "", CONV_NUMERIC_LITERAL, API_BLAS, UNSUPPORTED}}, // 11 + {"CUBLAS_GEMM_ALGO12", {"HIPBLAS_GEMM_ALGO12", "", CONV_NUMERIC_LITERAL, API_BLAS, UNSUPPORTED}}, // 12 + {"CUBLAS_GEMM_ALGO13", {"HIPBLAS_GEMM_ALGO13", "", CONV_NUMERIC_LITERAL, API_BLAS, UNSUPPORTED}}, // 13 + {"CUBLAS_GEMM_ALGO14", {"HIPBLAS_GEMM_ALGO14", "", CONV_NUMERIC_LITERAL, API_BLAS, UNSUPPORTED}}, // 14 + {"CUBLAS_GEMM_ALGO15", {"HIPBLAS_GEMM_ALGO15", "", CONV_NUMERIC_LITERAL, API_BLAS, UNSUPPORTED}}, // 15 + {"CUBLAS_GEMM_ALGO16", {"HIPBLAS_GEMM_ALGO16", "", CONV_NUMERIC_LITERAL, API_BLAS, UNSUPPORTED}}, // 16 + {"CUBLAS_GEMM_ALGO17", {"HIPBLAS_GEMM_ALGO17", "", CONV_NUMERIC_LITERAL, API_BLAS, UNSUPPORTED}}, // 17 + {"CUBLAS_GEMM_ALGO18", {"HIPBLAS_GEMM_ALGO18", "", CONV_NUMERIC_LITERAL, API_BLAS, UNSUPPORTED}}, // 18 + {"CUBLAS_GEMM_ALGO19", {"HIPBLAS_GEMM_ALGO19", "", CONV_NUMERIC_LITERAL, API_BLAS, UNSUPPORTED}}, // 19 + {"CUBLAS_GEMM_ALGO20", {"HIPBLAS_GEMM_ALGO20", "", CONV_NUMERIC_LITERAL, API_BLAS, UNSUPPORTED}}, // 20 + {"CUBLAS_GEMM_ALGO21", {"HIPBLAS_GEMM_ALGO21", "", CONV_NUMERIC_LITERAL, API_BLAS, UNSUPPORTED}}, // 21 + {"CUBLAS_GEMM_ALGO22", {"HIPBLAS_GEMM_ALGO22", "", CONV_NUMERIC_LITERAL, API_BLAS, UNSUPPORTED}}, // 22 + {"CUBLAS_GEMM_ALGO23", {"HIPBLAS_GEMM_ALGO23", "", CONV_NUMERIC_LITERAL, API_BLAS, UNSUPPORTED}}, // 23 + {"CUBLAS_GEMM_DEFAULT_TENSOR_OP", {"HIPBLAS_GEMM_DEFAULT_TENSOR_OP", "", CONV_NUMERIC_LITERAL, API_BLAS, UNSUPPORTED}}, // 99 + {"CUBLAS_GEMM_DFALT_TENSOR_OP", {"HIPBLAS_GEMM_DFALT_TENSOR_OP", "", CONV_NUMERIC_LITERAL, API_BLAS, UNSUPPORTED}}, // 99 + {"CUBLAS_GEMM_ALGO0_TENSOR_OP", {"HIPBLAS_GEMM_ALGO0_TENSOR_OP", "", CONV_NUMERIC_LITERAL, API_BLAS, UNSUPPORTED}}, // 100 + {"CUBLAS_GEMM_ALGO1_TENSOR_OP", {"HIPBLAS_GEMM_ALGO1_TENSOR_OP", "", CONV_NUMERIC_LITERAL, API_BLAS, UNSUPPORTED}}, // 101 + {"CUBLAS_GEMM_ALGO2_TENSOR_OP", {"HIPBLAS_GEMM_ALGO2_TENSOR_OP", "", CONV_NUMERIC_LITERAL, API_BLAS, UNSUPPORTED}}, // 102 + {"CUBLAS_GEMM_ALGO3_TENSOR_OP", {"HIPBLAS_GEMM_ALGO3_TENSOR_OP", "", CONV_NUMERIC_LITERAL, API_BLAS, UNSUPPORTED}}, // 103 + {"CUBLAS_GEMM_ALGO4_TENSOR_OP", {"HIPBLAS_GEMM_ALGO4_TENSOR_OP", "", CONV_NUMERIC_LITERAL, API_BLAS, UNSUPPORTED}}, // 104 + {"CUBLAS_GEMM_ALGO5_TENSOR_OP", {"HIPBLAS_GEMM_ALGO5_TENSOR_OP", "", CONV_NUMERIC_LITERAL, API_BLAS, UNSUPPORTED}}, // 105 + {"CUBLAS_GEMM_ALGO6_TENSOR_OP", {"HIPBLAS_GEMM_ALGO6_TENSOR_OP", "", CONV_NUMERIC_LITERAL, API_BLAS, UNSUPPORTED}}, // 106 + {"CUBLAS_GEMM_ALGO7_TENSOR_OP", {"HIPBLAS_GEMM_ALGO7_TENSOR_OP", "", CONV_NUMERIC_LITERAL, API_BLAS, UNSUPPORTED}}, // 107 + {"CUBLAS_GEMM_ALGO8_TENSOR_OP", {"HIPBLAS_GEMM_ALGO8_TENSOR_OP", "", CONV_NUMERIC_LITERAL, API_BLAS, UNSUPPORTED}}, // 108 + {"CUBLAS_GEMM_ALGO9_TENSOR_OP", {"HIPBLAS_GEMM_ALGO9_TENSOR_OP", "", CONV_NUMERIC_LITERAL, API_BLAS, UNSUPPORTED}}, // 109 + {"CUBLAS_GEMM_ALGO10_TENSOR_OP", {"HIPBLAS_GEMM_ALGO10_TENSOR_OP", "", CONV_NUMERIC_LITERAL, API_BLAS, UNSUPPORTED}}, // 110 + {"CUBLAS_GEMM_ALGO11_TENSOR_OP", {"HIPBLAS_GEMM_ALGO11_TENSOR_OP", "", CONV_NUMERIC_LITERAL, API_BLAS, UNSUPPORTED}}, // 111 + {"CUBLAS_GEMM_ALGO12_TENSOR_OP", {"HIPBLAS_GEMM_ALGO12_TENSOR_OP", "", CONV_NUMERIC_LITERAL, API_BLAS, UNSUPPORTED}}, // 112 + {"CUBLAS_GEMM_ALGO13_TENSOR_OP", {"HIPBLAS_GEMM_ALGO13_TENSOR_OP", "", CONV_NUMERIC_LITERAL, API_BLAS, UNSUPPORTED}}, // 113 + {"CUBLAS_GEMM_ALGO14_TENSOR_OP", {"HIPBLAS_GEMM_ALGO14_TENSOR_OP", "", CONV_NUMERIC_LITERAL, API_BLAS, UNSUPPORTED}}, // 114 + {"CUBLAS_GEMM_ALGO15_TENSOR_OP", {"HIPBLAS_GEMM_ALGO15_TENSOR_OP", "", CONV_NUMERIC_LITERAL, API_BLAS, UNSUPPORTED}}, // 115 // TODO: rename hipblasDatatype_t to hipDataType_t and move from hipBLAS to HIP - {"cudaDataType_t", {"hipblasDatatype_t", "", CONV_TYPE, API_RUNTIME}}, - {"cudaDataType", {"hipblasDatatype_t", "", CONV_TYPE, API_RUNTIME}}, - {"CUDA_R_16F", {"HIPBLAS_R_16F", "", CONV_NUMERIC_LITERAL, API_RUNTIME}}, // 2 // 150 - {"CUDA_C_16F", {"HIPBLAS_C_16F", "", CONV_NUMERIC_LITERAL, API_RUNTIME}}, // 6 // 153 - {"CUDA_R_32F", {"HIPBLAS_R_32F", "", CONV_NUMERIC_LITERAL, API_RUNTIME}}, // 0 // 151 - {"CUDA_C_32F", {"HIPBLAS_C_32F", "", CONV_NUMERIC_LITERAL, API_RUNTIME}}, // 4 // 154 - {"CUDA_R_64F", {"HIPBLAS_R_64F", "", CONV_NUMERIC_LITERAL, API_RUNTIME}}, // 1 // 152 - {"CUDA_C_64F", {"HIPBLAS_C_64F", "", CONV_NUMERIC_LITERAL, API_RUNTIME}}, // 5 // 155 - {"CUDA_R_8I", {"HIPBLAS_R_8I", "", CONV_NUMERIC_LITERAL, API_RUNTIME, HIP_UNSUPPORTED}}, // 3 // - {"CUDA_C_8I", {"HIPBLAS_C_8I", "", CONV_NUMERIC_LITERAL, API_RUNTIME, HIP_UNSUPPORTED}}, // 7 // - {"CUDA_R_8U", {"HIPBLAS_R_8U", "", CONV_NUMERIC_LITERAL, API_RUNTIME, HIP_UNSUPPORTED}}, // 8 // - {"CUDA_C_8U", {"HIPBLAS_C_8U", "", CONV_NUMERIC_LITERAL, API_RUNTIME, HIP_UNSUPPORTED}}, // 9 // - {"CUDA_R_32I", {"HIPBLAS_R_32I", "", CONV_NUMERIC_LITERAL, API_RUNTIME, HIP_UNSUPPORTED}}, // 10 // - {"CUDA_C_32I", {"HIPBLAS_C_32I", "", CONV_NUMERIC_LITERAL, API_RUNTIME, HIP_UNSUPPORTED}}, // 11 // - {"CUDA_R_32U", {"HIPBLAS_R_32U", "", CONV_NUMERIC_LITERAL, API_RUNTIME, HIP_UNSUPPORTED}}, // 12 // - {"CUDA_C_32U", {"HIPBLAS_C_32U", "", CONV_NUMERIC_LITERAL, API_RUNTIME, HIP_UNSUPPORTED}}, // 13 // + {"cudaDataType_t", {"hipblasDatatype_t", "rocblas_datatype_", CONV_TYPE, API_RUNTIME}}, + {"cudaDataType", {"hipblasDatatype_t", "rocblas_datatype", CONV_TYPE, API_RUNTIME}}, + {"CUDA_R_16F", {"HIPBLAS_R_16F", "rocblas_datatype_f16_r", CONV_NUMERIC_LITERAL, API_RUNTIME}}, // 2 // 150 + {"CUDA_C_16F", {"HIPBLAS_C_16F", "rocblas_datatype_f16_c", CONV_NUMERIC_LITERAL, API_RUNTIME}}, // 6 // 153 + {"CUDA_R_32F", {"HIPBLAS_R_32F", "rocblas_datatype_f32_r", CONV_NUMERIC_LITERAL, API_RUNTIME}}, // 0 // 151 + {"CUDA_C_32F", {"HIPBLAS_C_32F", "rocblas_datatype_f32_c", CONV_NUMERIC_LITERAL, API_RUNTIME}}, // 4 // 154 + {"CUDA_R_64F", {"HIPBLAS_R_64F", "rocblas_datatype_f64_r", CONV_NUMERIC_LITERAL, API_RUNTIME}}, // 1 // 152 + {"CUDA_C_64F", {"HIPBLAS_C_64F", "rocblas_datatype_f64_c", CONV_NUMERIC_LITERAL, API_RUNTIME}}, // 5 // 155 + {"CUDA_R_8I", {"HIPBLAS_R_8I", "rocblas_datatype_i8_r", CONV_NUMERIC_LITERAL, API_RUNTIME, HIP_UNSUPPORTED}}, // 3 // 160 + {"CUDA_C_8I", {"HIPBLAS_C_8I", "rocblas_datatype_i8_c", CONV_NUMERIC_LITERAL, API_RUNTIME, HIP_UNSUPPORTED}}, // 7 // 164 + {"CUDA_R_8U", {"HIPBLAS_R_8U", "rocblas_datatype_u8_r", CONV_NUMERIC_LITERAL, API_RUNTIME, HIP_UNSUPPORTED}}, // 8 // 161 + {"CUDA_C_8U", {"HIPBLAS_C_8U", "rocblas_datatype_u8_c", CONV_NUMERIC_LITERAL, API_RUNTIME, HIP_UNSUPPORTED}}, // 9 // 165 + {"CUDA_R_32I", {"HIPBLAS_R_32I", "rocblas_datatype_i32_r", CONV_NUMERIC_LITERAL, API_RUNTIME, HIP_UNSUPPORTED}}, // 10 // 162 + {"CUDA_C_32I", {"HIPBLAS_C_32I", "rocblas_datatype_i32_c", CONV_NUMERIC_LITERAL, API_RUNTIME, HIP_UNSUPPORTED}}, // 11 // 166 + {"CUDA_R_32U", {"HIPBLAS_R_32U", "rocblas_datatype_u32_r", CONV_NUMERIC_LITERAL, API_RUNTIME, HIP_UNSUPPORTED}}, // 12 // 163 + {"CUDA_C_32U", {"HIPBLAS_C_32U", "rocblas_datatype_u32_c", CONV_NUMERIC_LITERAL, API_RUNTIME, HIP_UNSUPPORTED}}, // 13 // 167 - - {"cublasHandle_t", {"hipblasHandle_t", "", CONV_TYPE, API_BLAS}}, + {"cublasHandle_t", {"hipblasHandle_t", "rocblas_handle", CONV_TYPE, API_BLAS}}, // TODO: dereferencing: typedef struct cublasContext *cublasHandle_t; - // {"cublasContext", {"hipblasHandle_t", "", CONV_TYPE, API_BLAS}}, + {"cublasContext", {"hipblasHandle_t", "_rocblas_handle", CONV_TYPE, API_BLAS, HIP_UNSUPPORTED}}, }; From 4a6bf8ed2df40c6792feb0e29e6032cfb519ec98 Mon Sep 17 00:00:00 2001 From: Maneesh Gupta Date: Thu, 7 Feb 2019 15:41:53 +0530 Subject: [PATCH 13/16] [ci] Remove rocm-2.0.x from test infrastructure Change-Id: I5d3832972de61e7ba5b32f4e50f3af5a152cb152 [ROCm/hip commit: 223093be60e251e3f62182dfa824f3384c75fdfa] --- projects/hip/Jenkinsfile | 47 +--------------------------------------- 1 file changed, 1 insertion(+), 46 deletions(-) diff --git a/projects/hip/Jenkinsfile b/projects/hip/Jenkinsfile index b157e71e59..0be0bf29bd 100644 --- a/projects/hip/Jenkinsfile +++ b/projects/hip/Jenkinsfile @@ -295,7 +295,7 @@ def docker_upload_dockerhub( String local_org, String image_name, String remote_ String build_config = 'Release' String job_name = env.JOB_NAME.toLowerCase( ) -// The following launches 4 builds in parallel: rocm-head, rocm-2.1.x, rocm-2.0.x and cuda-9.x +// The following launches 3 builds in parallel: rocm-head, rocm-2.1.x and cuda-9.x parallel rocm_2_1: { node('hip-rocm') @@ -341,51 +341,6 @@ parallel rocm_2_1: */ } }, -rocm_2_0: -{ - node('hip-rocm') - { - String hcc_ver = 'rocm-2.0.x' - String from_image = 'ci_test_nodes/rocm-2.0.x/ubuntu-16.04:latest' - String inside_args = '--device=/dev/kfd --device=/dev/dri --group-add=video' - - // Checkout source code, dependencies and version files - String source_hip_rel = checkout_and_version( hcc_ver ) - - // Create/reuse a docker image that represents the hip build environment - def hip_build_image = docker_build_image( hcc_ver, 'hip', '', source_hip_rel, from_image ) - - // Print system information for the log - hip_build_image.inside( inside_args ) - { - sh """#!/usr/bin/env bash - set -x - /opt/rocm/bin/rocm_agent_enumerator -t ALL - /opt/rocm/bin/hcc --version - """ - } - - // Conctruct a binary directory path based on build config - String build_hip_rel = build_directory_rel( build_config ); - - // Build hip inside of the build environment - docker_build_inside_image( hip_build_image, inside_args, hcc_ver, '', build_config, source_hip_rel, build_hip_rel ) - - // Clean docker build image - docker_clean_images( 'hip', docker_build_image_name( ) ) - - // After a successful build, upload a docker image of the results - /* - String hip_image_name = docker_upload_artifactory( hcc_ver, job_name, from_image, source_hip_rel, build_hip_rel ) - if( params.push_image_to_docker_hub ) - { - docker_upload_dockerhub( job_name, hip_image_name, 'rocm' ) - docker_clean_images( 'rocm', hip_image_name ) - } - docker_clean_images( job_name, hip_image_name ) - */ - } -}, rocm_head: { node('hip-rocm') From 32bbedaa557d21c0e0e010c9944ac9f753cf5b74 Mon Sep 17 00:00:00 2001 From: Evgeny Mankov Date: Thu, 7 Feb 2019 13:17:05 +0300 Subject: [PATCH 14/16] [HIPIFY][BLAS] Restrict hipification to 'ROC' to BLAS library only + Add utility functions isToRoc, isHipUnsupported, isRocUnsupported, isUnsupported [ROCm/hip commit: e93fe7864884aae89e12dbcdf0a8c7f8d171ca3c] --- projects/hip/hipify-clang/src/CUDA2HIP.cpp | 4 +-- .../hip/hipify-clang/src/HipifyAction.cpp | 32 ++++++------------- projects/hip/hipify-clang/src/Statistics.cpp | 25 +++++++++++++-- projects/hip/hipify-clang/src/Statistics.h | 11 +++++++ 4 files changed, 45 insertions(+), 27 deletions(-) diff --git a/projects/hip/hipify-clang/src/CUDA2HIP.cpp b/projects/hip/hipify-clang/src/CUDA2HIP.cpp index 0dcef4da35..920b310da8 100644 --- a/projects/hip/hipify-clang/src/CUDA2HIP.cpp +++ b/projects/hip/hipify-clang/src/CUDA2HIP.cpp @@ -37,8 +37,8 @@ const std::map CUDA_INCLUDE_MAP{ // cuComplex includes {"cuComplex.h", {"hip/hip_complex.h", "", CONV_INCLUDE_CUDA_MAIN_H, API_COMPLEX}}, // cuBLAS includes - {"cublas.h", {"hipblas.h", "", CONV_INCLUDE_CUDA_MAIN_H, API_BLAS}}, - {"cublas_v2.h", {"hipblas.h", "", CONV_INCLUDE_CUDA_MAIN_H, API_BLAS}}, + {"cublas.h", {"hipblas.h", "rocblas.h", CONV_INCLUDE_CUDA_MAIN_H, API_BLAS}}, + {"cublas_v2.h", {"hipblas.h", "rocblas.h", CONV_INCLUDE_CUDA_MAIN_H, API_BLAS}}, // cuRAND includes {"curand.h", {"hiprand.h", "", CONV_INCLUDE_CUDA_MAIN_H, API_RAND}}, {"curand_kernel.h", {"hiprand_kernel.h", "", CONV_INCLUDE, API_RAND}}, diff --git a/projects/hip/hipify-clang/src/HipifyAction.cpp b/projects/hip/hipify-clang/src/HipifyAction.cpp index a021fb3f74..f4d68cd820 100644 --- a/projects/hip/hipify-clang/src/HipifyAction.cpp +++ b/projects/hip/hipify-clang/src/HipifyAction.cpp @@ -41,11 +41,10 @@ void HipifyAction::RewriteString(StringRef s, clang::SourceLocation start) { StringRef name = s.slice(begin, end); const auto found = CUDA_RENAMES_MAP().find(name); if (found != CUDA_RENAMES_MAP().end()) { - StringRef repName = TranslateToRoc ? found->second.rocName : found->second.hipName; + StringRef repName = Statistics::isToRoc(found->second) ? found->second.rocName : found->second.hipName; hipCounter counter = {"[string literal]", "", ConvTypes::CONV_LITERAL, ApiTypes::API_RUNTIME, found->second.supportDegree}; Statistics::current().incrementCounter(counter, name.str()); - if ((!TranslateToRoc && (HIP_UNSUPPORTED != (counter.supportDegree & HIP_UNSUPPORTED))) || - (TranslateToRoc && (ROC_UNSUPPORTED != (counter.supportDegree & ROC_UNSUPPORTED)))) { + if (!Statistics::isUnsupported(counter)) { clang::SourceLocation sl = start.getLocWithOffset(begin + 1); ct::Replacement Rep(SM, sl, name.size(), repName.str()); clang::FullSourceLoc fullSL(sl, SM); @@ -60,7 +59,7 @@ void HipifyAction::RewriteString(StringRef s, clang::SourceLocation start) { } /** - * Look at, and consider altering, a given token. + * Look at, and consider altering, a given token. * * If it's not a CUDA identifier, nothing happens. * If it's an unsupported CUDA identifier, a warning is emitted. @@ -68,7 +67,7 @@ void HipifyAction::RewriteString(StringRef s, clang::SourceLocation start) { */ void HipifyAction::RewriteToken(const clang::Token& t) { clang::SourceManager& SM = getCompilerInstance().getSourceManager(); - // String literals containing CUDA references need fixing... + // String literals containing CUDA references need fixing. if (t.is(clang::tok::string_literal)) { StringRef s(t.getLiteralData(), t.getLength()); RewriteString(unquoteStr(s), t.getLocation()); @@ -86,26 +85,16 @@ void HipifyAction::RewriteToken(const clang::Token& t) { Statistics::current().incrementCounter(found->second, name.str()); clang::SourceLocation sl = t.getLocation(); clang::DiagnosticsEngine& DE = getCompilerInstance().getDiagnostics(); - bool bWarn = false; - std::string sWarn = "HIP"; - if (TranslateToRoc) { - if ((found->second.supportDegree & ROC_UNSUPPORTED) == ROC_UNSUPPORTED) { - sWarn = "ROCm"; - bWarn = true; - } - } else { - if ((found->second.supportDegree & HIP_UNSUPPORTED) == HIP_UNSUPPORTED) { - bWarn = true; - } - } // Warn the user about unsupported identifier. - if (bWarn) { + if (Statistics::isUnsupported(found->second)) { + std::string sWarn; + Statistics::isToRoc(found->second) ? sWarn = "ROC" : sWarn = "HIP"; sWarn = "" + sWarn; const auto ID = DE.getCustomDiagID(clang::DiagnosticsEngine::Warning, "CUDA identifier is unsupported in %0."); DE.Report(sl, ID) << sWarn; return; } - StringRef repName = TranslateToRoc ? found->second.rocName : found->second.hipName; + StringRef repName = Statistics::isToRoc(found->second) ? found->second.rocName : found->second.hipName; ct::Replacement Rep(SM, sl, name.size(), repName.str()); clang::FullSourceLoc fullSL(sl, SM); insertReplacement(Rep, fullSL); @@ -238,8 +227,7 @@ void HipifyAction::InclusionDirective(clang::SourceLocation hash_loc, Statistics::current().incrementCounter(found->second, file_name.str()); clang::SourceLocation sl = filename_range.getBegin(); - if ((!TranslateToRoc && (HIP_UNSUPPORTED == (found->second.supportDegree & HIP_UNSUPPORTED))) || - (TranslateToRoc && (ROC_UNSUPPORTED == (found->second.supportDegree & ROC_UNSUPPORTED)))) { + if (Statistics::isUnsupported(found->second)) { clang::DiagnosticsEngine& DE = getCompilerInstance().getDiagnostics(); DE.Report(sl, DE.getCustomDiagID(clang::DiagnosticsEngine::Warning, "Unsupported CUDA header.")); return; @@ -249,7 +237,7 @@ void HipifyAction::InclusionDirective(clang::SourceLocation hash_loc, // Keep the same include type that the user gave. if (!exclude) { clang::SmallString<128> includeBuffer; - llvm::StringRef name = TranslateToRoc ? found->second.rocName : found->second.hipName; + llvm::StringRef name = Statistics::isToRoc(found->second) ? found->second.rocName : found->second.hipName; if (is_angled) { newInclude = llvm::Twine("<" + name+ ">").toStringRef(includeBuffer); } else { diff --git a/projects/hip/hipify-clang/src/Statistics.cpp b/projects/hip/hipify-clang/src/Statistics.cpp index 1943d82f98..39f70e9d8a 100644 --- a/projects/hip/hipify-clang/src/Statistics.cpp +++ b/projects/hip/hipify-clang/src/Statistics.cpp @@ -177,8 +177,7 @@ Statistics::Statistics(const std::string& name): fileName(name) { ///////// Counter update routines ////////// void Statistics::incrementCounter(const hipCounter &counter, const std::string& name) { - if ((!TranslateToRoc && (HIP_UNSUPPORTED == (counter.supportDegree & HIP_UNSUPPORTED))) || - (TranslateToRoc && (ROC_UNSUPPORTED == (counter.supportDegree & ROC_UNSUPPORTED)))) { + if (Statistics::isUnsupported(counter)) { unsupported.incrementCounter(counter, name); } else { supported.incrementCounter(counter, name); @@ -202,7 +201,7 @@ void Statistics::add(const Statistics &other) { void Statistics::lineTouched(int lineNumber) { touchedLinesSet.insert(lineNumber); - touchedLines = touchedLinesSet.size(); + touchedLines = unsigned(touchedLinesSet.size()); } void Statistics::bytesChanged(int bytes) { @@ -284,5 +283,25 @@ void Statistics::setActive(const std::string& name) { Statistics::currentStatistics = &stats.at(name); } +bool Statistics::isToRoc(const hipCounter &counter) { + return TranslateToRoc && counter.apiType == API_BLAS; +} + +bool Statistics::isHipUnsupported(const hipCounter &counter) { + return HIP_UNSUPPORTED == (counter.supportDegree & HIP_UNSUPPORTED); +} + +bool Statistics::isRocUnsupported(const hipCounter &counter) { + return ROC_UNSUPPORTED == (counter.supportDegree & ROC_UNSUPPORTED); +} + +bool Statistics::isUnsupported(const hipCounter &counter) { + if (Statistics::isToRoc(counter)) { + return Statistics::isRocUnsupported(counter); + } else { + return Statistics::isHipUnsupported(counter); + } +} + std::map Statistics::stats = {}; Statistics* Statistics::currentStatistics = nullptr; diff --git a/projects/hip/hipify-clang/src/Statistics.h b/projects/hip/hipify-clang/src/Statistics.h index 4d51b71697..6d8986bc52 100644 --- a/projects/hip/hipify-clang/src/Statistics.h +++ b/projects/hip/hipify-clang/src/Statistics.h @@ -225,6 +225,17 @@ public: * timestamp into the currently active one. */ static void setActive(const std::string& name); + // Check the counter and option TranslateToRoc whether it should be translated to Roc or not. + static bool isToRoc(const hipCounter &counter); + // Check whether the counter is HIP_UNSUPPORTED or not. + static bool isHipUnsupported(const hipCounter &counter); + // Check whether the counter is ROC_UNSUPPORTED or not. + static bool isRocUnsupported(const hipCounter &counter); + /** + * Check whether the counter is ROC_UNSUPPORTED/HIP_UNSUPPORTED/UNSUPPORTED or not + * based on counter's API_TYPE and option TranslateToRoc. + */ + static bool isUnsupported(const hipCounter &counter); // Set this flag in case of hipification errors bool hasErrors = false; }; From 032cb00926669f78ff820730d225e4e2cd38fdb1 Mon Sep 17 00:00:00 2001 From: Evgeny Mankov Date: Thu, 7 Feb 2019 19:25:23 +0300 Subject: [PATCH 15/16] [HIPIFY][BLAS][tests] Add tests on hipifying to 'roc' [ROCm/hip commit: 385fe36f2a22e98e64e37b77734be84f29a4a0e7] --- projects/hip/tests/hipify-clang/run_test.bat | 7 +- projects/hip/tests/hipify-clang/run_test.sh | 5 +- .../cuBLAS/cublas_0_based_indexing.cu | 2 + .../cublas_0_based_indexing_rocblas.cu | 81 +++++++++++++ .../cublas_1_based_indexing_rocblas.cu | 90 +++++++++++++++ ...las_sgemm_matrix_multiplication_rocblas.cu | 108 ++++++++++++++++++ 6 files changed, 288 insertions(+), 5 deletions(-) create mode 100644 projects/hip/tests/hipify-clang/unit_tests/libraries/cuBLAS/rocBLAS/cublas_0_based_indexing_rocblas.cu create mode 100644 projects/hip/tests/hipify-clang/unit_tests/libraries/cuBLAS/rocBLAS/cublas_1_based_indexing_rocblas.cu create mode 100644 projects/hip/tests/hipify-clang/unit_tests/libraries/cuBLAS/rocBLAS/cublas_sgemm_matrix_multiplication_rocblas.cu diff --git a/projects/hip/tests/hipify-clang/run_test.bat b/projects/hip/tests/hipify-clang/run_test.bat index 58563be2c7..8b10bc8c2e 100644 --- a/projects/hip/tests/hipify-clang/run_test.bat +++ b/projects/hip/tests/hipify-clang/run_test.bat @@ -8,12 +8,13 @@ set HIPIFY=%1 set IN_FILE=%2 set TMP_FILE=%3 set CUDA_ROOT=%4 +set ROC=%5 set all_args=%* -call set clang_args=%%all_args:*%5=%% -set clang_args=%5%clang_args% +call set clang_args=%%all_args:*%6=%% +set clang_args=%6%clang_args% -%HIPIFY% -o=%TMP_FILE% %IN_FILE% %CUDA_ROOT% -- %clang_args% +%HIPIFY% -o=%TMP_FILE% %IN_FILE% %CUDA_ROOT% %ROC% -- %clang_args% if errorlevel 1 (echo Error: hipify-clang.exe failed with exit code: %errorlevel% && exit /b %errorlevel%) findstr /v /r /c:"[ ]*//[ ]*[CHECK*|RUN]" %TMP_FILE% | %FILE_CHECK% %IN_FILE% diff --git a/projects/hip/tests/hipify-clang/run_test.sh b/projects/hip/tests/hipify-clang/run_test.sh index eb3e822549..357976558e 100755 --- a/projects/hip/tests/hipify-clang/run_test.sh +++ b/projects/hip/tests/hipify-clang/run_test.sh @@ -10,8 +10,9 @@ HIPIFY=$1 IN_FILE=$2 TMP_FILE=$3 CUDA_ROOT=$4 -shift 4 +ROC=$5 +shift 5 # Remaining args are the ones to forward to clang proper. -$HIPIFY -o=$TMP_FILE $IN_FILE $CUDA_ROOT -- $@ && cat $TMP_FILE | sed -Ee 's|//.+|// |g' | FileCheck $IN_FILE +$HIPIFY -o=$TMP_FILE $IN_FILE $CUDA_ROOT $ROC -- $@ && cat $TMP_FILE | sed -Ee 's|//.+|// |g' | FileCheck $IN_FILE diff --git a/projects/hip/tests/hipify-clang/unit_tests/libraries/cuBLAS/cublas_0_based_indexing.cu b/projects/hip/tests/hipify-clang/unit_tests/libraries/cuBLAS/cublas_0_based_indexing.cu index af24737dbc..69812c98b0 100644 --- a/projects/hip/tests/hipify-clang/unit_tests/libraries/cuBLAS/cublas_0_based_indexing.cu +++ b/projects/hip/tests/hipify-clang/unit_tests/libraries/cuBLAS/cublas_0_based_indexing.cu @@ -1,5 +1,6 @@ // RUN: %run_test hipify "%s" "%t" %hipify_args %clang_args +// CHECK: #include #include #include #include @@ -33,6 +34,7 @@ int main(void) { } // cublasInit is not supported yet cublasInit(); + // cublasAlloc is not supported yet stat = cublasAlloc(M*N, sizeof(*a), (void**)&devPtrA); // CHECK: if (stat != HIPBLAS_STATUS_SUCCESS) { if (stat != CUBLAS_STATUS_SUCCESS) { diff --git a/projects/hip/tests/hipify-clang/unit_tests/libraries/cuBLAS/rocBLAS/cublas_0_based_indexing_rocblas.cu b/projects/hip/tests/hipify-clang/unit_tests/libraries/cuBLAS/rocBLAS/cublas_0_based_indexing_rocblas.cu new file mode 100644 index 0000000000..c61b9c8bd5 --- /dev/null +++ b/projects/hip/tests/hipify-clang/unit_tests/libraries/cuBLAS/rocBLAS/cublas_0_based_indexing_rocblas.cu @@ -0,0 +1,81 @@ +// RUN: %run_test hipify "%s" "%t" %hipify_args "-roc" %clang_args + +// CHECK: #include +#include +#include +#include +// CHECK: #include "rocblas.h" +#include "cublas.h" +#define M 6 +#define N 5 +#define IDX2C(i,j,ld) (((j)*(ld))+(i)) +static __inline__ void modify(float *m, int ldm, int n, int p, int q, float + alpha, float beta) { + // CHECK: rocblas_sscal(n - p, alpha, &m[IDX2C(p, q, ldm)], ldm); + // CHECK: rocblas_sscal(ldm - p, beta, &m[IDX2C(p, q, ldm)], 1); + cublasSscal(n - p, alpha, &m[IDX2C(p, q, ldm)], ldm); + cublasSscal(ldm - p, beta, &m[IDX2C(p, q, ldm)], 1); +} +int main(void) { + int i, j; + // CHECK: rocblas_status stat; + cublasStatus stat; + float* devPtrA; + float* a = 0; + a = (float *)malloc(M * N * sizeof(*a)); + if (!a) { + printf("host memory allocation failed"); + return EXIT_FAILURE; + } + for (j = 0; j < N; j++) { + for (i = 0; i < M; i++) { + a[IDX2C(i, j, M)] = (float)(i * M + j + 1); + } + } + // cublasInit is not supported yet + cublasInit(); + // cublasAlloc is not supported yet + stat = cublasAlloc(M*N, sizeof(*a), (void**)&devPtrA); + // CHECK: if (stat != rocblas_status_success) { + if (stat != CUBLAS_STATUS_SUCCESS) { + printf("device memory allocation failed"); + // cublasShutdown is not supported yet + cublasShutdown(); + return EXIT_FAILURE; + } + // CHECK: stat = rocblas_set_matrix(M, N, sizeof(*a), a, M, devPtrA, M); + stat = cublasSetMatrix(M, N, sizeof(*a), a, M, devPtrA, M); + // CHECK: if (stat != rocblas_status_success) { + if (stat != CUBLAS_STATUS_SUCCESS) { + printf("data download failed"); + // cublasFree is not supported yet + cublasFree(devPtrA); + // cublasShutdown is not supported yet + cublasShutdown(); + return EXIT_FAILURE; + } + modify(devPtrA, M, N, 1, 2, 16.0f, 12.0f); + // CHECK: stat = rocblas_get_matrix(M, N, sizeof(*a), devPtrA, M, a, M); + stat = cublasGetMatrix(M, N, sizeof(*a), devPtrA, M, a, M); + // CHECK: if (stat != rocblas_status_success) { + if (stat != CUBLAS_STATUS_SUCCESS) { + printf("data upload failed"); + // cublasFree is not supported yet + cublasFree(devPtrA); + // cublasShutdown is not supported yet + cublasShutdown(); + return EXIT_FAILURE; + } + // cublasFree is not supported yet + cublasFree(devPtrA); + // cublasShutdown is not supported yet + cublasShutdown(); + for (j = 0; j < N; j++) { + for (i = 0; i < M; i++) { + printf("%7.0f", a[IDX2C(i, j, M)]); + } + printf("\n"); + } + free(a); + return EXIT_SUCCESS; +} diff --git a/projects/hip/tests/hipify-clang/unit_tests/libraries/cuBLAS/rocBLAS/cublas_1_based_indexing_rocblas.cu b/projects/hip/tests/hipify-clang/unit_tests/libraries/cuBLAS/rocBLAS/cublas_1_based_indexing_rocblas.cu new file mode 100644 index 0000000000..0202e2f7fa --- /dev/null +++ b/projects/hip/tests/hipify-clang/unit_tests/libraries/cuBLAS/rocBLAS/cublas_1_based_indexing_rocblas.cu @@ -0,0 +1,90 @@ +// RUN: %run_test hipify "%s" "%t" %hipify_args "-roc" %clang_args + +#include +#include +#include +// CHECK: #include +#include +// CHECK: #include "rocblas.h" +#include "cublas_v2.h" +#define M 6 +#define N 5 +#define IDX2F(i,j,ld) ((((j)-1)*(ld))+((i)-1)) +// CHECK: static __inline__ void modify(rocblas_handle handle, float *m, int ldm, int +static __inline__ void modify(cublasHandle_t handle, float *m, int ldm, int + n, int p, int q, float alpha, float beta) { + // CHECK: rocblas_sscal(handle, n - p + 1, &alpha, &m[IDX2F(p, q, ldm)], ldm); + // CHECK: rocblas_sscal(handle, ldm - p + 1, &beta, &m[IDX2F(p, q, ldm)], 1); + cublasSscal(handle, n - p + 1, &alpha, &m[IDX2F(p, q, ldm)], ldm); + cublasSscal(handle, ldm - p + 1, &beta, &m[IDX2F(p, q, ldm)], 1); +} +int main(void) { + // CHECK: hipError_t cudaStat; + // CHECK: rocblas_status stat; + // CHECK: rocblas_handle handle; + cudaError_t cudaStat; + cublasStatus_t stat; + cublasHandle_t handle; + int i, j; + float* devPtrA; + float* a = 0; + a = (float *)malloc(M * N * sizeof(*a)); + if (!a) { + printf("host memory allocation failed"); + return EXIT_FAILURE; + } + for (j = 1; j <= N; j++) { + for (i = 1; i <= M; i++) { + a[IDX2F(i, j, M)] = (float)((i - 1) * M + j); + } + } + // CHECK: cudaStat = hipMalloc((void**)&devPtrA, M*N * sizeof(*a)); + cudaStat = cudaMalloc((void**)&devPtrA, M*N * sizeof(*a)); + // CHECK: if (cudaStat != hipSuccess) { + if (cudaStat != cudaSuccess) { + printf("device memory allocation failed"); + return EXIT_FAILURE; + } + // CHECK: stat = rocblas_create_handle(&handle); + stat = cublasCreate(&handle); + // CHECK: if (stat != rocblas_status_success) { + if (stat != CUBLAS_STATUS_SUCCESS) { + printf("CUBLAS initialization failed\n"); + return EXIT_FAILURE; + } + // CHECK: stat = rocblas_set_matrix(M, N, sizeof(*a), a, M, devPtrA, M); + stat = cublasSetMatrix(M, N, sizeof(*a), a, M, devPtrA, M); + // CHECK: if (stat != rocblas_status_success) { + if (stat != CUBLAS_STATUS_SUCCESS) { + printf("data download failed"); + // CHECK: hipFree(devPtrA); + // CHECK: rocblas_destroy_handle(handle); + cudaFree(devPtrA); + cublasDestroy(handle); + return EXIT_FAILURE; + } + modify(handle, devPtrA, M, N, 2, 3, 16.0f, 12.0f); + // CHECK: stat = rocblas_get_matrix(M, N, sizeof(*a), devPtrA, M, a, M); + stat = cublasGetMatrix(M, N, sizeof(*a), devPtrA, M, a, M); + // CHECK: if (stat != rocblas_status_success) { + if (stat != CUBLAS_STATUS_SUCCESS) { + printf("data upload failed"); + // CHECK: hipFree(devPtrA); + // CHECK: rocblas_destroy_handle(handle); + cudaFree(devPtrA); + cublasDestroy(handle); + return EXIT_FAILURE; + } + // CHECK: hipFree(devPtrA); + // CHECK: rocblas_destroy_handle(handle); + cudaFree(devPtrA); + cublasDestroy(handle); + for (j = 1; j <= N; j++) { + for (i = 1; i <= M; i++) { + printf("%7.0f", a[IDX2F(i, j, M)]); + } + printf("\n"); + } + free(a); + return EXIT_SUCCESS; +} diff --git a/projects/hip/tests/hipify-clang/unit_tests/libraries/cuBLAS/rocBLAS/cublas_sgemm_matrix_multiplication_rocblas.cu b/projects/hip/tests/hipify-clang/unit_tests/libraries/cuBLAS/rocBLAS/cublas_sgemm_matrix_multiplication_rocblas.cu new file mode 100644 index 0000000000..8e35f28f0e --- /dev/null +++ b/projects/hip/tests/hipify-clang/unit_tests/libraries/cuBLAS/rocBLAS/cublas_sgemm_matrix_multiplication_rocblas.cu @@ -0,0 +1,108 @@ +// RUN: %run_test hipify "%s" "%t" %hipify_args "-roc" %clang_args + +#include +#include +// CHECK: #include +#include +// CHECK: #include "rocblas.h" +#include "cublas_v2.h" +#define IDX2C(i,j,ld) (((j)*(ld))+(i)) +#define m 6 +#define n 4 +#define k 5 +int main(void) { + // CHECK: hipError_t cudaStat; + // CHECK: rocblas_status stat; + // CHECK: rocblas_handle handle; + cudaError_t cudaStat; + cublasStatus_t stat; + cublasHandle_t handle; + int i, j; + float * a; + float * b; + float * c; + a = (float *)malloc(m*k * sizeof(float)); + b = (float *)malloc(k*n * sizeof(float)); + c = (float *)malloc(m*n * sizeof(float)); + int ind = 11; + for (j = 0; j Date: Thu, 7 Feb 2019 21:51:01 +0000 Subject: [PATCH 16/16] Add hipInfo path for VDI build [ROCm/hip commit: 3ad75e8d14e77cee89cafd9daea40731f2a159fc] --- projects/hip/bin/hipcc | 8 +++++++- 1 file changed, 7 insertions(+), 1 deletion(-) diff --git a/projects/hip/bin/hipcc b/projects/hip/bin/hipcc index d422174ad8..29eb51d5ab 100755 --- a/projects/hip/bin/hipcc +++ b/projects/hip/bin/hipcc @@ -62,10 +62,16 @@ $HIP_CLANG_PATH=$ENV{'HIP_CLANG_PATH'}; $DEVICE_LIB_PATH=$ENV{'DEVICE_LIB_PATH'}; $HIP_CLANG_HCC_COMPAT_MODE=$ENV{'HIP_CLANG_HCC_COMPAT_MODE'}; # HCC compatibility mode +if (defined $HIP_VDI_HOME) { + $HIP_INFO_PATH= "$HIP_VDI_HOME/lib/.hipInfo"; +} else { + $HIP_INFO_PATH= "$HIP_PATH/lib/.hipInfo"; +} + #--- # Read .hipInfo my %hipConfig = (); -parse_config_file("$HIP_PATH/lib/.hipInfo", \%hipConfig); +parse_config_file("$HIP_INFO_PATH", \%hipConfig); #--- # Temporary directories