Frame Drops from 120 to 30 for about a second then returns, constantly repeats every second or so

Hey im quite new to Unreal and game dev as a whole so i was hoping i could get some answers on a bug ive experienced since i got UE5.

So whenever im in my Viewport or testing out my scene my game goes from 120 FPS at 8ms to 30 FPS at 15ms and this is on reapeat every 1 or 2 seconds. ive tired looking online to see what cuases this but ive not found anyone who has this issue. Any help would be appretiated :slight_smile:

My PC is an 7900xtx with a 7900x3d and 32gb ram

Is there by any chance a red heap in the log at this moment?)

Shader compilation message?

Timer + large array (loop node)?

Enter the command “stat unitgraph”, what catches the eye?

If it is still not clear what the reason is, make a profile and see what the problem is.

im not sure what a red heap is or how to check the loop node. but the stat unitgraph shows this

like i said im fairly new to unreal so im not sure what i need to look for.

by “red heap” I believe they are talking about if there are several red lines in the output log (grey/white is for default/display, yellow/orange is for Warnings, and red is for Errors) unless you specifically put log statements (including Print String, Print Text) into your code or scripts these will all be engine generated.

FPS is an average on the reciprocal of frame time, and really doesn’t mean all that much except to give a rational whole number approximation of performance, and even then it is the 1% and .1% in FPS that are the most indicative of feel, before we even get to FrameGen type stuff.

things that can account for frame time spikes

  • number of actors
  • number of things (actors, SceneComponents, ActorComponents, Subsystems) that are using Tick() and to an equal extent Delays and Timers.
  • the complexity of Tick, Delays, and Timers (if the thing firing off in the Tick, or inside a Delay loop is like 2-4 nodes it “should” be fine, but you get to 200 of these instances and the engine can have problems)
  • things loading into and out of memory whether it be vRAM or system RAM, the engine is Garbage Collected but it is not magic
  • the actual things that are happening at the point of the slowdown:
    • are things spawning?
    • are things being destroyed?
    • are things doing a bunch of calculations?

direct question to you:
how big is your scene? (like number of actors?)

how many things are using Tick(), Delay(), Timers() ?

does this happen when you are standing still, or moving around?

What kind of things are happening when you experience this slow down?

does this happen when you are looking at something with the camera? (if you rotate the camera does the slowdown go away?)

what kind of C++ or plugins is going on in your scene?

does this happen in an empty Scene, an empty project, or just your current level?

are you using version control?

if you have your Task Manager open in your OS around the time of these spikes does CPU utilization, memory, or GPU of the Editor jump, drop, or is it still consistent around these slow downs?

what other programs are running (background processes, or silent updates) on your system? (this could be OS scheduling where something else is demanding system resources away from the edit, and therefore you get frame time spikes)

Is this a new problem (started today, after an update to the Engine/editor operating system), or has this “always happened” (even if this is the first time you ever turned on the Editor)?

So I’ll answer your questions in order

  • This is a normal start-up scene when you select, first person or third person, blank canvas etc… so whatever initially loads
  • Like above it’ll be what ever the world spawns in when you start (if there is I’m not sure)
  • This occurs when I’m standing still or moving the camera. it only ever stops when I click off unreal or click the files dropdown, for example
  • This occurs irrespective of whether I’m in cam mode or playing in the scene and the slowdown doesn’t go away when rotating the cam
  • this is a fresh install of Unreal 5.5 so quixel bridge and FAB UE plugin
  • repeat of above
  • No, I’m not using version control
  • there is no visual spike in CPU, GPU, memory when it occurs
  • I have a lot of normal processes running in the background like discord, antivirus, drivers, chrome… only other thing would be steam but not sure how that would affect it
  • I only downloaded UE5 yesterday while following a YouTube tutorial, the very first project I opened had this stuttering issue

However, one weird thing I noticed while playing around trying to fix it is that when UE is fullscreened, it does it, but when it’s windowed and only quarter windowed, it works fine.

if this is consistent across projects, and a new Engine install lets go through moderate troubleshooting:
so this would indicate it is either the Editor/Engine itself, The way the Editor/Engine is being treated by the system, or your hardware.

first lets make sure the Engine/Editor: (I will presume that you are installing the Engine from the Epic Games Launcher as the pre-compiled binaries)

  • in the Epic Games Launcher for Unreal (where you would have downloaded the engine) on the tile for the given Engine version there is a little down arrow, and one of the options is “Verify” this may take some time (about halt to two thirds the amount of time to download the Engine initially). It will go through all of the binaries and code files that were pulled down, checksum them. if there is a discrepancy it will attempt to replace the file.
  • try to open the project again and see if the issue persists.

If you are compiling from source, then… clean and rebuild

try closing all other applications
I am not saying turn off your anti-virus, but at least make sure it isn’t running a scan, and a soft suggestion to maybe Ignore list the Engine directory, but this should not be needed.

the next is the way your OS treats the Editor/Engine (I will presume that you are on Windows, I am not completely sure about Mac or Linux)

    • the editor might be running with reduced privileges and therefore any other program with even slightly higher privileges can interrupt it.
  • navigate to where you installed the engine ..\UE_5.5\Engine\Binaries\Win64\UnrealEditor.exe
  • right click → properties → compatibility → "Run this program as an administrator”
  • then hit apply
    • NOTE: you may need to do User Account Control authorizations when launching the Editor but that is separate to this.

in your Task Manager look at the process for the Editor and see if it has “efficiency Mode” labeled on the Editor itself, or the instance, or your project (this can be rather clunky to have not happen, but often time Admin privileges disallows it from happening)

for hardware specifically, presuming everything is working fine otherwise. Particularly with Ryzen x3d you might need to set a CCX affinity for the Editor, to ensure it is not jumping between CCX units, and causing interchange issues.

  • without technically 3rd party tools to AMD (Project Lasso by bitsum) you can do it through task manager
    • select the Unreal Editor process
    • right click-> “Go To Details”
    • find “UnrealEditor.exe”
    • right click-> “set Affinity”
    • the dialog that pops up is talking about threads. where the 7900x3d is a 12-core with 2 CCX that mean you are either looking at 0-11, or 12-23 (I am not explicitly sure which of the sets is the one with 3d-V-Cache, so you might need to test both)

if none of this works then we might need to dig deeper.

yea none of this works

are you running multiple displays?

maybe Windows is being too aggressive with 'fullscreen optimizations"
UnrealEditor.exe->right click → Properties → Compatibility → “disable fullscreen optimizations”

is your GPU driver up to date {sometimes Windows tries to “help” and gives you an older GPU driver)

if your display has G-Sync/Freesync enabled then in might be competing with the engines default of VSync

  • in the Editor: Edit → Editor Preferences → General → Performance → Editor Performance → Enable VSync.

check your “Power Plan” (even if this is a desktop) and CPU parking

  • Window key → search “Power plan” → “choose a power plan” try either “High Performance” or “AMD Ryzen Balanced”

is discord “in game overlay” enabled?
Discord: Settings → Overlay → Disable In Game Overlay
AMD driver overlay?

does “New Editor Window (PIE)” make it better
from the level viewport there is the 3-vertical-dots menu on the same line as the Play button select "New Editor Window (PIE)

  • you can kind of try this out by opening a blueprint, and clicking the play button from there.

could your GPU or CPU be overheating??
GPU reports tempt to task manager, but CPU might require like HWInfo64 or MSI Afterburner

try to manually lock values in the editor:
in the console for the Editor either with PIE running or not
“r.vsync 0” “t.maxfps 60”
these respectively disable VSync and set max FPS to the value given.
there is also “r.ScreenPercentage 100” but this is more for cooked applications.

you can also set Unreal Insights targeted to profile the editor itself, but this can have a lot of background noise in the capture.