Граф коммитов

16 Коммитов

Автор SHA1 Сообщение Дата
Maneesh Gupta bbfc08f419 Move include/* to include/hip/*
Change-Id: I7a7b2839b4df59c7a4c503550f99fdc9e45c0f54
2016-10-04 22:17:18 +05:30
Ben Sander 60f797cc5a Remove USE_AV_COPY, USE_PEER_TO_PEER fallback paths.
Change-Id: I9c20173e62029c4caebabc98784c6d7697758e4f
2016-09-22 14:21:19 -05:00
Ben Sander fd67689114 Add hipStreamQuery
Change-Id: Ib0813b1065feba4fe9ae861d24cfc6f9c5f580be
2016-09-07 15:18:34 -05:00
Ben Sander 3c90766c70 remove printf
Change-Id: I36510a7ff0425f05a6d0b9c65cda4397c9cc2d95
2016-09-02 17:50:31 -05:00
Ben Sander 8e883ab666 hipStreamWaitEvent update.
Add passed to hipStreamWaitEvent test.
Fix pointerAttrib test to work with new and old HCC versions.
Minor code touchup.

Change-Id: I139ba6ce9f6bf2b4bee89aebdec5981b4346ffc0
2016-09-02 09:46:59 -05:00
Ben Sander 9a99000a62 Use create_blocking_marker for WaitEvent implementation
Change-Id: Ib3113f69a14e48b9fe0558d7b455148e478d8eed
2016-09-02 09:46:59 -05:00
Ben Sander 02f65a483c Refactor for stream->_av.
- 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
2016-09-02 09:46:59 -05:00
Ben Sander d09b19bb6c Split ihipCtx_t into ihipCtx_t and ihipDevice_t .
Major change to existing code base.
    Ctx holds streams, enables peers, and flags.
    Device holds accelerator, hsa-agent, device props.

Add hipCtx_t.

Add peer APIs that accept hipCtx_t (in addition to deviceId)

Compiles and passes directed tests.

Change-Id: Iddab1eb9edbf90caad2ef5959c6b811d658197f1
2016-08-08 11:55:57 -05:00
Ben Sander 0d16565061 Change Device->Ctx
Change ihipDevice_t -> ihipCtx_t (new)
Change ihipGetTlsDefaultDevice->ihipGetTlsDefaultCtx
Some other changes from device->ctx where appropriate.

Change-Id: I5c4ae93b2fd42c6303aa23d748eb166b7431925d
2016-08-07 21:47:12 -05:00
Ben Sander 6cab7862ae Stream thread-safe checkpoint.
Moving data structures to critical / protected section.
2016-03-28 09:46:40 -05:00
Ben Sander 82f57ca610 Improve debug print messages.
- Remove "call-to-call" for hipStreamCreate and hipEventCreate.
  These now call an internal functions rather than calling through
  hipStreamCreateWithFalgs and hipEventCreateWithFlags.

- Add HIP_INIT_API for more functions so they trace correctly.

- Use stream#DEVICE.STREAMID in debug messages via new specialization in
  tace_helper.
2016-03-26 12:35:04 -05:00
Ben Sander c47b5b04ef Protect _stream_id as well.
- move lockedaccessor
- clean up device class.
- add simple ihipDevice constructor.
2016-03-26 11:45:25 -05:00
Ben Sander 4dd77c6612 Make ihipDevice_t thread-safe.
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.
2016-03-26 10:46:20 -05:00
Aditya Atluri eea49cb66b added CR and hipsetdeviceflags func 2016-03-24 07:04:01 -05:00
Aditya Atluri 1c55019322 Split files based on functionality and changed cmake file 2016-03-24 04:57:30 -05:00
Ben Sander e52c3d9fe0 Partition hip_hcc into sections
Separate files for different categories of HIP API.
Currently just #include into hip_hcc.cpp
2016-03-24 09:28:54 -05:00