Grafico dei commit

890 Commit

Autore SHA1 Messaggio Data
Philip Yang 41b4ff5170 libhsakmt: update query pointer info document
Query pointer info return HsaPointerInfo with MemFlags for all pointer
type now.



Change-Id: I3c02b7b71ba0af953035e3ed9cd6bb6435bb9b65
Signed-off-by: Philip Yang <Philip.Yang@amd.com>


[ROCm/ROCR-Runtime commit: 991cde0656]
2021-07-29 21:10:38 -04:00
Philip Yang e826288132 kfdtest: fix KFDIPCTest on gfx1xxx
hsaKmtAllocMemory with mflags.HostAccess=1 will fail on desktop gfx1xxx GPU
because it's small bar PCIe. Remove this flag.

Child process exit status should use current_test_info, not unit test
info.



Change-Id: I060f23aa98a42251921d003878e70a409c92a4de
Signed-off-by: Philip Yang <Philip.Yang@amd.com>


[ROCm/ROCR-Runtime commit: 413979c319]
2021-07-29 21:10:17 -04:00
chen gong 820e03bd4c libhsakmt: add cyan skillfish support
Signed-off-by: chen gong <curry.gong@amd.com>
Signed-off-by: Oak Zeng <Oak.Zeng@amd.com>
Change-Id: Ie26c2e156c9c4e68a6b36fe699adccf3f808b5e7


[ROCm/ROCR-Runtime commit: 860931557c]
2021-07-29 16:44:16 -04:00
changzhu 5456bde2e2 kfdtest: blacklist some SVM test cases for gfx902 iommu path
Change-Id: I77f734df7ca65f2aa176548fd02ddac6036fe138
Signed-off-by: changzhu <Changfeng.Zhu@amd.com>


[ROCm/ROCR-Runtime commit: 3600cdfa01]
2021-07-29 00:02:57 -04:00
changzhu 0e9cdfecb9 kfdtest: take back SVM test cases for gfx90c
Change-Id: I28627f6eeaf9d213d7740849c6fadcccd91733c0
Signed-off-by: changzhu <Changfeng.Zhu@amd.com>


[ROCm/ROCR-Runtime commit: 1fe2225f52]
2021-07-28 15:44:02 +08:00
Philip Yang 0869422f81 kfdtest: KFDIPCTest BasicTest query shared memory
Parent process alloc memory with specific HsaMemFlags, child process
import the memory handle exported by parent process, query shared memory
pointer info, verify it has same HsaMemFlags.

If child process test failed, exit with error code to notify parent
process.

Change-Id: I5c9534e931b4565186d27124868799b893504c81
Signed-off-by: Philip Yang <Philip.Yang@amd.com>


[ROCm/ROCR-Runtime commit: 426b94015c]
2021-07-23 10:08:28 -04:00
Philip Yang 7100af1b99 kfdtest: query userptr pointer alloc flags
Test if query userptr pointer info return correct alloc flags,
CoarseGrain by default.

Test if query hsaKmtAllocMemory pointer info return correct alloc
CoarseGrain flags.



Change-Id: If3a1175645717e5d7c475d6ff35b02d6876a1f7c
Signed-off-by: Philip Yang <Philip.Yang@amd.com>


[ROCm/ROCR-Runtime commit: c3c1618db7]
2021-07-22 21:14:46 -04:00
Philip Yang f11efa6ee2 kfdtest: RegisterGraphicsHandle check CoarseGrain set
Register graphics memory should always coarse grain.



Change-Id: I9d056b41287fa63247a042e5530ba29d535173ea
Signed-off-by: Philip Yang <Philip.Yang@amd.com>


[ROCm/ROCR-Runtime commit: db288df695]
2021-07-22 21:14:46 -04:00
Philip Yang c26f323d51 libhsakmt: Qyery pointer info flags for registered memory
hsaKmtQueryPointerInfo return vm_obj flags for all below registered
memory types other than hsaKmtAllocMemory, and set the CoarseGrain flag
correctly for:

Graphics: always coarse grain.

Shared: hsaKmtShareMemory pass mflags with export handle to KFD to store
in KFD objs, hsaKmtRegisterSharedHandle get mflags from KFD with import
handle.

Userptr: it is already coarse-grain by default, or based on mflags
provided in hsaKmtRegisterMemoryWithFlags call.



Change-Id: Idc23e8b0cf599b02580737639da2f9ef4ccd0c0d
Signed-off-by: Philip Yang <Philip.Yang@amd.com>


[ROCm/ROCR-Runtime commit: fa7b4a6268]
2021-07-22 21:14:46 -04:00
Philip Yang 178c985a8b libhsakmt: Query pointer info returns HsaMemFlags
Query pointer info returns KFD_IOC_ALLOC_MEM_FLAGS_* flags, it should
return HsaMemFlags, fix it by renaming vm_obj->flags to mflags and
always saving HsaMemFlags.

Use consistent function parameter and variable name to avoid confusion:
mflags for HsaMemFlags and ioc_flags for KFD_IOC_ALLOC_MEM_FLAGS_*
flags.

AMDKFD_IOC_GET_DMABUF_INFO return ioc_flags, translate it to mflags
using new helper fmm_translate_ioc_to_hsa_flags.



Change-Id: If9e117c507139c0166abb1ab0df8c233ef7e48a1
Signed-off-by: Philip Yang <Philip.Yang@amd.com>


[ROCm/ROCR-Runtime commit: 2c796e62be]
2021-07-22 21:14:46 -04:00
Aaron Liu e709fed186 libhsakmt: add yellow carp DID
Signed-off-by: Aaron Liu <aaron.liu@amd.com>
Change-Id: If798dc733bc8d65c67922fb5d2e32aa1dada8381


[ROCm/ROCR-Runtime commit: 3d12437f1b]
2021-07-22 21:18:42 +08:00
Kent Russell 8d90ef172c libhsakmt: Add gfx1032 DID
0x73E3 DID was missing, add it.

Signed-off-by: Kent Russell <kent.russell@amd.com>
Change-Id: Id1ae2f268e0e8b5cfec5ae2065153fe73854b93a


[ROCm/ROCR-Runtime commit: ed62c7aa1c]
2021-07-22 07:37:19 -04:00
Philip Yang 6a15d17257 libhsakmt: update to KFD ioctl version 1.6
sync with KFD ioctl version 1.6:

1.6 - Query clear flags in SVM get_attr API

Change import export handle args pad field to flags, to pass memory
alloc flags from alloc process to import process.

Change-Id: I69360b244651947e885c4a8da9f64a1163101d20
Signed-off-by: Philip Yang <Philip.Yang@amd.com>


[ROCm/ROCR-Runtime commit: dee9c023a2]
2021-07-21 21:48:18 -04:00
Icarus Sparry e97ebfd200 Add dependency on rocm-core
Signed-off-by: Icarus Sparry <icarus.sparry@amd.com>
Change-Id: I5f99114e9186679585862f05db8a508663b74b0d
Signed-off-by: Icarus Sparry <icarus.sparry@amd.com>


[ROCm/ROCR-Runtime commit: b63dde24d0]
2021-07-21 15:57:54 -04:00
Kent Russell 77588e8159 Fix drm.h include path
kernel-headers provides the drm/drm.h path, while libdrm-dev[el]
provides the libdrm/drm.h path, which is what we want to use. Fix the
path so we use the newer drm.h header, as well as fixing SLES, which
doesn't provide drm.h in their kernel-headers.

Change-Id: Icb2b6643698d356169e3baeef17527a1b4e05483


[ROCm/ROCR-Runtime commit: 4f3440a8ac]
2021-07-20 12:49:15 -04:00
Jonathan Kim de34fa23ed libhsakmt: add drm.h header dependency for sles
Update to thunk API introduced dependency on drm.h in commit
1001f27cb5 libhsakmt: update thunk api for exception handling
so update dependency list in SLES builds.

Signed-off-by: Jonathan Kim <jonathan.kim@amd.com>
Change-Id: I6d987fac07612e3eca7b6087205d76df50dc13d9


[ROCm/ROCR-Runtime commit: 303c0748ce]
2021-07-19 12:48:13 -04:00
Jonathan Kim 6c4717ae7a libhsakmt: add runtime enable and disable calls
Add hsaKmtRuntimeEnable and disable.

Signed-off-by: Jonathan Kim <jonathan.kim@amd.com>
Reviewed-by: Felix Kuehling <felix.kuehling@amd.com>
Change-Id: I083f9293948e975546a1b3c1334cb41499b9ab1f


[ROCm/ROCR-Runtime commit: 1ce548829b]
2021-07-16 18:37:41 -04:00
Jonathan Kim 1001f27cb5 libhsakmt: update thunk api for exception handling
The debugger and debug agent no longer use the Thunk API.
Remove all deprecated functions and keep commented
references for future KFD tests.

Update and the keep the version checks for future use
and hsaKmtRuntimeEnable/Disable.

Signed-off-by: Jonathan Kim <jonathan.kim@amd.com>
Signed-off-by: Laurent Morichetti <laurent.morichetti@amd.com>
Reviewed-by: Felix Kuehling <felix.kuehling@amd.com>
Change-Id: Ia2f10d82f5ac36d0bd1bda233810f26e8a154d55


[ROCm/ROCR-Runtime commit: 31ac82617c]
2021-07-16 18:36:18 -04:00
Jonathan Kim fe03b35c8e libhsakmt: update create queue for exception handling
Update hsaKmtCreateQueue to initialize the new save area header with the
exception payload and event ID.

Signed-by-off: Jonathan Kim <jonathan.kim@amd.com>
Reviewed-by: Felix Kuehling <felix.kuehling@amd.com>
Reviewed-by: Sean Keely <sean.keely@amd.com>
Change-Id: Icd38062dc982cb29b30644699014eeb0b3e26d00


[ROCm/ROCR-Runtime commit: 96c7a5c9dc]
2021-07-16 18:34:35 -04:00
Felix Kuehling 14d821391e libhsakmt: Fix deadlocks in __fmm_release
__fmm_release is sometimes called with the aperture lock, and sometimes
without. Consistently call it with the aperture lock held and remove the
lock/unlock calls from this function.

Signed-off-by: Felix Kuehling <Felix.Kuehling@amd.com>
Change-Id: I80dddc64cc0703e5eed8e9f1eb65b75a2c7ae2eb


[ROCm/ROCR-Runtime commit: 5fac7dcc3b]
2021-07-12 18:27:55 -04:00
Felix Kuehling 559bb50c6a libhsakmt: Fix deadlock in map_mmio
Unlock mutex if MMIO mapping fails. This happens on all GFXv8 GPUs.

Signed-off-by: Felix Kuehling <Felix.Kuehling@amd.com>
Change-Id: I1dee1cbddefd9185c24ea79377f49f8ae2c5ff57


[ROCm/ROCR-Runtime commit: 19536080a8]
2021-07-09 17:07:42 -04:00
Kent Russell 1da08cffe1 kfdtest: Ensure devices are peer-accessible for peer mapping
If the devices aren't peer-accessible, we shouldn't try to run a test
that requires that the devices be peer-accessible. Thus, add a check in
MapVramToGPUNodesTest to check for peer accessibility before executing
the peer mappings.

Signed-off-by: Kent Russell <kent.russell@amd.com>
Change-Id: Ib79b141f8c1ac6d85f5ab49d62af62ec10b988b7


[ROCm/ROCR-Runtime commit: bdfe3a12a8]
2021-07-09 15:45:01 -04:00
Philip Yang c63b87aed2 kfdtest: add KFDMemoryTest MultiThreadRegisterUserptrTest
Test Thunk multiple threads register and deregister same userptr race
condition, to emulate application register same userptr to multiple
GPUs using multiple threads.

Use thread barrier to sync the threads, to start register userptr at
same time.



Change-Id: I6723dc39f75908026fa14a490e39e1fe49a13a1b
Signed-off-by: Philip Yang <Philip.Yang@amd.com>


[ROCm/ROCR-Runtime commit: 92076f6f1b]
2021-07-07 17:52:31 -04:00
Aaron Liu 9c544da3f6 kfdtest: add yellow_carp blacklist
Signed-off-by: Chen Gong <curry.gong@amd.com>
Signed-off-by: Aaron Liu <aaron.liu@amd.com>
Change-Id: Ib3a3172b0ac40109acbe42b9dc92517b3fedc84c


[ROCm/ROCR-Runtime commit: ef9c532187]
2021-07-07 09:47:05 +08:00
Aaron Liu 09d3f9749c libhsakmt: add yellow carp support
This patch is to add yellow carp support on thunk.

Signed-off-by: Aaron Liu <aaron.liu@amd.com>
Change-Id: Icfecc3fd1f472c9924f934c6a5352448356d83df


[ROCm/ROCR-Runtime commit: a55551309c]
2021-07-06 21:46:28 -04:00
Aaron Liu bb0146488f kfdtest: MigrateLargeBufTest support APU
Limit test buffer size to 3/4 total VRAM size, and max 1GB.

Signed-off-by: Aaron Liu <aaron.liu@amd.com>
Change-Id: I937e10b0a6bd8215e3865b50f22ce75b3982a6f7


[ROCm/ROCR-Runtime commit: fd131e875e]
2021-07-06 21:44:23 -04:00
Kent Russell ef56da6539 kfdtest.exclude: Add NV12 blacklist
Add a blacklist for gfx1xxx12, using the same list as gfx1012

Change-Id: I7e620dba8a36f6f89152a48066234884150a15dd


[ROCm/ROCR-Runtime commit: b2fb2a3470]
2021-07-06 11:58:53 -04:00
Sean Keely 4c960d7b3d Add error message to assertion.
Warn that HSA_FORCE_ASIC_TYPE may be needed if the engine major id
assertion fails.

Change-Id: I67e01e99c3d1bdc84630ccfae489dce5e77961b5


[ROCm/ROCR-Runtime commit: 408fca0278]
2021-06-28 23:18:43 -04:00
changzhu 1d15f33b5c kfdtest: skip KFDSVMRangeTest.MigrateAccessInPlaceTest for gfx902 and gfx90c
Change-Id: I671440c212a07fdfdb1c4245b4551c6344eaedc6
Signed-off-by: changzhu <Changfeng.Zhu@amd.com>


[ROCm/ROCR-Runtime commit: 1a9604ad57]
2021-06-28 13:37:52 +08:00
Philip Yang f94be2078c libhsakmt: fix multiple threads register userptr race
Aperture locking is too fine-grained, it has race between find userptr
and allocate userptr object.

Change _fmm_allocate_device and fmm_allocate_memory_object to not take
the aperture lock, the callers take it, this implements an atomic find
userptr or allocate a new one.



Change-Id: I6773404e22c1f4382a211c5a9817df23c5534a2a
Signed-off-by: Philip Yang <Philip.Yang@amd.com>


[ROCm/ROCR-Runtime commit: c4d5ee28f0]
2021-06-25 14:16:20 -04:00
Kent Russell 1b33825c8d kfdtest: Remove EvictTest.BasicTest from gfx906
This is causing PSDB/OSDB failures so disable it until investigation is
done

Signed-off-by: Kent Russell <kent.russell@amd.com>
Change-Id: I666cd45fdf8ae585486adc7cf43eacd1700704bb


[ROCm/ROCR-Runtime commit: 5796225011]
2021-06-17 17:07:22 -04:00
Philip Yang 2401e9aafd kfdtest: add KFDSVMRangeTest MigrateAccessInPlaceTest
To test ACCESS_IN_PLACE GPU mapping update to system memory.

Change-Id: I5b990215f39692e829128d848125e1ae0d571e03
Signed-off-by: Philip Yang <Philip.Yang@amd.com>


[ROCm/ROCR-Runtime commit: 351a41ac76]
2021-06-14 11:03:09 -04:00
Alex Sierra 221f75ea7a libhsakmt: move CoherentHostAccess prop to HSA_CAPABILITY
CoherentHostAccess flag member moved from HSA_MEMORYPROPERTY
to HSA_CAPABILITY struct. Now this is reported to the
topology as a capability of the device instead of a device
memory property.

Change-Id: I48e43e4b4a0635b711b62933734587facdfbf88b
Signed-off-by: Alex Sierra <alex.sierra@amd.com>


[ROCm/ROCR-Runtime commit: f85b428265]
2021-06-10 22:21:17 -05:00
Yifan Zhang b3e0b236df libhsakmt: add colon after KFDQMTest.SdmaConcurrentCopies
Signed-off-by: Yifan Zhang <yifan1.zhang@amd.com>
Change-Id: Ief14e513e4b09db0607f5533a55f80d3b0be017e


[ROCm/ROCR-Runtime commit: c24ed10dfa]
2021-06-07 18:21:59 +08:00
Yifan Zhang eb6d16072b kfdtest: Temporarily blacklist some svm related test cases for gfx902.
move blacklisted test case from gfx902 iommuv2 to dgpu path.

Signed-off-by: Yifan Zhang <yifan1.zhang@amd.com>
Change-Id: I8b101226ca8dcd0c12c484f5f6ce12fe73a75bdc
Signed-off-by: Yifan Zhang <yifan1.zhang@amd.com>
(cherry picked from commit 9cf4377572321396225950b9a58beb549120c2a3)


[ROCm/ROCR-Runtime commit: e72be0e54d]
2021-06-06 23:07:29 -04:00
Alex Sierra dd5e49d846 libhsakmt: change memory allocation alignment
it is to optimize memory allocation latency, which
changes alignment from 2MB to 1GB.

Signed-off-by: Alex Sierra <alex.sierra@amd.com>
Signed-off-by: Eric Huang <jinhuieric.huang@amd.com>
Change-Id: I7818e9f13b17e2c0992e75b17f978dc03a018a57


[ROCm/ROCR-Runtime commit: 973b35bc06]
2021-06-01 11:33:16 -04:00
Harish Kasiviswanathan 9a51b04c8e libhsakmt: Handle unaccessible p2p_links
Device cgroup can limit accessible devices. Handle the cases where
p2p_links are not accessible



Signed-off-by: Harish Kasiviswanathan <Harish.Kasiviswanathan@amd.com>
Change-Id: I513dc75ad14e4f2d426cf2fbd301bcba12b4ee54


[ROCm/ROCR-Runtime commit: e28b3fe8b3]
2021-05-25 12:01:44 -04:00
Yifan Zhang 35d61131f3 kfdtest: Temporarily blacklist some svm related test cases.
blacklist some svm related test cases until they are solved.

Signed-off-by: Yifan Zhang <yifan1.zhang@amd.com>
Change-Id: I05e2d965d89bcbf3d43bed2873297e98ad0738ef


[ROCm/ROCR-Runtime commit: 9e0fc7f3c6]
2021-05-24 22:06:53 -04:00
changzhu 2bb878c14a kfdtest: skip KFDLocalMemoryTest.AccessLocalMem if not on dgpu path
It needs to skip LocalMemoryTest because it doesn't support local memory
with no dgpu path.

Change-Id: Iedb6f6deba55e239b21747d933cf2d7005623106
Signed-off-by: changzhu <Changfeng.Zhu@amd.com>


[ROCm/ROCR-Runtime commit: 55cb03dbae]
2021-05-19 11:33:08 -04:00
Chengming Gui 560af3622a kfdtest: Temp disable all shader test related cases due to sp3 compiler update
The updated sp3 compiler does not support GFX10 temperaly.

Signed-off-by: Chengming Gui <Jack.Gui@amd.com>
Change-Id: Idd9336663814b7925d9742eee0bd310d00945d3e


[ROCm/ROCR-Runtime commit: b8ef20e35c]
2021-05-18 02:04:55 -04:00
Chengming Gui 50effa23de kfdtest: Add Beige_Goby support
Signed-off-by: Chengming Gui <Jack.Gui@amd.com>
Change-Id: I3c9d4f8af1dbb4fd7ce7ff238426a4af61fd771f


[ROCm/ROCR-Runtime commit: f28dbdf7bf]
2021-05-18 02:04:25 -04:00
Chengming Gui dc9f7ce1ff libhsakmt: Prepare Beige_goby support
PCI IDs have yet to be added later.

Signed-off-by: Chengming Gui <Jack.Gui@amd.com>
Change-Id: Ia0cbda17469b13fca807ce4eb74deae6f0d1eeac


[ROCm/ROCR-Runtime commit: ce995fe48d]
2021-05-18 02:04:06 -04:00
Philip Yang c173db344a kfdtest: Remove KFDSVMEvictTest.QueueTest GFX9 assembler meta
Fixes assembler error. The SP3 backend if already set to FamilyId.

Change-Id: I7721a555b05688b16993a03242a765694594825a
Signed-off-by: Philip Yang <Philip.Yang@amd.com>


[ROCm/ROCR-Runtime commit: 86a68b2774]
2021-05-14 10:44:30 -04:00
Kent Russell 7ab82d773f kfdtest: Increase timeout in EvictTest
Increasing the timeout will avoid some test failures. This shouldn't
mask any issues as any incomplete shaders should still hang and would
just time out at 180 sec instead of 120 sec.

Signed-off-by: Kent Russell <kent.russell@amd.com>
Change-Id: If4e893ab80d9d159bd0b8b112aa7574abc5e4f44


[ROCm/ROCR-Runtime commit: 9168dfe041]
2021-05-12 14:06:03 -04:00
Mike Li a8ceb5c406 Add Size of VGPR and SGPR to HsaNodeProperties
Signed-off-by: Mike Li <Tianxinmike.Li@amd.com>
Change-Id: I7e6c0c5b9fd90c0bb5f3b7d35362a073afdcf9b8


[ROCm/ROCR-Runtime commit: 47ccc6604d]
2021-05-03 15:16:15 -04:00
Felix Kuehling 5c323f2611 kfdtest: Allow some CS to fail in EvictTest
amdgpu_cs_submit can fail intermittently if another process has too much
memory reserved at the time. Allow a small percental of command
submissions to fail to make the test more robust.

Signed-off-by: Felix Kuehling <Felix.Kuehling@amd.com>
Change-Id: If9f62b2b6f67be71420016d4e38d4dd6b6bca9a5


[ROCm/ROCR-Runtime commit: 8baf02e80b]
2021-05-03 11:01:35 -04:00
Felix Kuehling c621b721fe kfdtest: Workaround delayed page faults
Delayed page faults from a terminated process can be attributed to the
next process with the same PASID. Work around that by adding a delay
after the Exception tests to allow the kernel to clean up any fault
storms before the next test.

Signed-off-by: Felix Kuehling <Felix.Kuehling@amd.com>
Change-Id: Id310c13ea9eb92b04d37b95d91a0dd60bd9954e5


[ROCm/ROCR-Runtime commit: bd68646772]
2021-05-03 11:01:24 -04:00
Felix Kuehling 4da176c09d kfdtest: Handle EINTR in waitpid
If the signal arrives too late, it interrupts waitpid. Handle this
situation gracefully.

Signed-off-by: Felix Kuehling <Felix.Kuehling@amd.com>
Change-Id: If4925c352c81ba7fef8a940460b91f5e720b451e


[ROCm/ROCR-Runtime commit: 25288e07dc]
2021-05-03 11:01:11 -04:00
Felix Kuehling ec289d055f libhsakmt: Add a new device ID for gfx90a
It is gfx90a VF device ID, for virtualization support.

Signed-off-by: Felix Kuehling <Felix.Kuehling@amd.com>
Change-Id: I9e51d6b58c702d185e6758a9c511e9b8bc72c2f5


[ROCm/ROCR-Runtime commit: d8d8e3ddd6]
2021-04-30 13:42:27 -04:00
Alex Sierra 6ae996c151 kfdtest: SetGetAttributes default access attr returned based on xnack
After unregistered memory is added, now default access attribute
is returned based on xnack configuration.

Change-Id: I8ef44fe1e165ba009622e8112436c1f7a683f6cb
Signed-off-by: Alex Sierra <alex.sierra@amd.com>


[ROCm/ROCR-Runtime commit: 0a2d7d8319]
2021-04-27 14:18:15 -04:00