Commit Graph

25 Commits

Author SHA1 Message Date
Jack Myers 7f9fadc314 fix: regression caused by tbx fault mngr
Addresses regressions from the reverted merge
of the tbx fault manager for host memory.

Recursive locking of mutex caused deadlock.

To fix, separate tbx fault data from base
cpu fault data, allowing separate mutexes
for each, eliminating recursive locks on
the same mutex.

By separating, we also help ensure that tbx-related
changes don't affect the original cpu fault manager code
paths.

As an added safe guard preventing critical regressions
and avoiding another auto-revert, the tbx fault manager
is hidden behind a new debug flag which is disabled by default.

Related-To: NEO-12268
Signed-off-by: Jack Myers <jack.myers@intel.com>
2025-01-09 07:48:53 +01:00
Compute-Runtime-Validation 124e755b9d Revert "fix: regression caused by tbx fault mngr"
This reverts commit 9a14fe2478.

Signed-off-by: Compute-Runtime-Validation <compute-runtime-validation@intel.com>
2024-12-19 17:35:03 +01:00
Jack Myers 9a14fe2478 fix: regression caused by tbx fault mngr
Addresses regressions from the reverted merge
of the tbx fault manager for host memory.

This fixes attempts by the tbx fault manager
to protect/unprotect host buffer memory, even
if the host ptr was not driver-allocated.

In the case of the smoke test that triggered
the critical regression, clCreateBuffer was
called with the CL_MEM_USE_HOST_PTR flag.
The subsequent `mprotect` calls on the
provided host ptr then failed.

Related-To: NEO-12268
Signed-off-by: Jack Myers <jack.myers@intel.com>
2024-12-18 23:16:36 +01:00
Compute-Runtime-Validation 6c5d9a6ed7 Revert "feature: extend TBX page fault manager from CPU implementation"
This reverts commit 51c0e80299.

Signed-off-by: Compute-Runtime-Validation <compute-runtime-validation@intel.com>
2024-12-12 12:30:22 +01:00
Jack Myers 51c0e80299 feature: extend TBX page fault manager from CPU implementation
In TBX mode, the host could not write to host buffers after access from device
code due to the lack of a migration mechanism post-initial TBX upload.
Migration is unnecessary with real hardware, but required for TBX.

This patch introduces a new page fault manager type that extends the original
CPU fault manager, enabling automatic migration of host buffers in TBX mode.

Refactoring was necessary to avoid diamond inheritance, achieved by using a
template parameter as the base class for OS-specific fault managers.

Related-To: NEO-12268
Signed-off-by: Jack Myers <jack.myers@intel.com>
2024-12-11 09:09:50 +01:00
Bartosz Dunajski dab4166837 fix: add missing aub polls on sync points
Related-To: HSD-14023925176

Signed-off-by: Bartosz Dunajski <bartosz.dunajski@intel.com>
2024-11-21 09:17:54 +01:00
Bartosz Dunajski dd8460beba refactor: reduce TBX download timeout for unit tests
Signed-off-by: Bartosz Dunajski <bartosz.dunajski@intel.com>
2024-09-09 19:05:03 +02:00
Bartosz Dunajski db611962f7 fix: improve task count handling in tbx download path
Related-To: HSD-18039789178

Signed-off-by: Bartosz Dunajski <bartosz.dunajski@intel.com>
2024-08-28 15:32:15 +02:00
Mateusz Hoppe b3d72ddd3d fix: write memory for resident allocations in simulation mode
- refactor and call proceesFlushResdiency() on memoryOperationsHandler
- call free() to remove allocation from resident allocations when
graphics allocation is released

Related-To: NEO-11719

Signed-off-by: Mateusz Hoppe <mateusz.hoppe@intel.com>
2024-06-14 18:49:01 +02:00
Mateusz Jablonski 739d181026 refactor: correct naming of enum class constants 6/n
Signed-off-by: Mateusz Jablonski <mateusz.jablonski@intel.com>
2023-12-13 14:48:52 +01:00
Dunajski, Bartosz 25195ebc96 fix: capability to write memory chunk in aub/tbx mode
Related-To: GSD-6604

Signed-off-by: Dunajski, Bartosz <bartosz.dunajski@intel.com>
2023-10-19 19:13:11 +02:00
Warchulski, Jaroslaw 0556d543a3 Cleanup includes 56
Related-To: NEO-5548
Signed-off-by: Warchulski, Jaroslaw <jaroslaw.warchulski@intel.com>
2023-02-16 14:42:44 +01:00
Warchulski, Jaroslaw a2fe929f0c Cleanup includes 18
Cleaned up files:
shared/source/command_stream/command_stream_receiver_hw.h
shared/source/compiler_interface/compiler_interface.h
shared/source/direct_submission/direct_submission_hw.h
shared/source/helpers/dirty_state_helpers.h

Related-To: NEO-5548
Signed-off-by: Warchulski, Jaroslaw <jaroslaw.warchulski@intel.com>
2023-01-02 13:28:29 +01:00
Maciej Plewka 4b42b066f8 Use dedicated using type for TaskCount
Related-To: NEO-7155

Signed-off-by: Maciej Plewka <maciej.plewka@intel.com>
2022-11-28 16:44:44 +01:00
Mateusz Jablonski 57cea7365e Return submission status from flushTagUpdate method
Related-To: NEO-7412
Signed-off-by: Mateusz Jablonski <mateusz.jablonski@intel.com>
2022-11-09 14:04:16 +01:00
Artur Harasimiuk 2cc2d05c37 remove unused include
Signed-off-by: Artur Harasimiuk <artur.harasimiuk@intel.com>
2022-06-28 10:59:30 +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
Jobczyk, Lukasz a285712cc4 Add missing download allocation calls
Signed-off-by: Jobczyk, Lukasz <lukasz.jobczyk@intel.com>
Signed-off-by: Lukasz Jobczyk <lukasz.jobczyk@intel.com>
2022-03-31 09:49:22 +02:00
Fabian Zwolinski 3d8effcd69 Clean-Up unused code related to GMock
This commit:
- Removes usings e.g. ::testing::Return
- Removes unnecessary gmock inclues
- Replaces Gmock macros (e.g. EXPECT_THAT) with our custom implementations

Related-To: NEO-4941
Signed-off-by: Fabian Zwolinski <fabian.zwolinski@intel.com>
2022-03-22 16:16:34 +01:00
Dominik Dabek e0c892ed55 Add lock to downloading allocations on tbx
When running multiple threads, one thread could clear
allocationsForDownload while another was iterating over it.

Signed-off-by: Dominik Dabek <dominik.dabek@intel.com>
2022-02-16 16:51:41 +01:00
Lukasz Jobczyk 7f1c87f049 Fix flush tag update in TBX mode
Signed-off-by: Lukasz Jobczyk <lukasz.jobczyk@intel.com>
2021-11-24 12:30:29 +01:00
Filip Hazubski 27b5952ba3 Correct initializeEngine usage in aub tests
Signed-off-by: Filip Hazubski <filip.hazubski@intel.com>
2021-10-14 19:36:00 +02:00
Filip Hazubski 29c64c3dd0 Disable implicit scaling for cooperative kernels
When implicit scaling is disabled use useSingleSubdeviceValue = true.

Resolves: NEO-5757

Signed-off-by: Filip Hazubski <filip.hazubski@intel.com>
2021-08-18 14:56:37 +02:00
Dominik Dabek 39f0387ecc Move tbx stream, tbx csr to shared
Related-To: NEO-5161

Signed-off-by: Dominik Dabek <dominik.dabek@intel.com>i
2021-05-31 14:35:32 +02:00
Dominik Dabek d0cb27226f Move mocks: cif, gmm context, compilers
Related-To: NEO-5161

Signed-off-by: Dominik Dabek <dominik.dabek@intel.com>
2021-05-27 12:51:28 +02:00