W3C home > Mailing lists > Public > public-web-perf@w3.org > January 2015

Re: [User Timing] Clarification of negative duration values

From: Nic Jansma <nic@nicj.net>
Date: Tue, 20 Jan 2015 18:08:33 -0500
Message-ID: <54BEDFF1.4030003@nicj.net>
To: Eli Perelman <eperelman@mozilla.com>, public-web-perf <public-web-perf@w3.org>
IE also "allows" for this scenario and shows a negative duration in the 
getEntries query.

- Nic
http://nicj.net/
@NicJ

On 1/20/2015 4:49 PM, Eli Perelman wrote:
> In working on the implementation of the User Timing spec in Gecko, it 
> was brought up about the potential of durations to return negative 
> values. Specifically it was unclear from the spec whether things like 
> this should be allowed:
>
> ```js
> performance.mark('A');
> performance.mark('B');
>
> performance.measure('delta', 'B', 'A');
>
> assert( performance.getEntriesByName('delta')[0].duration < 0 ); // true
> ```
>
> Chrome allows this interaction, enabling negative duration values for 
> measures. Is this intended, and if so, should we clarify the spec that 
> negative durations are allowed for performance measurements specifically?
>
> Eli Perelman
> Mozilla
Received on Tuesday, 20 January 2015 23:08:54 UTC

This archive was generated by hypermail 2.3.1 : Tuesday, 20 January 2015 23:08:55 UTC