ishitatsuyuki / LatencyFleX

Vendor agnostic latency reduction middleware. An alternative to NVIDIA Reflex.
Apache License 2.0
797 stars 20 forks source link

Loading latencyflex_layer.dll failed with error code: 1114 #45

Closed ParetoOptimalDev closed 7 months ago

ParetoOptimalDev commented 7 months ago

I'm trying to use latencyflex with Apex and get this error:

DXVK_NVAPI_ALLOW_OTHER_DRIVERS is set, reporting also GPUs with non-NVIDIA proprietary driver
NvAPI Device: NVIDIA GeForce RTX 3090 (545.29.6)
NvAPI Output: \\.\DISPLAY1
DXVK_NVAPI_DRIVER_VERSION is set to '49729', reporting driver version 497.29
11903.288:0178:017c:trace:loaddll:build_module Loaded L"C:\\windows\\system32\\latencyflex_layer.dll" at 0000000066280000: builtin
11903.288:0178:017c:trace:loaddll:free_modref Unloaded module L"C:\\windows\\system32\\latencyflex_layer.dll" : builtin
Loading latencyflex_layer.dll failed with error code: 1114
NvAPI_Initialize: OK
NvAPI_QueryInterface (0x33c7358c): Unknown function ID
NvAPI_QueryInterface (0x593e8644): Unknown function ID
NvAPI_D3D_SetSleepMode: No implementation
11903.339:0178:017c:trace:unwind:RtlCaptureStackBackTrace (1, 5, 00000000007C9AF0, 0000000000000000)

Another error that seemed notable was:

12524.935:0064:0090:warn:seh:handle_syscall_fault backtrace: --- Exception 0xc0000005 at 0x7f4857105e5e: /home/pod/.local/share/Steam/compatibilitytools.d/GE-Proton8-27/files/lib64/wine/x86_64-unix/winebus.so + 0x4e5e.
12524.935:0064:0090:trace:unwind:dwarf_virtual_unwind function 7f4857105e5e base 0x7f4857105b00 cie 0x7f4857114ca0 len 14 id 0 version 1 aug 'zR' code_align 1 data_align -8 retaddr %rip

Here are the files I've copied:

~/.local/share/Steam/compatibilitytools.d/GE-Proton8-27 $ fd latencyflex
files/lib64/wine/x86_64-unix/latencyflex_layer.so
files/lib64/wine/x86_64-windows/latencyflex_layer.dll
files/lib64/wine/x86_64-windows/latencyflex_wine.dll
files/share/default_pfx/drive_c/windows/system32/latencyflex_layer.dll
files/share/default_pfx/drive_c/windows/system32/latencyflex_wine.dll

I'm using latencyflex from NixOS, and it looks like the repo in the repo I use it's on revision 3bc9636f94a3220ce55edb642077349e396a7d6a.

I also tried the advice to modify toolmanifest.vdf to disable the steam container runtime here, but that didn't seem to work.

steam-log-apex.log

ParetoOptimalDev commented 7 months ago

Here are the places I copied all files to:

cp -v ~/Downloads/latencyflex-v0.1.1/wine/usr/lib/wine/x86_64-unix/latencyflex_layer.so  ~/.local/share/Steam/compatibilitytools.d/GE-Proton8-27/files/lib64/wine/x86_64-unix/latencyflex_layer.so

cp -v ~/Downloads/latencyflex-v0.1.1/wine/usr/lib/wine/x86_64-windows/latencyflex_layer.dll ~/.local/share/Steam/compatibilitytools.d/GE-Proton8-27/files/lib64/wine/x86_64-windows/
cp -v ~/Downloads/latencyflex-v0.1.1/wine/usr/lib/wine/x86_64-windows/latencyflex_wine.dll ~/.local/share/Steam/compatibilitytools.d/GE-Proton8-27/files/lib64/wine/x86_64-windows/

cp -v ~/Downloads/latencyflex-v0.1.1/wine/usr/lib/wine/x86_64-windows/latencyflex_layer.dll ~/.local/share/Steam/compatibilitytools.d/GE-Proton8-27/files/share/default_pfx/drive_c/windows/system32/ 
cp -v ~/Downloads/latencyflex-v0.1.1/wine/usr/lib/wine/x86_64-windows/latencyflex_wine.dll  ~/.local/share/Steam/compatibilitytools.d/GE-Proton8-27/files/share/default_pfx/drive_c/windows/system32/

# nvapi64.dll already existed, so backing it up before copy
mv ~/.local/share/Steam/compatibilitytools.d/GE-Proton8-27/files/lib64/wine/nvapi/nvapi64.dll ~/.local/share/Steam/compatibilitytools.d/GE-Proton8-27/files/lib64/wine/nvapi/nvapi64.dll.bak
cp -v ~/Downloads/x64/nvapi64.dll ~/.local/share/Steam/compatibilitytools.d/GE-Proton8-27/files/lib64/wine/nvapi/
ParetoOptimalDev commented 7 months ago

Things seem to be working fine now, closing.