Commit Graph

190 Commits

Author SHA1 Message Date
Paul bb145e77ae Create context for cuda 2020-02-10 15:52:34 -06:00
Paul 9494d0e3c9 Add setDevice to try and initialize the context on cuda 2020-02-10 13:37:45 -06:00
Paul fb8c7cb3ec Make threads a multiple of hardware concurrency 2020-02-06 16:23:29 -06:00
Paul bf69c7ae32 Add multithreaded test 2020-02-06 16:21:40 -06:00
lthakur 2ef4dead24 [dtest] Update hipLaunchCoopMultiKernel.cpp (#1844)
used reinterpret_cast<uint32_t*> for numBlocks, as expected by hipOccupancyMaxActiveBlocksPerMultiprocessor() api.
2020-02-04 19:37:38 +05:30
gandryey 3c718ebe15 [dtest] RCCL multi device launch test (#1731)
Simple test for hipLaunchCooperativeKernelMultiDevice API.
2020-02-04 08:53:43 +05:30
satyanveshd 262ad13dd5 Match Occupancy APIs syntax with CUDA (#1625)
* Match Occupancy APIs syntax with CUDA and fix tests using these APIs
2020-01-29 13:05:53 -08:00
Evgeny Mankov ed43699a3a Merge pull request #1759 from emankov/master
[HIP] Unify hipError_t (Step 2)
2019-12-30 19:21:09 +03:00
Evgeny Mankov 4aaa2336a8 [HIP] Clean-up deprecated HIP error codes
hipErrorMemoryAllocation -> hipErrorOutOfMemory
hipErrorInitializationError -> hipErrorNotInitialized
hipErrorMapBufferObjectFailed -> hipErrorMapFailed
hipErrorInvalidResourceHandle -> hipErrorInvalidHandle
2019-12-23 17:01:35 +03:00
Alex Voicu 150e690a3a Fix late-coming issues. (#1724)
Implementation for hipMemcpyWithStream.
2019-12-23 19:11:24 +05:30
Vladislav Sytchenko a91bafca40 Add comments explaining choice on the cap for system memory on Windows. 2019-12-13 21:38:27 -05:00
Vladislav Sytchenko 4c21eed68b Add explicit cast when computing the available amount of system memory. 2019-12-13 21:37:30 -05:00
Vladislav Sytchenko 282367ed6d Reduce the amount of free host memory to 40% of what is reported on Windows, otherwise we can run into OOM situations. 2019-12-11 20:21:12 -05:00
Rahul Garg a369bd4418 Revert - Changes related to hipMemcpyWithStream (#1718)
Reverting #1673, #1697 and #1707.
Support for hipMemcpyWithStream and memcpy optimizations, will be brought in again once issues seen with these are resolved independently.
2019-12-06 09:51:53 +05:30
Rahul Garg 261a04580f Fix hipMemcpyWithStream (#1707)
* Fix hipMemcpyWithStream
* Add a dtest for the same.
2019-12-04 11:56:23 +05:30
Sarbojit2019 8a3c36a424 Revert [HIP] Fixed hipStreamAddCallback (#1674)
This reverts commit 97fca3439d.
Addresses SWDEV#212675.
2019-11-20 11:55:46 +05:30
Rahul Garg fa1335f419 [dtest] Rename hipExtLaunchMultiKernelMultiDevice dtest (#1671) 2019-11-19 09:41:13 -08:00
Alex Voicu 355d0bdf95 Add support for extended launch syntax. (#1530)
* Add support for extended launch syntax.

* Add unit test.

* Fix typo

* hipExtLaunchKernelGGL lives in hip_ext.h

Change-Id: Ice32dab0d43475fda65c6a910c11416871a8f2ff

* [dtest] remove redundant include from hipModuleGetGlobal dtest
2019-11-16 22:24:07 -08:00
Sarbojit2019 97fca3439d [HIP] Fixed hipStreamAddCallback [SWDEV#165185] (#1425)
Fixed hipStreamAddCallback() as requested in SWDEV#165185
Added unit test to test the behavior
2019-11-07 13:18:12 +05:30
Rahul Garg dfee3ae279 Rename hip/hip_hcc.h to hip/hip_ext.h (#1341)
* Rename hip/hip_hcc.h to hip/hip_ext.h

* Deprecate hip_hcc.h
2019-11-07 13:17:10 +05:30
Aryan Salmanpour 7a3d592ed0 [hip][tests] Add two more workgroup sizes for testing hipLaunchCooperativeKernel (#1613) 2019-11-05 12:32:46 +05:30
Rahul Garg 1bec1445bb Merge pull request #1582 from amd-lthakur/hipExtMLK
Adding a directed test case for hipExtModuleLaunchKernel() api.
2019-10-31 17:13:26 -07:00
Rahul Garg 07f4431de8 Formatting changes 2019-10-30 18:12:51 -07:00
Rahul Garg cd1435cbc7 Formatting changes ,variable name and check update 2019-10-30 18:09:21 -07:00
Rahul Garg 27221bc823 Revert "Fix occupany APIs (#1560)"
This reverts commit 6c5fbf9b4a.
2019-10-29 11:41:08 -07:00
amd-lthakur 626cd5d07a Excluded the test case for nvcc platform 2019-10-25 15:52:11 +05:30
Rahul Garg 66a3c874c8 [dtest] Fix hipMemset2D test (#1579)
Reverts changes made in #1399. This is a RT api test. For testing hipMemAllocPitch , a new test should be written and that should use correct memset API.
2019-10-25 15:44:05 +05:30
amd-lthakur b2238bacd4 Refactored the file as suggested 2019-10-25 10:44:38 +05:30
amd-lthakur 84fb936dfe Update matmul.cpp 2019-10-25 09:22:07 +05:30
amd-lthakur 9a860e6766 Update hipExtModuleLaunchKernel.cpp 2019-10-25 09:19:49 +05:30
satyanveshd 6c5fbf9b4a Fix occupany APIs (#1560)
Addresses SWDEV-205006
2019-10-24 17:44:47 +05:30
amd-lthakur 0adcc890b0 Adding a directed test case for hipExtModuleLaunchKernel() api. 2019-10-24 15:06:28 +05:30
Vladislav Sytchenko f4440817cb _aligned_malloc() on Windows first takes size, then alignment, which is the opposite of how the similar function behaves on Linux. Memory allocated by it also has to be freed using _aligned_free(), unlike Linux where we can use regular free().
Edit aligned_alloc() macro and add a aligned_free() one to align with the above behaviour.
2019-10-17 18:58:32 -04:00
Vladislav Sytchenko 86d0c5fa5a hipMemset2D and hipMemset3D tests should be passing by default. 2019-10-16 11:02:38 -04:00
Vladislav Sytchenko cc5abec092 In the hipMemset2D and hipMemset3D tests synchronize with the default stream after performing an async memset. 2019-10-15 17:15:49 -04:00
Vladislav Sytchenko f402b6d01a Update indentation in the hipMemset3D test. Replace all tabs with four spaces. 2019-10-15 15:29:14 -04:00
Vladislav Sytchenko c83b6adb33 Add async subtest to hipMemSet3D 2019-10-15 14:24:04 -04:00
Vladislav Sytchenko 39e42d4056 hipMemset2D test should pass only if both async and sync subtests pass. 2019-10-15 14:20:14 -04:00
ansurya 9bb22c4e0f Fix for directed tests failure (#1511)
directed_tests/runtimeApi/module/hipLaunchCooperativeKernel.tst - Disabling test temporarily until driver support is available.
directed_tests/runtimeApi/memory/hipArray.tst - Disabling test temporarily to reimplement it correctly.
2019-10-10 19:58:41 +05:30
ansurya 96890792b0 Added new Memory API's (#1399)
Added new memory API's hipMemAllocPitch, hipMemAllocHost, hipMemsetD16, hipMemsetD16Async, hipMemsetD8Async
Modified to support all scenarios hipMemcpyParam2DAsync, hipMemcpyParam2D.
2019-10-04 13:36:31 +05:30
AlexBinXie cda068edd5 [hip] Added gfx803,gfx1010,gfx1012 kernel binary hipModule test. (#1444)
This is to address hipModule test seg fault in GFX1010
2019-09-30 10:38:37 +05:30
AlexBinXie 313726a457 [hip]Skip test when hipHostMallocCoherent is not supported by implementation (#1380) 2019-09-16 08:31:43 +00:00
ansurya e2a934f377 Added new device attributes (#1377)
* Added new device attributes

* updated comment

* updated with new device attributes supported
2019-09-16 08:31:30 +00:00
Aryan Salmanpour 51c7fedd36 [hip][tests] add a unit test for testing hipLaunchCooperativeKernel (#1361)
* [hip][tests] add a unit test for testing hipLaunchCooperativeKernel

* use __ockl_grid_sync function

* remove already defined __ockl_grid_sync function

* use sync function for grid synchronization
2019-09-16 08:31:09 +00:00
Rahul Garg c741ad3c80 [dtests] refactor windows specific changes (#1313)
* [dtests] refactor windows specific changes

* Refactor hipMemoryAllocateCoherentDriver - PR- 1309

* Fix missing z in _putenv_s

* Revert "Fix missing z in _putenv_s"

This reverts commit 099a1b20a5c75c5f122d57c0ad2bca01745cdc9c.

* Refactor changes from PR 1299

* Update hipEnvVarDriver.cpp
2019-08-16 02:13:00 +00:00
amd-lthakur 19ad365834 [dtests] Fix build issues with hipMemoryAllocateCoherentDriver.cpp on windows (#1309)
Compilation error being observed due to popen(), pclose() and setenv() linux calls on windows. Replaced with appropriate calls on windows.
2019-08-09 11:53:16 +00:00
amd-lthakur 93f5940ef8 [dtests] Fix build issue with hipMemcpy_simple.cpp on windows (#1306)
Compilation error being observed on windows due to aligned_alloc() call. Mapped the call to _aligned_malloc() for windows.
2019-08-09 11:52:46 +00:00
wkwchau ed04e96e2d Added CooperativeLaunch and CooperativeMultiDeviceLaunch flag and property for hipDeviceGetAttribute() and hipGetDeviceProperties() (#1247) 2019-08-02 10:00:25 +00:00
wkwchau abe6776677 Added query of hipDeviceAttributeHdpMemFlushCntl and hipDeviceAttribu… (#1238)
* Added query of hipDeviceAttributeHdpMemFlushCntl and hipDeviceAttributeHdpRegFlushCntl

* Added NVCC blocker for the hip*FlushCntl test cases
2019-08-01 16:03:35 +00:00
wkwchau 7b9801fe9a Added support of hipOccupancyMaxActiveBlocksPerMultiprocessor & hipOc… (#1240)
* Added support of hipOccupancyMaxActiveBlocksPerMultiprocessor & hipOccupancyMaxActiveBlocksPerMultiprocessorWithFlags APIs

* Taking into account of SGPR usage to determine the max active blocks in hipOccupancyMaxActiveBlocksPerMultiprocessor()
2019-08-01 08:58:48 +00:00