Re: Proposal for fixing race conditions

On Fri, Jun 28, 2013 at 12:06 PM, Chris Rogers <crogers@google.com> wrote:

> Of course I think we all agree that we need to have a system which is safe
> and secure.  But please apply more discretion in the discussion of these
> types of issues in the future.
>

Yes, I apologise for being careless.


> Additionally, it's important to keep in mind the performance hit of any
> memory copies.  Performance is very very important.
>

I don't think it's critical that the Web Audio content *in use today* have
optimal performance. If we introduce new APIs --- soon --- that support
minimal memory copying, and steer authors towards them, then that should be
good enough. I have a strong desire to support legacy content, but I don't
think it's very important for that content to be maximally efficient.

I would also like to see/generate some data about the performance impact of
various proposals. Have you got a performance benchmark of, say, granular
synthesis, that you expect to suffer from setValueCurveAtTime copying, that
we can examine? Any suggestions for a methodology that would demonstrate
significant performance regressions from that copying?

On Thu, Jun 20, 2013 at 7:32 PM, Robert O'Callahan <robert@ocallahan.org>wrote:
>
 2) AudioParam.setValueCurveAtTime(Float32Array values, double startTime,
>> double duration)
>> I propose copying the data during the setValueCurveAtTime call.
>>
>
> Copying is very inefficient, so I propose we mark this Float32Array as
> "un-neuterable" and a copy will be made if it's sent to a web worker.  In
> normal use cases, we can benefit for avoiding the copy.
>

You're proposing to introduce a new feature to the Web platform,
"un-neuterable typed arrays", in order to fix your safety issues related to
neutering. But this will do nothing to fix the problem of races, and any of
the proposals to avoid races will take care of neutering at the same time
without having to introduce this feature.

Rob
-- 
Jtehsauts  tshaei dS,o n" Wohfy  Mdaon  yhoaus  eanuttehrotraiitny  eovni
le atrhtohu gthot sf oirng iyvoeu rs ihnesa.r"t sS?o  Whhei csha iids  teoa
stiheer :p atroa lsyazye,d  'mYaonu,r  "sGients  uapr,e  tfaokreg iyvoeunr,
'm aotr  atnod  sgaoy ,h o'mGee.t"  uTph eann dt hwea lmka'n?  gBoutt  uIp
waanndt  wyeonut  thoo mken.o w  *
*

Received on Friday, 28 June 2013 09:42:34 UTC