Commit Graph

68 Commits

Author SHA1 Message Date
Warchulski, Jaroslaw f275eea6ec Cleanup includes 14
Cleaned up files:
shared/source/device/device.h

Related-To: NEO-5548

Signed-off-by: Warchulski, Jaroslaw <jaroslaw.warchulski@intel.com>
2022-12-23 10:46:34 +01:00
Mateusz Jablonski 10dbfc0d19 Reduce usage of global gfx core helper getter [3/n]
Related-To: NEO-6853
Signed-off-by: Mateusz Jablonski <mateusz.jablonski@intel.com>
2022-12-13 11:13:11 +01:00
Kamil Kopryk 03b687881f Rename HwHelper -> GfxCoreHelper
Related-To: NEO-6853
Signed-off-by: Kamil Kopryk <kamil.kopryk@intel.com>
2022-12-09 10:29:06 +01:00
Kamil Kopryk 91d39ad5bf Rename ClHwHelper -> ClGfxCoreHelper
Related-To: NEO-6853
Signed-off-by: Kamil Kopryk <kamil.kopryk@intel.com>
2022-12-05 11:26:20 +01:00
Kamil Kopryk 3b97ca8709 Move ClCoreHelper ownership to RootDeviceEnvironment 6/n
Related-To: NEO-6853
Signed-off-by: Kamil Kopryk <kamil.kopryk@intel.com>

Use RootDeviceEnvironment getHelper<ClCoreHelper> for
- allowImageCompression
- isFormatRedescribable
2022-11-18 15:35:10 +01:00
Kamil Kopryk 1e0a2b897f Introduce getHelper - helper getter for ClHwHelper and L0HwHelper
Related-To: NEO-6853
Signed-off-by: Kamil Kopryk <kamil.kopryk@intel.com>
2022-11-14 15:54:45 +01:00
Kamil Kopryk efa19a0b18 Simplify code - reverse helper function logic to avoid not needed negation
Signed-off-by: Kamil Kopryk <kamil.kopryk@intel.com>
2022-06-29 09:19:33 +02:00
Kamil Kopryk 47fa30b419 Simplify code - image create function
Reduce number of lines, reduce nested if statements
and others
Signed-off-by: Kamil Kopryk <kamil.kopryk@intel.com>
2022-06-27 17:46:03 +02:00
Bartosz Dunajski 39c1c4d530 Remove virtual padding support
Signed-off-by: Bartosz Dunajski <bartosz.dunajski@intel.com>
2022-06-08 12:42:44 +02:00
Krzysztof Gibala dc1fe7d59a Change MemoryPool to enum class
Use enum class for MemoryPool in GraphicsAllocation
This change will ensure that GA is constructed in the proper way

- Rename namespace for isSystemMemoryPool method
- Add method getMemoryPoolString for logging actual pool which is in used
- Remove wrong pattern in GraphicsAllocation constructor

Related-To: NEO-6523
Signed-off-by: Krzysztof Gibala <krzysztof.gibala@intel.com>
2022-06-02 12:46:15 +02:00
Artur Harasimiuk 3f04769f07 style: configure readability-identifier-naming.FunctionCase
Signed-off-by: Artur Harasimiuk <artur.harasimiuk@intel.com>
2022-05-17 20:55:56 +02:00
Artur Harasimiuk 819e0f5515 style: configure readability-identifier-naming.LocalVariableCase
Signed-off-by: Artur Harasimiuk <artur.harasimiuk@intel.com>
2022-05-16 12:39:44 +02:00
Artur Harasimiuk e9be9b64c6 clang-tidy configuration cleanup
Define single .clang-tidy configuration with all used checks and use
NOLINT to selectively silence tool. That way cleanup should be easier.
third_part/ has its own configuration that disables clang-tidy for this
folder.

Signed-off-by: Artur Harasimiuk <artur.harasimiuk@intel.com>
2022-05-11 14:02:04 +02:00
Krzysztof Gibala 9b778863b4 Store GmmHelper in Gmm class
Store GmmHelper in Gmm class instead of GmmClientContext

Related-To: NEO-6523
Signed-off-by: Krzysztof Gibala <krzysztof.gibala@intel.com>
2022-04-27 15:45:49 +02:00
Filip Hazubski 3123ab5bf9 Correct media compression format for planar images
Set most significant bit for chroma planes.

Signed-off-by: Filip Hazubski <filip.hazubski@intel.com>
2022-03-26 21:54:08 +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
Rafal Maziejuk 659a67672e Check if origin + region doesn't exceed image_array_size
Signed-off-by: Rafal Maziejuk <rafal.maziejuk@intel.com>
Related-To: NEO-6137
2022-01-27 15:49:55 +01:00
Rafal Maziejuk f064f7dd67 Check if origin + region doesn't exceed image dimensions
Signed-off-by: Rafal Maziejuk <rafal.maziejuk@intel.com>
Related-To: NEO-6137
2022-01-25 15:13:15 +01:00
Szymon Morek c282a78b14 Fix parent MemObj dereference.
Don't dereference parent obj multiple
times (per gfxAllocation). Dereference it once

Related-To: NEO-6418

Signed-off-by: Szymon Morek <szymon.morek@intel.com>
2022-01-14 14:54:59 +01:00
Bartosz Dunajski 68aea5bf62 Rename compression flags and helpers
Signed-off-by: Bartosz Dunajski <bartosz.dunajski@intel.com>
2021-12-03 18:09:02 +01:00
Bartosz Dunajski 55959d4d1d Helper method to check if allocation is compressed
Signed-off-by: Bartosz Dunajski <bartosz.dunajski@intel.com>
2021-12-02 16:13:53 +01:00
Bartosz Dunajski 7b55d38e34 Refactor [1/n]: Make compression preference allocation property
Signed-off-by: Bartosz Dunajski <bartosz.dunajski@intel.com>
2021-12-02 15:24:35 +01:00
Sebastian Luzynski ce78bab177 Image compression checks
Signed-off-by: Sebastian Luzynski <sebastian.jozef.luzynski@intel.com>
Related-To: NEO-6102
2021-10-27 13:36:41 +02:00
Bartosz Dunajski d34ef3170a Remove CPP_ATTRIBUTE_FALLTHROUGH macro
Signed-off-by: Bartosz Dunajski <bartosz.dunajski@intel.com>
2021-10-22 17:27:57 +02:00
Mateusz Jablonski 48f01f28f5 Move core part of MemoryPropertiesHelpers to shared
Signed-off-by: Mateusz Jablonski <mateusz.jablonski@intel.com>
2021-10-07 23:14:38 +02:00
Szymon Morek c8b85bb5a9 Add method to check tile only context
Related-To: NEO-6043

Signed-off-by: Szymon Morek <szymon.morek@intel.com>
2021-07-21 12:22:42 +02:00
Mateusz Jablonski 6f3c89decb Add mechanism to migrate multi root device memory
invalidate TLB cache if kernel requires migration


Related-To: NEO-3691

Signed-off-by: Mateusz Jablonski <mateusz.jablonski@intel.com>
2021-07-19 19:49:22 +02:00
Kamil Kopryk dbe3ef21c1 Prefer unique_ptr instead of raw pointer nv12 ults
Signed-off-by: Kamil Kopryk <kamil.kopryk@intel.com>
Related-To: NEO-4692
2021-06-28 13:54:37 +02:00
Mateusz Jablonski 7a2d3d6369 Setup create function in redescribed image
Related-To: NEO-3691
Signed-off-by: Mateusz Jablonski <mateusz.jablonski@intel.com>
2021-06-18 08:59:31 +02:00
Szymon Morek 3ed0f074af Add method to set compression flag
Signed-off-by: Szymon Morek <szymon.morek@intel.com>
2021-06-10 12:27:24 +02:00
Krzysztof Gibala df1162ff4d Change alignment for forced created ptr in image
Related-To: NEO-5723
Signed-off-by: Krzysztof Gibala <krzysztof.gibala@intel.com>
2021-05-14 17:12:06 +02:00
Krzysztof Gibala c3143ccf1f Change image with host ptr creation logic in multi device setup
When multi device config is available,
then allocations are created in system memory pool.

Related-To: NEO-5508
Signed-off-by: Krzysztof Gibala <krzysztof.gibala@intel.com>
2021-04-07 12:24:39 +02:00
Krzysztof Gibala 0b7d2da162 Create image allocations in system memory pool
Create image allocations in multi device setup in system memory pool

Related-To: NEO-5508

Signed-off-by: Krzysztof Gibala <krzysztof.gibala@intel.com>
2021-03-26 15:35:05 +01:00
Filip Hazubski 5618d4dfa4 Correct image initialization for linear storage allocations 2/2
Signed-off-by: Filip Hazubski <filip.hazubski@intel.com>
2021-02-02 17:12:18 +01:00
Filip Hazubski 3b9bd0b7e4 Correct image initialization for linear storage allocations
Signed-off-by: Filip Hazubski <filip.hazubski@intel.com>
2021-01-14 16:02:56 +01:00
Krzysztof Gibala 8d2cfd87ae Create graphicsAllocation for all devices in image
Unlock flow for multi device setup in:
- enqueueReadImage
- enqueueWriteImage

Related-To: NEO-4589
Signed-off-by: Krzysztof Gibala <krzysztof.gibala@intel.com>
2020-12-10 17:40:03 +01:00
Piotr Zdunowski 9a9bd6a805 Fix issue with creating image from buffer in local memory.
Resolves: NEO-4605

Signed-off-by: Piotr Zdunowski <piotr.zdunowski@intel.com>
2020-12-07 16:39:29 +01:00
Krzysztof Gibala 2c1551d40d Extend specialQueue in context to StackVec
Related-To: NEO-4589
Change-Id: I92db4cf8511e13a35307a4f48b51041a6fc7330f
Signed-off-by: Krzysztof Gibala <krzysztof.gibala@intel.com>
2020-10-30 13:33:46 +01:00
Krzysztof Gibala 214342f405 Create map for deviceBitfields per rootDeviceIndex
Pass rootDeviceIndex to getDeviceBitfieldForAllocation

Related-To: NEO-4589
Change-Id: Ib325a8bf822351ba36b225d94d4173fd725e8766
Signed-off-by: Krzysztof Gibala <krzysztof.gibala@intel.com>
2020-09-29 12:18:49 +02:00
Krzysztof Gibala cb5ab704b6 Destroy all GraphicsAllocation in ~MemObj
Related-To: NEO-4672
Change-Id: I4fa09ae7753ed258f489b9e9f328d0a455e7d9b6
Signed-off-by: Krzysztof Gibala <krzysztof.gibala@intel.com>
2020-08-13 12:18:35 +02:00
Krzysztof Gibala 1868658b2f Optimize MultiGraphicsAllocation
Related-To: NEO-4672
Change-Id: I28b23a1d1f3d824d2e2cbe6a62a7151a7d9d2296
Signed-off-by: Krzysztof Gibala <krzysztof.gibala@intel.com>
2020-08-03 15:01:23 +02:00
Krzysztof Gibala e9c42e54b2 Connect mem_obj with MultiGraphicsAllocation
Related-To: NEO-4672
Change-Id: I188db44b4cb0ac6245bd7c864c69b8f1c0084dc4
Signed-off-by: Krzysztof Gibala <krzysztof.gibala@intel.com>
2020-07-22 14:09:27 +02:00
Krzysztof Gibala 47df60c067 Pass MultiGraphicsAllocation in Image
Related-To: NEO-4672
Change-Id: I01c2e7b25cb3448af9520493025569895eb4a155
Signed-off-by: Krzysztof Gibala <krzysztof.gibala@intel.com>
2020-07-20 10:26:19 +02:00
Mateusz Jablonski 1b3086a823 Pass root device index to setImageArg and setMediaImageArg methods
Related-To: NEO-4672
Change-Id: I983adfe32ca153e9edbeb5918bf923516758d200
Signed-off-by: Mateusz Jablonski <mateusz.jablonski@intel.com>
2020-06-25 11:47:47 +02:00
Sebastian Luzynski fa3cb35fde Add check if device support Images.
Related-To: NEO-4675
Change-Id: I0c2b6e04536e45e70748983521e8469dd3dad697
2020-06-24 23:38:03 +02:00
Mateusz Jablonski 57d0967a2c Pass root device index to MemObj::getGraphicsAllocation method
leave parameterless method in Buffer and Image classes

add method to remove graphics allocation from MultiGraphicsAllocation

Related-To: NEO-4672
Change-Id: I3020eecfabe9a16af7f36d68a74b32d3f4fc2276
Signed-off-by: Mateusz Jablonski <mateusz.jablonski@intel.com>
2020-06-05 13:18:03 +02:00
Filip Hazubski 78d07b9b37 Pass Device when creating MemoryProperties
Related-To: NEO-4651

Change-Id: Ie1f7f55d4817612de83bfb2a372fd7ac35c11930
Signed-off-by: Filip Hazubski <filip.hazubski@intel.com>
2020-06-05 12:42:15 +02:00
Filip Hazubski 99b0f04cc0 Add new API properties queries
Add queries for getting properties that were used when creating an object:
 - CL_QUEUE_PROPERTIES_ARRAY
 - CL_PIPE_PROPERTIES
 - CL_MEM_PROPERTIES
 - CL_SAMPLER_PROPERTIES

Related-To: NEO-4368

Change-Id: Ib761ee3dd338e9718d72ed4c9596b38843a9b802
Signed-off-by: Filip Hazubski <filip.hazubski@intel.com>
2020-05-27 18:50:58 +02:00
Filip Hazubski 5eed521fe1 Update getInfo function
Allow return value size to be 0. Do not modify return value size in case
of error.

Related-To: NEO-4368

Change-Id: I201e8ee7c23fcdc2712f6b04bedc71bf4ab64f06
Signed-off-by: Filip Hazubski <filip.hazubski@intel.com>
2020-05-21 17:06:28 +02:00
Filip Hazubski 0a6da52bd4 Add implementation of new OpenCL 3.0 API functions
Additionally unify implementation of API functions related to creating buffers
and images.

Related-To: NEO-4368

Change-Id: Icfafc32f15e667e249fb318072194b6f76bd6481
Signed-off-by: Filip Hazubski <filip.hazubski@intel.com>
2020-05-15 12:09:08 +02:00