Commit Graph

441 Commits

Author SHA1 Message Date
Chodor, Jaroslaw eb58e1f964 feature: Allow NEOReadDebugKeys and PrintDebugMessages envs in ocloc
This enables NEO's NEOReadDebugKeys and PrintDebugMessages in ocloc
in the same scenarios as in NEO OCL/L0 RT

Note :
* NEOReadDebugKeys=1 should not be prefixed with NEO_OCLOC_
* PrintDebugMessages=1 should be prefixed with NEO_OCLOC_
(to distinguish from OCL/L0 RT usage), so the full env
is NEO_OCLOC_PrintDebugMessages=1

Related-To: NEO-14473
Signed-off-by: Chodor, Jaroslaw <jaroslaw.chodor@intel.com>
2025-04-16 18:17:15 +02:00
Chodor, Jaroslaw 2ce694c52b feature: Enabling support for redirecting FCL to IGC for OCLOC
This allows for invoking IGC as OCL C translator in OCLOC paths

Accepted debug env :
NEO_OCLOC_UseIgcAsFcl=1 ; forces IGC
NEO_OCLOC_UseIgcAsFcl=2 ; forces FCL
NEO_OCLOC_UseIgcAsFcl=0 ; use defaults

Related-To: NEO-14473
Signed-off-by: Chodor, Jaroslaw <jaroslaw.chodor@intel.com>
2025-04-15 16:44:35 +02:00
Marcel Skierkowski e82be94368 refactor: Modernize writeDataToFile function
Signed-off-by: Marcel Skierkowski <marcel.skierkowski@intel.com>
2025-04-14 14:28:58 +02:00
Chodor, Jaroslaw a079a2654d feature: Enabling support for DisableDeepBind debug env in ocloc
Accepted debug env :
NEO_OCLOC_DisableDeepBind=1

Related-To: NEO-14473
Signed-off-by: Chodor, Jaroslaw <jaroslaw.chodor@intel.com>
2025-04-12 23:21:19 +02:00
Chodor, Jaroslaw 72ae27d51e feature: Enabling debug variables reader in ocloc
This allows for using debug variables in ocloc with
a few by-design limitations :
* debug var needs to be prefixed with NEO_OCLOC_
(when setting-up at runtime as environment variable
or using .config file)
* debug var needs to be tagged with S_OCLOC scope
(at compile time, in debug_variable .inl files)

Related-To: NEO-14473
Signed-off-by: Chodor, Jaroslaw <jaroslaw.chodor@intel.com>
2025-04-11 19:58:53 +02:00
Marcel Skierkowski b75fbe8e2c refactor: mock filesystem in ocloc ult pt.1
Mocked IO operations in ./ocloc_tests application

Mocked gtest stdout capture in ocloc tests

Related-To: NEO-14084
Signed-off-by: Marcel Skierkowski <marcel.skierkowski@intel.com>
2025-04-08 16:08:42 +02:00
Filip Hazubski 504440fc4d feature: Add ftrHeaplessMode flag
Pass hwInfo to isHeaplessModeEnabled and isForceBindlessRequired functions.

Related-To: NEO-14526

Signed-off-by: Filip Hazubski <filip.hazubski@intel.com>
2025-04-02 21:06:05 +02:00
Arek G 4751461a30 fix: ocloc: allow passing -device and -device_options in different formats
Related-To: NEO-9563
Signed-off-by: Arek G <arkadiusz.grubba@intel.com>
2025-03-25 18:07:21 +01:00
Chodor, Jaroslaw 8040d8bebf refactor: ocloc command line refactor
Related-To: NEO-14135

Signed-off-by: Chodor, Jaroslaw <jaroslaw.chodor@intel.com>
2025-02-25 11:11:28 +01:00
Kamil Kopryk 7c3468794e fix: add option to enable/disable heapless in ocloc
Related-To: GSD-10681
Signed-off-by: Kamil Kopryk <kamil.kopryk@intel.com>
2025-02-24 17:06:26 +01:00
Filip Hazubski 6b6202446b fix: Add asserts to ensure NonCopyable and NonMovable 3/n
Related-To: NEO-14068

Signed-off-by: Filip Hazubski <filip.hazubski@intel.com>
2025-02-18 17:16:03 +01:00
Filip Hazubski 4c7900008f refactor: Change wording from NonCopyableOrMovable to NonCopyableAndNonMovable
Signed-off-by: Filip Hazubski <filip.hazubski@intel.com>
2025-02-17 14:19:10 +01:00
Kamil Kopryk 03b56dc919 fix: untrusted input
Do not read an unlimited size of environment variables.

Signed-off-by: Kamil Kopryk <kamil.kopryk@intel.com>
2025-02-10 14:54:03 +01:00
Vysochyn, Illia f96fc552b2 feature: Add cmake flag NEO_BUILD_UNVERSIONED_OCLOC
Introduces the NEO_BUILD_UNVERSIONED_OCLOC flag (defaults to FALSE)
that builds ocloc without a version suffix if set to TRUE.
The default behavior is to build a versioned one.

Applies only to UNIX-family systems.

Related-To: NEO-13060

Signed-off-by: Vysochyn, Illia <illia.vysochyn@intel.com>
2025-02-05 18:56:45 +01:00
Michał Pryba 75bc74089b refactor: adjust file names after pre-gen12 removal 2/3
Related-To: NEO-12681
Signed-off-by: Michał Pryba <michal.pryba@intel.com>
2025-02-03 15:31:51 +01:00
Naklicki, Mateusz 860b940edf fix(ocloc): add 'asm' and 'disasm' support for PTL
Related-To: NEO-12803
Signed-off-by: Naklicki, Mateusz <mateusz.naklicki@intel.com>
2025-02-03 15:04:46 +01:00
Naklicki, Mateusz 6d63f688eb fix(ocloc): add 'asm' and 'disasm' support for missing opensourced platforms
This change addresses the lack of translation in the specified file,
which resulted in non-functional 'disasm' and 'asm' ocloc commands
for the following platforms: Meteor Lake (MTL), Arrow Lake (ARL),
Battle Mage (BMG), and Lunar Lake (LNL).

Signed-off-by: Naklicki, Mateusz <mateusz.naklicki@intel.com>
2025-02-03 09:57:28 +01:00
Chodor, Jaroslaw 0938a0eaf9 feature: Adding support for extending KernerlDescriptor
Related-To: NEO-12747

Signed-off-by: Chodor, Jaroslaw <jaroslaw.chodor@intel.com>
2025-01-25 12:08:27 +01:00
Michał Pryba 53831f61df refactor: adjust file names after pre-gen12 removal 1/3
Related-To: NEO-12681
Signed-off-by: Michał Pryba <michal.pryba@intel.com>
2025-01-22 22:47:24 +01:00
Chodor, Jaroslaw 5619da6238 feature: Adding hook for applying OpenVino-related AIL
Related-To: NEO-12747

Signed-off-by: Chodor, Jaroslaw <jaroslaw.chodor@intel.com>
2025-01-20 17:38:49 +01:00
Compute-Runtime-Validation 242a31a024 Revert "refactor: remove excess cast to C-string and add const reference"
This reverts commit 34ee40393f.

Signed-off-by: Compute-Runtime-Validation <compute-runtime-validation@intel.com>
2025-01-15 02:43:40 +01:00
Semenov Herman (Семенов Герман) 34ee40393f refactor: remove excess cast to C-string and add const reference
Signed-off-by: Semenov Herman (Семенов Герман) <GermanAizek@yandex.ru>
2025-01-14 13:25:31 +01:00
Compute-Runtime-Validation 58707e0cf7 Revert "refactor: migration to std::make_unique C++17"
This reverts commit 4cf685cb7d.

Signed-off-by: Compute-Runtime-Validation <compute-runtime-validation@intel.com>
2025-01-09 01:41:36 +01:00
Semenov Herman (Семенов Герман) 4cf685cb7d refactor: migration to std::make_unique C++17
Signed-off-by: Semenov Herman (Семенов Герман) <GermanAizek@yandex.ru>
2025-01-08 17:20:00 +01:00
Marcel Skierkowski e27a6dc280 refactor: use virtualFileSystem in ULTs
reducing the number of tests that have interactions with filesystem.
writeDataToFile() saves filename and content in std::map.
fileExistsHasSize() checks if file was previously written to virtualFileSystem
loadDataFromVirtualFile() fetches data from std::map based on filename

Related-To: NEO-7006
Signed-off-by: Marcel Skierkowski <marcel.skierkowski@intel.com>
2024-12-13 17:57:07 +01:00
Filip Hazubski 43c199185a fix: Add explicit nullptr checks
Signed-off-by: Filip Hazubski <filip.hazubski@intel.com>
2024-12-10 10:06:56 +01:00
Mateusz Jablonski fa58073095 refactor: remove not used usings/typedefs/variables
Signed-off-by: Mateusz Jablonski <mateusz.jablonski@intel.com>
2024-11-28 16:19:39 +01:00
Chodor, Jaroslaw 3a0c2005d4 refactor: Cleanup around options files
* Adding options*.inl to sources list
* Improving robustness of missing IGC library log

Related-To: NEO-12747

Signed-off-by: Chodor, Jaroslaw <jaroslaw.chodor@intel.com>
2024-11-17 17:13:03 +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
Mateusz Jablonski fde3b36125 fix: avoid enum out of scope cast in getProductsForTargetRange function
Signed-off-by: Mateusz Jablonski <mateusz.jablonski@intel.com>
2024-11-07 13:24:17 +01:00
Artur Harasimiuk 7c0ecf234f build: detect IGA major version
Signed-off-by: Artur Harasimiuk <artur.harasimiuk@intel.com>
2024-11-06 14:27:39 +01:00
Marcel Skierkowski 49d999abe6 fix: remove defaultProfilingTimerResolution from RuntimeCapabilityTable
Related-To: NEO-12275
Signed-off-by: Marcel Skierkowski <marcel.skierkowski@intel.com>
2024-11-04 12:02:11 +01:00
Chodor, Jaroslaw 5f908ce092 feature: adding support for custom compiler backends
This adds abbility to load different versions of the backend
compiler based on underlying device.

Related-To: NEO-12747

Signed-off-by: Chodor, Jaroslaw <jaroslaw.chodor@intel.com>
2024-10-23 19:55:36 +02:00
Bartosz Dunajski ff80a02fcb refactor: parse extra zebin params
Related-To: NEO-12591

Signed-off-by: Bartosz Dunajski <bartosz.dunajski@intel.com>
2024-10-21 09:59:33 +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
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
Compute-Runtime-Validation 2098e64dc1 Revert "feature: adding support for custom compiler backends"
This reverts commit 8098bcc48d.

Signed-off-by: Compute-Runtime-Validation <compute-runtime-validation@intel.com>
2024-10-16 02:07:25 +02:00
Chodor, Jaroslaw 8098bcc48d feature: adding support for custom compiler backends
This adds abbility to load different versions of the backend
compiler based on underlying device.

Related-To: NEO-12747

Signed-off-by: Chodor, Jaroslaw <jaroslaw.chodor@intel.com>
2024-10-14 18:23:11 +02:00
Artur Harasimiuk 22505ca3ed refactor: cleanup coding style
Signed-off-by: Artur Harasimiuk <artur.harasimiuk@intel.com>
2024-10-02 12:42:39 +02:00
Mateusz Jablonski 9db83b8231 refactor: unify isMidThreadPreemptionSupported function
mid thread preemption can be enabled only by ftrWalkerMTP flag
pre-Xe2 devices doesn't support MTP

Signed-off-by: Mateusz Jablonski <mateusz.jablonski@intel.com>
2024-10-01 11:26:04 +02:00
Mateusz Jablonski 5912b43841 refactor: remove dead code
Signed-off-by: Mateusz Jablonski <mateusz.jablonski@intel.com>
2024-09-17 13:41:50 +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
Mateusz Jablonski 51d03ba130 refactor: remove not needed check
OsLibrary::load already checks if library is loaded

Related-To: NEO-12273
Signed-off-by: Mateusz Jablonski <mateusz.jablonski@intel.com>
2024-08-20 13:30:00 +02:00
Mateusz Jablonski 579af57161 refactor: don't call OsLibrary::load directly, use function pointer
this allows mocking this call in ULT

Signed-off-by: Mateusz Jablonski <mateusz.jablonski@intel.com>
2024-08-20 08:59:26 +02:00
Mateusz Jablonski 90015a584b fix(ocloc): disable ocloc output if former ocloc was used
in case of fallback to former ocloc, the former ocloc setups outputs

Related-To: NEO-12273
Signed-off-by: Mateusz Jablonski <mateusz.jablonski@intel.com>
2024-08-14 15:49:14 +02:00
Mateusz Jablonski 922edfd68d fix(ocloc): correct ocloc name in supported devices query
previous approach was to version ocloc library but it was deprecated
right now there will be 2 known libraries:
- libocloc.so - for mainstream
- libocloc-legacy1.so for legacy platforms

Related-To: NEO-12273, NEO-9630
Signed-off-by: Mateusz Jablonski <mateusz.jablonski@intel.com>
2024-08-14 11:05:28 +02:00
Mateusz Jablonski d963318cad fix: add fallback to former ocloc in case of invalid device error
Related-To: NEO-12273
Signed-off-by: Mateusz Jablonski <mateusz.jablonski@intel.com>
2024-08-14 09:30:57 +02:00
Mateusz Jablonski a32bb4d9a4 refactor: extract logic of calling former ocloc to separate function
Related-To: NEO-12273
Signed-off-by: Mateusz Jablonski <mateusz.jablonski@intel.com>
2024-08-13 17:24:48 +02:00
Mateusz Jablonski 0eec0cdf57 refactor: define ocloc current and former names in shared ocloc file
ensure both names are different

Related-To: NEO-12273
Signed-off-by: Mateusz Jablonski <mateusz.jablonski@intel.com>
2024-08-13 14:40:55 +02:00