================
@@ -25,6 +32,37 @@ cl::opt<bool> Verbose("offload-arch-test-verbose",
cl::Hidden, cl::init(false));
#ifdef _WIN32
+// --- primeLibraryLoad ---
+
+namespace {
+std::wstring CapturedPath;
+HANDLE CapturedFile;
+DWORD CapturedFlags;
+
+HMODULE WINAPI mockLoadLibraryExW(LPCWSTR Path, HANDLE File, DWORD Flags) {
----------------
ScottTodd wrote:
Hmmm.. I found
https://github.com/llvm/llvm-project/tree/main/llvm/unittests/Support/DynamicLibrary
which might let us
1. create a fake `amdhip64_*.dll`
2. create a second fake DLL that it imports a symbol from
3. put both into a new directory (off PATH and CWD) so the loader needs to work
to access them
4. call the real function
https://github.com/llvm/llvm-project/pull/209898
_______________________________________________
cfe-commits mailing list
[email protected]
https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits