mirror of
https://github.com/intel/compute-runtime.git
synced 2026-01-08 22:12:59 +08:00
fix: truncated invalid kernel reason message
IGC will add "invalid_kernel: uses-fp64-math" into kernel binary for fp64 unsupported platform. "uses-fp64-math" will be truncated to "uses" due to "-" is not a valid identifier. It makes application can't get "uses-fp64-math" through zeKernelGetSourceAttributes. Related-To: NEO-7794 Signed-off-by: Pan Zhenjie <zhenjie.pan@intel.com>
This commit is contained in:
committed by
Compute-Runtime-Automation
parent
57e68624f3
commit
ad49a6e3b0
@@ -1,5 +1,5 @@
|
||||
/*
|
||||
* Copyright (C) 2020-2022 Intel Corporation
|
||||
* Copyright (C) 2020-2023 Intel Corporation
|
||||
*
|
||||
* SPDX-License-Identifier: MIT
|
||||
*
|
||||
@@ -79,13 +79,14 @@ TEST(YamlIsAlphaNumeric, GivenCharThenReturnsTrueOnlyWhenCharIsNumberOrLetter) {
|
||||
}
|
||||
}
|
||||
|
||||
TEST(YamlIsNameIdentifierCharacter, GivenCharThenReturnsTrueOnlyWhenCharIsNumberOrLetterOrUnderscore) {
|
||||
TEST(YamlIsNameIdentifierCharacter, GivenCharThenReturnsTrueOnlyWhenCharIsNumberOrLetterOrUnderscoreOrHyphen) {
|
||||
std::set<char> validChars{};
|
||||
using It = IteratorAsValue<char>;
|
||||
validChars.insert(It{'a'}, ++It{'z'});
|
||||
validChars.insert(It{'A'}, ++It{'Z'});
|
||||
validChars.insert(It{'0'}, ++It{'9'});
|
||||
validChars.insert('_');
|
||||
validChars.insert('-');
|
||||
for (int c = std::numeric_limits<char>::min(); c <= std::numeric_limits<char>::max(); ++c) {
|
||||
bool expected = validChars.count(static_cast<char>(c)) > 0;
|
||||
EXPECT_EQ(expected, NEO::Yaml::isNameIdentifierCharacter(static_cast<char>(c))) << static_cast<char>(c);
|
||||
|
||||
Reference in New Issue
Block a user