diff --git a/.jenkins/multicompiler.groovy b/.jenkins/multicompiler.groovy index e91eef35f..ad5d50272 100644 --- a/.jenkins/multicompiler.groovy +++ b/.jenkins/multicompiler.groovy @@ -94,7 +94,7 @@ ci: { } String hostBuildCommand = './install.sh -c --compiler=g++' - String hipClangBuildCommand = './install.sh -c --compiler=/opt/rocm/hip/bin/hipcc' + String hipClangBuildCommand = './install.sh -c --compiler=/opt/rocm/bin/hipcc' String clangBuildCommand = './install.sh -c --compiler=clang++' setupCI(urlJobName, jobNameList, hostBuildCommand, runCI, 'g++') diff --git a/.readthedocs.yaml b/.readthedocs.yaml index 43a0890c9..2c1c2064c 100644 --- a/.readthedocs.yaml +++ b/.readthedocs.yaml @@ -9,6 +9,10 @@ sphinx: formats: [htmlzip] python: - version: "3.8" install: - requirements: docs/.sphinx/requirements.txt + +build: + os: ubuntu-20.04 + tools: + python: "3.8" diff --git a/CHANGELOG.md b/CHANGELOG.md index ec71359f2..65095b4ca 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -1,13 +1,20 @@ # Change Log for hipBLAS -## (Unreleased) hipBLAS 1.1.0 +## (Unreleased) hipBLAS 2.0.0 for ROCm 6.0.0 +### Deprecated +- hipblasDatatype_t is deprecated and will be removed in a future release and replaced with hipDataType +- hipblasComplex and hipblasDoubleComplex are deprecated and will be removed in a future release and replaced with hipComplex and hipDoubleComplex +### Removed +- hipblasXtrmm that calculates B <- alpha * op(A) * B is removed and replaced with hipblasXtrmm that calculates C <- alpha * op(A) * B + +## hipBLAS 1.1.0 for ROCm 5.7.0 ### Changed - updated documentation requirements ### Dependencies - dependency rocSOLVER now depends on rocSPARSE -## (Unreleased) hipBLAS 1.0.0 +## hipBLAS 1.0.0 for ROCm 5.6.0 ### Changed - added const qualifier to hipBLAS functions (swap, sbmv, spmv, symv, trsm) where missing @@ -19,7 +26,7 @@ - in-place trmm is deprecated. It will be replaced by trmm which includes both in-place and out-of-place functionality -## (Unreleased) hipBLAS 0.54.0 +## hipBLAS 0.54.0 for ROCm 5.5.0 ### Added - added option to opt-in to use __half for hipblasHalf type in the API for c++ users who define HIPBLAS_USE_HIP_HALF - added scripts to plot performance for multiple functions diff --git a/CMakeLists.txt b/CMakeLists.txt index c65ad05bc..ab4e9bb4e 100644 --- a/CMakeLists.txt +++ b/CMakeLists.txt @@ -87,7 +87,7 @@ rocm_setup_version( VERSION ${VERSION_STRING} ) list( APPEND CMAKE_MODULE_PATH ${CMAKE_CURRENT_SOURCE_DIR}/cmake ${ROCM_PATH}/lib/cmake/hip /opt/rocm/lib/cmake/hip ${HIP_DIR}/cmake ) # NOTE: workaround until hip cmake modules fixes symlink logic in their config files; remove when fixed -list( APPEND CMAKE_PREFIX_PATH /opt/rocm /opt/rocm/llvm /opt/rocm/hip ) +list( APPEND CMAKE_PREFIX_PATH ${ROCM_PATH}/lib/cmake/hip /opt/rocm /opt/rocm/llvm /opt/rocm/hip ) option( BUILD_VERBOSE "Output additional build information" OFF ) @@ -107,15 +107,16 @@ if (USE_CUDA) endif() # Hip headers required of all clients; clients use hip to allocate device memory -if( USE_CUDA) - find_package( HIP MODULE REQUIRED ) -else( ) - find_package( hip REQUIRED CONFIG PATHS ${HIP_DIR} ${ROCM_PATH} /opt/rocm) -endif( ) - if( USE_CUDA ) - list( APPEND HIP_INCLUDE_DIRS "${HIP_ROOT_DIR}/include" ) -endif( ) + find_package( hip CONFIG PATHS ${HIP_DIR} ${ROCM_PATH} /opt/rocm ) + # support for cuda backend with hip < 6.0 + if( NOT hip_FOUND ) + find_package( HIP MODULE REQUIRED ) + list( APPEND HIP_INCLUDE_DIRS "${HIP_ROOT_DIR}/include" ) + endif() +else() + find_package( hip REQUIRED CONFIG PATHS ${HIP_DIR} ${ROCM_PATH} /opt/rocm) +endif() option(BUILD_CODE_COVERAGE "Build with code coverage enabled" OFF) if(BUILD_CODE_COVERAGE) diff --git a/docs/.sphinx/requirements.txt b/docs/.sphinx/requirements.txt index a9bece5ca..6f10fcce1 100644 --- a/docs/.sphinx/requirements.txt +++ b/docs/.sphinx/requirements.txt @@ -26,7 +26,7 @@ charset-normalizer==3.1.0 # via requests click==8.1.3 # via sphinx-external-toc -cryptography==41.0.3 +cryptography==41.0.4 # via pyjwt deprecated==1.2.13 # via pygithub @@ -92,7 +92,7 @@ requests==2.31.0 # via # pygithub # sphinx -rocm-docs-core==0.24.1 +rocm-docs-core==0.24.2 # via -r requirements.in smmap==5.0.0 # via gitdb diff --git a/docs/deprecation.rst b/docs/deprecation.rst index 144c51bd3..89e400289 100644 --- a/docs/deprecation.rst +++ b/docs/deprecation.rst @@ -2,21 +2,23 @@ Deprecations by version ####################### + Announced in hipBLAS 0.49 ************************* -Replace inplace hipblasXtrmm with out of place hipblasXtrmm -=========================================================== +Inplace hipblasXtrmm will be replaced with out-of-place hipblasXtrmm +==================================================================== The hipblasXtrmm API, along with batched versions, will be changing in hipBLAS 1.0 release to allow in-place and out-of-place behavior. This change will introduce an output matrix 'C', matching the rocblas_xtrmm_outofplace API and the cublasXtrmm API. + Announced in hipBLAS 0.53 ************************* -Remove packed_int8x4 datatype -============================= +packed_int8x4 datatype will be removed +====================================== The packed_int8x4 datatype will be removed in hipBLAS 1.0. There are two int8 datatypes: @@ -27,17 +29,18 @@ int8_t is the C99 unsigned 8 bit integer. packed_int8x4 has 4 consecutive int8_t in the k dimension packed into 32 bits. packed_int8x4 is only used in hipblasGemmEx. int8_t will continue to be available in hipblasGemmEx. + Announced in hipBLAS 1.0 -^^^^^^^^^^^^^^^^^^^^^^^^ +************************ -Replace Legacy BLAS in-place trmm functions with trmm functions that support both in-place and out-of-place functionality -========================================================================================================================= +Legacy BLAS in-place trmm functions will be replaced with trmm functions that support both in-place and out-of-place functionality +================================================================================================================================== Use of the deprecated Legacy BLAS in-place trmm functions will give deprecation warnings telling you to compile with -DHIPBLAS_V1 and use the new in-place and out-of-place trmm functions. Note that there are no deprecation warnings for the hipBLAS Fortran API. -The Legacy BLAS in-place trmm calculates B <- alpha * op(A) * B. Matrix B is replaced in-place by +The Legacy BLAS in-place trmm calculates B <- alpha * op(A) * B. Matrix B is overwritten by triangular matrix A multiplied by matrix B. The prototype in the include file rocblas-functions.h is: :: @@ -55,7 +58,7 @@ triangular matrix A multiplied by matrix B. The prototype in the include file ro float* BP, int ldb); -hipBLAS 1.0 deprecates the legacy BLAS trmm functionality and replaces it with C <- alpha * op(A) * B. The prototype is: +The above is replaced by an in-place and out-of-place trmm that calculates C <- alpha * op(A) * B. The prototype is: :: @@ -80,23 +83,23 @@ ldc equal to ldb. There are similar deprecations for the _batched and _strided_batched versions of trmm. Removed in hipBLAS 1.0 -^^^^^^^^^^^^^^^^^^^^^^ +********************** HIPBLAS_INT8_DATATYPE_PACK_INT8x4 hipblasGemmEx support removed -''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''' +=============================================================== -Packed int8x4 was removed as support for arbitrary dimensioned int8_t data is a superset of this functionality: +Packed int8x4 is removed as support for arbitrary dimensioned int8_t data is a superset of this functionality: -* enum hipblasInt8Datatype_t was removed -* function hipblasSetInt8Datatype was removed -* function hipblasGetInt8Datatype was removed +* enum hipblasInt8Datatype_t is removed +* function hipblasSetInt8Datatype is removed +* function hipblasGetInt8Datatype is removed Announced in hipBLAS 2.0 -^^^^^^^^^^^^^^^^^^^^^^^^ +************************ -Remove hipblasDatatype_t and replace with hipDataType +hipblasDatatype_t will be replaced with hipDataType ===================================================== -Use of the deprecated hipblasDatatype_t will give deprecation warnings telling you to compile with -DHIPBLAS_V2 +Use of hipblasDatatype_t will give deprecation warnings telling you to compile with -DHIPBLAS_V2 and to use hipDataType instead. All functions which currently use hipblasDatatype_t are therefore deprecated as well, and will be replaced with functions which use hipDataType in the place of hipblasDatatype_t. These functions include: hipblasTrsmEx, hipblasGemmEx, hipblasGemmExWithFlags, hipblasAxpyEx, hipblasDot(c)Ex, hipblasNrm2Ex, hipblasRotEx, hipblasScalEx, @@ -106,7 +109,7 @@ Note that there are no deprecation warnings for the hipBLAS Fortran API. hipblasDatatype_t will be removed in a future release, and the use of this type in the API will be replaced with hipDataType. -Remove hipblasComplex and hipblasDoubleComplex, replaced by hipComplex and hipDoubleComplex +hipblasComplex and hipblasDoubleComplex will be replaced by hipComplex and hipDoubleComplex =========================================================================================== Use of these datatypes will give deprecation warnings telling you to compile with -DHIPBLAS_V2 and to use HIP complex types instead. All functions which currently use hipblasComplex and hipblasDoubleComplex are therefore deprecated as well, @@ -120,10 +123,10 @@ hipComplex and hipDoubleComplex. ROCM_MATHLIBS_API_USE_HIP_COMPLEX is also deprecated as the behavior provided by defining it will be the default in the future. Removed in hipBLAS 2.0 -^^^^^^^^^^^^^^^^^^^^^^ +********************** -Legacy BLAS in-place trmm -''''''''''''''''''''''''' +Legacy BLAS in-place trmm is removed +==================================== The legacay BLAS in-place hipblasXtrmm that calculates B <- alpha * op(A) * B is removed and replaced with the out-of-place hipblasXtrmm that calculates C <- alpha * op(A) * B. diff --git a/library/CMakeLists.txt b/library/CMakeLists.txt index 4875b4f18..982fb3dba 100644 --- a/library/CMakeLists.txt +++ b/library/CMakeLists.txt @@ -20,7 +20,7 @@ # ######################################################################## # This is incremented when the ABI to the library changes -set( hipblas_SOVERSION 2.0.0 ) +set( hipblas_SOVERSION 2.0 ) list( APPEND CMAKE_MODULE_PATH ${PROJECT_SOURCE_DIR}/cmake ) diff --git a/library/src/CMakeLists.txt b/library/src/CMakeLists.txt index 94e5b6659..c83738e9e 100755 --- a/library/src/CMakeLists.txt +++ b/library/src/CMakeLists.txt @@ -1,5 +1,5 @@ # ######################################################################## -# Copyright (C) 2016-2022 Advanced Micro Devices, Inc. All rights reserved. +# Copyright (C) 2016-2023 Advanced Micro Devices, Inc. All rights reserved. # # Permission is hereby granted, free of charge, to any person obtaining a copy # of this software and associated documentation files (the "Software"), to deal @@ -64,18 +64,13 @@ add_library( hipblas ) add_library( roc::hipblas ALIAS hipblas ) -# External header includes included as system files -target_include_directories( hipblas - SYSTEM PRIVATE - $ -) - # Build hipblas from source on AMD platform if( NOT USE_CUDA ) if( NOT TARGET rocblas ) if( CUSTOM_ROCBLAS ) set ( ENV{rocblas_DIR} ${CUSTOM_ROCBLAS}) find_package( rocblas REQUIRED CONFIG NO_CMAKE_PATH ) + elseif( WIN32 ) find_package( rocblas REQUIRED CONFIG PATHS ${ROCBLAS_PATH}) else() @@ -91,6 +86,12 @@ if( NOT USE_CUDA ) if( CUSTOM_ROCSOLVER) set ( ENV{rocsolver_DIR} ${CUSTOM_ROCSOLVER}) find_package( rocsolver REQUIRED CONFIG NO_CMAKE_PATH ) + + # in case of using custom rocsolver and not custom rocblas, we need to have + # custom rocsolver include directories before rocblas/hip include directories + # in case there is a rocsolver installed on the system. + target_include_directories( hipblas + SYSTEM PRIVATE $ ) elseif(WIN32) find_package( rocsolver REQUIRED CONFIG PATHS ${ROCSOLVER_PATH} ) else() @@ -116,6 +117,14 @@ else( ) ) endif( ) +# External header includes included as system files +target_include_directories( hipblas + SYSTEM PRIVATE + $ + $ + $ +) + # Internal header includes target_include_directories( hipblas PUBLIC $