PresentMon icon indicating copy to clipboard operation
PresentMon copied to clipboard

Request: Please still provide information about Present calls w/ 2.0 metrics`

Open alinsavix opened this issue 1 year ago • 4 comments

In the 2.0 release, most of the information that used to be provided about present calls (in particular msBetweenPresents and msInPresentAPI) is no longer provided. Though I understand that this information has limited use in studying the performance of games and such directly, there is definitely still use for it -- for example, in analyzing the behavior of software that hooks into a game's present calls for various purposes (e.g. recording gameplay). It would be great if that information were still surfaced in some way in the 2.0 format -- either with absolute timestamps (the way CPUStartTime is done in the 2.0 format) or relative ones (the way msBetweenPresents is done in the 1.0 format). Having exit times (or a delta like msInPresentAPI) would also be appreciated.

I realize there is a --v1_metrics CLI flag available, but this robs the user of the 2.0 metrics, which are also quite useful in these types of analysis.

Thanks!

alinsavix avatar Apr 11 '24 22:04 alinsavix

You may reconstruct V1 metrics from V2 ones:

CPUWait = msInPresentAPI CPUStart is the frame start timestamp, which matches with return from present() call, so you can calculate present() call timestamp using those two values easily

AlexUnwinder avatar Apr 12 '24 00:04 AlexUnwinder

Aha! That wasn't obvious to me, but now that you've put it that way, it makes sense. That's exactly what I need, thanks!

alinsavix avatar Apr 12 '24 02:04 alinsavix

Cannot say about all tools which will integrate PresentMon 2.0, but at least for RTSS PresentMon metrics integration I'll provide new V2 metrics together with reconstructed V1 metrics, so users will be able to use both and compare apples to oranges or switch between V1 and V2 frametimes on the fly:

https://www.youtube.com/watch?v=_uQPqLruGtg

AlexUnwinder avatar Apr 13 '24 18:04 AlexUnwinder

I think you're right we should add this back in. Here's what I'm thinking:

  • Add msInPresentAPI metric back in, though possibly renamed to be more consistent with the new naming. Maybe "CPUFramePacingStall"
  • Keep the "CPUWait" metric. Inititally, these will be the same value but as we add detection of more CPU idle/wait conditions CPUWait will increase while CPUFramePacingStall will continue to only measure CPU time spent in Present() call.

Let me know if you have any feedback, otherwise will try to get this done for the next release.

this has been added back in already since 2.3

planetchili avatar Nov 14 '25 00:11 planetchili