Commit Graph

887 Commits

Author SHA1 Message Date
Rahul Garg 8d254a7113 Updated context management logic:
1) hipSetDevice sets a flag so that next call to hipCtxGetCurrent returns primary context on current device
2) hipCtxGetCurrent returns primary context on current device if TLS context stack is empty
3) hipCtxPopCurrent falls back to primary context on current device as default
4) hipCtxPushCurrent, hipCtxSetCurrent and hipCtxCreate reset the flag set in hipSetDevice


[ROCm/hip commit: 3e84cf4aba]
2017-08-08 07:02:22 +05:30
Siu Chi Chan 21c1d69e77 implement __threadfence_system
[ROCm/hip commit: 96e79f97e2]
2017-08-02 08:50:18 +00:00
Maneesh Gupta e7c823b4ed Merge pull request #134 from gargrahul/fix_hipMemcpy2DAsync
fix hipMemcpy2DAsync

[ROCm/hip commit: fce1d0d7f0]
2017-07-31 10:27:18 +05:30
Maneesh Gupta 1be0719063 Merge pull request #135 from bensander/fix_tracing
Some fixes to tracing.

[ROCm/hip commit: 48573a037e]
2017-07-31 10:24:41 +05:30
Ben Sander 4a234edea9 Some fixes to tracing.
[ROCm/hip commit: ecbb494a58]
2017-07-28 22:13:43 -05:00
Rahul Garg 7e9c13f8de fix hipMemcpy2DAsync
[ROCm/hip commit: 0053e4db03]
2017-07-29 06:50:56 +05:30
Maneesh Gupta b763034c65 Merge pull request #127 from bensander/pass_module_kname
Pass kernel name to HCC dispatch_hsa_kernel, for debug/profile

[ROCm/hip commit: 375ec84bc6]
2017-07-28 10:19:15 +05:30
Ben Sander 1ff23db17b Add workweek check to make sure we have a new enough compiler
[ROCm/hip commit: 4980a6d3ab]
2017-07-27 23:00:58 -05:00
Maneesh Gupta 90fa6b18eb Merge pull request #122 from bensander/enable_async_null_stream
Set HIP_SYNC_NULL_STREAM=0.

[ROCm/hip commit: fcc294ed41]
2017-07-28 09:15:56 +05:30
Ben Sander 3ab70ad042 Pass kernel name to HCC dispatch_hsa_kernel, for debug/profile
[ROCm/hip commit: 3a4dfc0f85]
2017-07-27 22:00:15 -05:00
Ben Sander cba82d9e24 Set HIP_SYNC_NULL_STREAM=0.
Optimizes null stream synchronization so it uses GPU-side dependency
resolution. Requires HCC __hcc_workweek__ > 17300.


[ROCm/hip commit: 77fb9893b4]
2017-07-27 11:11:54 -05:00
Maneesh Gupta da4042554f Merge pull request #116 from bensander/enable_coh_host
Make host memory allocations coherent by default.

[ROCm/hip commit: 526fcb1223]
2017-07-27 10:45:32 +05:30
Ben Sander 9ec4b0b66f Merge pull request #100 from weixingzhang/texture
HIP Texture Support

[ROCm/hip commit: 4f93b99f23]
2017-07-26 19:28:15 -05:00
Ben Sander 6834270f15 Make host memory allocations coherent by default.
Associated change is to optimize event recording so it uses
agent-scope releaes (since it was only using system-scope release
to support non-coherent host mem).

Flags and environment variables exist to obtain previous behavior
if desired.  Options are documented in new performance guide.


[ROCm/hip commit: 8b8e97ff28]
2017-07-26 19:20:34 -05:00
Ben Sander 149ec02e84 Enable HCC_OPT_FLUSH=1 (if HCC compiler new enough)
[ROCm/hip commit: 67f5d2de3d]
2017-07-24 18:57:19 -05:00
Maneesh Gupta f4ca1c96c4 Don't crash for hipEventDestroy(NULL)
Change-Id: I3f4de1ad2712dbe8af81e10c5d3bef16d468c582


[ROCm/hip commit: 7ddb6b6b76]
2017-07-18 11:01:02 +05:30
Weixing Zhang 65bec11393 HIP Texture Support
[ROCm/hip commit: e671cec367]
2017-07-17 15:16:12 -04:00
Maneesh Gupta ee697e8c4c remove unsupported erf(c)inv related host functionality
Change-Id: I665c33616359a0124b5552076359d2f8faa54930


[ROCm/hip commit: 7066ff4478]
2017-07-14 11:31:40 +05:30
Wen-Heng (Jack) Chung a80bc4c3b6 Temporarily disables HCC_OPT_FLUSH
Change-Id: I290791e58dd52ab3823f6c3315e42b0d386e9d64


[ROCm/hip commit: 17555eabc0]
2017-07-12 16:08:36 +00:00
Wen-Heng (Jack) Chung a4d39f50a1 Fix hip_db header inclusion path
Change-Id: I8a95798301de73887dde3316dc593a1847002712


[ROCm/hip commit: 35ebfda9d4]
2017-07-12 16:08:20 +00:00
Wen-Heng (Jack) Chung f28a1365f8 Remove explicit address spaces declarations
[ROCm/hip commit: 30ee797dd4]
2017-07-07 12:46:29 -05:00
Ben Sander 042ed2c38f Add hipdbPrintMem - wrapper for hcc memory tracker.
[ROCm/hip commit: 0459f3db72]
2017-07-03 15:05:30 -05:00
Rahul Garg 9498754cf6 Fixed build error in hipDeviceGetByPCIBusId
Change-Id: I33be362910c4c5dca7435fb9c41f427b54f0e9a7


[ROCm/hip commit: 34fcaa23bb]
2017-07-01 07:56:30 +05:30
Ben Sander ba0215ad9f Set default HIP_SYNC_NULL_STREAM=1.
[ROCm/hip commit: 626b5191e8]
2017-06-30 19:01:14 -05:00
Rahul Garg 83f3ed16de Fixed hipDeviceGetByPCIBusId
Change-Id: Ia36bb9425671ef7659541c9aeedae4098456a31b


[ROCm/hip commit: 65cb024b61]
2017-06-30 10:11:41 +05:30
Aditya Atluri f7bfec2252 automate gcnarch detection
Change-Id: Ibbad22db136f7f5e2be84c82e9169298a144cc77


[ROCm/hip commit: 3e610ab0fe]
2017-06-29 12:01:40 -05:00
Rahul Garg ff48608355 Fixed hipDeviceGetPCIBusId for HIP/HCC
Change-Id: I3688fa2476e1baada2d3c5fc3735cec3f15a1e21


[ROCm/hip commit: f4ea3b76c8]
2017-06-28 23:48:27 +05:30
Ben Sander 3ba979d2b7 Set default HIP_HIDDEN_FREE_MEM
[ROCm/hip commit: 148dbc1027]
2017-06-27 12:17:12 -05:00
Sun, Peng 84fbc3dfaa Add support of HIP_HIDDEN_FREE_MEM, to deduct the returned available
memory from hipMemGetInfo API, measured in MB.

Change-Id: I7a8260c12e032e04e26611db4c38c893a29f2653


[ROCm/hip commit: 1df08626c8]
2017-06-26 15:29:38 -05:00
Ben Sander 0f2fd1372f Add option to pass names to HCC dispatch API (for debug)
[ROCm/hip commit: 176ff824d1]
2017-06-23 18:05:30 -05:00
Ben Sander ed1f242c60 Clean up old USE_* and RELEASE.md notes.
[ROCm/hip commit: 7912e61502]
2017-06-23 18:05:30 -05:00
Rahul Garg 3cb1061f65 Abort device function in HIP/HCC, need new HCC
Change-Id: I4195ab75e9b7b48c8b8128d6925ddc0fa5e9e009


[ROCm/hip commit: 3c73229916]
2017-06-18 12:31:31 +05:30
Aditya Atluri f76e9f4640 fixed float2int functions
Change-Id: I67be79149f06daacf0f0d131bdedabf294126248


[ROCm/hip commit: d1e28df226]
2017-06-16 09:07:06 -05:00
Rahul Garg 74e3617ef8 Arguments validation in hipDeviceGetPCIBusId
Change-Id: I89770517c3ac94e4bf476344d27c18f03cfcde08


[ROCm/hip commit: d24818bff6]
2017-06-15 00:21:47 +05:30
Rahul Garg a8a8b2c888 Validity check of input arguments in Ipc Mem APIs
Change-Id: Ia48e949d19f354f10c7e44cc2457fd4154bf6d76


[ROCm/hip commit: ba51d7f676]
2017-06-14 15:18:57 +05:30
Rahul Garg 0e4dbe0b2f Input args NULL check in hipChooseDevice
Change-Id: I1a7b8cded2f81d739645bbf3dab2f04bb9c3c796


[ROCm/hip commit: a833b9a704]
2017-06-13 13:35:50 +05:30
Sun, Peng 47921e39d2 Fix error related to undefined reference of __get_dynamicgroupbaseptr().
Change-Id: I14951e1725e35dd5f5e53805f81cdb58661f59f2


[ROCm/hip commit: 43df5ba660]
2017-06-08 19:24:32 -05:00
Ben Sander ef7c9be9c6 Use amHostCoherentFlag. Requires new HCC version.
[ROCm/hip commit: 99e9c7cca5]
2017-06-07 09:06:40 -05:00
Ben Sander 1d1e50fa77 Enable HCC_OPT_FLUSH=1.
Requires appropriate HCC with this support   :
commit 38e392b517a46a09a3b1c8f388e6a0db3741c510


[ROCm/hip commit: ac634bf334]
2017-06-07 00:15:05 -05:00
Ben Sander 65f91dbb0d Enable HIP_SYNC_NULL_STREAM=0 optimization.
[ROCm/hip commit: decf3eee18]
2017-06-05 08:50:41 -05:00
Ben Sander 445042f916 Fix HIP_SYNC_NULL_STREAM=0 mode.
- Fix null-stream sync
- hipStreamDestroy of null stream returns hipErrorInvalidResourceHandle
- Update documentation.
- Add tests for null stream sync, hipEventElapsedTime.
- Rename internal enum hipEventStatusRecorded to hipEventStatusComplete
- refactor hipStreamWaitEvent to streamline control-flow


[ROCm/hip commit: 39c18e5e5f]
2017-06-05 08:50:22 -05:00
Ben Sander a1bdd5f585 Update tests, add p2p coherency test.
[ROCm/hip commit: d5c1616324]
2017-06-03 17:11:34 -05:00
Siu Chi Chan cc54bc4d85 fix atomicCAS:remove load for the return value after CAS
[ROCm/hip commit: 741eb844fe]
2017-05-31 15:20:19 -04:00
Ben Sander 59833bea80 Set event->_stream on hipHccModuleLaunchKernel path if start/stop used
Ensure _stream is always non-null in recorded events.
Fixes isDefaultStream fault.


[ROCm/hip commit: cb60763737]
2017-05-30 21:55:46 -05:00
Maneesh Gupta 56bf96c6df Disable normcdfinvf on __host__
Change-Id: If7bfc9826a09eb9b7675ea2a417b9418759b7912


[ROCm/hip commit: 4ff01c971f]
2017-05-30 15:45:22 +05:30
Ben Sander b3e01ed74f Add event controls for release fences.
Env var : HIP_EVENT_SYS_RELEASE
Event allocation flags : hipEventReleaseToDevice, hipEventReleaseToSystem
   (remove hipEventDisableSystemRelease)

Update test for new functionality.


[ROCm/hip commit: ec7102f461]
2017-05-27 16:02:34 -05:00
Ben Sander e24627aa80 Cleanup hipEvent. (Intermediate checkpoint)
Support hipEventDisableSystemRelease flag.
Update test.
Remove stray printf


[ROCm/hip commit: 620eb30691]
2017-05-27 16:02:34 -05:00
Ben Sander 715aeef97c Add isDefaultStream() accessor.
Fix code that checked for stream==nullptr after stream had been
resolved to a "true stream".


[ROCm/hip commit: b251d72917]
2017-05-26 13:46:48 -05:00
Siu Chi Chan ef1a8c2788 fix hip_fast_dsqrt* to call a double fp sqrt function
[ROCm/hip commit: 1dce01f9bb]
2017-05-25 23:15:30 -04:00
Ben Sander b7b7c7b7ac Remove HIP_NUM_KERNELS_INFLIGHT. (redundant with HCC controls)
[ROCm/hip commit: 578d430bb3]
2017-05-24 01:03:28 -05:00