Skip to content

Commit 742eb26

Browse files
authored
Merge pull request #252 from pszymich/add_kernelarg_wa
Enable `kernel_arg_type_qual` translation workaround
2 parents 8ce4bc8 + 1cd3e95 commit 742eb26

File tree

1 file changed

+6
-0
lines changed

1 file changed

+6
-0
lines changed

common_clang.cpp

Lines changed: 6 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -330,6 +330,12 @@ Compile(const char *pszProgramSource, const char **pInputHeaders,
330330
std::string Err;
331331
SPIRV::TranslatorOpts SPIRVOpts;
332332
SPIRVOpts.enableAllExtensions();
333+
334+
// Enable a workaround for this issue:
335+
// KhronosGroup/SPIRV-LLVM-Translator/issues/1109
336+
// To be disabled when implemeted without the workaround.
337+
SPIRVOpts.setPreserveOCLKernelArgTypeMetadataThroughString(true);
338+
333339
if (!optionsParser.hasOptDisable()) {
334340
SPIRVOpts.setMemToRegEnabled(true);
335341
}

0 commit comments

Comments
 (0)