fix: Disable compiler cache if any IGC_ env is set

Related-To: NEO-12721
Signed-off-by: Aleksandra Nizio <aleksandra.nizio@intel.com>
This commit is contained in:
Aleksandra Nizio
2025-07-07 08:43:54 +00:00
committed by Compute-Runtime-Automation
parent 689839143c
commit 6975f7bb8d
13 changed files with 176 additions and 11 deletions

View File

@@ -555,6 +555,23 @@ int pidfdgetfd(int pid, int targetfd, unsigned int flags) {
}
return 0;
}
char **getEnviron() {
return NEO::ULT::getCurrentEnviron();
}
} // namespace SysCalls
namespace ULT {
static char **mockEnviron = nullptr;
char **getCurrentEnviron() {
return mockEnviron ? mockEnviron : environ;
}
void setMockEnviron(char **mock) {
mockEnviron = mock;
}
} // namespace ULT
} // namespace NEO

View File

@@ -16,6 +16,9 @@
#include <unistd.h>
#include <vector>
extern "C" {
extern char **environ;
}
namespace NEO {
namespace SysCalls {
@@ -103,5 +106,10 @@ extern std::string dlOpenFilePathPassed;
extern std::string mkfifoPathNamePassed;
extern long sysconfReturn;
char **getEnviron();
} // namespace SysCalls
namespace ULT {
char **getCurrentEnviron();
void setMockEnviron(char **mock);
} // namespace ULT
} // namespace NEO

View File

@@ -465,7 +465,14 @@ BOOL verQueryValueW(LPCVOID pBlock, LPCWSTR lpSubBlock, LPVOID *lplpBuffer, PUIN
}
return FALSE;
}
LPWCH mockEnvStringsW = nullptr;
BOOL mockFreeEnvStringsWResult = TRUE;
LPWCH getEnvironmentStringsW() {
return mockEnvStringsW;
}
BOOL freeEnvironmentStringsW(LPWCH) {
return mockFreeEnvStringsWResult;
}
} // namespace SysCalls
bool isShutdownInProgress() {
@@ -475,5 +482,4 @@ bool isShutdownInProgress() {
unsigned int readEnablePreemptionRegKey() {
return 1;
}
} // namespace NEO