Commit Graph

16 Commits

Author SHA1 Message Date
German 1a0c3e4dc4 SWDEV-311270 - Add IPC support for memory pools
Initial implementation for hipMemPoolExportToShareableHandle,
hipMemPoolImportFromShareableHandle,
hipMemPoolExportPointer and hipMemPoolImportPointer

Change-Id: I0ebdc48e9163b394ded560adca6c38bbc5aee7d1
2023-06-15 11:36:52 -04:00
German 04b696abee SWDEV-353281 - VM support in mempool for graphs
The change enables VM support in graphs on Windows. That allows
to avoid caching of all allocations at the cost of map/unmap
overhead during memory create/destroy.

Change-Id: I792be00fba099e5e5d3cd44a963e1dfd6976a86d
2023-05-05 15:31:26 -04:00
Ioannis Assiouras db9d9faaeb SWDEV-389611 - Changed hipMallocAsync to return success for zero size allocation to match hipMalloc
Change-Id: Ia2cbfaf2df9be37b62f23b2bb5b619205752ba84
2023-04-05 10:56:51 +00:00
Ioannis Assiouras 06927fd3c1 SWDEV-381402 - Remove unused getNullStream() from device. Make stream destructor private.
Change-Id: Idde30a8bfe97a525bd9f9fb50698a5cb14b798fc
2023-02-24 10:42:46 +00:00
German Andryeyev eef47ca24a SWDEV-353281 - Initial support of memalloc in graph
Add memory allocation support in graph. Current implementation uses
cache from mempool  to hold the allocations which belong to the graph.
Also the resource tracking is disabled at this moment because mempool
operates with hip::Stream objects, but graph has execution with
amd::HostQueue objects.

Change-Id: I54fe3250126d24f5a26ada975f37d429bb4ef17b
2023-01-13 13:06:59 -05:00
sdashmiz 33f02abc41 SWDEV-356569 - check for mempool device
- mem pool should be from same device

Signed-off-by: sdashmiz <shadi.dashmiz@amd.com>
Change-Id: Id06a7f070c019548462c235bff3c0cd972e6eb8a
2022-11-04 09:36:22 -04:00
pghafari 88c399a43d SWDEV-356570, SWDEV-356571, SWDEV-356572, SWDEV-356575 -
updating with current status of hipNotSupported and null checks

Change-Id: I3b1ce3d3e5ce9b69d1f5dacda35f5aa586714f5c
2022-10-11 23:45:27 -04:00
pghafari 42b5a6d5af SWDEV-356554 - updated hipDeviceGetDefaultMemPool
updated the error check/messages

Change-Id: I518d497a82a14862d5168cc423aeaa20075336b8
2022-09-20 16:42:48 -04:00
sdashmiz 58c5e17c5f SWDEV-347595 - return proper error
- if flags are not supported

Signed-off-by: sdashmiz <shadi.dashmiz@amd.com>
Change-Id: Id7570d2c5f3d1169da33561f05c278dcd1834db6
2022-08-04 15:57:15 -04:00
Jaydeep Patel 465421e71c SWDEV-347592 - hipMemAllocationType must be hipMemAllocationTypePinned.
Change-Id: I36a5c37c6d66587c6804b60a5f0a88efb60801a4
2022-07-26 23:46:02 -04:00
Jaydeep Patel 0fed29f77c SWDEV-347592 - validate hipMemAllocationType & hipMemLocationType
Change-Id: Ia8c4d3edc7ad96efa429b3530a118199d4f92902
2022-07-25 23:56:20 -04:00
German Andryeyev ff23c5b716 SWDEV-311271 - Avoid a crash with the default queue
Move device access after the queue look-up

Change-Id: I799f23ff0299b20437c9a8edae42c38daa3e9ceb
2022-07-12 17:01:06 -04:00
Ajay 36a85741de SWDEV-344440 SWDEV-344433 - null ptr checks for hipMemPoolGetAttribute hipMemPoolSetAttribute
Change-Id: I812abb3c74a05c4ec9097b09ee7e9a86b0c91e9b
2022-07-05 18:42:34 +00:00
German Andryeyev 8b132beb92 SWDEV-311271 - Enable MGPU support for memory pool
Change-Id: I36850de282d62139b5cfe342df97bb1204cb7869
2022-05-11 11:04:24 -04:00
German Andryeyev 5957ff9f7b SWDEV-311271 - Make sure memory pool can accept default stream
Add lock protection for access to the pool list.
Remove destroyed stream from the list of the safe streams

Change-Id: I1863b89bd3f5e188c161227cc790c3adaf72cc58
2022-04-18 10:34:21 -04:00
German Andryeyev 539d264eb0 SWDEV-311271 - Initial mempool implementation
HIP_MEM_POOL_SUPPORT controls memory pool support in runtime.
Currently it's disabled by default. The initial change doesn't
include: IPC, MGPU, virtual memory alloc, suballoc, defragmentation,
internal dependencies.

Change-Id: Ibed8528ebec698b045ebb247e49c0ecd6e587ed7
2022-03-31 09:21:37 -04:00