mirror of
https://github.com/intel/compute-runtime.git
synced 2026-01-05 18:00:01 +08:00
Ocloc asm/disasm support for zebin
This commit adds option to disassemble and assemble zebinary. Disasm disassembles zebinary into sections. Text sections are translated to assembly, relocations and symbols are translated into human readable format. Asm assembles zebinary from files generated by disasm. Signed-off-by: Krystian Chmielewski <krystian.chmielewski@intel.com>
This commit is contained in:
committed by
Compute-Runtime-Automation
parent
cdffa8619c
commit
4f0d19628e
@@ -168,6 +168,23 @@ class ConstStringRef {
|
||||
return ('\0' == *rhs);
|
||||
}
|
||||
|
||||
constexpr bool startsWith(ConstStringRef subString) const noexcept {
|
||||
if (subString.length() > len) {
|
||||
return false;
|
||||
}
|
||||
const char *findEnd = ptr + subString.length();
|
||||
const char *lhs = ptr;
|
||||
const char *rhs = subString.begin();
|
||||
while ((lhs < findEnd)) {
|
||||
if (*lhs != *rhs) {
|
||||
return false;
|
||||
}
|
||||
lhs++;
|
||||
rhs++;
|
||||
}
|
||||
return true;
|
||||
}
|
||||
|
||||
constexpr bool isEqualWithoutSeparator(const char separator, const char *subString) const noexcept {
|
||||
const char *end = ptr + len;
|
||||
const char *lhs = ptr;
|
||||
|
||||
Reference in New Issue
Block a user