mirror of
https://github.com/intel/compute-runtime.git
synced 2026-01-03 23:03:02 +08:00
Refactor cloc UTLS - use inititializer list
Using initializer list instead of C array Change-Id: I0520fc8f782347b884b6134208e6b6edaea532dd
This commit is contained in:
committed by
sys_ocldev
parent
6ca84c278a
commit
29794db9d9
@@ -103,7 +103,7 @@ OfflineCompiler::~OfflineCompiler() {
|
||||
////////////////////////////////////////////////////////////////////////////////
|
||||
// Create
|
||||
////////////////////////////////////////////////////////////////////////////////
|
||||
OfflineCompiler *OfflineCompiler::create(uint32_t numArgs, const char **argv, int &retVal) {
|
||||
OfflineCompiler *OfflineCompiler::create(size_t numArgs, const char *const *argv, int &retVal) {
|
||||
retVal = CL_SUCCESS;
|
||||
auto pOffCompiler = new OfflineCompiler();
|
||||
|
||||
@@ -282,7 +282,7 @@ std::string OfflineCompiler::getStringWithinDelimiters(const std::string &src) {
|
||||
////////////////////////////////////////////////////////////////////////////////
|
||||
// Initialize
|
||||
////////////////////////////////////////////////////////////////////////////////
|
||||
int OfflineCompiler::initialize(uint32_t numArgs, const char **argv) {
|
||||
int OfflineCompiler::initialize(size_t numArgs, const char *const *argv) {
|
||||
int retVal = CL_SUCCESS;
|
||||
const char *pSource = nullptr;
|
||||
void *pSourceFromFile = nullptr;
|
||||
@@ -438,7 +438,7 @@ int OfflineCompiler::initialize(uint32_t numArgs, const char **argv) {
|
||||
////////////////////////////////////////////////////////////////////////////////
|
||||
// ParseCommandLine
|
||||
////////////////////////////////////////////////////////////////////////////////
|
||||
int OfflineCompiler::parseCommandLine(uint32_t numArgs, const char **argv) {
|
||||
int OfflineCompiler::parseCommandLine(size_t numArgs, const char *const *argv) {
|
||||
int retVal = CL_SUCCESS;
|
||||
bool compile32 = false;
|
||||
bool compile64 = false;
|
||||
|
||||
@@ -46,7 +46,7 @@ std::string generateFilePath(const std::string &directory, const std::string &fi
|
||||
|
||||
class OfflineCompiler {
|
||||
public:
|
||||
static OfflineCompiler *create(uint32_t numArgs, const char **argv, int &retVal);
|
||||
static OfflineCompiler *create(size_t numArgs, const char *const *argv, int &retVal);
|
||||
int build();
|
||||
std::string &getBuildLog();
|
||||
void printUsage();
|
||||
@@ -68,8 +68,8 @@ class OfflineCompiler {
|
||||
int getHardwareInfo(const char *pDeviceName);
|
||||
std::string getFileNameTrunk(std::string &filePath);
|
||||
std::string getStringWithinDelimiters(const std::string &src);
|
||||
int initialize(uint32_t numArgs, const char **argv);
|
||||
int parseCommandLine(uint32_t numArgs, const char **argv);
|
||||
int initialize(size_t numArgs, const char *const *argv);
|
||||
int parseCommandLine(size_t numArgs, const char *const *argv);
|
||||
void parseDebugSettings();
|
||||
void storeBinary(char *&pDst, size_t &dstSize, const void *pSrc, const size_t srcSize);
|
||||
int buildSourceCode();
|
||||
|
||||
Reference in New Issue
Block a user