All of lore.kernel.org
 help / color / mirror / Atom feed
From: Pekka Paalanen <ppaalanen@gmail.com>
To: Jason Ekstrand <jason@jlekstrand.net>
Cc: mesa-dev@lists.freedesktop.org, Keith Packard <keithp@keithp.com>,
	dri-devel@lists.freedesktop.org
Subject: Re: [PATCH 1/3] vulkan: Define new VK_MESA_query_timestamp extension [v2]
Date: Tue, 10 Jul 2018 10:16:15 +0300	[thread overview]
Message-ID: <20180710101615.610c7966@eldfell> (raw)
In-Reply-To: <1642da34868.27ad.c6988b7ea6112e3e892765a0d4287e0c@jlekstrand.net>


[-- Attachment #1.1: Type: text/plain, Size: 1942 bytes --]

On Sat, 23 Jun 2018 12:13:53 -0500
Jason Ekstrand <jason@jlekstrand.net> wrote:

> I haven't thought through this comment all that hard but would it make 
> sense to have three timestamps, CPU, GPU, CPU so that you have error bars 
> on the GPU timestamp?  At the very least, two timestamps would be better 
> than one so that, when we pull it into the kernel, it can provide something 
> more accurate than userspace trying to grab a snapshot.

Hi,

three timestamps sounds like a good idea to me, but you might want to
reach out to media developers (e.g. gstreamer) who have experience in
synchronizing different clocks and what that will actually take.

When reading the CPU timestamp, I believe it would be necessary for
userspace to tell which clock it should be reading. I'm not sure all
userspace is always using CLOCK_MONOTONIC. But if you have a better
rationale, that would be interesting to record and document.


Thanks,
pq

> On June 23, 2018 10:15:34 Keith Packard <keithp@keithp.com> wrote:
> 
> > This extension adds a single function to query the current GPU
> > timestamp, just like glGetInteger64v(GL_TIMESTAMP, &timestamp). This
> > function is needed to complete the implementation of
> > GOOGLE_display_timing, which needs to be able to correlate GPU and CPU
> > timestamps.
> >
> > v2:	Adopt Jason Ekstrand's coding conventions
> >
> > 	Declare variables at first use, eliminate extra whitespace between
> > 	types and names. Wrap lines to 80 columns.
> >
> > 	Add extension to list in alphabetical order
> >
> > 	Suggested-by: Jason Ekstrand <jason.ekstrand@intel.com>
> >
> > Signed-off-by: Keith Packard <keithp@keithp.com>
> > ---
> > include/vulkan/vk_mesa_query_timestamp.h | 41 ++++++++++++++++++++++++
> > src/vulkan/registry/vk.xml               | 15 +++++++++
> > 2 files changed, 56 insertions(+)
> > create mode 100644 include/vulkan/vk_mesa_query_timestamp.h

[-- Attachment #1.2: OpenPGP digital signature --]
[-- Type: application/pgp-signature, Size: 833 bytes --]

[-- Attachment #2: Type: text/plain, Size: 160 bytes --]

_______________________________________________
dri-devel mailing list
dri-devel@lists.freedesktop.org
https://lists.freedesktop.org/mailman/listinfo/dri-devel

  reply	other threads:[~2018-07-10  7:16 UTC|newest]

Thread overview: 9+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2018-06-23 15:15 [PATCH 0/3] Add (internal) MESA_query_timestamp extension to anv/radv Keith Packard
2018-06-23 15:15 ` [PATCH 1/3] vulkan: Define new VK_MESA_query_timestamp extension [v2] Keith Packard
2018-06-23 17:13   ` Jason Ekstrand
2018-07-10  7:16     ` Pekka Paalanen [this message]
2018-07-10 18:02       ` Keith Packard
2018-07-11  7:31         ` Pekka Paalanen
2018-07-11 15:56           ` Keith Packard
2018-06-23 15:15 ` [PATCH 2/3] anv: Add new VK_MESA_query_timestamp extension to anv driver [v2] Keith Packard
2018-06-23 15:15 ` [PATCH 3/3] radv: Add new VK_MESA_query_timestamp extension to radv driver Keith Packard

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=20180710101615.610c7966@eldfell \
    --to=ppaalanen@gmail.com \
    --cc=dri-devel@lists.freedesktop.org \
    --cc=jason@jlekstrand.net \
    --cc=keithp@keithp.com \
    --cc=mesa-dev@lists.freedesktop.org \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.