Commit Graph

4887 Commits

Author SHA1 Message Date
sdashmiz 38a67df312 SWDEV-403638 - Fix warnings
- disable deprecated function use warning
- disalbe size_t to .type' warning
- disable conversion from 'type1' to 'type2' warning

Signed-off-by: sdashmiz <shadi.dashmiz@amd.com>
Change-Id: I64161fd37cf56de3d132102103267ae8da40193a
2023-06-15 12:17:22 -04:00
German 1a0c3e4dc4 SWDEV-311270 - Add IPC support for memory pools
Initial implementation for hipMemPoolExportToShareableHandle,
hipMemPoolImportFromShareableHandle,
hipMemPoolExportPointer and hipMemPoolImportPointer

Change-Id: I0ebdc48e9163b394ded560adca6c38bbc5aee7d1
2023-06-15 11:36:52 -04:00
Jaydeep Patel ec75a3e60e SWDEV-403766 - Release mem obj while device reset.
Change-Id: I8a93061c9c4ed692bf7ba1b872af370f79a13a5d
2023-06-15 09:52:50 -04:00
Saleel Kudchadker 8d193c32bb SWDEV-384557 - Use toggle for SDMA query
- Use HIP_USE_SDMA_QUERY env var toggle for new API use. Env var is 0 by
default

Change-Id: If725a0c41e15f78a1a6c3f47942954fe9240b4db
2023-06-15 01:02:24 -04:00
Jacob Lambert 8047d8e3e8 Revert "SWDEV-371628 - Shift device lib linking into clang driver"
This reverts commit a4c5c44008.

Reason for revert: Performance regressions and failures observed. Need to investigate those and before re-applying patch

Change-Id: I42ba0605797f9bdcfb5d5102927dd01405cf05e3
2023-06-15 00:56:08 -04:00
Jaydeep Patel 2c9c58e7bb SWDEV-403995 - uniform_work_group_size is interger type is 1 for true and 0 for false. Lighting kernel's init sets uniform work group flag and hence not need to set it from options.
Change-Id: Ife45c1e3ccef03d16d7e07c3e0714fd8fd388fd3
2023-06-06 23:05:25 -04:00
Jacob Lambert 443f912c7f SWDEV-375055 - Re-enable Comgr unbundler
With recent upstream changes (D145770), we can now use the
Comgr unbundler without requiring an env field in the supplied
targetID. For users, this is consistent with previous legacy
unbundler behavior.

Change-Id: I5f085b0fa1ad352bbbb282b75367c206b75f279f
2023-05-31 16:14:08 -04:00
Vikram 7b6a8f1702 SWDEV-354050 - Runtime support for HIP non hostcall printf
Relates to https://reviews.llvm.org/D150427,

Each printf call populates buffer with following data
1. Control DWord - contains info regarding stream, format string constness and size of data frame
   (see http://gerrit-git.amd.com/c/lightning/ec/device-libs/+/857722 for more info)
2. Hash of the format string (if constant) else the format string itself
3. Printf arguments (each aligned to 8 byte boundary)

Change-Id: I7e320deb343921b4b4cfaf08a2be2883e0bc1f65
2023-05-26 01:55:20 -04:00
Saleel Kudchadker 5436d362b1 SWDEV-301667 - Add a flag for gpuvm kernargs
HIP_FORCE_DEV_KERNARG=1 will create a device allocation for kernel arg
segment. Flag is 0 by default.

Change-Id: Iaaf5a149f3be8596568878d5d272268baf067c60
2023-05-22 11:23:48 -04:00
Saleel Kudchadker 60d9a4ebab SWDEV-384557 - Do not fall back to compute
- Use regular copy API if we exhaust free SDMA engines and not fall back
to compute copy. Falling to compute is affecting performance for
numerous apps that are GPU bound

Change-Id: I75c767eff0b9f5ada324301c5c327fe2c23a9806
2023-05-22 11:23:23 -04:00
Alex Voicu 06df9e2efd SWDEV-301667 - Kernelarg gpuvm
Add aligned, nontemporal `memcpy` for kernarg.

Change-Id: I5d8ac76904feaf793b45ec2ea5fbd1069be20068
2023-05-22 11:21:14 -04:00
Jacob Lambert a4c5c44008 SWDEV-371628 - Shift device lib linking into clang driver
Previously, we used the following approach and Comgr actions
for device lib linking:

    AMD_COMGR_COMPILE_SOURCE_TO_BC (compile with clang driver)
    AMD_COMGR_ADD_DEVICE_LIBRARIES (link in device libs with
      llvm-link API)

However, the clang driver can link in device libraries as part
of compilation, assuming a --rocm-path is set. In this context,
this is accomplished by using the following Comgr action instead:

  AMD_COMGR_COMPILE_SOURCE_WITH_DEVICE_LIBS_TO_BC (compile and
    link in device libs with clang driver)

Change-Id: I661465865365afecc44aa15d4df91bfab361af8d
2023-05-17 17:40:56 -04:00
AravindanC 3f4b70cafd SWDEV-336531 - Fix for relative path issue in debuginfo
Change-Id: Ie36d1a93f40ddc3a42823eb83e041af8c55bcdee
2023-05-17 13:06:26 -04:00
Ioannis Assiouras a07e38be2f SWDEV-400119 - Return error from globalFreeMemory() if HSA available memory query fails
Change-Id: I33c069fa1e0d31891f64dc8167a24ef9d7ed1426
2023-05-15 11:54:25 +01:00
Saleel Kudchadker 0b475284e9 SWDEV-398151 - Partly relax static engine allocation
Change-Id: I4903b51a34b597a2e84d771b52cf629f877dba05
2023-05-11 00:52:18 -04:00
Jaydeep Patel ffa1deef27 SWDEV-398047 - Disable arena for XNACK.
Change-Id: If6c98490bd5b8146a357f45ed132f687def0877f
2023-05-10 23:28:05 -04:00
taosang2 7624a48de9 SWDEV-366528 – Fix image memory format updating issue
Add dstMemory format updating.
Separate format updating for srcMemory and dstMemory.

Change-Id: I1692b92d417bbd742d562679f218ebf8ca532e92
2023-05-08 21:43:42 -04:00
Jaydeep Patel 0eb96cbc59 SWDEV-397168 - Enable dynamic call stack size for PAL.
Change-Id: I8be51ffb48e6a742117491a4bf6f12f152e4a0b3
2023-05-07 23:26:28 -04:00
German 04b696abee SWDEV-353281 - VM support in mempool for graphs
The change enables VM support in graphs on Windows. That allows
to avoid caching of all allocations at the cost of map/unmap
overhead during memory create/destroy.

Change-Id: I792be00fba099e5e5d3cd44a963e1dfd6976a86d
2023-05-05 15:31:26 -04:00
kjayapra-amd f14e8a2dba SWDEV-393910 - Port gfx94x changes to mainline.
Change-Id: Ibf727223bbe5230b132b47c39e0fc1d87cbd3b9c
2023-05-05 15:16:23 -04:00
Sourabh Betigeri afa28cdf44 SWDEV-393362 - Move setData() from profilingEnd() to profilingBegin() to eliminate a possible data race
- Introduce a state variable to indicate if HwProfiling is enabled to
eliminate a possible data race of vector<> signals_.

Change-Id: Id504cc76d7fa9f7e6455587dd232b60ccbbb735b
2023-05-04 17:19:25 -04:00
Saleel Kudchadker 0a7708f982 SWDEV-301667 - Better log
Change-Id: I7399de7fe7a8840568d02362d2d936173583030c
2023-05-04 16:29:02 -04:00
Jaydeep Patel 82e4859e03 SWDEV-392870 - Enable p2p support for image using PAL.
Change-Id: I3acbbc01ee11e488e93204814361b8c3431bca4f
2023-05-03 00:34:08 -04:00
Jatin Chaudhary c585aefdb7 SWDEV-376453 - Changes to fix crash seen with HIP and recent compiler change with -O0
Change-Id: I37de83b7449461ce2378741e97ff8fb8da736523
2023-05-02 17:46:38 -04:00
Saleel Kudchadker 538d453b86 SWDEV-301667 - Cleanup log
Change-Id: I9719ec8b19406a062727937471e7a845a522a0be
2023-05-01 11:07:55 -07:00
Saleel Kudchadker 9775c38725 SWDEV-392427 - Invalidate Barrier Value AQL header
Change-Id: Id8e04ffe44da58641361468957d397af128443bb
2023-05-01 14:06:05 -04:00
victzhan d9c00767dc SWDEV-345751 - fix misinitialize arraySlice in partialMemCopyTo()
Change-Id: I622c368957b1bd39e973f9afa4ee01593dd9e8ac
2023-05-01 13:07:44 -04:00
German 7ef2da5aba SWDEV-353281 - Move VirtualMem map update to memobj
- The implementation in mempool graphs requires refcounting VA object.
That requires release() to update the map only on the actual destruction.
- Add GPU event tracking for paging operation. Otherwise, runtime
may not always flush IB.

Change-Id: Idf99ffb894321a38e04b490116a7ca435635918d
2023-04-28 17:22:11 -04:00
Saleel Kudchadker 4a73fbec00 SWDEV-355540 - Do not reset core affinities
- Do not reset core affinities when spawning new threads

Change-Id: I26a12075a1ff197bc217aafb9ba18ffbb019ef43
2023-04-26 16:52:37 -04:00
German Andryeyev 3e5803c4c0 SWDEV-381627 - Move cl_vk_amd.hpp into rocclr
Rename VK interop to ExternalMemory object, since it should handle
DX interops also

Change-Id: I536ec46d3e53ece35234a2e29030393ad411b96d
2023-04-26 15:25:01 -04:00
Jacob Lambert 2a9d8b5862 SWDEV-1 - Add missing newlines to debug log output
Change-Id: I6c98d482079c34931cdc0615075eba34f87241f3
2023-04-25 13:10:57 -04:00
pghafari afa15ddb89 SWDEV-367145 - adding support for timeline semaphore
Change-Id: I654359b48abe8bbaac2def5118d3ad0bb05d9492
2023-04-25 10:02:43 -04:00
Saleel Kudchadker 5865c642d4 SWDEV-384557 - Fix engine status query
- Maintain a map of SDMA engine# to stream allocated following a greedy
approach
- Anything past that will query SDMA engine status always and go with a
SDMA or Blit copy path

Change-Id: Ibfaed7f951ab84d80cb0430596a4d11b5aec9202
2023-04-21 00:57:26 -04:00
victzhan 636983de49 SWDEV-387117 - Support negative miplevel for clCreateFromGLTexture()
Change-Id: Ieaa340196e6844b2d18cdcc2278f913fc7c7bbb8
2023-04-19 12:46:45 -04:00
pghafari 78de2ae692 SWDEV-366992 - adding handle type for vk interop
Change-Id: I79ee0d89b948c21b96709e9e607abe7901621a97
2023-04-18 16:59:25 -04:00
German Andryeyev e82eecf33e SWDEV-231145 - Add a validation for uniform launch
Change-Id: I68d61690c50060d9dcca117b248dddf69204a23f
2023-04-18 12:56:09 -04:00
Jason Tang c95944fd7e SWDEV-1 - Make gl.h mandatory for build
Change-Id: I6f68d1bdb455f219c7b05a05256eb67d00e81a3c
2023-04-17 18:22:18 -04:00
German Andryeyev 1cd99b5056 SWDEV-1 - Enable PAL interface 792
Change-Id: I4b77ecc8e4c129c5e1e62ec84ac4a5381f97a823
2023-04-17 09:44:29 -04:00
Konstantin Zhuravlyov 667f048d18 SWDEV-383199 - Use SC for luxmark for gfx10+
Change-Id: I693b00fd9fe8e48b7602c8c5a87b59cfae69d891
2023-04-14 13:20:00 -04:00
Chauncey Hui 3d87e3848b SWDEV-2 - Change OpenCL version number from 3580 to 3581 2023-04-05 07:51:04 +00:00
Saleel Kudchadker 20ca8b8116 SWDEV-384557 - Leverage SDMA engine status query
Change-Id: I5f386f2965de24a229ea43b6c4da82099692f91f
2023-04-05 07:50:53 +00:00
Shadi Dashmiz 471ff60a90 SWDEV-387508 - construct uuid from pal props
This reverts commit e83c7a0510195fda6640c22d7ad98f056cf95dcd.

Reason for revert: it is a test issue to consider uuid a string it is array of values 

Change-Id: Ifb2ae05a99cdaa80e689b83693fc553dd974a249
2023-04-05 07:50:45 +00:00
jatang d897082a6c SWDEV-383606 - Find the correct LocalWorkSize
when uniformWorkGroupSize_ is true

Change-Id: Ic7fa25d5fa503e59509d481a492f6519c6e52889
2023-04-05 07:50:34 +00:00
Chauncey Hui 391bbd0455 SWDEV-2 - Change OpenCL version number from 3579 to 3580 2023-04-05 07:50:25 +00:00
taosang2 82d2213cfa SWDEV-380903 - Add program lock
Create seperate locks for program and HSAIL

Change-Id: I7c826ed9c2f2d839d359e5158f578830655616fd
2023-04-05 07:50:16 +00:00
Rahul Garg 7b419f42eb SWDEV-389676 - Update stack size limit
Change-Id: Id0cf66820e76e1bbd7f6c17ceb110782cdb5f978
2023-04-05 07:50:06 +00:00
Chauncey Hui 899c0e54e7 SWDEV-2 - Change OpenCL version number from 3578 to 3579 2023-04-05 07:49:57 +00:00
Xie.AlexBin 91e2cd5d67 SWDEV-339709 - Device Atomic test failed
Code change for Linux

Change-Id: I002881c188b9de351618a06ee8b5ce2aa5d9fd95
2023-04-05 07:49:47 +00:00
Xie.AlexBin c2b64f8bf5 SWDEV-339709 - Device Atomic test failed
Code change for Windows.

Change-Id: I5ad520b67d1d9ec029cd2c2df7009915caaa8583
2023-04-05 07:49:34 +00:00
Chauncey Hui f670c97ad8 SWDEV-2 - Change OpenCL version number from 3577 to 3578 2023-04-05 07:49:23 +00:00