diff --git a/docs/.doxygen/mainpage.md b/docs/.doxygen/mainpage.md index 44e41c67d0..65f03dc619 100644 --- a/docs/.doxygen/mainpage.md +++ b/docs/.doxygen/mainpage.md @@ -24,7 +24,6 @@ This is the full HIP Runtime API reference. The API is organized into - @ref Clang - @ref Texture - @ref TextureD - - @ref TextureU - @ref Runtime - @ref Callback - @ref Graph diff --git a/docs/doxygen-input/doxy.cfg b/docs/doxygen-input/doxy.cfg index 16c2c900b6..f4e08a678f 100644 --- a/docs/doxygen-input/doxy.cfg +++ b/docs/doxygen-input/doxy.cfg @@ -1,4 +1,4 @@ -# Doxyfile 1.8.17 +# Doxyfile 1.8.20 # This file describes the settings to be used by the documentation system # doxygen (www.doxygen.org) for a project. @@ -186,7 +186,7 @@ STRIP_FROM_INC_PATH = # support long names like on DOS, Mac, or CD-ROM. # The default value is: NO. -SHORT_NAMES = NO +SHORT_NAMES = YES # If the JAVADOC_AUTOBRIEF tag is set to YES then doxygen will interpret the # first line (until the first dot) of a Javadoc-style comment as the brief @@ -227,6 +227,14 @@ QT_AUTOBRIEF = NO MULTILINE_CPP_IS_BRIEF = NO +# By default Python docstrings are displayed as preformatted text and doxygen's +# special commands cannot be used. By setting PYTHON_DOCSTRING to NO the +# doxygen's special commands can be used and the contents of the docstring +# documentation blocks is shown as doxygen documentation. +# The default value is: YES. + +PYTHON_DOCSTRING = YES + # If the INHERIT_DOCS tag is set to YES then an undocumented member inherits the # documentation from any documented member that it re-implements. # The default value is: YES. @@ -263,12 +271,6 @@ TAB_SIZE = 4 ALIASES = -# This tag can be used to specify a number of word-keyword mappings (TCL only). -# A mapping has the form "name=value". For example adding "class=itcl::class" -# will allow you to use the command class in the itcl::class meaning. - -TCL_SUBST = - # Set the OPTIMIZE_OUTPUT_FOR_C tag to YES if your project consists of C sources # only. Doxygen will then generate output that is more tailored for C. For # instance, some of the names that are used will be different. The list of all @@ -310,13 +312,13 @@ OPTIMIZE_OUTPUT_SLICE = NO # extension. Doxygen has a built-in mapping, but you can override or extend it # using this tag. The format is ext=language, where ext is a file extension, and # language is one of the parsers supported by doxygen: IDL, Java, JavaScript, -# Csharp (C#), C, C++, D, PHP, md (Markdown), Objective-C, Python, Slice, +# Csharp (C#), C, C++, D, PHP, md (Markdown), Objective-C, Python, Slice, VHDL, # Fortran (fixed format Fortran: FortranFixed, free formatted Fortran: # FortranFree, unknown formatted Fortran: Fortran. In the later case the parser # tries to guess whether the code is fixed or free formatted code, this is the -# default for Fortran type files), VHDL, tcl. For instance to make doxygen treat -# .inc files as Fortran files (default is PHP), and .f files as C (default is -# Fortran), use: inc=Fortran f=C. +# default for Fortran type files). For instance to make doxygen treat .inc files +# as Fortran files (default is PHP), and .f files as C (default is Fortran), +# use: inc=Fortran f=C. # # Note: For files without extension you can use no_extension as a placeholder. # @@ -455,6 +457,19 @@ TYPEDEF_HIDES_STRUCT = NO LOOKUP_CACHE_SIZE = 0 +# The NUM_PROC_THREADS specifies the number threads doxygen is allowed to use +# during processing. When set to 0 doxygen will based this on the number of +# cores available in the system. You can set it explicitly to a value larger +# than 0 to get more control over the balance between CPU load and processing +# speed. At this moment only the input processing can be done using multiple +# threads. Since this is still an experimental feature the default is set to 1, +# which efficively disables parallel processing. Please report any issues you +# encounter. Generating dot graphs in parallel is controlled by the +# DOT_NUM_THREADS setting. +# Minimum value: 0, maximum value: 32, default value: 1. + +NUM_PROC_THREADS = 1 + #--------------------------------------------------------------------------- # Build related configuration options #--------------------------------------------------------------------------- @@ -559,7 +574,7 @@ INTERNAL_DOCS = YES # names in lower-case letters. If set to YES, upper-case letters are also # allowed. This is useful if you have classes or files whose names only differ # in case and if your file system supports case sensitive file names. Windows -# (including Cygwin) ands Mac users are advised to set this option to NO. +# (including Cygwin) and Mac users are advised to set this option to NO. # The default value is: system dependent. CASE_SENSE_NAMES = YES @@ -829,15 +844,14 @@ WARN_LOGFILE = # spaces. See also FILE_PATTERNS and EXTENSION_MAPPING # Note: If this tag is empty the current directory is searched. -INPUT = $(HIP_PATH)/docs/doxygen-input/mainpage.txt \ - $(HIP_PATH)/README.md \ - $(HIP_PATH)/CONTRIBUTING.md \ - $(HIP_PATH)/docs/doxygen-input/sync.txt \ - $(HIP_PATH)/INSTALL.md \ - $(HIP_PATH)/docs/markdown \ - $(HIP_PATH)/include/hip \ - $(HIP_PATH)/include/hip/amd_detail/ \ - $(HIP_PATH)/src/ +INPUT = mainpage.txt \ + ../../README.md \ + ../../CONTRIBUTING.md \ + sync.txt \ + ../../INSTALL.md \ + ../../docs/markdown \ + ../../include/hip \ + ../../../hipamd/include/hip/amd_detail/ # This tag can be used to specify the character encoding of the source files # that doxygen parses. Internally doxygen uses the UTF-8 encoding. Doxygen uses @@ -861,7 +875,7 @@ INPUT_ENCODING = UTF-8 # *.hh, *.hxx, *.hpp, *.h++, *.cs, *.d, *.php, *.php4, *.php5, *.phtml, *.inc, # *.m, *.markdown, *.md, *.mm, *.dox (to be provided as doxygen C comment), # *.doc (to be provided as doxygen C comment), *.txt (to be provided as doxygen -# C comment), *.py, *.pyw, *.f90, *.f95, *.f03, *.f08, *.f, *.for, *.tcl, *.vhd, +# C comment), *.py, *.pyw, *.f90, *.f95, *.f03, *.f08, *.f18, *.f, *.for, *.vhd, # *.vhdl, *.ucf, *.qsf and *.ice. FILE_PATTERNS = *.c \ @@ -873,7 +887,7 @@ FILE_PATTERNS = *.c \ *.md \ *.dox \ *.doc \ - *.txt \ + *.txt # The RECURSIVE tag can be used to specify whether or not subdirectories should # be searched for input files as well. @@ -941,7 +955,7 @@ EXAMPLE_RECURSIVE = NO # that contain images that are to be included in the documentation (see the # \image command). -IMAGE_PATH = $(HIP_PATH)/docs/doxygen-input/images +IMAGE_PATH = images # The INPUT_FILTER tag can be used to specify a program that doxygen should # invoke to filter for each input file. Doxygen will invoke the filter program @@ -1105,10 +1119,13 @@ CLANG_ASSISTED_PARSING = NO CLANG_OPTIONS = # If clang assisted parsing is enabled you can provide the clang parser with the -# path to the compilation database (see: -# http://clang.llvm.org/docs/HowToSetupToolingForLLVM.html) used when the files -# were built. This is equivalent to specifying the "-p" option to a clang tool, -# such as clang-check. These options will then be passed to the parser. +# path to the directory containing a file called compile_commands.json. This +# file is the compilation database (see: +# http://clang.llvm.org/docs/HowToSetupToolingForLLVM.html) containing the +# options used when the source files were built. This is equivalent to +# specifying the "-p" option to a clang tool, such as clang-check. These options +# will then be passed to the parser. Any options specified with CLANG_OPTIONS +# will be added as well. # Note: The availability of this option depends on whether or not doxygen was # generated with the -Duse_libclang=ON option for CMake. @@ -1378,7 +1395,7 @@ CHM_FILE = HHC_LOCATION = # The GENERATE_CHI flag controls if a separate .chi index file is generated -# (YES) or that it should be included in the master .chm file (NO). +# (YES) or that it should be included in the main .chm file (NO). # The default value is: NO. # This tag requires that the tag GENERATE_HTMLHELP is set to YES. @@ -1540,6 +1557,17 @@ TREEVIEW_WIDTH = 250 EXT_LINKS_IN_WINDOW = NO +# If the HTML_FORMULA_FORMAT option is set to svg, doxygen will use the pdf2svg +# tool (see https://github.com/dawbarton/pdf2svg) or inkscape (see +# https://inkscape.org) to generate formulas as SVG images instead of PNGs for +# the HTML output. These images will generally look nicer at scaled resolutions. +# Possible values are: png (the default) and svg (looks nicer but requires the +# pdf2svg or inkscape tool). +# The default value is: png. +# This tag requires that the tag GENERATE_HTML is set to YES. + +HTML_FORMULA_FORMAT = png + # Use this tag to change the font size of LaTeX formulas included as images in # the HTML documentation. When you change the font size after a successful # doxygen run you need to manually remove any form_*.png images from the HTML @@ -1595,7 +1623,7 @@ MATHJAX_FORMAT = HTML-CSS # Content Delivery Network so you can quickly see the result without installing # MathJax. However, it is strongly recommended to install a local copy of # MathJax from https://www.mathjax.org before deployment. -# The default value is: https://cdnjs.cloudflare.com/ajax/libs/mathjax/2.7.5/. +# The default value is: https://cdn.jsdelivr.net/npm/mathjax@2. # This tag requires that the tag USE_MATHJAX is set to YES. MATHJAX_RELPATH = https://cdnjs.cloudflare.com/ajax/libs/mathjax/2.7.5/ @@ -1834,9 +1862,11 @@ LATEX_EXTRA_FILES = PDF_HYPERLINKS = YES -# If the USE_PDFLATEX tag is set to YES, doxygen will use pdflatex to generate -# the PDF file directly from the LaTeX files. Set this option to YES, to get a -# higher quality PDF documentation. +# If the USE_PDFLATEX tag is set to YES, doxygen will use the engine as +# specified with LATEX_CMD_NAME to generate the PDF file directly from the LaTeX +# files. Set this option to YES, to get a higher quality PDF documentation. +# +# See also section LATEX_CMD_NAME for selecting the engine. # The default value is: YES. # This tag requires that the tag GENERATE_LATEX is set to YES. @@ -2075,6 +2105,10 @@ DOCBOOK_PROGRAMLISTING = NO GENERATE_AUTOGEN_DEF = NO +#--------------------------------------------------------------------------- +# Configuration options related to Sqlite3 output +#--------------------------------------------------------------------------- + #--------------------------------------------------------------------------- # Configuration options related to the Perl module output #--------------------------------------------------------------------------- @@ -2170,7 +2204,8 @@ INCLUDE_FILE_PATTERNS = # recursively expanded use the := operator instead of the = operator. # This tag requires that the tag ENABLE_PREPROCESSING is set to YES. -PREDEFINED = __HIP_PLATFORM_AMD__ +PREDEFINED = __HIP_PLATFORM_AMD__ \ + __HIP__ # If the MACRO_EXPANSION and EXPAND_ONLY_PREDEF tags are set to YES then this # tag can be used to specify a list of macro names that should be expanded. The @@ -2268,9 +2303,9 @@ HIDE_UNDOC_RELATIONS = YES # http://www.graphviz.org/), a graph visualization toolkit from AT&T and Lucent # Bell Labs. The other options in this section have no effect if this option is # set to NO -# The default value is: YES. +# The default value is: NO. -HAVE_DOT = YES +HAVE_DOT = NO # The DOT_NUM_THREADS specifies the number of dot invocations doxygen is allowed # to run in parallel. When set to 0 doxygen will base this on the number of @@ -2424,9 +2459,7 @@ DIRECTORY_GRAPH = YES # Note: If you choose svg you need to set HTML_FILE_EXTENSION to xhtml in order # to make the SVG files visible in IE 9+ (other browsers do not have this # requirement). -# Possible values are: png, png:cairo, png:cairo:cairo, png:cairo:gd, png:gd, -# png:gd:gd, jpg, jpg:cairo, jpg:cairo:gd, jpg:gd, jpg:gd:gd, gif, gif:cairo, -# gif:cairo:gd, gif:gd, gif:gd:gd, svg, png:gd, png:gd:gd, png:cairo, +# Possible values are: png, jpg, gif, svg, png:gd, png:gd:gd, png:cairo, # png:cairo:gd, png:cairo:cairo, png:cairo:gdiplus, png:gdiplus and # png:gdiplus:gdiplus. # The default value is: png. diff --git a/include/hip/device_functions.h b/include/hip/device_functions.h index 9e1d091364..8388a5c24b 100644 --- a/include/hip/device_functions.h +++ b/include/hip/device_functions.h @@ -1,5 +1,5 @@ /* -Copyright (c) 2015 - 2021 Advanced Micro Devices, Inc. All rights reserved. +Copyright (c) 2015 - 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 @@ -23,7 +23,9 @@ THE SOFTWARE. #ifndef HIP_INCLUDE_HIP_DEVICE_FUNCTIONS_H #define HIP_INCLUDE_HIP_DEVICE_FUNCTIONS_H +#if !defined(__HIPCC_RTC__) #include +#endif #if (defined(__HIP_PLATFORM_HCC__) || defined(__HIP_PLATFORM_AMD__)) && !(defined(__HIP_PLATFORM_NVCC__) || defined(__HIP_PLATFORM_NVIDIA__)) #include diff --git a/include/hip/driver_types.h b/include/hip/driver_types.h index 695d047fc9..0675dde25f 100644 --- a/include/hip/driver_types.h +++ b/include/hip/driver_types.h @@ -1,5 +1,5 @@ /* -Copyright (c) 2015 - 2021 Advanced Micro Devices, Inc. All rights reserved. +Copyright (c) 2015 - 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 @@ -23,7 +23,9 @@ THE SOFTWARE. #ifndef HIP_INCLUDE_HIP_DRIVER_TYPES_H #define HIP_INCLUDE_HIP_DRIVER_TYPES_H +#if !defined(__HIPCC_RTC__) #include +#endif #if !(defined(__HIP_PLATFORM_HCC__) || defined(__HIP_PLATFORM_AMD__)) && (defined(__HIP_PLATFORM_NVCC__) || defined(__HIP_PLATFORM_NVIDIA__)) #include "driver_types.h" diff --git a/include/hip/hip_common.h b/include/hip/hip_common.h index 539952b998..f0a8f2ccac 100644 --- a/include/hip/hip_common.h +++ b/include/hip/hip_common.h @@ -1,5 +1,5 @@ /* -Copyright (c) 2015 - 2021 Advanced Micro Devices, Inc. All rights reserved. +Copyright (c) 2015 - 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 @@ -23,6 +23,10 @@ THE SOFTWARE. #ifndef HIP_INCLUDE_HIP_HIP_COMMON_H #define HIP_INCLUDE_HIP_HIP_COMMON_H +#if defined(__clang__) +#pragma clang diagnostic push +#pragma clang diagnostic ignored "-Wreserved-macro-identifier" +#endif // Common code included at start of every hip file. // Auto enable __HIP_PLATFORM_AMD__ if compiling on AMD platform // Other compiler (GCC,ICC,etc) need to set one of these macros explicitly @@ -99,4 +103,8 @@ THE SOFTWARE. #define __HIP_ARCH_HAS_DYNAMIC_PARALLEL__ (0) #endif +#if defined(__clang__) +#pragma clang diagnostic pop +#endif + #endif diff --git a/include/hip/hip_complex.h b/include/hip/hip_complex.h index 51873fbe6b..0e70f245d5 100644 --- a/include/hip/hip_complex.h +++ b/include/hip/hip_complex.h @@ -1,5 +1,5 @@ /* -Copyright (c) 2015 - 2021 Advanced Micro Devices, Inc. All rights reserved. +Copyright (c) 2015 - 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 @@ -23,7 +23,9 @@ THE SOFTWARE. #ifndef HIP_INCLUDE_HIP_HIP_COMPLEX_H #define HIP_INCLUDE_HIP_HIP_COMPLEX_H +#if !defined(__HIPCC_RTC__) #include +#endif #if (defined(__HIP_PLATFORM_HCC__) || defined(__HIP_PLATFORM_AMD__)) && !(defined(__HIP_PLATFORM_NVCC__) || defined(__HIP_PLATFORM_NVIDIA__)) #include diff --git a/include/hip/hip_runtime_api.h b/include/hip/hip_runtime_api.h index db5a403ba1..8295a68cc6 100644 --- a/include/hip/hip_runtime_api.h +++ b/include/hip/hip_runtime_api.h @@ -1273,6 +1273,30 @@ typedef struct hipMemAllocationProp { } allocFlags; } hipMemAllocationProp; +/** + * External semaphore signal node parameters + */ +typedef struct hipExternalSemaphoreSignalNodeParams { + ///< Array containing external semaphore handles. + hipExternalSemaphore_t* extSemArray; + ///< Array containing parameters of external signal semaphore. + const hipExternalSemaphoreSignalParams* paramsArray; + ///< Total number of handles and parameters contained in extSemArray and paramsArray. + unsigned int numExtSems; +} hipExternalSemaphoreSignalNodeParams; + +/** + * External semaphore wait node parameters + */ +typedef struct hipExternalSemaphoreWaitNodeParams { + ///< Array containing external semaphore handles. + hipExternalSemaphore_t* extSemArray; + ///< Array containing parameters of external wait semaphore. + const hipExternalSemaphoreWaitParams* paramsArray; + ///< Total number of handles and parameters contained in extSemArray and paramsArray. + unsigned int numExtSems; +} hipExternalSemaphoreWaitNodeParams; + /** * Generic handle for memory allocation */ @@ -4086,14 +4110,6 @@ hipError_t hipMalloc3D(hipPitchedPtr* pitchedDevPtr, hipExtent extent); * @see hipMalloc, hipMallocPitch, hipFree, hipMallocArray, hipHostMalloc, hipHostFree */ hipError_t hipFreeArray(hipArray* array); -/** - * @brief Frees a mipmapped array on the device - * - * @param[in] mipmappedArray - Pointer to mipmapped array to free - * - * @return #hipSuccess, #hipErrorInvalidValue - */ -hipError_t hipFreeMipmappedArray(hipMipmappedArray_t mipmappedArray); /** * @brief Allocate an array on the device. * @@ -4107,36 +4123,6 @@ hipError_t hipFreeMipmappedArray(hipMipmappedArray_t mipmappedArray); */ hipError_t hipMalloc3DArray(hipArray** array, const struct hipChannelFormatDesc* desc, struct hipExtent extent, unsigned int flags); -/** - * @brief Allocate a mipmapped array on the device - * - * @param[out] mipmappedArray - Pointer to allocated mipmapped array in device memory - * @param[in] desc - Requested channel format - * @param[in] extent - Requested allocation size (width field in elements) - * @param[in] numLevels - Number of mipmap levels to allocate - * @param[in] flags - Flags for extensions - * - * @return #hipSuccess, #hipErrorInvalidValue, #hipErrorMemoryAllocation - */ -hipError_t hipMallocMipmappedArray( - hipMipmappedArray_t *mipmappedArray, - const struct hipChannelFormatDesc* desc, - struct hipExtent extent, - unsigned int numLevels, - unsigned int flags __dparm(0)); -/** - * @brief Gets a mipmap level of a HIP mipmapped array - * - * @param[out] levelArray - Returned mipmap level HIP array - * @param[in] mipmappedArray - HIP mipmapped array - * @param[in] level - Mipmap level - * - * @return #hipSuccess, #hipErrorInvalidValue - */ -hipError_t hipGetMipmappedArrayLevel( - hipArray_t *levelArray, - hipMipmappedArray_const_t mipmappedArray, - unsigned int level); /** * @brief Gets info about the specified array * @@ -5416,22 +5402,6 @@ hipError_t hipExtLaunchKernel(const void* function_address, dim3 numBlocks, dim3 * This section describes the texture management functions of HIP runtime API. */ -/** - * @brief Binds a mipmapped array to a texture. - * - * @param [in] tex pointer to the texture reference to bind - * @param [in] mipmappedArray memory mipmapped array on the device - * @param [in] desc opointer to the channel format - * - * @returns #hipSuccess, #hipErrorInvalidValue - * - */ -DEPRECATED(DEPRECATED_MSG) -hipError_t hipBindTextureToMipmappedArray( - const textureReference* tex, - hipMipmappedArray_const_t mipmappedArray, - const hipChannelFormatDesc* desc); - /** * @brief Creates a texture object. * @@ -5581,6 +5551,101 @@ hipError_t hipTexObjectGetTextureDesc( HIP_TEXTURE_DESC* pTexDesc, hipTextureObject_t texObject); +/** + * @brief Allocate a mipmapped array on the device. + * + * @param[out] mipmappedArray - Pointer to allocated mipmapped array in device memory + * @param[in] desc - Requested channel format + * @param[in] extent - Requested allocation size (width field in elements) + * @param[in] numLevels - Number of mipmap levels to allocate + * @param[in] flags - Flags for extensions + * + * @return #hipSuccess, #hipErrorInvalidValue, #hipErrorMemoryAllocation + * + * @note This API is implemented on Windows, under development on Linux. + * + */ +hipError_t hipMallocMipmappedArray( + hipMipmappedArray_t *mipmappedArray, + const struct hipChannelFormatDesc* desc, + struct hipExtent extent, + unsigned int numLevels, + unsigned int flags __dparm(0)); + +/** + * @brief Frees a mipmapped array on the device. + * + * @param[in] mipmappedArray - Pointer to mipmapped array to free + * + * @return #hipSuccess, #hipErrorInvalidValue + * + * @note This API is implemented on Windows, under development on Linux. + * + */ +hipError_t hipFreeMipmappedArray(hipMipmappedArray_t mipmappedArray); + +/** + * @brief Gets a mipmap level of a HIP mipmapped array. + * + * @param[out] levelArray - Returned mipmap level HIP array + * @param[in] mipmappedArray - HIP mipmapped array + * @param[in] level - Mipmap level + * + * @return #hipSuccess, #hipErrorInvalidValue + * + * @note This API is implemented on Windows, under development on Linux. + * + */ +hipError_t hipGetMipmappedArrayLevel( + hipArray_t *levelArray, + hipMipmappedArray_const_t mipmappedArray, + unsigned int level); + +/** + * @brief Create a mipmapped array. + * + * @param [out] pHandle pointer to mipmapped array + * @param [in] pMipmappedArrayDesc mipmapped array descriptor + * @param [in] numMipmapLevels mipmap level + * + * @returns #hipSuccess, #hipErrorNotSupported, #hipErrorInvalidValue + * + * @note This API is implemented on Windows, under development on Linux. + */ +hipError_t hipMipmappedArrayCreate( + hipMipmappedArray_t* pHandle, + HIP_ARRAY3D_DESCRIPTOR* pMipmappedArrayDesc, + unsigned int numMipmapLevels); + +/** + * @brief Destroy a mipmapped array. + * + * @param [out] hMipmappedArray pointer to mipmapped array to destroy + * + * @returns #hipSuccess, #hipErrorInvalidValue + * + * @note This API is implemented on Windows, under development on Linux. + * + */ +hipError_t hipMipmappedArrayDestroy(hipMipmappedArray_t hMipmappedArray); + +/** + * @brief Get a mipmapped array on a mipmapped level. + * + * @param [in] pLevelArray Pointer of array + * @param [out] hMipMappedArray Pointer of mipmapped array on the requested mipmap level + * @param [out] level Mipmap level + * + * @returns #hipSuccess, #hipErrorInvalidValue + * + * @note This API is implemented on Windows, under development on Linux. + * + */ +hipError_t hipMipmappedArrayGetLevel( + hipArray_t* pLevelArray, + hipMipmappedArray_t hMipMappedArray, + unsigned int level); + /** * * @addtogroup TextureD Texture Management [Deprecated] @@ -5588,6 +5653,23 @@ hipError_t hipTexObjectGetTextureDesc( * @ingroup Texture * This section describes the deprecated texture management functions of HIP runtime API. */ + +/** + * @brief Binds a mipmapped array to a texture. + * + * @param [in] tex pointer to the texture reference to bind + * @param [in] mipmappedArray memory mipmapped array on the device + * @param [in] desc opointer to the channel format + * + * @returns #hipSuccess, #hipErrorInvalidValue + * + */ +DEPRECATED(DEPRECATED_MSG) +hipError_t hipBindTextureToMipmappedArray( + const textureReference* tex, + hipMipmappedArray_const_t mipmappedArray, + const hipChannelFormatDesc* desc); + /** * @brief Gets the texture reference related with the symbol. * @@ -5857,7 +5939,6 @@ DEPRECATED(DEPRECATED_MSG) hipError_t hipTexRefGetMipmapFilterMode( enum hipTextureFilterMode* pfm, const textureReference* texRef); -DEPRECATED(DEPRECATED_MSG) /** * @brief Gets the mipmap level bias for a texture reference. * @@ -5867,6 +5948,7 @@ DEPRECATED(DEPRECATED_MSG) * @warning This API is deprecated. * */ +DEPRECATED(DEPRECATED_MSG) hipError_t hipTexRefGetMipmapLevelBias( float* pbias, const textureReference* texRef); @@ -6015,53 +6097,6 @@ hipError_t hipTexRefSetMipmappedArray( struct hipMipmappedArray* mipmappedArray, unsigned int Flags); -/** - * - * @addtogroup TextureU Texture Management [Not supported] - * @{ - * @ingroup Texture - * This section describes the texture management functions currently unsupported in HIP runtime. - */ -/** - * @brief Create a mipmapped array. - * - * @param [out] pHandle pointer to mipmapped array - * @param [in] pMipmappedArrayDesc mipmapped array descriptor - * @param [in] numMipmapLevels mipmap level - * - * @returns #hipSuccess, #hipErrorNotSupported, #hipErrorInvalidValue - * - */ -DEPRECATED(DEPRECATED_MSG) -hipError_t hipMipmappedArrayCreate( - hipMipmappedArray_t* pHandle, - HIP_ARRAY3D_DESCRIPTOR* pMipmappedArrayDesc, - unsigned int numMipmapLevels); -/** - * @brief Destroy a mipmapped array. - * - * @param [out] hMipmappedArray pointer to mipmapped array to destroy - * - * @returns #hipSuccess, #hipErrorInvalidValue - * - */ -DEPRECATED(DEPRECATED_MSG) -hipError_t hipMipmappedArrayDestroy(hipMipmappedArray_t hMipmappedArray); -/** - * @brief Get a mipmapped array on a mipmapped level. - * - * @param [in] pLevelArray Pointer of array - * @param [out] hMipMappedArray Pointer of mipmapped array on the requested mipmap level - * @param [out] level Mipmap level - * - * @returns #hipSuccess, #hipErrorInvalidValue - * - */ -DEPRECATED(DEPRECATED_MSG) -hipError_t hipMipmappedArrayGetLevel( - hipArray_t* pLevelArray, - hipMipmappedArray_t hMipMappedArray, - unsigned int level); // doxygen end deprecated texture management /** * @} @@ -7322,6 +7357,105 @@ hipError_t hipGraphNodeSetEnabled(hipGraphExec_t hGraphExec, hipGraphNode_t hNod hipError_t hipGraphNodeGetEnabled(hipGraphExec_t hGraphExec, hipGraphNode_t hNode, unsigned int* isEnabled); +/** + * @brief Creates a external semaphor wait node and adds it to a graph. + * + * @param [out] pGraphNode - pointer to the graph node to create. + * @param [in] graph - instance of the graph to add the created node. + * @param [in] pDependencies - const pointer to the dependencies on the memset execution node. + * @param [in] numDependencies - the number of the dependencies. + * @param [in] nodeParams -pointer to the parameters. + * @returns #hipSuccess, #hipErrorInvalidValue + * @warning : This API is marked as beta, meaning, while this is feature complete, + * it is still open to changes and may have outstanding issues. + */ +hipError_t hipGraphAddExternalSemaphoresWaitNode(hipGraphNode_t* pGraphNode, hipGraph_t graph, + const hipGraphNode_t* pDependencies, size_t numDependencies, + const hipExternalSemaphoreWaitNodeParams* nodeParams); + +/** + * @brief Creates a external semaphor signal node and adds it to a graph. + * + * @param [out] pGraphNode - pointer to the graph node to create. + * @param [in] graph - instance of the graph to add the created node. + * @param [in] pDependencies - const pointer to the dependencies on the memset execution node. + * @param [in] numDependencies - the number of the dependencies. + * @param [in] nodeParams -pointer to the parameters. + * @returns #hipSuccess, #hipErrorInvalidValue + * @warning : This API is marked as beta, meaning, while this is feature complete, + * it is still open to changes and may have outstanding issues. + */ +hipError_t hipGraphAddExternalSemaphoresSignalNode(hipGraphNode_t* pGraphNode, hipGraph_t graph, + const hipGraphNode_t* pDependencies, size_t numDependencies, + const hipExternalSemaphoreSignalNodeParams* nodeParams); +/** + * @brief Updates node parameters in the external semaphore signal node. + * + * @param [in] hNode - Node from the graph from which graphExec was instantiated. + * @param [in] nodeParams - Pointer to the params to be set. + * @returns #hipSuccess, #hipErrorInvalidValue + * @warning : This API is marked as beta, meaning, while this is feature complete, + * it is still open to changes and may have outstanding issues. + */ +hipError_t hipGraphExternalSemaphoresSignalNodeSetParams(hipGraphNode_t hNode, + const hipExternalSemaphoreSignalNodeParams* nodeParams); +/** + * @brief Updates node parameters in the external semaphore wait node. + * + * @param [in] hNode - Node from the graph from which graphExec was instantiated. + * @param [in] nodeParams - Pointer to the params to be set. + * @returns #hipSuccess, #hipErrorInvalidValue + * @warning : This API is marked as beta, meaning, while this is feature complete, + * it is still open to changes and may have outstanding issues. + */ +hipError_t hipGraphExternalSemaphoresWaitNodeSetParams(hipGraphNode_t hNode, + const hipExternalSemaphoreWaitNodeParams* nodeParams); +/** + * @brief Returns external semaphore signal node params. + * + * @param [in] hNode - Node from the graph from which graphExec was instantiated. + * @param [out] params_out - Pointer to params. + * @returns #hipSuccess, #hipErrorInvalidValue + * @warning : This API is marked as beta, meaning, while this is feature complete, + * it is still open to changes and may have outstanding issues. + */ +hipError_t hipGraphExternalSemaphoresSignalNodeGetParams(hipGraphNode_t hNode, + const hipExternalSemaphoreSignalNodeParams* params_out); +/** + * @brief Returns external semaphore wait node params. + * + * @param [in] hNode - Node from the graph from which graphExec was instantiated. + * @param [out] params_out - Pointer to params. + * @returns #hipSuccess, #hipErrorInvalidValue + * @warning : This API is marked as beta, meaning, while this is feature complete, + * it is still open to changes and may have outstanding issues. + */ +hipError_t hipGraphExternalSemaphoresWaitNodeGetParams(hipGraphNode_t hNode, + const hipExternalSemaphoreWaitNodeParams* params_out); +/** + * @brief Updates node parameters in the external semaphore signal node in the given graphExec. + * + * @param [in] hGraphExec - The executable graph in which to set the specified node. + * @param [in] hNode - Node from the graph from which graphExec was instantiated. + * @param [in] nodeParams - Pointer to the params to be set. + * @returns #hipSuccess, #hipErrorInvalidValue + * @warning : This API is marked as beta, meaning, while this is feature complete, + * it is still open to changes and may have outstanding issues. + */ +hipError_t hipGraphExecExternalSemaphoresSignalNodeSetParams(hipGraphExec_t hGraphExec, hipGraphNode_t hNode, + const hipExternalSemaphoreSignalNodeParams* nodeParams); +/** + * @brief Updates node parameters in the external semaphore wait node in the given graphExec. + * + * @param [in] hGraphExec - The executable graph in which to set the specified node. + * @param [in] hNode - Node from the graph from which graphExec was instantiated. + * @param [in] nodeParams - Pointer to the params to be set. + * @returns #hipSuccess, #hipErrorInvalidValue + * @warning : This API is marked as beta, meaning, while this is feature complete, + * it is still open to changes and may have outstanding issues. + */ +hipError_t hipGraphExecExternalSemaphoresWaitNodeSetParams(hipGraphExec_t hGraphExec, hipGraphNode_t hNode, + const hipExternalSemaphoreWaitNodeParams* nodeParams); // doxygen end graph API /** * @} diff --git a/include/hip/library_types.h b/include/hip/library_types.h index 1088cd4c90..6251b7f2ce 100644 --- a/include/hip/library_types.h +++ b/include/hip/library_types.h @@ -1,5 +1,5 @@ /* -Copyright (c) 2015 - 2021 Advanced Micro Devices, Inc. All rights reserved. +Copyright (c) 2015 - 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 @@ -23,7 +23,9 @@ THE SOFTWARE. #ifndef HIP_INCLUDE_HIP_LIBRARY_TYPES_H #define HIP_INCLUDE_HIP_LIBRARY_TYPES_H +#if !defined(__HIPCC_RTC__) #include +#endif #if (defined(__HIP_PLATFORM_HCC__) || defined(__HIP_PLATFORM_AMD__)) && !(defined(__HIP_PLATFORM_NVCC__) || defined(__HIP_PLATFORM_NVIDIA__)) diff --git a/include/hip/math_functions.h b/include/hip/math_functions.h index c451defa42..3216e24317 100644 --- a/include/hip/math_functions.h +++ b/include/hip/math_functions.h @@ -1,5 +1,5 @@ /* -Copyright (c) 2015 - 2021 Advanced Micro Devices, Inc. All rights reserved. +Copyright (c) 2015 - 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 @@ -27,7 +27,9 @@ THE SOFTWARE. // paths to provide a consistent include env and avoid "missing symbol" errors that only appears // on NVCC path: +#if !defined(__HIPCC_RTC__) #include +#endif #if (defined(__HIP_PLATFORM_HCC__) || defined(__HIP_PLATFORM_AMD__)) && !(defined(__HIP_PLATFORM_NVCC__) || defined(__HIP_PLATFORM_NVIDIA__)) #include diff --git a/include/hip/surface_types.h b/include/hip/surface_types.h index c7f588de09..62fb681111 100644 --- a/include/hip/surface_types.h +++ b/include/hip/surface_types.h @@ -1,5 +1,5 @@ /* -Copyright (c) 2022 Advanced Micro Devices, Inc. All rights reserved. +Copyright (c) 2022 - 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 in the Software without restriction, including without limitation the rights @@ -25,7 +25,14 @@ THE SOFTWARE. #ifndef HIP_INCLUDE_HIP_SURFACE_TYPES_H #define HIP_INCLUDE_HIP_SURFACE_TYPES_H +#if defined(__clang__) +#pragma clang diagnostic push +#pragma clang diagnostic ignored "-Wreserved-identifier" +#endif + +#if !defined(__HIPCC_RTC__) #include +#endif /** * An opaque value that represents a hip surface object @@ -49,4 +56,8 @@ enum hipSurfaceBoundaryMode { hipBoundaryModeClamp = 2 }; +#if defined(__clang__) +#pragma clang diagnostic pop +#endif + #endif /* !HIP_INCLUDE_HIP_SURFACE_TYPES_H */ diff --git a/include/hip/texture_types.h b/include/hip/texture_types.h index d83470698f..33c749ed05 100644 --- a/include/hip/texture_types.h +++ b/include/hip/texture_types.h @@ -1,5 +1,5 @@ /* -Copyright (c) 2015 - 2021 Advanced Micro Devices, Inc. All rights reserved. +Copyright (c) 2015 - 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 @@ -23,7 +23,16 @@ THE SOFTWARE. #ifndef HIP_INCLUDE_HIP_TEXTURE_TYPES_H #define HIP_INCLUDE_HIP_TEXTURE_TYPES_H +#if defined(__clang__) +#pragma clang diagnostic push +#pragma clang diagnostic ignored "-Wreserved-identifier" +#pragma clang diagnostic ignored "-Wreserved-macro-identifier" +#pragma clang diagnostic ignored "-Wc++98-compat" +#endif + +#if !defined(__HIPCC_RTC__) #include +#endif #if !(defined(__HIP_PLATFORM_HCC__) || defined(__HIP_PLATFORM_AMD__)) && (defined(__HIP_PLATFORM_NVCC__) || defined(__HIP_PLATFORM_NVIDIA__)) #include "texture_types.h" @@ -179,4 +188,8 @@ struct __HIP_TEXTURE_ATTRIB texture : public textureReference { #error("Must define exactly one of __HIP_PLATFORM_AMD__ or __HIP_PLATFORM_NVIDIA__"); #endif +#if defined(__clang__) +#pragma clang diagnostic pop +#endif + #endif