W3C home > Mailing lists > Public > public-audio@w3.org > July to September 2013

Re: ROC's Proposal for fixing race conditions

From: Robert O'Callahan <robert@ocallahan.org>
Date: Fri, 9 Aug 2013 18:29:47 +1200
Message-ID: <CAOp6jLZ3sMSMsvUXL7-mOSMEtkonq_0TcjsKwxACJz2NWdoLQw@mail.gmail.com>
To: Jer Noble <jer.noble@apple.com>
Cc: WG <public-audio@w3.org>
On Fri, Aug 9, 2013 at 5:53 PM, Jer Noble <jer.noble@apple.com> wrote:

> It seems as though your proposal could be implemented on any platform with
> support for copy-on-write page semantics, without requiring neutering any
> outstanding ArrayBuffers.  E.g., on Posix platforms, the "acquire the
> contents" step could simply mmap(MAP_PRIVATE) the source memory, and if the
> original memory contents are modified, the AudioBuffer gets a fresh copy.

I considered trying to use mmap to create copy-on-write snapshots of memory
blocks but couldn't figure out how to get it to work on Linux or Windows.
Can you be specific about exactly how this would work?

So why specify these explicit mechanisms (such as neutering), rather than
> just a general, implementable requirement: "Modifications to 'acquired
> contents' must have no affect on live nodes." and allow implementations to
> fulfill this requirement however they see fit?

If you can tell me an reasonably easy way to implement it that works on the
major OSes, I'd go for it :-).

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, 9 August 2013 06:30:14 UTC

This archive was generated by hypermail 2.4.0 : Friday, 17 January 2020 19:03:23 UTC