Commit Graph

38 Commits

Author SHA1 Message Date
Patryk Wrobel 9b26e96b11 Do not copy std::vector of OS handles when it is not needed
This change replaces unneeded copying of std::vectors
with usage of const references. Furthermore, it adds
reserve() call before filling the container via push_back().

Signed-off-by: Patryk Wrobel <patryk.wrobel@intel.com>
2022-10-21 10:28:58 +02:00
Compute-Runtime-Validation 40ddeeb3ba Revert "Add support for USM shared in WSL for dGPU"
This reverts commit 1044a8aeee.

Signed-off-by: Compute-Runtime-Validation <compute-runtime-validation@intel.com>
2022-10-21 05:59:34 +02:00
Kamil Diedrich 1044a8aeee Add support for USM shared in WSL for dGPU
This patch force KMD allocation path for USM host allocation
and also for host part of USM shared allocation

Related-To: NEO-6913
Signed-off-by: Kamil Diedrich <kamil.diedrich@intel.com>
2022-10-20 11:26:24 +02:00
Compute-Runtime-Validation e744116bbb Revert "Add support for USM shared in WSL for dGPU"
This reverts commit 68d0523ccf.

Signed-off-by: Compute-Runtime-Validation <compute-runtime-validation@intel.com>
2022-10-19 05:05:55 +02:00
Kamil Diedrich 68d0523ccf Add support for USM shared in WSL for dGPU
This patch force KMD allocation path for USM host allocation
and also for host part of USM shared allocation


Related-To: NEO-6913
Signed-off-by: Kamil Diedrich <kamil.diedrich@intel.com>
2022-10-18 14:00:14 +02:00
Igor Venevtsev cb6db5672b Debugger L0 Win - register allocations metadata in debugger
Related-To: NEO-6764

Signed-off-by: Igor Venevtsev <igor.venevtsev@intel.com>
2022-06-22 17:22:15 +02:00
Maciej Plewka 213dc2fe24 Make CPU copy for read buffer when host ptr is write combined on DG2
With this commit on DG2 32bit driver will check if passed host ptr for
clEnqueueReadBuffer is write combined memory. If check will be true copy
will be make on CPU.

Signed-off-by: Maciej Plewka <maciej.plewka@intel.com>
2022-06-13 21:23:21 +02:00
Jaime Arteaga 3f26f45c10 Add support for IPC handles with implicit scaling
When using implicit scaling, device allocations may have
more than one internal allocation created internally. In that case,
a separate dma-buf handle per internal allocation needs to be
exported.

So introduced two driver experimental extensions to export and
import more than one IPC handle:

- zexMemGetIpcHandles
- zexMemOpenIpcHandles

Related-To: LOCI-2919

Signed-off-by: Jaime Arteaga <jaime.a.arteaga.molina@intel.com>
2022-05-09 00:38:17 +02:00
Jaime Arteaga a010fb3634 Dont close shared handle on imported allocations
Related-To: LOCI-2272

Signed-off-by: Jaime Arteaga <jaime.a.arteaga.molina@intel.com>
2022-03-06 04:35:47 +01:00
Bartosz Dunajski 4b0d986876 Move AllocationType enum out of GraphicsAllocation class
Signed-off-by: Bartosz Dunajski <bartosz.dunajski@intel.com>
2022-02-04 17:49:09 +01:00
Spruit, Neil R ae77bd1bd2 Enable Device Memory to be shared in WSL-2 with L0
- Add getMemoryManagerType to check which memory manager has been init
to determine if Linux + WDDM memory manager is in use.
- Add isNTHandle to test and verify if a handle is an NT handle during
L0 Open IPC Handle.

Signed-off-by: Spruit, Neil R <neil.r.spruit@intel.com>
2022-01-27 23:14:29 +01:00
Mateusz Jablonski 95610188af Fallback to cpu copy when filling work partition allocation
move some command stream receiver tests to shared

Related-To: NEO-6325
Signed-off-by: Mateusz Jablonski <mateusz.jablonski@intel.com>
2021-11-03 12:17:02 +01:00
Compute-Runtime-Validation 782a287b27 Revert "Fallback to cpu copy when filling work partition allocation"
This reverts commit 93e3d948f5.

Signed-off-by: Compute-Runtime-Validation <compute-runtime-validation@intel.com>
2021-10-29 04:39:22 +02:00
Mateusz Jablonski 93e3d948f5 Fallback to cpu copy when filling work partition allocation
move some command stream receiver tests to shared

Related-To: NEO-6325
Signed-off-by: Mateusz Jablonski <mateusz.jablonski@intel.com>
2021-10-28 14:30:00 +02:00
Jitendra Sharma f8c89fe984 Refactor memory manager so as to support device reset
Move out neoDevice dependent pieces of memory manager code into
separate methods. Those methods could be used for recreating a neoDevice
after a device reset is performed.

Related-To: LOCI-2615

Signed-off-by: Jitendra Sharma <jitendra.sharma@intel.com>
2021-10-19 07:16:29 +02:00
Kamil Diedrich 4390590831 Add shareable allocation for Windows
Signed-off-by: Kamil Diedrich <kamil.diedrich@intel.com>
2021-08-26 13:43:55 +02:00
Jaroslaw Chodor 766d56e300 WSL - fixing allocation alignment
Signed-off-by: Jaroslaw Chodor <jaroslaw.chodor@intel.com>
2021-08-20 08:28:27 +02:00
Dominik Dabek 2a7757651a Change percent of global memory returned
Related-To: NEO-5796

Signed-off-by: Dominik Dabek <dominik.dabek@intel.com>
2021-08-11 13:33:16 +02:00
Kamil Diedrich 2d5d071e66 Extended import device memory functionality
Signed-off-by: Kamil Diedrich <kamil.diedrich@intel.com>
2021-08-10 13:24:56 +02:00
Szymon Morek 74e6c74071 Disable shareable allocs with huge size
Signed-off-by: Szymon Morek <szymon.morek@intel.com>
2021-07-28 15:52:27 +02:00
Bartosz Dunajski 3c88492229 Revert "Extended import device memory"
This reverts commit ea6555e788c98314160a11898212c2d664999705.

Signed-off-by: Bartosz Dunajski <bartosz.dunajski@intel.com>
2021-07-16 09:56:52 +02:00
Jaroslaw Chodor 78499ca48d Mitigation for WDDM_LINUX allocation size limits
Signed-off-by: Jaroslaw Chodor <jaroslaw.chodor@intel.com>
2021-07-16 03:36:19 +02:00
Kamil Diedrich d5fdb949eb Extended import device memory
Signed-off-by: Kamil Diedrich <kamil.diedrich@intel.com>
2021-07-07 16:12:36 +02:00
Jaroslaw Chodor 1fa74b9b3c Changing sysmem allocation logic for WSL
Signed-off-by: Jaroslaw Chodor <jaroslaw.chodor@intel.com>
2021-06-29 16:03:28 +02:00
Jaime Arteaga 5e29dccddc Add IPC events support
Signed-off-by: Jaime Arteaga <jaime.a.arteaga.molina@intel.com>
2021-06-08 08:11:15 +02:00
lgotszal 3bd4bca911 Copyright header update
Dates corrected in copyright headers to reflect original publication date
(2018 for OpenCL, 2020 for Level Zero).

Signed-off-by: lgotszal <lukasz.gotszald@intel.com>
2021-05-17 20:38:19 +02:00
Katarzyna Cencelewska d9172c9b7f 1Mb alignment support in OsAgnostic path
Signed-off-by: Katarzyna Cencelewska <katarzyna.cencelewska@intel.com>
2021-03-10 10:56:25 +01:00
Bartosz Dunajski d35806fdd8 Improve returning global and max alloc memory size
Change-Id: I2f22481412184f01652b7e49bc30a57c56e6204b
Signed-off-by: Bartosz Dunajski <bartosz.dunajski@intel.com>
2020-10-30 15:58:42 +01:00
Bartosz Dunajski fb0651521d Linker: Fix incremental patching for local memory allocations
Change-Id: Ib85e4a2abc8a62477003853aa0c35f8107444f4e
Signed-off-by: Bartosz Dunajski <bartosz.dunajski@intel.com>
2020-10-09 09:13:42 +02:00
Jaime Arteaga 5c1e60208e Share USM host pointers among devices (2)
Dont pin and instantiate buffer objects associated with a USM
allocation for device >0 at allocation time, but instead, just
do a USERPTR ioctl, as with the allocation associated with
device 0.

Change-Id: Ib37f379df177d14e9d2781a3ed6335cd9550cc87
Signed-off: Jaime Arteaga <jaime.a.arteaga.molina@intel.com>
2020-09-04 12:10:06 +02:00
Koska 2a4af0b89b Adding handle verification
Change-Id: I46d6bd2dda46ace927cdfea5f47b0e614d5818f4
Signed-off-by: Koska <andrzej.koska@intel.com>
Related-To: NEO-4819
2020-08-06 16:36:39 +02:00
Mateusz Hoppe b3249c244b Make MemoryManager methods pure virtual
Related-To: NEO-4829

Change-Id: I97d0ef07bd26dac9869e61b5ff22064ea08596a8
Signed-off-by: Mateusz Hoppe <mateusz.hoppe@intel.com>
2020-07-08 12:00:09 +02:00
Igor Venevtsev 1f63f39d77 Pass preferred GPU virtual address to mapMultiHandleAllocationWithRetry()
Related-To: NEO-4479

Change-Id: I4591b013e3c9bf459e944c34f3617aaa11a66baf
Signed-off-by: Igor Venevtsev <igor.venevtsev@intel.com>
2020-07-07 08:58:58 +02:00
Bartosz Dunajski 6dd07bd3bc Use correct Heap32 index for local memory allocations
Change-Id: I068f712ab2b05ee3d5a9716b21de685a7fee3a02
Signed-off-by: Bartosz Dunajski <bartosz.dunajski@intel.com>
2020-07-01 17:31:43 +02:00
Igor Venevtsev 3859e13322 Split large allocations on Windows due to Wddm limitation
Resolves: NEO-4479

Change-Id: Iffb862a93570a60c2126620d9e5106359acba64a
Signed-off-by: Igor Venevtsev <igor.venevtsev@intel.com>
2020-06-17 12:47:54 +02:00
Michal Mrozek 490e9e666b Add wddm implementation for detection whether cpu copy is required.
Change-Id: Ia8dbd38b2e701bf56148785815599e15f4711b66
Signed-off-by: Michal Mrozek <michal.mrozek@intel.com>
2020-03-11 13:15:02 +01:00
Mateusz Jablonski 7df9945ebe Add absolute include paths
Change-Id: I67a6919bbbff1d30c7d6cdb257b41c87bad51e7f
Signed-off-by: Mateusz Jablonski <mateusz.jablonski@intel.com>
2020-02-23 23:49:12 +01:00
kamdiedrich e072275ae6 Reorganization directory structure [3/n]
Change-Id: If3dfa3f6007f8810a6a1ae1a4f0c7da38544648d
2020-02-23 23:48:28 +01:00