Commit Graph

190 Commits

Author SHA1 Message Date
Mateusz Jablonski 5fa5387781 fix(ocloc): remove incorrect ir binary caching during build from source
Signed-off-by: Mateusz Jablonski <mateusz.jablonski@intel.com>
2024-06-12 12:02:39 +02:00
Mateusz Hoppe 037957a7ae feature: add -stateful_address_mode to ocloc
- allows to choose bindless or bindful addressing in generated code

Related-To: NEO-11704

Signed-off-by: Mateusz Hoppe <mateusz.hoppe@intel.com>
2024-06-12 07:46:12 +02:00
Mateusz Jablonski cfd5f0c9b3 fix: use .spv for intermediate representation
Related-To: NEO-7785
Signed-off-by: Mateusz Jablonski <mateusz.jablonski@intel.com>
2024-06-11 12:06:57 +02:00
Compute-Runtime-Validation f4106ca44c Revert "fix: use .spv for intermediate representation"
This reverts commit 6c9bca8cdc.

Signed-off-by: Compute-Runtime-Validation <compute-runtime-validation@intel.com>
2024-06-11 05:57:05 +02:00
Mateusz Jablonski 6c9bca8cdc fix: use .spv for intermediate representation
Related-To: NEO-7785
Signed-off-by: Mateusz Jablonski <mateusz.jablonski@intel.com>
2024-06-10 15:38:50 +02:00
Filip Hazubski 5ae2709e6e fix: Remove allow-zebin and enable-zebin compile options
Zebin is enabled by default.

Signed-off-by: Filip Hazubski <filip.hazubski@intel.com>
2024-06-10 14:08:40 +02:00
Fabian Zwoliński 78bd3da078 fix: ocloc - add bindless mode options if bindless is enabled
If release helper is not present,
do not add bindless mode options.

Related-To: NEO-7063
Signed-off-by: Fabian Zwoliński <fabian.zwolinski@intel.com>
2024-05-23 14:10:28 +02:00
Timo Aaltonen cb984b3e4b fix: Fix various typos.
Signed-off-by: Timo Aaltonen <tjaalton@debian.org>
2024-04-17 20:03:06 +02:00
Kacper Nowak 35ca2bbea9 refactor: refactor logic for querying atomic FP capabilities
- Move logic from product helper to compiler product helper
- Add method for adjusting fp16 and extra capabilities using release
helper (if present).


Signed-off-by: Kacper Nowak <kacper.nowak@intel.com>
2024-03-28 15:27:45 +01:00
Mateusz Hoppe 9f701d204e test: remove unnecessary error output in ocloc ults
Signed-off-by: Mateusz Hoppe <mateusz.hoppe@intel.com>
2024-03-08 14:21:22 +01:00
Mateusz Jablonski 82147fcdd6 fix: remove redundant saveOutput method in ocloc
when saving string as output make it null-terminated string

Signed-off-by: Mateusz Jablonski <mateusz.jablonski@intel.com>
2024-03-04 15:28:42 +01:00
Mateusz Hoppe 6d68b1fac4 test: cleanup ocloc_tests - suppress printing
- do not print messages to stdout from ocloc_tests

Signed-off-by: Mateusz Hoppe <mateusz.hoppe@intel.com>
2024-02-20 16:39:24 +01:00
Chodor, Jaroslaw b58717b9e3 feature: Add support for legacy acronyms in ocloc's fatbinary
Expands support for deprecated acronyms to fatbinary. Previously,
these were allowed only in single-target builds.

Related-To: NEO-10190

Signed-off-by: Chodor, Jaroslaw <jaroslaw.chodor@intel.com>
2024-02-15 10:14:49 +01:00
Chodor, Jaroslaw 7e795cd3c1 feature: Adding support for OCL C support queries to ocloc
Feature needed for automated OCL C compilation with ocloc as backend.
Added queries :
* CL_DEVICE_EXTENSIONS
* CL_DEVICE_EXTENSIONS_WITH_VERSION
* CL_DEVICE_PROFILE
* CL_DEVICE_OPENCL_C_ALL_VERSIONS
* CL_DEVICE_OPENCL_C_FEATURES

Sample command line:
ocloc query -device skl CL_DEVICE_OPENCL_C_FEATURES

Related-To: GSD-7420

Signed-off-by: Chodor, Jaroslaw <jaroslaw.chodor@intel.com>
2023-12-18 15:19:16 +01:00
Mateusz Jablonski c9664e6bad refactor: rename global debug manager to debugManager
Signed-off-by: Mateusz Jablonski <mateusz.jablonski@intel.com>
2023-11-30 13:00:59 +01:00
Mateusz Jablonski 330fb40107 fix: fix clang-tidy issues
Signed-off-by: Mateusz Jablonski <mateusz.jablonski@intel.com>
2023-10-31 16:32:06 +01:00
Fabian Zwolinski b2ba1fbecf fix: enforce zebin format by default in Ocloc for ICL/TGL/RKL/ADL
Products for which zebin has been set as default format in OCLOC:
- ICELAKE_LP
- TIGERLAKE_LP
- ROCKETLAKE
- ALDERLAKE_S
- ALDERLAKE_P
- ALDERLAKE_N

The default format does not override `--format` parameter.

Related-To: NEO-8334
Signed-off-by: Fabian Zwolinski <fabian.zwolinski@intel.com>
2023-09-08 16:16:18 +02:00
Fabian Zwolinski 41914be8c3 fix: enforce zebin format by default in Ocloc
Related-To: NEO-8334
Signed-off-by: Fabian Zwolinski <fabian.zwolinski@intel.com>
2023-09-06 15:22:01 +02:00
Chodor, Jaroslaw 49edbc3b60 refactor: ocloc - folding error codes to lib api header
These error codes are used as return codes from ocloc api.
As such, it's useful to have them defined in the ocloc api header.

Signed-off-by: Chodor, Jaroslaw <jaroslaw.chodor@intel.com>
2023-09-05 20:28:11 +02:00
Kacper Kasper abfed5a762 fix: add specialization constants to cache hash in spirv path
Related-To: NEO-4262

Signed-off-by: Kacper Kasper <kacper.k.kasper@intel.com>
2023-09-01 14:04:59 +02:00
Fabian Zwolinski 1369882b3c fix: ocloc - regenerate genHash after compilation
This PR ensures that the genHash will be the same
whether the cl_cache is re-used or just created.
So it has to be regenerated after compilation
to make sure it's created with non NULL irBinary.

It also allows to cache debugDataBinary.

Minor: Rename NEO_PERSISTENT_CACHE -> NEO_CACHE_PERSISTENT in FAQ,
since this version is used in code.

Related-To: NEO-8288, NEO-8092
Signed-off-by: Fabian Zwolinski <fabian.zwolinski@intel.com>
2023-08-28 13:11:49 +02:00
Mateusz Jablonski 02337bbbf8 refactor: remove not needed includes from ocloc sources
Signed-off-by: Mateusz Jablonski <mateusz.jablonski@intel.com>
2023-07-28 18:56:16 +02:00
Artem Gindinson 7afedd7a63 fix: Add OCL C extensions to empty device ext string for Clang 14 compatibility
Clang 13+ requires (1) that each enabled extension be accompanied by
corresponding OCL C extension macro definitions. Fix the extension string for
empty device cases to conform to that - pass the same language feature macros
as we would for regular image support.

(1) release/14.x/clang/lib/Basic/OpenCLOptions.cpp#L142-L149

Related-To: HSD-18031230472

Signed-off-by: Artem Gindinson <artem.gindinson@intel.com>
2023-07-24 15:40:25 +02:00
Mateusz Hoppe eb2225e623 Revert "fix: no longer append .bin to binary name when "-output_no_suffix" ...
This reverts commit df62888efc.

Signed-off-by: Mateusz Hoppe <mateusz.hoppe@intel.com>
2023-07-05 12:21:55 +02:00
Filip Hazubski df62888efc fix: no longer append .bin to binary name when "-output_no_suffix" is passed
Signed-off-by: Filip Hazubski <filip.hazubski@intel.com>
2023-06-29 14:10:25 +02:00
Mateusz Hoppe b600410af2 fix: ocloc - rename "-device_options" param
- ocloc param names use "_"
Related-To: NEO-8037

Signed-off-by: Mateusz Hoppe <mateusz.hoppe@intel.com>
2023-06-16 11:14:57 +02:00
Fabian Zwolinski bb16789fcd feature: Allow to pass multiple devices separated by commas in -device-options
Related-To: NEO-8037
Signed-off-by: Fabian Zwolinski <fabian.zwolinski@intel.com>
2023-06-14 17:23:35 +02:00
Fabian Zwolinski d00345d115 feature: Add ability to specify options per-device in Ocloc
Related-To: NEO-8037
Signed-off-by: Fabian Zwolinski <fabian.zwolinski@intel.com>
2023-06-06 19:33:48 +02:00
Daria Hinz 68b6cfebd2 feature: Add default ip version values to helper
Signed-off-by: Daria Hinz <daria.hinz@intel.com>
Related-To: NEO-8021
2023-06-02 12:10:21 +02:00
Daria Hinz 1d64b94f30 feature: Match config based on device & rev ID
This change matches the appropriate aot config
for the combination of device ID and revision ID.

Signed-off-by: Daria Hinz <daria.hinz@intel.com>
Related-To: NEO-7905
2023-05-10 08:22:09 +02:00
Mateusz Hoppe 252c5a99cf feature: ocloc - add new option for output binary filename
- new option "-o [filename]" allows to set output binary filename, ocloc
will not add any extension to the name
- no other files will be produced (.spv/.cpp/.dbg)
Related-To: NEO-7935

Signed-off-by: Mateusz Hoppe <mateusz.hoppe@intel.com>
2023-05-10 02:24:59 +02:00
Daria Hinz 856318ccc2 test: Add output capture to ULT
Signed-off-by: Daria Hinz <daria.hinz@intel.com>
2023-04-24 15:17:16 +02:00
Daria Hinz a2bc1d82e4 fix: Improved reporting of incorrect device
We want to report unrecognized device only after verifying
all possible variants, including deprecated ones.

Signed-off-by: Daria Hinz <daria.hinz@intel.com>
Related-To: NEO-7903
2023-04-21 12:33:34 +02:00
Daria Hinz 2647efc23c feat: Add support for ip version value in ocloc
Ocloc supports passing hw ip version value to -device arg in
the form of major.minor.revision.
This change adds support for directly passed value as uint32_t as well.
Support added for single and fat binary.

Signed-off-by: Daria Hinz <daria.hinz@intel.com>
Related-To: NEO-7903
2023-04-20 13:20:11 +02:00
Mateusz Hoppe 97a8f15fbd fix: cleanup memory leaks in ocloc
- enable memory leaks detection in ocloc tests

Related-To: NEO-7467

Signed-off-by: Mateusz Hoppe <mateusz.hoppe@intel.com>
2023-04-19 13:48:49 +02:00
Maciej Plewka 730578112f Report cl_khr_integer_dot_product extension
Related-To: NEO-6206

With this commit OpenCL will report cl_khr_integer_dot_product extension
in version 2. With all properties enabled.

Signed-off-by: Maciej Plewka <maciej.plewka@intel.com>
2023-04-14 14:46:18 +02:00
Mateusz Hoppe 5576b9e074 fix: ocloc - remove memory leaks
Related-To: NEO-7467

Signed-off-by: Mateusz Hoppe <mateusz.hoppe@intel.com>
2023-04-06 16:58:18 +02:00
Mateusz Hoppe 1498ae30bd fix: do not append .bin extension when -output filename has .out/exe
- effective only when -output_no_suffix is also passed
- this change allows to keep backwards compatibility before:
0c5264dfeb

Related-To: NEO-7474

Signed-off-by: Mateusz Hoppe <mateusz.hoppe@intel.com>
2023-04-03 10:01:28 +02:00
Mateusz Hoppe 0c5264dfeb Ocloc - fix binary output filename with "-output_no_suffix"
- .bin extension should be added to produced binary file when
"-output_no_suffix" flag is passed

Related-To: NEO-7474

Signed-off-by: Mateusz Hoppe <mateusz.hoppe@intel.com>
2023-03-08 15:51:20 +01:00
Krystian Chmielewski 9f7f2318bd fix(ocloc): fallback to deprecated acronyms
When revision_id argument is passed fallback to using
initHardwareInfoForDeprecatedAcronyms.
* initHardwareInfoForProductConfig returns INVALID_DEVICE if device
acronym and revision id is passed.
* initHardwareInfoForDeprecatedAcronyms sets aot config revision
to revisionId.

Resolves: NEO-7738

Signed-off-by: Krystian Chmielewski <krystian.chmielewski@intel.com>
2023-03-02 11:43:34 +01:00
Daria Hinz 59109a08bb Switch device ID support to product config helper
This commit switches the device ID logic from the deprecated
to the new one, so that if the user passes a hex value to the -device
parameter, ocloc will use the new implementation in the product config
helper. The change also introduces a fix for setting the values in the
correct order to configure the hwIfno correctly.

Signed-off-by: Daria Hinz daria.hinz@intel.com
Related-To: NEO-7487
2023-02-03 16:55:41 +01:00
Kamil Kopryk cab4b956eb refactor: rename compiler product helper files
Related-To: NEO-6853
Signed-off-by: Kamil Kopryk <kamil.kopryk@intel.com>
2023-02-03 09:03:24 +01:00
Daria Hinz 14f5a61993 Fatbinary optimization for -device release target
This commit is to introduce optimizations in ocloc when building
targets for release and family.
Instead of building fatbinary after all available targets in
the RTL ID table, we introduce optimizations when there is an
acronym available for the platform in the DEVICE table,
we limit to them only.

Signed-off-by: Daria Hinz <daria.hinz@intel.com>
Related-To: NEO-7582
2023-02-01 16:19:13 +01:00
Kamil Kopryk 7487d1450e Move CompilerProductHelper ownership to RootDeviceEnvironment and Ocloc
Related-To: NEO-6853
Signed-off-by: Kamil Kopryk <kamil.kopryk@intel.com>
2023-02-01 13:09:12 +01:00
Daria Hinz 4d359b5eef fix: Support multiple option settings in ocloc
If ocloc is given -options several times, the variable is overwritten.
This change allows the user to add additional options multiple times.

Signed-off-by: Daria Hinz <daria.hinz@intel.com>
2023-01-20 12:10:21 +01:00
Mateusz Jablonski 4647180c76 refactor: remove platform type string
this property is no longer needed as we compile kernels per product family

Signed-off-by: Mateusz Jablonski <mateusz.jablonski@intel.com>
2023-01-04 13:48:16 +01:00
Compute-Runtime-Validation 5a6d358166 Revert "refactor: remove platform type string"
This reverts commit 58b443ecf1.

Signed-off-by: Compute-Runtime-Validation <compute-runtime-validation@intel.com>
2023-01-04 11:08:51 +01:00
Mateusz Jablonski 58b443ecf1 refactor: remove platform type string
this property is no longer needed as we compile kernels per product family

Signed-off-by: Mateusz Jablonski <mateusz.jablonski@intel.com>
2023-01-04 09:26:29 +01:00
Kamil Kopryk 232b886056 Rename HwInfoConfig to ProductHelper
Related-To: NEO-6853
Signed-off-by: Kamil Kopryk <kamil.kopryk@intel.com>
2022-12-14 14:39:52 +01:00
Mateusz Jablonski 23fd280334 Unify definition of hardware ip version
Signed-off-by: Mateusz Jablonski <mateusz.jablonski@intel.com>
2022-12-06 17:22:24 +01:00