- move _av into stream critical section. ( HCC accelerator_view is not
thread-safe but HIP steram is. )
- Refactored many places in code that need to acquire critical section.
some were previously thread races, ie enqueueing marker.
-remove support for GRID_LAUNCH_VERSION < 20
-Enable USE_AV_COPY based on HCC work-week.
- Review hipModule docs, some calrity/editing.
Change-Id: I3ce7c25ece048c3504f55ecd4683e506bb1fc8b6
- Added cuda and cudart linking for nvcc path in hipcc
- Added hipMemcpyHtoD and hipMemcpyDtoH for nvcc path
- Changed hipDeviceptr to hipDeviceptr_t
- Fixed hipMemcpy*to* API signatues
Change-Id: I6ef076b507f92502efda475c83dcdcdd462afc37
Change ihipDevice_t -> ihipCtx_t (new)
Change ihipGetTlsDefaultDevice->ihipGetTlsDefaultCtx
Some other changes from device->ctx where appropriate.
Change-Id: I5c4ae93b2fd42c6303aa23d748eb166b7431925d
- stubs and documentation in include/hcc_details/hip_runtime.h
- stubs with "no-op" in src/hip_memory.cpp
- document update in hip_kernel_language.md, add suggestions to
disable L1 and L2 caches when using the threadfence routines.
Change-Id: Ic0753170f802003055bca9d7476d7f48817b98b7
- Complete translation tables for cudaError <-> hipError_t.
- Remove some odd errors that were not correctly translated or not used.
- Add HIPCHECK_API to test infrastructure. Used for negative testing
an API ; if a mismatch occurs it shows the expected return error
code. Can also print a warning rather than error.
- Enable hipMemoryAllocate on NV system, and review error coded.
- Add hipErrorName to nvcc.
Change-Id: I680427dcf32a5796d5913cf9e7f3b4c6f6b91599
Conflicts:
tests/src/CMakeLists.txt
Bug fixes and improved docs for hipFree and hipHostFree.
- Passing NULL pointer initialized runtime and return hipSuccess
(not an error like before).
- add negative test for this. (hipMemoryAllocate, improved)
- Match NVCC errors for invalid pointers, add to test.
- Update hipFree and hipHostFree docs.
- hipGetDevicePointer always set *devicePointer=NULL, even for
invalid flags.
- Gate shared memory usage on specific HCC work-week.
Change-Id: I533b4fd3280a3d6cdbf05eb768976f0c7506c012
- devicereset would lose track of default stream and thus subsequent
synchronization calls might not actually sychronize.
- Also deviceReset now correctly frees streams.
- fix waits in P2P staging copy - first phase (Device0-to-Staging) must
wait for second phase (Staging to Device1) to finish draining the
buffer.
- set USE_PEER_TO_PEER=3 (requires HCC "am_memtracker_update_peers")
- when enabling peer, turn it on for previously allocated memory.
- hipDeviceCanAccessPeer is no longer self-ware (self does not qualify
as a peer)
- device peerlist always includes self, so when we call allow_access
we never remove self access.
- hipDeviceReset() removes old peer mappings.
introduce LockedAccessor option so destructor does not unlock.
Allows locks to exist across function boundaries, required
for hipLaunchKernel macro which has several unusual requirements.
(including C comppatibility, must use variadic macro, more).
Move critical data into separate class and protect with LockAccessor
wrapper class.
For device, the streams list is the critical data since it is modified when
streams are created or destroyed. The streams list is accessed in
several places including when synchronizing across all streams on the
device (ie from the default stream).
Other device data is set once by the device cosntructor and is not critical
so
All functions which acquire the LockAccessor now named with "locked_" prefix.