mirror of
https://github.com/intel/compute-runtime.git
synced 2026-01-03 06:49:52 +08:00
fix: Better IR file format ext handling
This fix makes ocloc honor IR file format when picking extension for the output file. Additionally, this commit removes reduntant IR output when compiling from IR. Related-To: NEO-15876 Signed-off-by: Chodor, Jaroslaw <jaroslaw.chodor@intel.com>
This commit is contained in:
committed by
Compute-Runtime-Automation
parent
abb713e18f
commit
1aa869d67d
@@ -1,5 +1,5 @@
|
||||
/*
|
||||
* Copyright (C) 2021-2022 Intel Corporation
|
||||
* Copyright (C) 2021-2025 Intel Corporation
|
||||
*
|
||||
* SPDX-License-Identifier: MIT
|
||||
*
|
||||
@@ -10,6 +10,7 @@
|
||||
|
||||
#include "CL/cl.h"
|
||||
|
||||
#include <algorithm>
|
||||
#include <cstdint>
|
||||
#include <cstring>
|
||||
#include <string>
|
||||
@@ -83,4 +84,14 @@ inline std::vector<std::string> split(const std::string &input, const char *deli
|
||||
inline uint32_t toUint32t(const std::string &input) {
|
||||
return static_cast<uint32_t>(std::stoul(input, nullptr, 0));
|
||||
}
|
||||
|
||||
inline void toLowerInPlace(std::string &src) {
|
||||
std::transform(src.begin(), src.end(), src.begin(), [](unsigned char c) { return std::tolower(c); });
|
||||
}
|
||||
|
||||
inline std::string toLower(const std::string &src) {
|
||||
std::string ret = src;
|
||||
toLowerInPlace(ret);
|
||||
return ret;
|
||||
}
|
||||
} // namespace StringHelpers
|
||||
|
||||
Reference in New Issue
Block a user