Hoppe, Mateusz
55a045ebe1
Refactor graphics memory allocation scheme
...
- replace createGraphicsAllocationWithRequiredBitness with more general
methodallocateGraphicsMemoryInPreferredPool based on passed
AllocationData
- proper flags for allocation selected based on AllocationType
- remove allocateGraphicsMemory(size_t size, size_t alignment)
and use allocateGraphicsMemory(size_t size) instead where default
alignment is sufficient, otherwise use full options version:
allocateGraphicsMemory(size_t size, size_t alignment,
bool forcePin, bool uncacheable)
Change-Id: I2da891f372ee181253cb840568a61b33c0d71fc9
2018-07-11 15:48:05 +02:00
Dunajski, Bartosz
e26d67cde3
Aux surface programming for Buffers [1/n]: Gmm interface improvement
...
Change-Id: I984b8ebee27808a236217e82bb4e910550d624c4
2018-07-03 13:00:08 +02:00
Kamil Diedrich
784ddf0a6c
cleanup dead code, readability fixes
...
Change-Id: I91a3947d4ec0ef2264afed5abc58ff66151f0dc6
2018-07-02 12:50:15 +02:00
Koska, Andrzej
3548876263
Setting the GpuAddress from a fragment in createGraphicsAllocation
...
Change-Id: I4d60aceea96dfbe50b2af4a1fbaada6a150ddd35
2018-06-29 16:13:29 +02:00
Dunajski, Bartosz
e18e9fb94e
Move static methods from Gmm to new GmmHelper class
...
Change-Id: I84fbe94f0e1072324164086b456c71a46ae5040c
2018-06-27 16:46:09 +02:00
Koska, Andrzej
4a4ad6460c
Revert: Setting the GpuAddress from a fragment in createGraphicsAllocation
...
Change-Id: Ifd0a26f58b748df5e43e57b4e0be6b94c2051890
2018-06-26 17:05:26 +02:00
Koska, Andrzej
b563e07394
Setting the GpuAddress from a fragment in createGraphicsAllocation
...
Change-Id: I4f6afbdd4d86ab2958de29cf49aaed9b8e2ea642
2018-06-26 14:43:08 +02:00
Koska, Andrzej
e15c2b899f
Setting the right handle value in fragment
...
Change-Id: Idcbdce5fc686360f252c8db0423ae77d9155702e
2018-06-15 16:36:52 +02:00
Koska, Andrzej
fe56c57318
Tracking the internal allocation when creating a buffer
...
This fix prevents the creation of a buffer from the pointer
obtained from clEnqueueMapBuffer
Change-Id: I203f2d5263eeb02fe0d73bc9db159438af3cf1fc
2018-06-08 07:33:07 +02:00
Mrozek, Michal
d2817427af
Remove createInternalGraphicsAllocation function.
...
- Route directly to allocate32BitGraphicsMemory
Change-Id: Ia6872bae655c530ff06b0ec270f419ca91d005ce
2018-05-21 04:11:43 +02:00
Hoppe, Mateusz
baa7640c90
Rename MemoryType enum to AllocationOrigin
...
- better describes the meaning of INTERNAL and
EXTERNAL allocation types
Change-Id: Iacb97f5a9d63f45b60bc404cc6dd32c7ebd72ab3
2018-05-14 12:38:52 +02:00
Dunajski, Bartosz
bab9ad6cda
Wddm interface [3/n]: Improve constructing Wddm object
...
- Only Wddm object owns Gdi
- Dont pass Gdi object to constructor
- Move Wddm related files to new directory
Change-Id: Iadd26634c7692db760d7d3367211c32d2c2c8121
2018-05-10 17:14:25 +02:00
Dunajski, Bartosz
44e54ef69b
Wddm interface [2/n]: Move WddmMock to igdrcl_mocks + more cleanup
...
Change-Id: I993312c1e17fb474e142424b154666f8af6a4170
2018-05-08 15:57:38 +02:00
Hoppe, Mateusz
aa088da8d3
User pointer read-only memory fix
...
- do not store fragment in map until hostPointerValidation
is done
- set pointers to nullptr after delete in cleanOsHandles
Change-Id: I0bf99c3215c4b91ce059bb4e94716671c49f1946
2018-03-28 12:42:31 +02:00
Hoppe, Mateusz
ed30f6e55f
Read-only memory allocations handling in Wddm
...
- return InvalidHostPointer when createallocation
fails with NO_VIDEO_MEMORY
Change-Id: I6946eeb04d3a191550478e1d26a6ce0c32b75c34
2018-03-23 14:30:00 +01:00
Woloszyn, Wojciech
0ad81024b7
Implement cl_khr_mipmap_image [1/n]
...
- Add mipmap image handling for clEnqueueReadImage, clEnqueueWriteImage
- Fix mipmap image handling for clCreateImage
Change-Id: I42938a330b55c7e69a16c26dce3ab5d66f8a8938
2018-03-21 10:51:13 +01:00
Hoppe, Mateusz
a1a20a3b34
Service read only memory passed as host_ptr
...
- read only memory cannot be used for allocation,
Oses cannot create graphics alocation for such memory
- if memory allocation fails for host_ptr passed
to enqueueWrite calls, then try doing new allocation
and copy host_ptr on cpu
Change-Id: I415a4673ae1319ea8f77e53bd8fba7489fe85218
2018-03-14 13:16:36 +01:00
Mrozek, Michal
2119d5db08
[13/n] Internal 4GB allocator.
...
- Add common function for all memory managers to obtain internal heap base.
Change-Id: Iacdaaf598e8786dad046b3f4550f9c80ce3f15d9
2018-03-12 16:19:24 +01:00
Mrozek, Michal
8254d6a081
Ensure that submissions are flushed prior to csr destruction.
...
Change-Id: Ie04de561d3d295f40f55a19f01274d873d259abd
2018-03-12 12:54:47 +01:00
Mrozek, Michal
3d139c204e
Remove unrecoverable.
...
Change-Id: I4f8db72668d8d36a68f46a591ee0823b35e41fb7
2018-03-09 16:20:28 +01:00
Artur Harasimiuk
12b7c551d8
use ADAPTER_INFO in one method only
...
size of structure can vary. Create single point of conversion to extract
required data and store them in Neo specific structures.
Change-Id: I822ec633014aa7394cbd626ecbc275e32e61cf60
2018-03-09 12:30:05 +01:00
Woloszyn, Wojciech
5c8cd51fc8
Use allocateGraphicsMemoryForImage for mipmaps
...
Change-Id: I0cd740ca4c8286fb73f766b74abc50ed53cfc9d0
2018-03-01 20:39:15 +01:00
Dunajski, Bartosz
d9dd68a8ef
Remove copy constructor for GraphicsAllocation
...
Change-Id: If547a004b6f9e5cadb1f6ba0a0f44c3ac0d1ff0d
2018-03-01 14:00:24 +01:00
Mrozek, Michal
19c68a608f
[1/n] Internal 4GB allocator
...
- Add new entry point in memory manager for internal allocations.
- Route to allocate32BitGraphicsMemory
- Add new enum to control memory region
- Change mm to memoryManager
Change-Id: I2ee069aa9baf7f69f652022e026569ec4fdb9d77
2018-02-27 16:35:12 +01:00
Zdanowicz, Zbigniew
a1db4ddd7a
Retry Wddm mapGPUVA after failure when deferred deleter is set
...
mapGPUVA will fail when allocation is still in deferred deleter and using
the same base pointer to map, while there is no reserveGPUVA for SVM range.
In that case driver should drain deleter and retry mapGPUVA call
Change-Id: I4ded7d79e0cd935ec62d7fae785d66570c847535
2018-02-08 10:28:40 +01:00
Zdanowicz, Zbigniew
292f8fae90
Use alignedSize for map range and to calculate trim budget
...
Change-Id: Iceaf5c1d7fd1abfa6bdb08c97a439dba3bbccdf4
2018-02-01 19:20:27 +01:00
Zdanowicz, Zbigniew
bf270c4643
Use reserved memory to map GPU VA when cpu memory doesnt meet restrictions
...
Change-Id: I9f255a3f2ce6b1c22110e7da6e90c013f1f598e6
2018-01-31 18:05:11 +01:00
Zdanowicz, Zbigniew
e42d43953d
Restrict system memory allocations to certain address range
...
Change-Id: Ibe8c1183368ce48f2c820d0f1a71f0b15703ffcd
2018-01-26 15:16:41 +01:00
Dunajski, Bartosz
3532c6373f
D3D sharable 2D texture: Map Aux GpuVa and set renderCompressed if possible
...
Change-Id: I508965d07f456af74ecef6e980337f42f5967b43
2018-01-26 08:38:59 +01:00
Zdanowicz, Zbigniew
75a902bf2c
Wddm freeGraphicsMemory should handle null GraphicsAllocation same as Drm
...
Change-Id: Idafdaf654f630d41b890f87c6e8c14833b18f714
2018-01-18 08:24:07 +01:00
Mrozek, Michal
e923c2211b
Add Unrecoverable if GraphicsAllocation in use is being destroyed.
...
Change-Id: I74a54ef023c62e12d711db07d79942166e002188
2018-01-17 18:36:33 +01:00
Mrozek, Michal
42798fcae0
Revert "Add Unrecoverable if GraphicsAllocation in use is being destroyed."
...
This reverts commit 920d952a4a .
Change-Id: Ib14743e37545776ebf1b6e782daceb436d280f9b
2018-01-15 14:43:11 +01:00
Mrozek, Michal
920d952a4a
Add Unrecoverable if GraphicsAllocation in use is being destroyed.
...
Change-Id: Ie224ac4d098678a99da0a8c084f02740f323c475
2018-01-12 15:22:15 +01:00
Mateusz Jablonski
502e9c2d15
Async deleter: move releasing cpu/gpu pointers to main thread
...
Change-Id: I3c3c9fb6200c38ecf1fc8910380531d6a5f1e875
2018-01-12 13:16:59 +01:00
Mateusz Jablonski
f12b5861fd
Drain deferred deletions when cannot allocate memory for tiled image
...
Change-Id: I68b15269da4b5a58e02571a9c594c52b9a95edeb
2018-01-09 09:20:10 +01:00
Zdanowicz, Zbigniew
21f92d8258
Add preemption WA to make CSR surface uncacheable
...
Change-Id: Ia468c6f5df16522c3bc9aae22802895f2badc431
2018-01-05 22:44:26 +01:00
Zdunowski, Piotr
b006972d07
Improve error handling for shared handles in wddm.
...
Change-Id: I93d33d89cb4b6333924c362b54e0638174e44091
2017-12-29 16:10:16 +01:00
Brandon Fliflet
7e9ad41290
Initial commit
...
Change-Id: I4bf1707bd3dfeadf2c17b0a7daff372b1925ebbd
2017-12-21 00:45:38 +01:00