Commit Graph

494 Commits

Author SHA1 Message Date
Lukasz Jobczyk f4c40c74cb Flush tag update if any heap was allocated
Signed-off-by: Lukasz Jobczyk <lukasz.jobczyk@intel.com>
2022-10-14 13:12:43 +02:00
Aravind Gopalakrishnan f9fab3ff49 Update SBA in hybrid immediate and regular commandlist usages
Fix to check and update heap states.

Related-To: LOCI-3379
Signed-off-by: Aravind Gopalakrishnan <aravind.gopalakrishnan@intel.com>
2022-10-14 11:42:06 +02:00
Szymon Morek 06e5b1cd42 Early preallocate command buffer to reuse for csr
Signed-off-by: Szymon Morek <szymon.morek@intel.com>
2022-10-13 19:43:38 +02:00
Compute-Runtime-Validation 71149b29c5 Revert "Propagate exec buffer error to L0 API level"
This reverts commit 9a95f3c62d.

Signed-off-by: Compute-Runtime-Validation <compute-runtime-validation@intel.com>
2022-10-13 06:21:31 +02:00
Mateusz Jablonski 9a95f3c62d Propagate exec buffer error to L0 API level
This change makes that drm file is opened in nonblocking mode for prelim
kernels. In such case when calling exec buffer ioctl and get
EAGAIN (aka EWOULDBLOCK) we may return error to API level

Related-To: NEO-7144
Signed-off-by: Mateusz Jablonski <mateusz.jablonski@intel.com>
2022-10-12 17:34:35 +02:00
Zbigniew Zdanowicz 87822f94e2 Replace virtual method call for DC flush with stored bool value 2/n
Signed-off-by: Zbigniew Zdanowicz <zbigniew.zdanowicz@intel.com>
2022-10-12 09:43:01 +02:00
Zbigniew Zdanowicz 31f97717db Replace virtual method call for DC flush with stored bool value 1/n
Signed-off-by: Zbigniew Zdanowicz <zbigniew.zdanowicz@intel.com>
2022-10-11 13:27:58 +02:00
Michal Mrozek 2eb47bd73e Optimize makeResident call.
Some portions only make sense in Batching mode.

Signed-off-by: Michal Mrozek <michal.mrozek@intel.com>
2022-10-10 19:56:29 +02:00
Michal Mrozek 809abb005f Optimize flushTask.
Move Batching code under batching if to not call not required functions.
Update task level only if level is closed.
70ns gain.

Signed-off-by: Michal Mrozek <michal.mrozek@intel.com>
2022-10-10 19:22:43 +02:00
Lukasz Jobczyk b21fef96cb Wait for events from host
Signed-off-by: Lukasz Jobczyk <lukasz.jobczyk@intel.com>
2022-10-10 12:12:13 +02:00
Neumann, Marta 1b669f52d8 Embed NEO regkeys in AUB file
Resolves: NEO-3105

Signed-off-by: Neumann, Marta <marta.neumann@intel.com>
2022-10-05 14:49:13 +02:00
Zbigniew Zdanowicz 322719e7a2 prepare tests to enable heap sharing feature
Related-To: NEO-7142

Signed-off-by: Zbigniew Zdanowicz <zbigniew.zdanowicz@intel.com>
2022-10-05 11:54:16 +02:00
Dunajski, Bartosz 52b63be026 Remove isCleanLeftoverMemoryRequired() + refactor sampler support path
Signed-off-by: Dunajski, Bartosz <bartosz.dunajski@intel.com>
2022-10-04 16:24:03 +02:00
Zbigniew Zdanowicz 3d92186362 Add heap sharing to immediate command lists
This change is intended to be used in immediate command lists that are
using flush task functionality.
With this change all immediate command list using the same csr will consume
shared allocations for dsh and ssh heaps. This will decrease number of SBA
commands dispatched when multiple command lists coexists and dispatch kernels.
With this change new SBA command should be dispatched only when current heap
allocation is exhausted.
Functionality is currently disabled and available under debug key.
Functionality will be enabled by default for all immediate command lists
with flush task functionality enabled.

Related-To: NEO-7142

Signed-off-by: Zbigniew Zdanowicz <zbigniew.zdanowicz@intel.com>
2022-10-03 18:50:10 +02:00
Michal Mrozek e6daa207ad sizeUsed doesn't have to be atomic.
Linear stream is always being updated under mutex.
Massive improvement for whole zeCommandListAppendLaunchKernel +20%.

Signed-off-by: Michal Mrozek <michal.mrozek@intel.com>
2022-09-30 17:07:21 +02:00
Michal Mrozek 2cb4cc3278 Optimize getSpace method for size 0.
Add early return for this case.
+32% performance gain.

Signed-off-by: Michal Mrozek <michal.mrozek@intel.com>
2022-09-30 16:04:34 +02:00
Zbigniew Zdanowicz a95ab1d16b Share pipeline select state updates between regular and immediate command lists
Related-To: NEO-5019

Signed-off-by: Zbigniew Zdanowicz <zbigniew.zdanowicz@intel.com>
2022-09-26 11:14:53 +02:00
Zbigniew Zdanowicz 5986a7199a Share front end state updates between regular and immediate command lists
Related-To: NEO-5019

Signed-off-by: Zbigniew Zdanowicz <zbigniew.zdanowicz@intel.com>
2022-09-23 09:46:35 +02:00
Zbigniew Zdanowicz e960802e33 Add pipeline select state tracking
This optimization removes pipeline select from command list preamble
and presented to command queue for necessary state update.
Code is disabled by default and available under debug key.

Related-To: NEO-5019

Signed-off-by: Zbigniew Zdanowicz <zbigniew.zdanowicz@intel.com>
2022-09-23 08:21:00 +02:00
Fabian Zwolinski 645600d141 Return error when there is no memory to evict
We want to return error code to the application instead of aborting when
we are not able to make more memory resident.

Related-To: NEO-7289
Signed-off-by: Fabian Zwolinski <fabian.zwolinski@intel.com>
2022-09-22 14:26:55 +02:00
Igor Venevtsev 43676ed02a L0Debug Win: initialize device with empty submission
In case of debuggable context device should be additionally
initialized by early empty submission issue.

Signed-off-by: Igor Venevtsev <igor.venevtsev@intel.com>
2022-09-21 12:02:34 +02:00
Maciej Bielski 56cb1f757b programStateBaseAddress: improve code reuse
Another step towards cleaner callers of
StateBaseAddressHelper<>::programStateBaseAddress.

Export programming state base address into a separate function to
improve code reuse and reduce copy-pasted fragments, which make code
modifications or maintenance more and more difficult over time. Use
specialization for gen-specific variations.

Related-To: NEO-6774
Signed-off-by: Maciej Bielski <maciej.bielski@intel.com>
2022-09-21 11:54:57 +02:00
Milczarek, Slawomir 0192e8038f Check for GPU hang in path with wait for timestamps
Related-To: NEO-6868

Signed-off-by: Milczarek, Slawomir <slawomir.milczarek@intel.com>
2022-09-19 15:01:46 +02:00
Zbigniew Zdanowicz 8eaa9d690e add tracking of the state of pipeline select for command lists and queues
This change prepares infrastructure for pipeline select handling in
command lists and queues by optimization of number of commands dispatched.
State is synchronized between flush-task immediate and regular command lists.
Next step is to add optimization itself which disables legacy hw command
dispatch algorithm.
This change corrects ADL-P support for systolic mode changes.

Related-To: NEO-5019

Signed-off-by: Zbigniew Zdanowicz <zbigniew.zdanowicz@intel.com>
2022-09-19 11:57:34 +02:00
Zbigniew Zdanowicz 218a98f7f7 Refactor of pipeline select programming
Adding new interface to cooperate with hw context state
Simplify programming removing unnecessary functions
Code optimization that stop using expensive call and instead
stores configuration parameter

Related-To: NEO-5019

Signed-off-by: Zbigniew Zdanowicz <zbigniew.zdanowicz@intel.com>
2022-09-15 15:38:10 +02:00
Zbigniew Zdanowicz cee520b311 simplify systolic mode code and reduce double implementation
Related-To: NEO-5019

Signed-off-by: Zbigniew Zdanowicz <zbigniew.zdanowicz@intel.com>
2022-09-15 11:57:54 +02:00
Zbigniew Zdanowicz 647661e701 add pipeline select hw properties support flags
Related-To: NEO-5019

Signed-off-by: Zbigniew Zdanowicz <zbigniew.zdanowicz@intel.com>
2022-09-14 11:23:44 +02:00
Maciej Bielski 0d0d6a300e Debugger: simplify captureStateBaseAddress()
So far captureStateBaseAddress() was a wrapper around
programSbaTrackingCommands(), doing an additional checking before
calling the latter. The checking is apparently no longer relevant, so
unify the distinction and remove part of the code which is no longer
needed.

In practice, keep the captureStateBaseAddress() while moving the body of
programSbaTrackingCommands() into it. This imposes lower diff-impact
onto the class hierarchy. Remove the second function. Simplify the
caller which had to distinct these two functions previously.

Related-To: NEO-6774
Signed-off-by: Maciej Bielski <maciej.bielski@intel.com>
2022-09-13 17:08:31 +02:00
Maciej Bielski e1b80ba1a8 Cleanup: updateStreamProperties(), SBA tracking
Fixes found out while working on the StateBaseAddress adaptation to
StreamProperties. Removing unused parameters, improving code reuse
(further improvements come with following commits).

Related-To: NEO-6774
Signed-off-by: Maciej Bielski <maciej.bielski@intel.com>
2022-09-12 17:56:28 +02:00
Michal Mrozek 824c781ab5 Do not program extended WA.
It was only needed for LOAD_BALANCED scenarios, so with recent disabling
of this feature in KMD, it is no longer required.

Signed-off-by: Michal Mrozek <michal.mrozek@intel.com>
2022-09-08 13:51:17 +02:00
Mateusz Hoppe 6ad16c9e72 Missing support for OCL debugging with L0
- make resident debugSurface
- allocate debugSurface with correct allocation type and size
- notify cmdQ create/destroy

Related-To: NEO-7075

Signed-off-by: Mateusz Hoppe <mateusz.hoppe@intel.com>
2022-09-07 13:30:05 +02:00
Zbigniew Zdanowicz 18af46296d Optimize programming of front end by selecting correct hardware
Related-To: NEO-5019

Signed-off-by: Zbigniew Zdanowicz <zbigniew.zdanowicz@intel.com>
2022-09-02 17:41:37 +02:00
Zbigniew Zdanowicz a4b9b3b837 Extend encode class for start and end hw commands
Related-To: NEO-5019

Signed-off-by: Zbigniew Zdanowicz <zbigniew.zdanowicz@intel.com>
2022-09-02 16:29:36 +02:00
Patryk Wrobel 90ba50bf52 Warn when RAII lock returned from function is discarded
Discarding RAII lock returned from function almost always
is a bug. This change introduces usage of [[no_discard]]
attribute from C++17 to prevent such misues.

Signed-off-by: Patryk Wrobel <patryk.wrobel@intel.com>
2022-09-01 16:53:03 +02:00
Zbigniew Zdanowicz c3f7e40a8d Rename special pipeline select mode to systolic
Signed-off-by: Zbigniew Zdanowicz <zbigniew.zdanowicz@intel.com>
2022-08-31 22:16:26 +02:00
Dominik Dabek 8cc0177f1c Change DG2 l1 cache policy to WB
With compiler LSC WAs this gives better performance.

If debugger is active, policy will not be changed ie.
will be WBP.

Related-To: NEO-7003

Signed-off-by: Dominik Dabek <dominik.dabek@intel.com>
2022-08-31 14:31:23 +02:00
Zbigniew Zdanowicz 816e059c66 connect hardware support with front end properties state management
Related-To: NEO-5019

Signed-off-by: Zbigniew Zdanowicz <zbigniew.zdanowicz@intel.com>
2022-08-31 11:09:10 +02:00
Patryk Wrobel 9f2cfc6f9d Limit files included by fence.h and csr_definitions.h
This change introduces usage of forward declarations
and removes unneeded includes from the mentioned files.

Signed-off-by: Patryk Wrobel <patryk.wrobel@intel.com>
2022-08-30 13:13:40 +02:00
Compute-Runtime-Validation 2621460e80 Revert "Change DG2 l1 cache policy to WB"
This reverts commit a820e73dd7.

Signed-off-by: Compute-Runtime-Validation <compute-runtime-validation@intel.com>
2022-08-27 08:04:19 +02:00
Dominik Dabek a820e73dd7 Change DG2 l1 cache policy to WB
With compiler LSC WAs this gives better performance.

If debugger is active, policy will not be changed ie.
will be WBP.

Related-To: NEO-7003

Signed-off-by: Dominik Dabek <dominik.dabek@intel.com>
2022-08-26 12:58:45 +02:00
Zbigniew Zdanowicz f656707fc0 Use hardware support flags for state compute mode state changes
Related-To: NEO-5019

Signed-off-by: Zbigniew Zdanowicz <zbigniew.zdanowicz@intel.com>
2022-08-25 18:46:37 +02:00
Zbigniew Zdanowicz 72c3a04bfd connect hardware pipeline properties support flags to stream properties
Related-To: NEO-5019

Signed-off-by: Zbigniew Zdanowicz <zbigniew.zdanowicz@intel.com>
2022-08-24 14:32:29 +02:00
Dunajski, Bartosz 595cfebaef Refactor PIPE_CONTROL programming
Signed-off-by: Dunajski, Bartosz <bartosz.dunajski@intel.com>
2022-08-23 13:55:25 +02:00
Zbigniew Zdanowicz 0011368775 Add parameter to set surface state base address value
This change introduces capability to set surface state base address
when surface state heap or global base address are not available

Related-To: NEO-7187

Signed-off-by: Zbigniew Zdanowicz <zbigniew.zdanowicz@intel.com>
2022-08-18 15:36:43 +02:00
Zbigniew Zdanowicz 6c38b36251 Unify getting state base address command space from command buffer
Related-To: NEO-5019

Signed-off-by: Zbigniew Zdanowicz <zbigniew.zdanowicz@intel.com>
2022-08-17 11:49:02 +02:00
Zbigniew Zdanowicz ceb9d81f87 Add struct argument for input/output in StateBaseAddressHelper
This refactor makes future interface changes easier

Related-To: NEO-5019

Signed-off-by: Zbigniew Zdanowicz <zbigniew.zdanowicz@intel.com>
2022-08-17 10:28:49 +02:00
Zbigniew Zdanowicz 1b9d50660a Unify programming of binding table base address command
Signed-off-by: Zbigniew Zdanowicz <zbigniew.zdanowicz@intel.com>
2022-08-10 14:35:02 +02:00
Dunajski, Bartosz 98d776867f Add initial support for KernelArgsBuffer allocation
Signed-off-by: Dunajski, Bartosz <bartosz.dunajski@intel.com>
2022-08-03 20:28:21 +02:00
Zbigniew Zdanowicz 0c301e5e99 Limit preemption programming in level zero command queues
When multiple command queues use the same context and retain the same state
No preemption programming for copy command queues
Program preemption preamble only for mid thread preemption

Related-To: NEO-7187

Signed-off-by: Zbigniew Zdanowicz <zbigniew.zdanowicz@intel.com>
2022-07-28 10:05:10 +02:00
Zbigniew Zdanowicz 469ab367b1 Limit number of pipeline select commands when using multiple command queues
Related-To: NEO-7187

Signed-off-by: Zbigniew Zdanowicz <zbigniew.zdanowicz@intel.com>
2022-07-27 12:44:03 +02:00