W3C home > Mailing lists > Public > public-web-perf@w3.org > May 2012

Re: requestAnimationFrame time and DOMHighResTimestamp

From: Boris Zbarsky <bzbarsky@MIT.EDU>
Date: Mon, 14 May 2012 14:03:23 -0400
Message-ID: <4FB148EB.7080104@mit.edu>
To: public-web-perf@w3.org
On 5/10/12 5:47 PM, James Robinson wrote:
> I've made this change in 458:4843fb42912f along with defining that the
> callback's parameter is gathered by running the window.performance.now()
> algorithm before any callbacks are invoked.

I've finally had a chance to read over the result, and it has some problems:

1)  Step 1 of section 5 doesn't define which window's performance.now() 
should be used.  As far as I can tell, the value of performance.now() 
differs in different windows, because the value of 
performance.timing.navigationStart differs in different windows.  Note 
that this also means that using performance.now() in any sort of 
cross-frame scripting situation is a footgun, by the way.  I'll raise 
this as a separate issue

2)  The example in section 1 is now broken.

Fixing #2 is easy.

Fixing #1, I'm not sure.  If performance.now() doesn't change, then we 
probably need to first walk all the documents and gather up the relevant 
now() values, and only then start making the callbacks...  Or something. 
  In any casem the current setup makes no sense.

> My understanding is that this is consistent with
> Mozilla and Chrome's expected behavior.

The spec as written is definitely not consistent with anything we'd 
ship.  ;)

-Boris
Received on Monday, 14 May 2012 18:04:00 UTC

This archive was generated by hypermail 2.3.1 : Tuesday, 6 January 2015 21:04:32 UTC