Bug 144538 - [WebAudio] Add experimental support for a streaming audio decoder.
Summary: [WebAudio] Add experimental support for a streaming audio decoder.
Status: NEW
Alias: None
Product: WebKit
Classification: Unclassified
Component: New Bugs (show other bugs)
Version: 528+ (Nightly build)
Hardware: Unspecified Unspecified
: P2 Normal
Assignee: Jer Noble
URL:
Keywords: InRadar
Depends on:
Blocks:
 
Reported: 2015-05-02 20:31 PDT by Jer Noble
Modified: 2016-04-02 19:27 PDT (History)
6 users (show)

See Also:


Attachments
Patch (60.95 KB, patch)
2015-05-02 22:13 PDT, Jer Noble
no flags Details | Formatted Diff | Diff
Archive of layout-test-results from ews102 for mac-mavericks (565.72 KB, application/zip)
2015-05-02 22:54 PDT, Build Bot
no flags Details
Archive of layout-test-results from ews107 for mac-mavericks-wk2 (628.38 KB, application/zip)
2015-05-02 23:21 PDT, Build Bot
no flags Details
Patch (62.59 KB, patch)
2015-05-03 08:16 PDT, Jer Noble
no flags Details | Formatted Diff | Diff
Archive of layout-test-results from ews102 for mac-mavericks (582.49 KB, application/zip)
2015-05-03 08:57 PDT, Build Bot
no flags Details
Archive of layout-test-results from ews105 for mac-mavericks-wk2 (620.80 KB, application/zip)
2015-05-03 09:02 PDT, Build Bot
no flags Details
Patch (62.79 KB, patch)
2015-05-03 09:05 PDT, Jer Noble
no flags Details | Formatted Diff | Diff
Patch (62.81 KB, patch)
2015-05-03 09:26 PDT, Jer Noble
no flags Details | Formatted Diff | Diff
Archive of layout-test-results from ews102 for mac-mavericks (570.20 KB, application/zip)
2015-05-03 10:08 PDT, Build Bot
no flags Details
Archive of layout-test-results from ews104 for mac-mavericks-wk2 (629.26 KB, application/zip)
2015-05-03 10:35 PDT, Build Bot
no flags Details
Patch (64.54 KB, patch)
2015-05-03 15:44 PDT, Jer Noble
no flags Details | Formatted Diff | Diff
Patch (64.48 KB, patch)
2016-02-01 08:34 PST, Jer Noble
no flags Details | Formatted Diff | Diff
Patch (64.47 KB, patch)
2016-02-01 08:51 PST, Jer Noble
eric.carlson: review+
Details | Formatted Diff | Diff
Patch for landing (64.66 KB, patch)
2016-02-01 09:26 PST, Jer Noble
no flags Details | Formatted Diff | Diff
Patch for landing (62.96 KB, patch)
2016-02-02 10:22 PST, Jer Noble
buildbot: commit-queue-
Details | Formatted Diff | Diff
Archive of layout-test-results from ews100 for mac-yosemite (789.77 KB, application/zip)
2016-02-02 11:53 PST, Build Bot
no flags Details
Archive of layout-test-results from ews104 for mac-yosemite-wk2 (836.16 KB, application/zip)
2016-02-02 11:57 PST, Build Bot
no flags Details
Archive of layout-test-results from ews114 for mac-yosemite (858.98 KB, application/zip)
2016-02-02 12:03 PST, Build Bot
no flags Details

Note You need to log in before you can comment on or make changes to this bug.
Description Jer Noble 2015-05-02 20:31:37 PDT
[WebAudio] Add experimental support for a streaming audio decoder.
Comment 1 Jer Noble 2015-05-02 22:13:53 PDT
Created attachment 252257 [details]
Patch
Comment 2 Build Bot 2015-05-02 22:54:51 PDT
Comment on attachment 252257 [details]
Patch

Attachment 252257 [details] did not pass mac-ews (mac):
Output: http://webkit-queues.appspot.com/results/5467842996600832

New failing tests:
js/dom/global-constructors-attributes.html
Comment 3 Build Bot 2015-05-02 22:54:54 PDT
Created attachment 252258 [details]
Archive of layout-test-results from ews102 for mac-mavericks

The attached test failures were seen while running run-webkit-tests on the mac-ews.
Bot: ews102  Port: mac-mavericks  Platform: Mac OS X 10.9.5
Comment 4 Build Bot 2015-05-02 23:21:48 PDT
Comment on attachment 252257 [details]
Patch

Attachment 252257 [details] did not pass mac-wk2-ews (mac-wk2):
Output: http://webkit-queues.appspot.com/results/6352887043063808

New failing tests:
js/dom/global-constructors-attributes.html
webaudio/audiostreamdecoder.html
Comment 5 Build Bot 2015-05-02 23:21:50 PDT
Created attachment 252259 [details]
Archive of layout-test-results from ews107 for mac-mavericks-wk2

The attached test failures were seen while running run-webkit-tests on the mac-wk2-ews.
Bot: ews107  Port: mac-mavericks-wk2  Platform: Mac OS X 10.9.5
Comment 6 Jer Noble 2015-05-03 08:16:01 PDT
Created attachment 252269 [details]
Patch
Comment 7 Build Bot 2015-05-03 08:57:11 PDT
Comment on attachment 252269 [details]
Patch

Attachment 252269 [details] did not pass mac-ews (mac):
Output: http://webkit-queues.appspot.com/results/4505168490004480

New failing tests:
js/dom/global-constructors-attributes.html
webaudio/audiostreamdecoder.html
Comment 8 Build Bot 2015-05-03 08:57:14 PDT
Created attachment 252271 [details]
Archive of layout-test-results from ews102 for mac-mavericks

The attached test failures were seen while running run-webkit-tests on the mac-ews.
Bot: ews102  Port: mac-mavericks  Platform: Mac OS X 10.9.5
Comment 9 Build Bot 2015-05-03 09:02:41 PDT
Comment on attachment 252269 [details]
Patch

Attachment 252269 [details] did not pass mac-wk2-ews (mac-wk2):
Output: http://webkit-queues.appspot.com/results/4818787538829312

New failing tests:
js/dom/global-constructors-attributes.html
Comment 10 Build Bot 2015-05-03 09:02:45 PDT
Created attachment 252272 [details]
Archive of layout-test-results from ews105 for mac-mavericks-wk2

The attached test failures were seen while running run-webkit-tests on the mac-wk2-ews.
Bot: ews105  Port: mac-mavericks-wk2  Platform: Mac OS X 10.9.5
Comment 11 Jer Noble 2015-05-03 09:05:42 PDT
Created attachment 252273 [details]
Patch
Comment 12 Jer Noble 2015-05-03 09:26:38 PDT
Created attachment 252274 [details]
Patch
Comment 13 Build Bot 2015-05-03 10:08:14 PDT
Comment on attachment 252274 [details]
Patch

Attachment 252274 [details] did not pass mac-ews (mac):
Output: http://webkit-queues.appspot.com/results/6047085908459520

New failing tests:
js/dom/global-constructors-attributes.html
webaudio/audiostreamdecoder.html
Comment 14 Build Bot 2015-05-03 10:08:19 PDT
Created attachment 252277 [details]
Archive of layout-test-results from ews102 for mac-mavericks

The attached test failures were seen while running run-webkit-tests on the mac-ews.
Bot: ews102  Port: mac-mavericks  Platform: Mac OS X 10.9.5
Comment 15 Build Bot 2015-05-03 10:35:27 PDT
Comment on attachment 252274 [details]
Patch

Attachment 252274 [details] did not pass mac-wk2-ews (mac-wk2):
Output: http://webkit-queues.appspot.com/results/5132313172115456

New failing tests:
js/dom/global-constructors-attributes.html
webaudio/audiostreamdecoder.html
Comment 16 Build Bot 2015-05-03 10:35:29 PDT
Created attachment 252280 [details]
Archive of layout-test-results from ews104 for mac-mavericks-wk2

The attached test failures were seen while running run-webkit-tests on the mac-wk2-ews.
Bot: ews104  Port: mac-mavericks-wk2  Platform: Mac OS X 10.9.5
Comment 17 Jer Noble 2015-05-03 15:44:07 PDT
Created attachment 252288 [details]
Patch
Comment 18 Jer Noble 2015-05-03 17:15:37 PDT
Finally ready for review (EWS are all green).
Comment 19 Jer Noble 2016-02-01 08:34:00 PST
Created attachment 270386 [details]
Patch
Comment 20 Jer Noble 2016-02-01 08:51:23 PST
Created attachment 270387 [details]
Patch
Comment 21 Eric Carlson 2016-02-01 08:59:41 PST
Comment on attachment 270387 [details]
Patch

View in context: https://bugs.webkit.org/attachment.cgi?id=270387&action=review

> Source/WebCore/ChangeLog:1
> +2015-05-02  Jer Noble  <jer.noble@apple.com>

This marinated for a while!

> Source/WebCore/Modules/webaudio/AudioStreamDecoder.cpp:2
> + * Copyright (C) 2015 Apple Inc. All rights reserved.

This should be updated.

> Source/WebCore/Modules/webaudio/AudioStreamDecoder.cpp:52
> +    // 1. If audioData is null or not a valid ArrayBuffer, return a rejected promise with a

I think it would be useful to include the url these steps came from to make it easier to review now and to check for spec changes in the future.

> Source/WebCore/Modules/webaudio/AudioStreamDecoder.h:2
> + * Copyright (C) 2015 Apple Inc. All rights reserved.

This should be updated.

> Source/WebCore/Modules/webaudio/AudioStreamDecoder.idl:2
> + * Copyright (C) 2015 Apple Inc. All rights reserved.

Ditto.

> Source/WebCore/bindings/js/JSAudioStreamDecoderCustom.cpp:2
> + * Copyright (C) 2015 Apple Inc. All rights reserved.

Ditto.

> Source/WebCore/platform/audio/AudioStreamReader.h:2
> + * Copyright (C) 2015 Apple Inc. All rights reserved.

Ditto.

> Source/WebCore/platform/audio/mac/AudioStreamReaderMac.h:2
> + * Copyright (C) 2015 Apple Inc. All rights reserved.

Ditto.

> Source/WebCore/platform/audio/mac/AudioStreamReaderMac.h:52
> +    dispatch_queue_t m_queue;

m_decodingQueue might be a better name to make its task clearer.

> Source/WebCore/platform/audio/mac/AudioStreamReaderMac.mm:2
> + * Copyright (C) 2015 Apple Inc. All rights reserved.

This should be updated.

> Source/WebCore/platform/audio/mac/AudioStreamReaderMac.mm:51
> +AudioStreamReaderMac::~AudioStreamReaderMac()
> +{
> +    if (m_stream) {
> +        OSStatus status = AudioFileStreamClose(m_stream);
> +        ASSERT(status == noErr);
> +        UNUSED_PARAM(status);
> +    }
> +}

The ChangeLog says "Close the dispatch queue." Is that not necessary?
Comment 22 Jer Noble 2016-02-01 09:22:48 PST
Comment on attachment 270387 [details]
Patch

View in context: https://bugs.webkit.org/attachment.cgi?id=270387&action=review

>> Source/WebCore/Modules/webaudio/AudioStreamDecoder.cpp:2
>> + * Copyright (C) 2015 Apple Inc. All rights reserved.
> 
> This should be updated.

Okay, to this and all the other 2015 -> 2016 changes.

>> Source/WebCore/Modules/webaudio/AudioStreamDecoder.cpp:52
>> +    // 1. If audioData is null or not a valid ArrayBuffer, return a rejected promise with a
> 
> I think it would be useful to include the url these steps came from to make it easier to review now and to check for spec changes in the future.

Sure thing.

>> Source/WebCore/platform/audio/mac/AudioStreamReaderMac.h:52
>> +    dispatch_queue_t m_queue;
> 
> m_decodingQueue might be a better name to make its task clearer.

Ok.

>> Source/WebCore/platform/audio/mac/AudioStreamReaderMac.mm:51
>> +}
> 
> The ChangeLog says "Close the dispatch queue." Is that not necessary?

Whoops. At the time I wrote this, I didn't know about OSObjectPtr (a RetainPtr<> for things like dispatch_queue_t). I'll add that here so that the dispatch queue doesn't need to be explicitly released.
Comment 23 Jer Noble 2016-02-01 09:26:49 PST
Created attachment 270391 [details]
Patch for landing
Comment 24 Jer Noble 2016-02-02 10:22:31 PST
Created attachment 270496 [details]
Patch for landing
Comment 25 Build Bot 2016-02-02 11:53:39 PST
Comment on attachment 270496 [details]
Patch for landing

Attachment 270496 [details] did not pass mac-ews (mac):
Output: http://webkit-queues.webkit.org/results/773529

New failing tests:
js/dom/global-constructors-attributes.html
webaudio/audiostreamdecoder.html
Comment 26 Build Bot 2016-02-02 11:53:43 PST
Created attachment 270501 [details]
Archive of layout-test-results from ews100 for mac-yosemite

The attached test failures were seen while running run-webkit-tests on the mac-ews.
Bot: ews100  Port: mac-yosemite  Platform: Mac OS X 10.10.5
Comment 27 Build Bot 2016-02-02 11:57:27 PST
Comment on attachment 270496 [details]
Patch for landing

Attachment 270496 [details] did not pass mac-wk2-ews (mac-wk2):
Output: http://webkit-queues.webkit.org/results/773532

New failing tests:
js/dom/global-constructors-attributes.html
webaudio/audiostreamdecoder.html
Comment 28 Build Bot 2016-02-02 11:57:30 PST
Created attachment 270502 [details]
Archive of layout-test-results from ews104 for mac-yosemite-wk2

The attached test failures were seen while running run-webkit-tests on the mac-wk2-ews.
Bot: ews104  Port: mac-yosemite-wk2  Platform: Mac OS X 10.10.5
Comment 29 Build Bot 2016-02-02 12:03:28 PST
Comment on attachment 270496 [details]
Patch for landing

Attachment 270496 [details] did not pass mac-debug-ews (mac):
Output: http://webkit-queues.webkit.org/results/773528

New failing tests:
js/dom/global-constructors-attributes.html
webaudio/audiostreamdecoder.html
Comment 30 Build Bot 2016-02-02 12:03:32 PST
Created attachment 270503 [details]
Archive of layout-test-results from ews114 for mac-yosemite

The attached test failures were seen while running run-webkit-tests on the mac-debug-ews.
Bot: ews114  Port: mac-yosemite  Platform: Mac OS X 10.10.5
Comment 31 Radar WebKit Bug Importer 2016-04-02 19:27:14 PDT
<rdar://problem/25513370>