Zebin: Add support for querying device globals by host name

This commit adds support for querying global pointers via decorated
names passed in zeInfo.
Related-To: NEO-6734
Signed-off-by: Kacper Nowak <kacper.nowak@intel.com>
This commit is contained in:
Kacper Nowak
2022-02-23 11:48:31 +00:00
committed by Compute-Runtime-Automation
parent 999c6424a4
commit 38086029ed
11 changed files with 289 additions and 8 deletions

View File

@@ -1,5 +1,5 @@
/*
* Copyright (C) 2020-2021 Intel Corporation
* Copyright (C) 2020-2022 Intel Corporation
*
* SPDX-License-Identifier: MIT
*
@@ -664,6 +664,16 @@ inline bool YamlParser::readValueChecked<bool>(const Node &node, bool &outValue)
return true;
}
template <>
inline bool YamlParser::readValueChecked<std::string>(const Node &node, std::string &outValue) const {
const auto &token = tokens[node.value];
if (Token::Type::LiteralString != token.traits.type) {
return false;
}
outValue.resize(token.len);
std::copy(token.pos, token.pos + token.len, outValue.begin());
return true;
}
} // namespace Yaml
} // namespace NEO