Граф коммитов

403 Коммитов

Автор SHA1 Сообщение Дата
Jason Tang a3fe0fafe2 SWDEV-1 - Disable OCLAtomicCounter for now
OCLAtomicCounter should only be run when the compiler is HSAIL.

Change-Id: I862e23b22157d2c25bc5697fa58079c78040f5f5
2022-04-20 16:38:48 -04:00
Jeremy Newton 3121b1020a Merge "SWDEV-321116 - Allow disabling ICD loader" into amd-staging 2022-04-19 12:35:21 -04:00
Jeremy Newton d1782940f3 SWDEV-321116 - Allow disabling ICD loader
This patch adds an option (BUILD_ICD) to toggle the ICD loader build
with rocm-opencl. This isn't useful for official ROCm use, but distros
or users may want build rocm-opencl with their own OCL ICD loader.

The default option is BUILD_ICD=ON.
If this option is set to OFF, an OpenCL OCD loader must be installed
prior to attempting to build rocm-opencl.

E.g. distros already provide ocl icd loader packages:
sudo yum install ocd-icd-devel
sudo apt-get install ocl-icd-opencl-dev
sudo zypper install ocd-icd-devel

Signed-off-by: Jeremy Newton <Jeremy.Newton@amd.com>
Change-Id: I6006593eceed543cd829e8949ec2256482815673
2022-04-13 18:27:13 -04:00
sdashmiz 9f5685ea0a SWDEV-329349 - add display support for Opencl
Signed-off-by: sdashmiz <shadi.dashmiz@amd.com>
Change-Id: Icf5253ba87f3852153c620fb7b789bd6e90cb52e
2022-04-13 15:11:29 -04:00
Hao Yuan 4d300d1f8a Merge "SWDEV-328274 - Move DLLMain from VDI layer to HIP/OCL layers" into amd-staging 2022-04-12 11:00:51 -04:00
haoyuan2 fe173ed9fb SWDEV-328274 - Move DLLMain from VDI layer to HIP/OCL layers
Change-Id: I89db993ba90783c53546c5290c00e13f5c24edf4
2022-04-08 12:12:07 -07:00
Jeremy Newton b8c124acb5 SWDEV-321118 - Use GNUInstallDirs
Use GNUInstallDirs variables to determine the location of BINDIR,
LIBDIR, DOCDIR, and SYSCONFDIR.

Note that CMAKE_INSTALL_LIBDIR is overriden, since the default for RHEL
is lib64, but ROCm packaging wants it to be lib always. Distros or users
can easily override this.

Signed-off-by: Jeremy Newton <Jeremy.Newton@amd.com>
Change-Id: Ifb38263dce80d80c5ebb4eacd8e49c76bb013a44
2022-04-08 13:52:08 -04:00
Jeremy Newton 86c9bb1946 SWDEV-321116 - Drop unnecessary ICD include
This looks unused. This should allow building rocm-opencl without any
dependency on any particular OCL ICD.

Signed-off-by: Jeremy Newton <Jeremy.Newton@amd.com>
Change-Id: Ib9229ede8400fd0e883275659ab99513b03952cb
2022-04-07 14:45:43 -04:00
Maneesh Gupta 69b7cb5069 Merge "SWDEV-325869 - Update ASAN linker options" into amd-staging 2022-03-10 01:50:00 -05:00
Ranjith Ramakrishnan f90e95f8b1 Merge "SWDEV-291455 - File Reorganization with backward compatibility" into amd-staging 2022-03-04 19:21:56 -05:00
Maneesh Gupta 94ed5262c6 SWDEV-325869 - Update ASAN linker options
Change-Id: I9ef513ab647ec0866cdf0f70f759ab95d80081b9
2022-03-03 11:45:06 +00:00
Ranjith Ramakrishnan c110ac233f SWDEV-291455 - File Reorganization with backward compatibility
Package installed in /opt/rocm
Warpper header files and soft link to libraries for backward compatibilty

Change-Id: Ib1edb27713dfa589369f0a03c59d3ac1b0dc8400
2022-02-27 15:36:02 -08:00
haoyuan2 5d65c0da88 SWDEV-298331 - Fix FreeLibrary throw exception issue on Windows
dummy function for OCL, release resource for HIP

Change-Id: Idda5047ab7393747d13a9231e0cca5953fc68a6a
2022-02-25 20:02:41 -08:00
Jeremy Newton 7ac4483be7 Merge "SWDEV-1 - Fix cmake build" into amd-staging 2022-02-23 14:11:56 -05:00
Saravanan Solaiyappan 56dde03fbb SWDEV-323670 - RPM: Remove symlinks during upgrade as well
During RPM upgrade, lib/libOpenCL.so* files/symlinks from the previous
installed version are not removed.
This change will remove those symlinks as part of the RPM remove
or upgrade operation.

Signed-off-by: Saravanan Solaiyappan <saravanan.solaiyappan@amd.com>
Change-Id: Ia943407052ec24911756042a5f9839a605522443
2022-02-22 08:04:02 -05:00
Saravanan Solaiyappan c741a808ae SWDEV-323670 - Remove lib/libOpenCL.so* symlinks during upgrade
During upgrade lib/libOpenCL.so* files/symlinks are not
removed.
This change will remove those symlinks as part of the upgrade
package activity.

Signed-off-by: Saravanan Solaiyappan <saravanan.solaiyappan@amd.com>
Change-Id: Ia12e89e857b358101f93a6044fe090aa7acafbe0
2022-02-17 09:43:30 -05:00
Jeremy Newton 9c1f2da1a2 SWDEV-1 - Fix cmake build
CPACK_PACKAGING_INSTALL_PREFIX is defined in the wrong location.

Signed-off-by: Jeremy Newton <Jeremy.Newton@amd.com>
Change-Id: Id8ce6beb1d18878c9132cab335cb372a53cc0ee8
2022-02-09 16:09:25 -05:00
Ashutosh Mishra e3fe3a6109 SWDEV-306262 - Fix RUNPATH
RUNPATH was not changed to correct ROCM_RPATH
Packaged proper binaries after RUNPATH correction

Signed-off-by: Ashutosh Mishra <Ashutosh.Mishra@amd.com>

Change-Id: I97443cc0d6cb1ecf7352e3c83ae0fe38a8f339bf
2022-02-08 15:14:05 -08:00
German Andryeyev 81ed495bbd SWDEV-300515 - Expose RT CU granularity
Change-Id: I15369eb522c29035cd67cd36a9a88517ef3aca59
2022-02-04 00:04:58 -05:00
Freddy Paul 8fa82f6e64 SWDEV-309024 - Providing debug information for released libraries
Current packaging structure using custom command fail to work for
generating debug symbols.Hence changing the packaging to more
conventional way of using single CMakeLists.txt and split packages
using components like binary, dev and icd

Change-Id: I7fcf5f8afc3602f77576f2a13aa4916acb10888b
2022-01-26 08:14:05 -08:00
Jeremy Newton 3898530e2c SWDEV-316087 - Fix ROCM_DEP_ROCMCORE logic
ROCM_DEP_ROCMCORE is not passed to the packaging cmake files, so
rocm-core is never added to the dependency list, even if it's set.

Signed-off-by: Jeremy Newton <Jeremy.Newton@amd.com>
Change-Id: I57ec415b5e2b816f8bc226a66643ca0a808e9a35
2021-12-22 11:07:58 -05:00
Jeremy Newton cb1e7cd48d SWDEV-306262 - Add ocl-icd subpackages
These packages contains only the ICD loader (libopencl.so). This allows
legacy opencl (PAL) to use these packages instead of duplicating these
packages in both builds.

This also resolves a licensing issue where OCL ICD is licensed as
Apache, while opencl is MIT. Having a separate package avoid license
confusion.

Signed-off-by: Jeremy Newton <Jeremy.Newton@amd.com>
Change-Id: I3dd29239841da7f5dc767419a9bc35d9046e9936
2021-12-08 16:15:59 -05:00
Jeremy Newton e885ae9591 SWDEV-306293 - fix regression in cleanup
To fix SWDEV-306293, x86_64-rocm-opencl.conf was renamed to
10-rocm-opencl.conf. This was not changes in the clean up, only in the
creation, so the patch causes a regression by not cleaning up the new
filename.

Signed-off-by: Jeremy Newton <Jeremy.Newton@amd.com>
Change-Id: I4aa456955f6f7c2d52a3560e5e792537f95add17
2021-12-07 09:59:03 -05:00
taosang2 76c6dcd558 SWDEV-1 - Add EMU_ENV option
Fix FEAT-39125
Add EMU_ENV option. If it is ON, the building is for
emulation environment, thus some logics can be adjusted
to match emulation environment. If it is OFF, the
building is for regular environment.
Currently only ocltst will use the option. But it can
be used for other modules.

Change-Id: I54e1bc1309e82794b41fca2ae1f01f004138dced
2021-12-03 10:03:00 -05:00
Jeremy Newton df2eec8465 Merge "SWDEV-312927 - Fix rocm-opencl package licensing" into amd-staging 2021-12-02 11:48:59 -05:00
Freddy Paul 3f1e227182 SWDEV-306293 - Failing Ubuntu, CL-GL subtest in OpenCL conformance
renaming rocm-opencl ldconfig file with "10-" prefix to prioritize
over system icd loader.
Change-Id: I0a54de7a0bc0e256d6470eae743ec712d1e42a36

Change-Id: I4af1d0e3e27f40f8b03b798cae43cfd4ba4a1880
2021-12-01 07:29:54 -08:00
Jeremy Newton 5416bcb7e8 SWDEV-312927 - Fix rocm-opencl package licensing
The license file needs to be installed.

RPM also requires the LICENSE field to be set.

Signed-off-by: Jeremy Newton <Jeremy.Newton@amd.com>
Change-Id: I8bcec77e51b88f3f6a6fa5799d6e38db1d1ab566
2021-11-30 17:27:03 -05:00
Jason Tang 36298f36d3 Merge "SWDEV-1 - Fix getopt for options that don't have colon" into amd-staging 2021-11-23 16:36:34 -05:00
Jason Tang aba8b08701 SWDEV-1 - Fix getopt for options that don't have colon
Change-Id: Ibb8907e23294bfa033bdefb243ddac35574983b0
2021-11-22 15:51:28 -05:00
Jason Tang 63bd627252 SWDEV-1 - Enable ocltst Jenkins service messages
Change-Id: I201e3feea4598c4bfcfa77585dd01a6b60e452a3
2021-11-19 16:05:26 -05:00
Ashutosh Misra 0f79d51998 SWDEV-264665 - resolve uninstall breakage
Check required of existence of dir in the prerm

Change-Id: I54e1bc0309e82794b41fcc2ae1f01f004138dcee
2021-11-12 12:37:13 -04:00
Julia Jiang 398e093f79 SWDEV-306204 - update disclaimer in opencl
Change-Id: I6d5a33cd062c8f5193c09483432685c64519da50
2021-11-08 17:38:04 -05:00
Alex Xie 1ced9040b6 SWDEV-305752 - OCL WIN Conformance select test fail
unmap should complete before working on the other mapping API

Change-Id: I27517888f3112d1113894cdbcb7a786321a3e554
2021-10-28 12:20:15 -04:00
Jason Tang b1e9a4227c SWDEV-301289 - Enable building and installing ocltst on Windows
Change-Id: I512dbcb96dd6a7c52a5ebad819043fdd0138215d
2021-10-25 14:10:15 -04:00
Jason Tang 5c13f33da2 SWDEV-307023 - Fix cltrace build
Change-Id: I75fd953668dc576c3132ae463e34ecb4ae2fb0c7
2021-10-14 09:26:27 -04:00
Sarbojit Sarkar 1643555ad7 Merge "SWDEV-301823 - Fix for memset2D/3D optimization" into amd-staging 2021-09-28 00:06:39 -04:00
Freddy Paul b4b83e274e SWDEV-304500 - OpenCL tests are failed for Ubuntu 20.04.3
As part of the stack unification some of the application using
opencl seem to depend on libopencl.so provided from thirdparty
providers. For libopencl.so from thirdparty provider to find
libamdocl.so ldconfig path to {opencl install path}/lib is required

Change-Id: I8e12e463209a44177ee433644c75ef0781f1da2f
2021-09-27 07:36:06 -07:00
Vladislav Sytchenko c4aa6febe5 SWDEV-301289 - Treewide macro rename
ATI_OS_WIN -> _WIN32
ATI_OS_LINUX -> __linux__

We should not rely on non-standard macros for platform detections.

Change-Id: If1d06e2e1187268df62a59609ea5496ab7eb709d
2021-09-26 12:13:37 -04:00
Jason Tang 159f7f24cd Merge "SWDEV-301289 - Add missing sources files needed for ocltst on Windows" into amd-staging 2021-09-25 17:09:12 -04:00
Vladislav Sytchenko 6c9b07370c SWDEV-301289 - Point to local AMD OpenCL via OCL_ICD_FILENAMES
The OCL_ICD_FILENAMES env var contains a list of OpenCL platforms that
the ICD should prepend to the list of reported platforms. Since the
built amdocl library will show up as the first platform, we can tell
ocltst to always run with platform 0. This way we guarantee that the
correct binary is being loaded.

Using this env var also makes programming LD_LIBRARY_PATH redundant
for Linux.

Change-Id: I8c1729e8b4dd1cd2df1a3da08c7b7addebd08b4f
2021-09-25 17:03:17 -04:00
Vladislav Sytchenko 3d82092632 SWDEV-301289 - Correctly reset optind when using getopt()
optind's starting value is 1 and it needs to be reset to 1 after each
getopt() invocation. Resetting it to 0 will cause getopt() to
reinitialize its internal state. This is only needed for some corner
cases. In our current usage, we should be resetting it to 1.

Change-Id: I68da7e41ee8b83b275e2a7bd660c13af569769f1
2021-09-25 17:02:35 -04:00
Sarbojit Sarkar 5847bb9c7d SWDEV-301823 - Fix for memset2D/3D optimization
Change-Id: I03d41a1908ca547e27774e6ced98571913e1808a
2021-09-25 12:11:26 +00:00
Alex Xie 19ca123460 SWDEV-302875 - OpenCL build failure
clinfo should rely on OpenCL interface, headere file and library only

Change-Id: I8e09aa73b55f1a28c2e4403f52740803d0338c12
2021-09-16 22:16:06 -04:00
Jason Tang 9ca733ca1e SWDEV-1 - switch to C++17
Change-Id: I555914fc65f61259fe32a7f58864ac0dba1d641f
2021-09-04 17:19:02 -04:00
Maneesh Gupta e9833dce24 Merge "SWDEV-293197 - Add dependency on rocm-core" into amd-staging 2021-09-02 01:10:40 -04:00
jujiang 422a26142d SWDEV-286322 - clean up trailing white space
Change-Id: Ie47bc977e1598356b455957d96f9afa37794c1fd
2021-09-01 14:53:14 -04:00
Icarus Sparry d91e1d9daa SWDEV-293197 - Add dependency on rocm-core
Signed-off-by: Icarus Sparry <icarus.sparry@amd.com>
Change-Id: Id1b34c7c6fa551f3aacc35827cb6906cec4484e3
2021-09-01 00:21:42 -07:00
Vladislav Sytchenko 35ee5f675c SWDEV-301289 - Add missing sources files needed for ocltst on Windows
Change-Id: Icf96028f7891781e4ce1a7d425ff8d41e2602ffd
2021-08-30 22:33:28 -04:00
Freddy Paul 4790350f63 SWDEV-300274 - Path to OCL library not handled consistently
OpenCl applications are expected to work with publicly available
libopencl.so that is capable of finding vendor specific library
libamdocl64.so using the ICD loader entry.
x86_64-rocm-opencl.conf should provide ldconfig entry for
libamdocl64.so and libamdocl64.so shall use RUNPATH for finding
dependencies like hsa runtime.

Change-Id: Icf1267c7a04c1545eae0a7236bf8b7581ffa11ef
2021-08-26 09:31:03 -07:00
Julia Jiang fdb61872c8 SWDEV-291894 - update branch info in OpenCL readme
Change-Id: I18e497f08ac3ef98e7b383eda62ec42ec7559912
2021-08-13 12:47:03 -04:00