# Profiler show peak frame

**URL:** <https://forum.defold.com/t/profiler-show-peak-frame/74164>\
**Category:** Questions\
**Created:** [September 21, 2023, 5:19am UTC](https://forum.defold.com/t/profiler-show-peak-frame/74164 "2023-09-21T05:19:13Z")\
**Posts on this page:** 7\
**Page:** 1

<div class="post-metadata">

**Author:** ![Alex\_8BitSkull](https://forum-defold.b-cdn.net/user_avatar/forum.defold.com/alex_8bitskull/32/5424_2.png) [@Alex\_8BitSkull](https://forum.defold.com/u/Alex_8BitSkull)\
**Post date:** [September 21, 2023, 5:19am UTC](https://forum.defold.com/t/profiler-show-peak-frame/74164/1 "2023-09-21T05:19:14Z")

</div>

Feel like I’m missing something obvious, but I can’t get the peak frame functionality of the profiler to work. I do this:

```lua
profiler.enable_ui(true)
profiler.set_ui_mode(profiler.MODE_SHOW_PEAK_FRAME)

```

But I just get the regular profiler 🤔 By that I mean it’s constantly updating, it never stops on a particular frame.

Am I doing it wrong? If it looks right, could you check that it works for you?

---

<div class="post-metadata">

**Author:** ![Mathias\_Westerdahl](https://forum-defold.b-cdn.net/user_avatar/forum.defold.com/mathias_westerdahl/32/228_2.png) [@Mathias\_Westerdahl](https://forum.defold.com/u/Mathias_Westerdahl)\
**Post date:** [September 21, 2023, 5:46am UTC](https://forum.defold.com/t/profiler-show-peak-frame/74164/2 "2023-09-21T05:46:02Z")

</div>

I’m currently thinking it broke when we updated to the new profiler backend ☹

---

<div class="post-metadata">

**Author:** ![britzl](https://forum-defold.b-cdn.net/user_avatar/forum.defold.com/britzl/32/23_2.png) [@britzl](https://forum.defold.com/u/britzl)\
**Post date:** [September 21, 2023, 5:54am UTC](https://forum.defold.com/t/profiler-show-peak-frame/74164/3 "2023-09-21T05:54:05Z")

</div>

In the meantime, can you profile using the web profiler? And if the target platform doesn’t support it (ie html5) then maybe you get useful values when running on desktop?

---

<div class="post-metadata">

**Author:** ![Alex\_8BitSkull](https://forum-defold.b-cdn.net/user_avatar/forum.defold.com/alex_8bitskull/32/5424_2.png) [@Alex\_8BitSkull](https://forum.defold.com/u/Alex_8BitSkull)\
**Post date:** [September 21, 2023, 6:32am UTC](https://forum.defold.com/t/profiler-show-peak-frame/74164/4 "2023-09-21T06:32:14Z")

</div>

> [@Mathias\_Westerdahl](#):
>
> I’m currently thinking it broke when we updated to the new profiler backend ☹

Do you remember when that was? Maybe I can revert and test with that.

> [@britzl](#):
>
> In the meantime, can you profile using the web profiler? And if the target platform doesn’t support it (ie html5) then maybe you get useful values when running on desktop?

Not sure if I’m doing something wrong, but I don’t understand the web profiler. When I click on a frame, I don’t see any change in the data displayed.

---

<div class="post-metadata">

**Author:** ![britzl](https://forum-defold.b-cdn.net/user_avatar/forum.defold.com/britzl/32/23_2.png) [@britzl](https://forum.defold.com/u/britzl)\
**Post date:** [September 21, 2023, 8:06am UTC](https://forum.defold.com/t/profiler-show-peak-frame/74164/5 "2023-09-21T08:06:23Z")

</div>

The samples for Main are not showing because it is outside the screen to the right of the other sample windows. Untick AsyncLoad, GraphicsWorker, log, Remotery. This should show the samples of the Main thread and they should update as you select the different samples on the timeline.

---

<div class="post-metadata">

**Author:** ![Alex\_8BitSkull](https://forum-defold.b-cdn.net/user_avatar/forum.defold.com/alex_8bitskull/32/5424_2.png) [@Alex\_8BitSkull](https://forum.defold.com/u/Alex_8BitSkull)\
**Post date:** [September 21, 2023, 8:29am UTC](https://forum.defold.com/t/profiler-show-peak-frame/74164/6 "2023-09-21T08:29:05Z")

</div>

Yes, that works thank you! It’s not as useful as the in-built profiler however, as it will be difficult for me to match up specific frames to in-game events. But I can use it for general performance measurement.

---

<div class="post-metadata">

**Author:** ![Alex\_8BitSkull](https://forum-defold.b-cdn.net/user_avatar/forum.defold.com/alex_8bitskull/32/5424_2.png) [@Alex\_8BitSkull](https://forum.defold.com/u/Alex_8BitSkull)\
**Post date:** [September 21, 2023, 3:04pm UTC](https://forum.defold.com/t/profiler-show-peak-frame/74164/7 "2023-09-21T15:04:34Z")

</div>

I’ve submitted an issue:

[https://github.com/defold/defold/issues/8027](https://github.com/defold/defold/issues/8027)
