解锁Nvidia 3000卡上的FP/BF16指令发行率到其专业等效
这个Linux内核模块结合了CMP解锁器的V67/PLM技术与UEFI方法的驱动前时间。 它运行解锁,写出速度选择器(SS0 0x8888888888,它选择了完整的BF16速率,以及4位SS1 0x8 IMLA4),并在未修改的NVIDIA驱动程序绑定卡之前执行FLR. 它既不是一个UEFI应用程序,也不是一个补丁的NVIDIA驱动程序。
这个早期klod驱动器的好处是,它不需要每次手动补丁nvidia 发布一个新的驱动器版本。
这个解锁的作用是它翻倍,指令发行速度为FP/BF16 FMA在GA102,GA103,GA104和GA106卡上进入FP32操作。
3090 Ti 稠密 81923 GEMM at 450 W,五样中位数,FP32累积:
首发:
git 克隆 https://github.com/Zagitta/gpu-unlock
cd gpu- 解锁
制造安装
然后将 gpu unlock. targets = all 附加到您的内核命令行中,保留
现有选项:
- GRUB(Debian/Ubuntu/Mint):在GRUB CMDLINE LINUX DEFAULT内加进/etc/default/grub,然后运行sudo更新-grub.
- GRUB(Arch/CachyOS):同样的编辑,然后运行
sudo grub-mkconfig -o /boot/grub/grub.cfg.
- 费多拉/雷尔:跑
sudo grubby -- update-内核=ALL --args="gpu unlock. targers=全部".
- systemd-boot:附加到您的启动条目中的选项行
(bootctl状态显示它的位置).
- UKI / 生成条目:将其添加到/etc/内核/立方体并再生
您的启动图像/ 连接( 如 sudo mkinitcpio - P for mkinitcpio UKIs)。
每组下载 HTTPS 上绑定的 NVIDIA/ CachyOS 输入,请检查
他们的SHA-256,并且只在构建目录和
二进制包。 所有三种格式都通过相同的制造安装*
目标。 包裹是从坚定的头部建造的。
构建、安装构建依赖,并一步安装软件包( sudo 密码的任务 ):
制作安装 # 检测分布并选择安装器
制造安装- arch # makepkg - sif
制造安装- deb # apt-get building-dep, dpkg-building package, apt-get 安装
制造安装- rpm # dnf 构建dep, rpmbuilding, dnf 安装
制作安装使用/etc/os-release(ID,然后是ID LIKE)以检测Arch
Debian/Ubuntu,或Fedora/RHEL/CentOS家族。 RPM安装器需要DNF.
对于其他分布,请在上面选择一个兼容的明显目标。
铸造拱门,制作Deb 和 rpm 只建。 Debian 和 RPM 软件包开始
用于建造/调试和建造/编审。 NVIDIA 输入被缓存于
~/.cache/gpu-解锁/输入(输入;与 INPUTS=覆盖).
dpkg-building package 本身从不使用网络,所以一个干净的芯片建筑(building 或
pbuilder)需要GPU UNLOCK INPUTS指向缓存。
make distr档案、Debian源包和.nosrc.rpm
没有 NVIDIA 档案或生成固件。
软件包将 gpu unlock 及其固件放入initramfs 并加载
在nvidia绑定卡片之前:
- mkinitcpio:/etc/mkinitcpio.conf.d/zz-gpu-unlock.conf在MODULES中的nvidia之前插入gpu unlock,所以显示卡是空白的。
尽可能短的时间。 没有nvidia的图像,它去
在从根文件系统装入 nvidia 之前,最后一个并仍在运行。
图像在安装时重建。 mkinitcpio 忽略一个图像的滴入
用 -c < config > 或预设 config 构建;将 gpu unlock 右移
之前的nvidia 在那个配置的移动自己。
- initramfs-工具:/usr/share/initramfs-工具/模块.d/gpu-unlock.conf.
- dracut: /usr/lib/dracut/dracut.conf.d/gpu-unlock.conf.
使用initramfs-tool和dracut,模块是为每个安装有头的内核建造的,这些内核的图像在安装时重建,在移除时再次重建。 安装的内核后来从内核自身的安装钩子中获取模块和新图像。
没有软的nvidia预告:规则:klod只荣耀第一
它读的软Dep nvidia线,所以其他包的规则(nvidia-utils)
gddr6 hwmon)会默默地推翻它,或者它会压倒他们的。
除非内核命令行选择在:
gpu unlock. targets= all # 每张无约束的GA102/GA103/GA104/GA106卡
gpu unlock. 目标=00: 21:00.0 只有这些牌
gpu unlock. 目标=00:21:00.00000:22:00.0#逗号分离
地址是完整的 PCI 名称,因为 Ispci - D 打印它们( 任意一个数字)
),独立于GPU编号和显示角色。 非条目
a GA102/GA103/GA104/GA106卡,包括所有与地址混合的卡,均登录和忽略。
牌是同时解锁的,大约一秒钟,不管多少
有一张卡片,每张卡片都是靠自己已经捆绑或供电
跳过控制板固件所留下的客车(超小型)
X11 无论选择 ROM 和总线主机设置如何,都会被清除
首先;已经启用的驱动程序仍然被拒绝。 礛
nvidia装满并按惯例捆绑每张卡片。
显示卡也有效。 其固件帧缓冲器(启动控制台和
Plymouth)在解锁的固件步骤运行时继续运行,并且是。
nvidia -drm在卡片重置前就被移除了,因为nvidia -drm会做一分钟
以后再说吧它的屏幕是空白的从重置,直到 nvidia -drm
结束了。
启动后用手装入模块对 nvidia 的卡没有任何作用
已经约束。
悬浮到内存中给卡片加电源,卡片会重排速度选择器。 之后
恢复模块解锁在靴子上解锁的每张卡片
nvidia恢复:它的暂停通知器运行在nvidia前方
恢复其卡片来自( NVreg UseKernelSupend Notifiers=1),默认为
目前的驱动程序;nvidia-resume. service service later still). 这个新增大约是a
第二处是恢复。 保持电源的卡片,就像暂停闲置一样,仍然
解锁后只读。 nvidia已经恢复的卡片,或者就是
绑在另一个驱动器上,是左侧的,对数称为什么。 添加
gpu unlock.resume=0 到内核命令行,或写 0 到
/sys/module/gpu unlock/参数/resume,以关闭此功能。 休眠状态
未覆盖。
检查结果为:
日记ctl -k -b QQ grep gpu 解锁
lspci -nnk -s 0000:21:00.0
要停止解锁,请移除 gpu unlock。 目标=来自内核命令行;
对于一次性的靴子,删除它在靴子装填器的编辑屏幕。 删除
软件包还删除模块和initramfs 滴入。
如果卡片上的固件从未停止,模块会记录它,并保留固件可能仍然使用的DMA缓冲器,直到下一个功率关闭。 再试一次就关掉电源
内核模块和当地包装只有GPL-2.0-. 生成的有效载荷
(b) NVIDIA固件仍保存在自己的之下;
条件。 见确定软件/NOTIEC.md和许可证/归属和通知。
帮我买更多 GPU < 3
https://burymeacoffee.com/zagitta 页面存档备份,存于互联网档案馆。
ETH: 0xf4eee937937f92038D70B16AbD7736D8a53a1c5c
BTC: bc1qwwpkkwp70fn76z3s4kg2l9y3j4kst95twcznuugf (中文(简体) ).
索尔:8Rih6HY7V4LcdjYHz4iSffT4fTniqw5 CACa BigSVxNYu
本文由 AI图鉴自动抓取并翻译,版权归原作者所有;如需查看原文请点下方链接。
Unlock FP/BF16 instruction issue rate on Nvidia 3000's cards to their professional equivalents
This Linux kernel module combines the CMP unlocker's V67/PLM technique with the pre-driver timing of the UEFI approach. It runs the unlock, writes the speed selectors (SS0 0x88888888, which selects the full BF16 rate, and the 4-bit SS1 0x8 IMLA4) and performs FLR before the unmodified NVIDIA driver binds the card. It is neither a UEFI application nor a patched NVIDIA driver.
The benefit of this early kmod driver is that it does not require manual patching each time nvidia releases a new driver version.
The effect of this unlock is that it doubles the instruction issuing speed of FP/BF16 FMA into FP32 operations on GA102, GA103, GA104 and GA106 cards.
3090 Ti dense 8192³ GEMM at 450 W, five-sample medians with FP32 accumulation:
First run:
git clone https://github.com/Zagitta/gpu-unlock
cd gpu-unlock
make install
Then append gpu_unlock.targets=all to your kernel command line, keeping
existing options:
- GRUB (Debian/Ubuntu/Mint): add it inside GRUB_CMDLINE_LINUX_DEFAULT in /etc/default/grub, then run sudo update-grub.
- GRUB (Arch/CachyOS): same edit, then run
sudo grub-mkconfig -o /boot/grub/grub.cfg.
- Fedora/RHEL: run
sudo grubby --update-kernel=ALL --args="gpu_unlock.targets=all".
- systemd-boot: append it to the options line in your boot entry
(bootctl status shows its location).
- UKI / generated entries: add it to /etc/kernel/cmdline and regenerate
your boot images/entries (e.g. sudo mkinitcpio -P for mkinitcpio UKIs).
Every build downloads the pinned NVIDIA/CachyOS inputs over HTTPS, checks
their SHA-256, and generates firmware only in the build directory and the
binary package. All three formats install through the same make install-*
targets. Packages are built from the committed HEAD.
Build, install build dependencies, and install the packages in one step (asks for your sudo password):
make install # detect the distribution and select an installer
make install-arch # makepkg -sif
make install-deb # apt-get build-dep, dpkg-buildpackage, apt-get install
make install-rpm # dnf builddep, rpmbuild, dnf install
make install uses /etc/os-release (ID, then ID_LIKE) to detect Arch,
Debian/Ubuntu, or Fedora/RHEL/CentOS families. The RPM installer requires DNF.
For other distributions, select a compatible explicit target above.
make arch, make deb and make rpm only build. Debian and RPM packages go
to build/deb and build/rpm. The NVIDIA inputs are cached in
~/.cache/gpu-unlock/inputs (make inputs; override with INPUTS=).
dpkg-buildpackage itself never uses the network, so a clean-chroot build (sbuild or
pbuilder) needs GPU_UNLOCK_INPUTS pointing at that cache.
The make dist archive, the Debian source package and the .nosrc.rpm
contain no NVIDIA archives or generated firmware.
The packages put gpu_unlock and its firmware in the initramfs and load it
there, before nvidia can bind a card:
- mkinitcpio: /etc/mkinitcpio.conf.d/zz-gpu-unlock.conf inserts gpu_unlock right before nvidia in MODULES, so a display card is blank
for as short a time as possible. Without nvidia in the image, it goes
last and still runs before an nvidia loaded from the root filesystem.
Images are rebuilt on install. mkinitcpio ignores drop-ins for an image
built with -c <config> or a preset _config; put gpu_unlock right
before nvidia in that config's MODULES yourself.
- initramfs-tools: /usr/share/initramfs-tools/modules.d/gpu-unlock.conf.
- dracut: /usr/lib/dracut/dracut.conf.d/gpu-unlock.conf.
With initramfs-tools and dracut, the module is built for every installed kernel that has headers, and those kernels' images are rebuilt on install and again on removal. Kernels installed later get the module and a new image from the kernel's own install hooks.
There is no softdep nvidia pre: rule: kmod honours only the first
softdep nvidia line it reads, so other packages' rules (nvidia-utils,
gddr6_hwmon) would silently override it, or it would override theirs.
The module does nothing unless the kernel command line opts in:
gpu_unlock.targets=all # every unbound GA102/GA103/GA104/GA106 card
gpu_unlock.targets=0000:21:00.0 # only these cards
gpu_unlock.targets=0000:21:00.0,0000:22:00.0 # comma-separated
Addresses are full PCI names as lspci -D prints them (hex digits in either
case), independent of GPU numbering and display role. An entry that is not
a GA102/GA103/GA104/GA106 card, including all mixed with addresses, is logged and ignored.
The cards are unlocked concurrently, about a second in all however many
there are, and each on its own: a card that is already bound or powered
down is skipped. Bus mastering that the board firmware left on (Supermicro
X11 does this whatever its option ROM and bus master settings) is cleared
first; a card some driver already initialised is still refused. Then
nvidia loads and binds every card as usual.
The display card works too. Its firmware framebuffer (the boot console and
Plymouth) keeps running while the unlock's firmware steps run, and is
removed just before the card's reset, as nvidia-drm would do a moment
later anyway. Its screen is blank from that reset until nvidia-drm takes
over.
Loading the module by hand after boot does nothing to a card that nvidia
has bound.
Suspend to RAM powers the cards off, which resets the speed selectors. After
resume the module unlocks every card it unlocked at boot again, before
nvidia resumes it: its suspend notifier runs just ahead of the one nvidia
resumes its cards from (NVreg_UseKernelSuspendNotifiers=1, the default in
current drivers; nvidia-resume.service runs later still). This adds about a
second to resume. A card that kept power, as in suspend to idle, is still
unlocked and is only read. A card that nvidia has already resumed, or that is
bound to another driver, is left as it is, and the log says why. Add
gpu_unlock.resume=0 to the kernel command line, or write 0 to
/sys/module/gpu_unlock/parameters/resume, to turn this off. Hibernation is
not covered.
Check the result with:
journalctl -k -b | grep gpu_unlock
lspci -nnk -s 0000:21:00.0
To stop unlocking, remove gpu_unlock.targets= from the kernel command line;
for a one-off boot, delete it in the bootloader's edit screen. Removing the
packages also removes the module and the initramfs drop-ins.
If the firmware on a card never stops, the module logs it and keeps the DMA buffers that firmware may still use until the next power off. Power off before trying again.
The kernel module and local packaging are GPL-2.0-only. The generated payload
derives from the pinned CMP reference; NVIDIA firmware remains under its own
terms. See firmware/NOTICE.md and licenses/ for attribution and notices.
Help me buy more GPUs <3
https://buymeacoffee.com/zagitta
ETH: 0xf4eee937937f92038D70B16AbD7736D8a53a1c5c
BTC: bc1qwpkwp70fn76z3s4kg2l9y3j4kst95twcznuugf
SOL: 8Rih6HY7V4LcdjYHz4iSffT4fTniqw5CACaBigSVxNYu
Auto-fetched and translated by AI Atlas. All rights belong to the original author.