Commit Graph

350 Commits

Author SHA1 Message Date
Maciej Bielski 6924a48ca6 refactor: prepare CLOS logic for extension
Prepare cache setup and reservation logic to be extended w.r.t other
cache-levels.

Conceptually this change is like adding a switch-statement, in several
places, in which existing code makes a single (and only) case. This is
caused by splitting larger development to ease the review. Further cases
will be added in following steps. Such approach sometimes creates code
which may seem redundant but it is meant to simplify plugging following
extensions in an easy way.

Related-To: NEO-12837
Signed-off-by: Maciej Bielski <maciej.bielski@intel.com>
2025-02-17 10:43:08 +01:00
Lukasz Jobczyk c7c7ae9d49 refactor: Remove redundancy around gemCloseWorker in csr
Related-To: NEO-13922

Signed-off-by: Lukasz Jobczyk <lukasz.jobczyk@intel.com>
2025-02-13 21:42:28 +01:00
Mateusz Jablonski d25237c104 fix: pass ReadOnly flag only for page-misaligned input ptr
Related-To: NEO-12986
Signed-off-by: Mateusz Jablonski <mateusz.jablonski@intel.com>
2025-02-11 10:42:42 +01:00
Chandio, Bibrak Qamar 7149743162 fix: Set vmbind user fence when makeMemoryResident
Related-To: NEO-11977, GSD-10293

Signed-off-by: Chandio, Bibrak Qamar <bibrak.qamar.chandio@intel.com>
2025-02-10 14:20:09 +01:00
Slawomir Milczarek 354064a539 refactor: Extend wrapper for system calls with mkfifo command
Related-To: NEO-12952

Signed-off-by: Slawomir Milczarek <slawomir.milczarek@intel.com>
2025-02-07 18:49:36 +01:00
Brandon Yates f7e63ba0d0 feature: Add support for optional PF enable flag for exec queue create
Related-to: NEO-8306

Signed-off-by: Brandon Yates <brandon.yates@intel.com>
2025-02-05 19:24:01 +01:00
Mateusz Jablonski a924761ed1 fix: correct flags for creating allocation with existing system memory
on Windows setup ReadOnly flag, it makes there is no ProbeForWrite call within
CreateAllocation2 function call

it doesn't force read-only access from GPU perspective, that access it
defined in MapGpuVa function

Related-To: NEO-12986, HSD-15016952776
Signed-off-by: Mateusz Jablonski <mateusz.jablonski@intel.com>
2025-02-03 11:24:55 +01:00
Compute-Runtime-Validation 3556d9ded6 Revert "fix: set ReadOnly flag when creating allocation with existing system ...
This reverts commit bddb24124d.

Signed-off-by: Compute-Runtime-Validation <compute-runtime-validation@intel.com>
2025-01-31 12:15:12 +01:00
Compute-Runtime-Validation d23249b061 Revert "fix: Set vmbind user fence when makeMemoryResident"
This reverts commit 80dc4fb43a.

Signed-off-by: Compute-Runtime-Validation <compute-runtime-validation@intel.com>
2025-01-31 11:36:29 +01:00
Mateusz Jablonski bddb24124d fix: set ReadOnly flag when creating allocation with existing system memory
setting ReadOnly flag makes there is no ProbeForWrite call within
CreateAllocation2 function call

it doesn't make read-only access from GPU perspective, that access it
defined in MapGpuVa function

Related-To: NEO-12986, HSD-15016952776
Signed-off-by: Mateusz Jablonski <mateusz.jablonski@intel.com>
2025-01-30 19:43:44 +01:00
Chandio, Bibrak Qamar 80dc4fb43a fix: Set vmbind user fence when makeMemoryResident
Related-To: NEO-11977, GSD-10293

Signed-off-by: Chandio, Bibrak Qamar <bibrak.qamar.chandio@intel.com>
2025-01-28 22:04:37 +01:00
Mateusz Hoppe 19a0a27862 refactor: adjust unit tests to work with secondary engines
Related-To: NEO-12952, NEO-13789


Signed-off-by: Mateusz Hoppe <mateusz.hoppe@intel.com>
2025-01-22 13:31:43 +01:00
Chodor, Jaroslaw dd3d5c6460 feature: Add logic for reading loaded library's version
getLoadedLibVersion is intended for reading version of a library that was
already loaded into the process prior to this call (i.e. new instance of
the library willnot be loaded).
Note: Currently, only windows version of this functionality is implemented.
Related-To: GSD-10248

Signed-off-by: Chodor, Jaroslaw <jaroslaw.chodor@intel.com>
2024-12-20 17:29:19 +01:00
Mateusz Jablonski e7a8936d70 test: don't use product specific ioctl helper in generic tests
Related-To: NEO-13527
Signed-off-by: Mateusz Jablonski <mateusz.jablonski@intel.com>
2024-12-18 17:26:12 +01:00
Mateusz Jablonski 169469eb06 refactor: extract querying device id / revision id to separate method in xe path
Related-To: NEO-13527
Signed-off-by: Mateusz Jablonski <mateusz.jablonski@intel.com>
2024-12-18 09:57:19 +01:00
Mateusz Jablonski 86ecbf3507 fix: explicitly report unhandled event exec queue placements
Signed-off-by: Mateusz Jablonski <mateusz.jablonski@intel.com>
2024-12-16 13:11:39 +01:00
Mateusz Jablonski 8f7bacdd95 feature: add eudebug interface class
eudebug interface is now hidden under EuDebugInterface class
shared code uses generic object and param values

layout of structs is guarded by static asserts

eudebug support is guarded by cmake flags:
- NEO_ENABLE_XE_EU_DEBUG_SUPPORT - enables eudebug in general
- NEO_USE_XE_EU_DEBUG_EXP_UPSTREAM - registers exp upstream uAPI support
- NEO_ENABLE_XE_PRELIM_DETECTION - registers prelim uAPI support

This way we can support two different xe-eudebug interfaces within
single binary.

In unit tests there is mock eudebug interface enabled (even if no
eudebug support is enabled by cmake flag).

Related-To: NEO-13472
Signed-off-by: Mateusz Jablonski <mateusz.jablonski@intel.com>
2024-12-13 17:07:12 +01:00
Maciej Bielski 1fafd44af5 refactor: use level-specific name for CacheInfo instances
Related-To: NEO-12837

Signed-off-by: Maciej Bielski <maciej.bielski@intel.com>
2024-12-10 11:45:11 +01:00
Maciej Bielski c9726dbb10 refactor: simplify tracking CacheRegion reservations
Leverage features of the mechanism to simplify implementation:
- The maximum number of possible cache-region reservations is a small
value known at compile-time
- Each reservation is unique (described by `CacheRegion`) so can have
a dedicated entry with either zero (free) or non-zero (reserved) value

So, there is no need for a dynamic collection (unordered_map here) to
keep track of reservations. A simple array is enough for that purpose.

Also, add some helper-code to enable array-indexing with the values of
`CacheRegion` enum.

Related-To: NEO-12837
Signed-off-by: Maciej Bielski <maciej.bielski@intel.com>
2024-12-09 16:50:28 +01:00
Alicja Lukaszewicz 789efc8909 fix: remove number of RT stacks from capability table
Related-To: NEO-10830

Signed-off-by: Alicja Lukaszewicz <alicja.lukaszewicz@intel.com>
2024-11-21 14:46:50 +01:00
Wenbin Lu 2ba80ce114 feature: support physical host memory
Related-To: NEO-11981

Signed-off-by: Wenbin Lu <wenbin.lu@intel.com>
2024-11-20 08:19:52 +01:00
Chodor, Jaroslaw d1ab846a5a refactor: cleanup around options files
This patchset improves handling of library names for NEO's dynamic
dependencies.

Related-To: NEO-12747

Signed-off-by: Chodor, Jaroslaw <jaroslaw.chodor@intel.com>
2024-11-15 22:21:16 +01:00
Dominik Dabek 22a3ec948b fix: ulls controller sleep, windows
Request higher resolution for windows periodic timers for ulls
controller sleep.

Allows for controller thread to sleep with granularity of 1ms.

Related-To: NEO-10800

Signed-off-by: Dominik Dabek <dominik.dabek@intel.com>
2024-10-24 18:07:04 +02:00
Mateusz Jablonski 4154e6666b fix: correct loading L0 loader functions
- don't load ze_loader.dll from file system
- to perform self-open on Windows use getModuleHandleA with proper module name
- don't free library loaded with getModuleHandleA
- as loader may be not available during runtime teardown:
- load translate handle function during global setup
- load setDriverTeardown function during global teardown
- when loader is not available during teardown, unset translate handle
function

Related-To: GSD-10147

Signed-off-by: Mateusz Jablonski <mateusz.jablonski@intel.com>
2024-10-17 15:39:20 +02:00
Tomasz Biernacik c982981dde feature: add number of rt stacks to capability table
Related-To: NEO-12138

Signed-off-by: Tomasz Biernacik <tomasz.biernacik@intel.com>
2024-10-17 14:46:19 +02:00
Compute-Runtime-Validation f117b5fb68 Revert "fix: correct loading L0 loader functions"
This reverts commit 9c7b3c5e19.

Signed-off-by: Compute-Runtime-Validation <compute-runtime-validation@intel.com>
2024-10-17 08:20:19 +02:00
Mateusz Jablonski 9c7b3c5e19 fix: correct loading L0 loader functions
on Windows use getModuleHandleA with proper module name
don't load ze_loader.dll from file system

Signed-off-by: Mateusz Jablonski <mateusz.jablonski@intel.com>
2024-10-16 19:53:05 +02:00
Tomasz Biernacik bf6d9fc416 feature: read new params from blob
Related-To: NEO-12138

Signed-off-by: Tomasz Biernacik <tomasz.biernacik@intel.com>
2024-10-16 10:29:22 +02:00
Bartosz Dunajski 5adfaa0380 test: improve drm mocking
Signed-off-by: Bartosz Dunajski <bartosz.dunajski@intel.com>
2024-10-14 11:49:04 +02:00
Weronika Kapusta 8cb630b29a test: neo ULT should build with optimizations disabled
Related-To: NEO-8116
Signed-off-by: Weronika Kapusta <weronika.kapusta@intel.com>
2024-10-11 17:26:06 +02:00
Mateusz Jablonski 8fbe873e1b build: correct setting for i915/xe prelim setting in package scripts
rename i915 flag to uppercase, for consistency
disable i915 / xe prelim by default in package scripts

Signed-off-by: Mateusz Jablonski <mateusz.jablonski@intel.com>
2024-10-09 15:55:59 +02:00
Mateusz Jablonski c7ae732a2a test: enable global mock sip in tests
Signed-off-by: Mateusz Jablonski <mateusz.jablonski@intel.com>
2024-09-30 18:19:57 +02:00
Mateusz Jablonski 86a088e13f feature: move L3 bank query from xe-prelim to xe-nonprelim path
Related-To: NEO-11125
Signed-off-by: Mateusz Jablonski <mateusz.jablonski@intel.com>
2024-09-17 18:14:17 +02:00
Bartosz Dunajski ed05912c40 test: improve handling mock queue id
Signed-off-by: Bartosz Dunajski <bartosz.dunajski@intel.com>
2024-09-16 13:34:37 +02:00
Kamil Kopryk d18d58d4f7 test: correct expectations in ults if heapless enabled
Related-To: NEO-10681
Signed-off-by: Kamil Kopryk <kamil.kopryk@intel.com>
2024-09-12 09:20:47 +02:00
Mateusz Jablonski bc5237ca8a feature: add support for query l3 bank count in xe-prelim
Related-To: NEO-11125
Signed-off-by: Mateusz Jablonski <mateusz.jablonski@intel.com>
2024-09-11 11:28:43 +02:00
Mateusz Jablonski 1c15fa5c70 fix: correct thread-safety in removing from bind info vector in xe path
Signed-off-by: Mateusz Jablonski <mateusz.jablonski@intel.com>
2024-09-11 02:49:27 +02:00
Fabian Zwoliński ea5b586c37 fix: move pathExists out of sys calls and do not mock it
Moved pathExists from SysCalls to path.h.
In ULTs, use unchanged pathExists and mock stat, getFileAttributesA instead.
Add Windows and Linux ULTs for pathExists.

Signed-off-by: Fabian Zwoliński <fabian.zwolinski@intel.com>
2024-09-10 19:24:45 +02:00
Kamil Kopryk 49a2050312 test: correct drm ults if heapless is enabled
Related-To: NEO-10641

Signed-off-by: Kamil Kopryk <kamil.kopryk@intel.com>
2024-09-10 18:12:29 +02:00
Mateusz Jablonski dfbad8029b feature: add support for SIMD16 EU per DSS to xe-prelim helper
Related-To: NEO-12012
Signed-off-by: Mateusz Jablonski <mateusz.jablonski@intel.com>
2024-09-10 15:35:46 +02:00
Mateusz Jablonski 4bf8e6de2e test: correct expectation for pat index in bind test
Related-To: NEO-10158

Signed-off-by: Maciej Bielski <maciej.bielski@intel.com>
Signed-off-by: Mateusz Jablonski <mateusz.jablonski@intel.com>
2024-08-30 20:16:13 +02:00
Mateusz Jablonski c934877790 refactor: remove not needed function
Signed-off-by: Mateusz Jablonski <mateusz.jablonski@intel.com>
2024-08-30 12:18:14 +02:00
Mateusz Jablonski 512dac67fa test: move xe specific mocks to shared/test/common
Signed-off-by: Mateusz Jablonski <mateusz.jablonski@intel.com>
2024-08-30 11:22:58 +02:00
Mateusz Jablonski c8ead35afa test: correct adding subdirectories in test cmake files
Signed-off-by: Mateusz Jablonski <mateusz.jablonski@intel.com>
2024-08-29 16:16:05 +02:00
Compute-Runtime-Validation 5dbbaa39b9 Revert "fix: ulls controller sleep, windows"
This reverts commit 6455d4648c.

Signed-off-by: Compute-Runtime-Validation <compute-runtime-validation@intel.com>
2024-08-24 06:37:58 +02:00
Dominik Dabek 6455d4648c fix: ulls controller sleep, windows
Request higher resolution for windows periodic timers for ulls
controller sleep.

Allows for controller thread to sleep with granularity of 1ms.

Related-To: NEO-10800

Signed-off-by: Dominik Dabek <dominik.dabek@intel.com>
2024-08-23 12:05:26 +02:00
Bellekallu Rajkiran be4570fe10 fix: Read appropriate entry for HBM channels
Related-To: NEO-11949

Signed-off-by: Bellekallu Rajkiran <bellekallu.rajkiran@intel.com>
2024-08-12 09:44:37 +02:00
Maciej Bielski 790bb84841 refactor: decouple ClosCacheReservation from Drm
The dependency towards `Drm` is unnecessary and only makes testing more
difficult. Instead, dependency towards `IoctlHelper` alone only is
sufficient.

Related-To: NEO-10158
Signed-off-by: Maciej Bielski <maciej.bielski@intel.com>
2024-07-31 10:38:35 +02:00
Mateusz Jablonski e24acc6155 fix: ensure memory info is queried before querying engine info
initialization of engine info relies on memory info data

Related-To: NEO-12073
Signed-off-by: Mateusz Jablonski <mateusz.jablonski@intel.com>
2024-07-26 09:28:50 +02:00
Maciej Bielski 2165154530 feature: add support for L3-cache reservation
Resolves: NEO-7849

Signed-off-by: Maciej Bielski <maciej.bielski@intel.com>
2024-07-24 10:10:28 +02:00