[Performance regression] New blocking job on main thread for UI-related tasks

New performance regression in the latest update.
What looks like a new job running every frame (blocking the main thread), looks like all the “UI Layouts” that used to happen on lua-call have been moved here.

Looks like the job happens every frame.

The entire job takes around 4ms (every frame), with the “step” portion taking 2ms (in this game on the computer I’m currently using).

Regression: A few months ago before any ui system updates, this job (and the 4ms penalty on every frame) did not exist.

Repro: Join this game: RoBeats! 🎧 Music + Rhythm + RPG - Roblox

  • Make sure you join a fairly-full server.
  • Set graphics settings to max.
  • Make sure chat is visible.

@Tiffblocks @darthskrill

This regression is caused by a few microseconds of work being done every frame per-GuiLayerCollector. In places with hundreds of them, it can add up. This never came up in performance testing because most games only have a few. I’m working on a fix now.

Edit: I have a fix now which takes it from 4ms to 0.1ms on my machine.

1 Like

Is this fix live? Noticed the name of the bar has changed (now it also includes tweenservice)

No, I moved around some of the microprofiler labels to happen in more meaningful locations and have better names.

I’ll be turning on the change as soon as I can, it’s still in testing.

The fix is live now.

1 Like

Thank you for submitting this report. We are currently reviewing all bug reports to ensure we have not overlooked any ongoing issues. Since this issue was reported over two years ago, can you please confirm you are still experiencing the problem? If so, please respond to this thread, and we will investigate. If we do not receive any response within 30 days, we will consider this matter resolved. Thank you.