Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

[CS2] FPS Drops after a few rounds of playing #3845

Open
Dazukodesu opened this issue Oct 3, 2024 · 22 comments
Open

[CS2] FPS Drops after a few rounds of playing #3845

Dazukodesu opened this issue Oct 3, 2024 · 22 comments
Labels

Comments

@Dazukodesu
Copy link

Dazukodesu commented Oct 3, 2024

https://gist.github.com/Dazukodesu/26cf6d9747c1e2ada57c4b1a83a62cab)
OS: EndeavourOS Linux x86_64
Kernel: 6.10.10-arch1-1
DE: Hyprland
CPU: 13th Gen Intel i7-13700K (24) @ 5.300GHz
GPU: NVIDIA GeForce RTX 4070
GPU: Intel Raptor Lake-S GT1 [UHD Graphics 770]
RAM: 32GB

Please describe your issue in as much detail as possible:

Describe what you expected should happen and what did happen. Please link any large pastes as a Github Gist.

Steps for reproducing this issue:

  1. Enter a game in the competitive game mode on any map.
  2. Play 3-4 rounds.
  3. FPS Drops from a range of 200-400 to 80-115

https://cdn.discordapp.com/attachments/690648583082606645/1291442499658715247/VID_20241003_124634.mp4?ex=67001d0d&is=66fecb8d&hm=75e3eed2c291aa05c44b0eddf888bfc01e1a68eaf362531b80ee0ecdc272c6bd&

https://cdn.discordapp.com/attachments/690648583082606645/1291442500124414034/VID_20241003_124614.mp4?ex=67001d0d&is=66fecb8d&hm=9d271bd448c383045fd85ed19e33347396478e8ca0b5377597b30666bab41aff&

Launch options:
gamescope -w 1280 -h 960 -S stretch -f -e -r 144.0 --force-grab-cursor --adaptive-sync --immediate-flips --mangoapp %command%

@Zonyia
Copy link

Zonyia commented Oct 3, 2024

Experiencing frame drops after the recent update after playing for a bit too.

@Dazukodesu Dazukodesu closed this as not planned Won't fix, can't repro, duplicate, stale Oct 3, 2024
@Dazukodesu
Copy link
Author

Dazukodesu commented Oct 3, 2024

this has been happening since before update

@Dazukodesu Dazukodesu reopened this Oct 3, 2024
@itouchdennis
Copy link

itouchdennis commented Oct 4, 2024

Replying to #3845 (comment)

Just out of curiosity, are you able on Hyprland with NVIDIA to get tearing working?
I tried everything and CS feels horrible on Hyprland when I uncapped the FPS / I have more Frames as my monitor has HZ.

It seems like I cannot get my setup ready for the tearing validations (3070 ti - 12600k, 6.10 Kernel EndeavourOS).
The only way I can play the game on Hyprland for me was to set my max FPS fixed to my displays HZ rate.

If you have set up your system and working tearing, I would love to know what you set up :-D

(yes I have modset enabled and all these hyprland nvidia variables from the documentation on + I am on the newest git self compiled version - tried others but nothing changed. Hyprland maintainer just said "if hyprctl monitors doesnt show solitary 1, its not an hyprland issue" - welp)

@burd1
Copy link

burd1 commented Oct 5, 2024

Same issue on Pop! OS 22.04 after the new update, fps dips to mid 50's or 60's. My hardware is more than capable just like yours.

@Dazukodesu
Copy link
Author

Dazukodesu commented Oct 6, 2024

Replying to #3845 (comment)

i have my vsync off

@koreanfan
Copy link

I always play at low preset with disabled fidelity_fx. Recently valve broke cs2 on linux system (game crash at menu when press tab, when alt+tabbing, drop players, massive fps drop). After few weeks they fix it. But again they broke game with new big patch patch. Even at 1024x768 i got now 90-160 fps instead of 280-320fps. At 1920x1080 now i got shitty average 85fps with double increased frame time and its total unplayable at this resolution. They broke game almost with every patch. Qualified developers first test the patch, and if there are no problems with it, it can be used for the official release. Also, I don't want to waste my CPU, GPU, RAM, SSD, LAN resources on any skins and stickers. Make an optimal performance mode that only uses standard models when turned on.

@firashacker
Copy link

i had this issue 5 months ago and i came back to game to try it 3 days ago and this shit is still there,
i get 400 fps first match then after a while its only 180 fps , even in the main menu where i cap fps on 144 it drops to 100 and can't rise back after a while

@firashacker
Copy link

firashacker commented Oct 9, 2024

i recorded when it started dropping frames it occures suddenly and it makes the game unplayable

out2.mp4

idk what my cursor doing in there

  • i used ffmpeg to crop and trim the video maybe the encoder captured my curser during reincoding :(

@Dwyriel
Copy link

Dwyriel commented Oct 10, 2024

Probably related, not sure:
After the latest wave of updates (since early October), after a few matches (it builds up slowly each round) every now and then I get jitters and low FPS (goes from 200+ to 60-80), this gets progressively worse the more I play.
I didn't do any in-depth analysis but just having htop and nvtop open on a second window and playing casual matches I could see cs2 using more and more ram, but never releasing it. Joining the first match it would be using around 25% (out of 16gbs, or around 4gb), at the end it usually is around 33% to 38% (depends on match length/total rounds). second match starts at around 30 to 33%, and goes up to 50%~ at the end of it. this keeps building up, making the game more and more unplayable until the whole system "crashes" (or at least gets so slow that I can't even switch to a TTY to kill cs2).

@Dazukodesu
Copy link
Author

So its a memory leak issue?

@itouchdennis
Copy link

itouchdennis commented Oct 15, 2024

Could be a problem in EGL (nvidia related)
NVIDIA/egl-wayland#126 (comment)

There is also a workaround for nvidia users:

create the path
/etc/nvidia/nvidia-application-profiles-rc.d
create the file 50-limit-free-buffer-pool-in-wayland-compositors.json

Content might be look something like:
(I will try it now, dont know 100% if the match pattern for cs2 will work)
https://pastebin.com/tvMiWKrv

@Dwyriel
Copy link

Dwyriel commented Oct 15, 2024

@Dazukodesu it's possible that the memory leak is the cause but it could be something else. There's definitely a memory leak going on though, at least on my end and on casual matches.

Just played 3 consecutive self hosted casual matches with bots, cs2 RAM usage started at 33% and never went above 36%, rebooted the game and played 2 casual matches on valve servers, and by the end of the second it was at 45%. VRAM for both of those went up until around 8.9/10 GBs and stayed there. Haven't played a competitive match yet to test so can't comment on that end. If I had to guess I'd say it's potentially related to networking or skins.

ps: I'm on X11 + KDE with a Ryzen 5900x & RTX 3080. No wayland here.

@Dazukodesu
Copy link
Author

Yeah this happens on both x11 and wayland. Tho after a recent update today the game now instantly crashes

@Dazukodesu
Copy link
Author

Dazukodesu commented Oct 15, 2024

Replying to #3845 (comment)

how do i do this

@firashacker
Copy link

firashacker commented Oct 15, 2024

Replying to #3845 (comment)

i use amd radeon rx6600 and i still have similar fps lose after some time

it starts at around 340 fps and suddenly it can't do more than 180 with very clear hangs and frame drops

@burd1
Copy link

burd1 commented Oct 15, 2024

Yeah this happens on both x11 and wayland. Tho after a recent update today the game now instantly crashes

Same, but mine worked for 3-5s before crashing

@itouchdennis
Copy link

itouchdennis commented Oct 16, 2024

Replying to #3845 (comment)

how do i do this

Not sure if its working, but yesterday games worked bit better without hitting my vram limit of 8 GB
(but it was only 2 games... mostly I got issues after 4)

create the path
$ sudo mkdir -p /etc/nvidia/nvidia-application-profiles-rc.d
create the file
$ sudo touch /etc/nvidia/nvidia-application-profiles-rc.d/50-limit-free-buffer-pool-in-wayland-compositors.json

Edit the file and paste this content in:
https://pastebin.com/tvMiWKrv

& Reboot

@mildly-useful
Copy link

mildly-useful commented Oct 17, 2024

This happened on my PC ever since like... more than half a year ago (can't remember when I started playing CS2). And since it's a lower end PC, it's very noticeable/impactful. I have to restart my game/PC after some matches, otherwise the FPS would suffer. GPU is GTX 1650 4GB, and I have 16 GB of RAM.

@luminoucid
Copy link

luminoucid commented Oct 20, 2024

Replying to #3845 (comment)

hey itouchdennis,
did you add this also in you hyprland.conf? This fixed it for me. :)
(Also on EndeavourOS + 4070ti)

https://wiki.hyprland.org/Configuring/Tearing/

`general {
allow_tearing = true
}

windowrulev2 = immediate, class:^(cs2)$`

Also make sure that cs is running in fullscreen mode.
(I added bind = $mainMod, F, fullscreen to double check)

@Dazukodesu
Copy link
Author

So i tried screenrecording it today. And i noticed sometimes my weapon gets stuck inspecting. And after i shot a bullet the stuttering started. I am going to test it again soon

@Dazukodesu
Copy link
Author

alr that is not the cause

@Dazukodesu
Copy link
Author

[](https://youtu.be/b1MuRsDgMFo)
github wont let me upload video so i used an old channel of mine to upload

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

No branches or pull requests

10 participants