MangoHud icon indicating copy to clipboard operation
MangoHud copied to clipboard

Severe framedrops with older AMD GPU when overlay is active

Open PerAstraAdDeum opened this issue 5 months ago • 11 comments

Describe the bug When using Mangohud with my old Radeon Fury X, every other second the framerate drops significantly. This does only happen when the overlay is visible. When turned off with SHIFT_R+F12, the game/application runs smoothly. This issue does not occur with newer GPUs (see details below)

List relevant hardware/software information

  • Linux Distribution: Tested on Bazzite and Secureblue (Both Fedora Atomic), both with Kernel 6.15.9
  • MangoHud version: 0.8.1
  • GPU: AMD Radeon Fury X

To Reproduce Steps to reproduce the behavior:

  1. Start any application with Mangohud enabled.
  2. Watch the framerate drop significantly every other second.

Expected behavior No framedrops. The same setup works flawlessly with other cards. Tested with NVIDIA GeForce RTX 2060 Super and AMD RX 7900 XTX.

Screenshots

Image Image

Additional context Screenshot 1: OpenJK on Bottles. Screenshot 2: Grim Dawn on Bottles. Ignore the "3080 Ti" label, the real GPU that's being used is shown below. Notice the frametimes. There you can observe the framedrops.

PerAstraAdDeum avatar Aug 14 '25 17:08 PerAstraAdDeum

Likely causing a stutter when reading some sysfs nodes. We'd want to figure out which one(s) are causing it

flightlessmango avatar Aug 19 '25 20:08 flightlessmango

Likely causing a stutter when reading some sysfs nodes. We'd want to figure out which one(s) are causing it

Hmm, I see. I'll test them one after another this weekend and report back.

PerAstraAdDeum avatar Aug 20 '25 11:08 PerAstraAdDeum

Likely causing a stutter when reading some sysfs nodes. We'd want to figure out which one(s) are causing it

I've done some testing on a fresh installation with Mangohud and Mangojuice, and it seems to me like whenever gpu_stats is set to on, the framedrops occur.

Image Image

PerAstraAdDeum avatar Aug 22 '25 16:08 PerAstraAdDeum

try setting gpu_power=0

flightlessmango avatar Oct 24 '25 21:10 flightlessmango

I have same issue with R9 390.

PiratePaprika avatar Nov 27 '25 20:11 PiratePaprika

Does gpu_power=0 change anything?

flightlessmango avatar Dec 05 '25 15:12 flightlessmango

No, same behavior. Turning on any GPU stats does what person above described.

PiratePaprika avatar Dec 06 '25 13:12 PiratePaprika

For old AMDGPUs we touch sysfs nodes. Namely gpu_busy_percent mem_info_vram_total mem_info_vram_used and mem_info_gtt_used. Try accessing them each with time cat gpu_busy_percent etc and post the result here. They are in /sys/class/drm/card0/device/, or card1 etc depending on your setup

flightlessmango avatar Dec 06 '25 13:12 flightlessmango

time cat /sys/class/drm/card1/device/gpu_busy_percent
0
real    0m0.002s
user    0m0.000s
sys     0m0.002s

time cat /sys/class/drm/card1/device/mem_info_vram_total
8589934592
real    0m0.001s
user    0m0.000s
sys     0m0.001s

time cat /sys/class/drm/card1/device/mem_info_vram_used
568184832
real    0m0.002s
user    0m0.001s
sys     0m0.000s

time cat /sys/class/drm/card1/device/mem_info_gtt_used
102166528
real    0m0.002s
user    0m0.000s
sys     0m0.002s

PiratePaprika avatar Dec 06 '25 16:12 PiratePaprika

Nice those look fine. We also poke some hwmon nodes. /sys/class/drm/card1/device/hwmon/*/temp1_input /sys/class/drm/card1/device/hwmon/*/temp2_input /sys/class/drm/card1/device/hwmon/*/temp3_input /sys/class/drm/card1/device/hwmon/*/freq1_input /sys/class/drm/card1/device/hwmon/*/in0_input /sys/class/drm/card1/device/hwmon/*/freq2_input

flightlessmango avatar Dec 06 '25 18:12 flightlessmango

time cat /sys/class/drm/card1/device/hwmon/*/temp1_input
59000
real    0m0.001s
user    0m0.000s
sys     0m0.001s

time cat /sys/class/drm/card1/device/hwmon/*/temp2_input
cat: '/sys/class/drm/card1/device/hwmon/*/temp2_input': No such file or directory
real    0m0.002s
user    0m0.000s
sys     0m0.002s

time cat /sys/class/drm/card1/device/hwmon/*/temp3_input
cat: '/sys/class/drm/card1/device/hwmon/*/temp3_input': No such file or directory
real    0m0.001s
user    0m0.000s
sys     0m0.002s

time cat /sys/class/drm/card1/device/hwmon/*/freq1_input
300090000
real    0m0.002s
user    0m0.000s
sys     0m0.002s

time cat /sys/class/drm/card1/device/hwmon/*/in0_input
1118
real    0m0.002s
user    0m0.000s
sys     0m0.002s

time cat /sys/class/drm/card1/device/hwmon/*/freq2_input
150000000
real    0m0.002s
user    0m0.001s
sys     0m0.001s

PiratePaprika avatar Dec 06 '25 18:12 PiratePaprika