From 564a13492f321654ed8e14223a74ae2f4fe30823 Mon Sep 17 00:00:00 2001 From: Jan Svabenik Date: Thu, 19 Mar 2026 11:57:19 +0100 Subject: [PATCH] Add gpudemod DLL override path and document Windows warning --- README.md | 2 ++ internal/demod/gpudemod/gpudemod_windows.go | 3 +++ 2 files changed, 5 insertions(+) diff --git a/README.md b/README.md index afee8b8..710c826 100644 --- a/README.md +++ b/README.md @@ -51,6 +51,8 @@ Important: - `build-sdrplay.ps1` prepares the runtime DLL placement and PATH setup for SDRplay + CUDA DLLs - the gpudemod DLL is built with `-cudart=hybrid` - GPU validation is disabled by default for performance; enable it with `SDR_GPU_VALIDATE=1` when debugging +- you can override DLL lookup with `GPUMOD_DLL=C:\path\to\gpudemod_kernels.dll` +- Windows builds may still show a harmless `__cdecl redefined` warning from CUDA headers - older experimental Windows build scripts were removed to avoid confusion ### Linux diff --git a/internal/demod/gpudemod/gpudemod_windows.go b/internal/demod/gpudemod/gpudemod_windows.go index 75870ca..24e1c35 100644 --- a/internal/demod/gpudemod/gpudemod_windows.go +++ b/internal/demod/gpudemod/gpudemod_windows.go @@ -124,6 +124,9 @@ func ensureDLLLoaded() error { filepath.Join(wd, "internal", "demod", "gpudemod", "build", "gpudemod_kernels.dll"), ) } + if env := os.Getenv("GPUMOD_DLL"); env != "" { + candidates = append([]string{env}, candidates...) + } seen := map[string]bool{} for _, p := range candidates { if p == "" || seen[p] {