keylase / nvidia-patch

This patch removes restriction on maximum number of simultaneous NVENC video encoding sessions imposed by Nvidia to consumer-grade GPUs.
3.52k stars 277 forks source link

Question: how to find bytecode for nvidia-fbc ? #796

Open Vincenzo-Puzone opened 5 months ago

Vincenzo-Puzone commented 5 months ago

Hello,

My question is: how do i find the bytecode for nvidia-fbc patch?

I can use the script in tools/autopatch/find_bytecode.sh to find nvenc bytecode but not nvfbc

jailuthra commented 5 months ago

@Vincenzo-Puzone the script currently doesn't automate looking for NvFBC bytestring, as it does not change often.

To me looks like it has changed in recent releases.. I've tried to manually patch it, but really guessing here.

Can you test #799 to see if the patch applies cleanly, and removes NvFBC limitation for you?

SjoerdV commented 5 months ago

@jailuthra In my case your patch fails to start sunshine with the following segfault (ouch!) error

sunshine[1789]: segfault at 7f4764c07f20 ip 00007f4764c07f20 sp 00007ffe17fcd8f8 error 14 in nvidiactl[7f4764e34000+4000] likely on CPU 6 (core 6, socket 0)
Code: Unable to access opcode bytes at 0x7f4764c07ef6.
Sid127 commented 5 months ago

if anyone wants to test: try replacing 85 c0 0f 85 9b 00 00 00 48 with 85 C0 90 90 90 90 90 90 48 in libnvidia-fbc.so.555.52.04

EDIT: had a friend test it on his desktop, it does seem to work.