Move platform audio to a separate process |
|||||||||||||||||||||
Issue descriptionBrowser and Renderer processes will be communicating with audio system over Mojo interfaces. Audio process should be restarted upon hang or crash without disturbing browser process. Design doc: https://docs.google.com/a/chromium.org/document/d/1fVHVJjd5zTqc6O7b0lprILyuFPC9qVQUudzjEgOq1HY/edit?usp=sharing
,
Dec 12 2016
,
Jan 26 2017
,
Jan 26 2017
,
Feb 22 2017
,
Jun 5 2017
I don't see Android listed as one of the platforms and was wondering if this was an intentional omission. This could actually be really useful on Android as part of webapks where we could attribute (the seemingly expensive processing) to the WebApk as opposed to it showing up as chrome using your battery. There's also implications for permission management and audio capture that would be desirable. Happy to follow up with a separate bug/thread if you want to discuss more or understand what I'm talking about and whether it's feasible.
,
Jun 5 2017
The reason for excluding Android is that we did not consider the advantages to justify the memory overhead of a separate process (granted, we're not even sure about how large the overhead is). This can be reconsidered. Either way, we get the ability to run audio in a separate process on Android for ~free when doing it for the other platforms, so we're not locking ourselves into a decision on this.
,
Jun 5 2017
Awesome, that makes sense. I'll follow along on this bug until this matures more and we can try it on android
,
Jun 20 2017
Issue 729494 has been merged into this issue.
,
Jun 20 2017
Users experienced this crash on the following builds: Win Dev 61.0.3128.0 - 0.11 CPM, 29 reports, 27 clients (signature [Shutdown hang] media::AudioManager::Shutdown) Linux Dev 61.0.3128.3 - 0.59 CPM, 3 reports, 3 clients (signature [Shutdown hang] media::AudioManager::Shutdown) If this update was incorrect, please add "Fracas-Wrong" label to prevent future updates. - Go/Fracas
,
Jul 21 2017
Users experienced this crash on the following builds: Linux Beta 60.0.3112.72 - 0.74 CPM, 1 reports, 1 clients (signature [Shutdown hang] media::AudioManager::Shutdown) If this update was incorrect, please add "Fracas-Wrong" label to prevent future updates. - Go/Fracas
,
Aug 15 2017
,
Oct 3 2017
Users experienced this crash on the following builds: Linux Dev 63.0.3223.8 - 0.51 CPM, 2 reports, 2 clients (signature [Shutdown hang] media::AudioManager::Shutdown) If this update was incorrect, please add "Fracas-Wrong" label to prevent future updates. - Go/Fracas
,
Oct 11 2017
,
Oct 13 2017
Users experienced this crash on the following builds: Linux Beta 62.0.3202.45 - 0.13 CPM, 2 reports, 2 clients (signature [Shutdown hang] media::AudioManager::Shutdown) If this update was incorrect, please add "Fracas-Wrong" label to prevent future updates. - Go/Fracas
,
Oct 20 2017
Users experienced this crash on the following builds: Win Canary 64.0.3244.0 - 0.10 CPM, 3 reports, 3 clients (signature [Shutdown hang] media::AudioManager::Shutdown) If this update was incorrect, please add "Fracas-Wrong" label to prevent future updates. - Go/Fracas
,
Nov 22 2017
Just to update: Magic Signature: '[Shutdown hang] media::AudioManager::Shutdown' This is top#20th browser crash seen on latest Dev-64.0.3269.3 & still seeing 19 instances from 16 clients so far. 64.0.3269.3 0.04% 19 -Dev 64.0.3268.0 0.00% 2 64.0.3266.0 0.00% 1 Link to the list of builds: -------------------------- https://crash.corp.google.com/browse?q=product.name%3D%27Chrome%27%20AND%20custom_data.ChromeCrashProto.ptype%3D%27browser%27%20AND%20custom_data.ChromeCrashProto.magic_signature_1.name%3D%27%5BShutdown%20hang%5D%20media%3A%3AAudioManager%3A%3AShutdown%27&sql_dialect=dremelsql&ignore_case=false&enable_rewrite=true&omit_field_name=&omit_field_value=&omit_field_opt=%3D#productversion:1000 olka@,Please take a look. Thanks..!
,
Nov 22 2017
,
Nov 27 2017
,
Dec 6 2017
,
Feb 2 2018
Users experienced this crash on the following builds: Win Canary 66.0.3335.0 - 0.17 CPM, 3 reports, 3 clients (signature [Shutdown hang] media::AudioManager::Shutdown) If this update was incorrect, please add "Fracas-Wrong" label to prevent future updates. - Go/Fracas
,
Feb 15 2018
,
Mar 22 2018
Users experienced this crash on the following builds: Win Canary 67.0.3377.0 - 0.13 CPM, 4 reports, 4 clients (signature [Shutdown hang] media::AudioManager::Shutdown) If this update was incorrect, please add "Fracas-Wrong" label to prevent future updates. - Go/Fracas
,
Mar 28 2018
The following revision refers to this bug: https://chromium.googlesource.com/chromium/src.git/+/5772174d5f9fcaff06d5b47df2df9112949a2290 commit 5772174d5f9fcaff06d5b47df2df9112949a2290 Author: Olga Sharonova <olka@chromium.org> Date: Wed Mar 28 14:07:00 2018 Standalone Audio service infrastructure * OwningAudioManagerAccessor * ServiceMain() * Test fixture for out-of-process tests; used only for lifetime tests at this point. * ServiceTest modification to allow custom test-specific manifests: we need that to be able to have both in-process and out-of-process tests for the service. Done following rockot@'s detailed instructions, see [1] * kAudioServiceQuitTimeoutMs media switch to allow a non-default Audio service quit timeout value (used in tests). At this point we do not run Audio service out-of-process in Chrome: it's only an basic infrastructure to enable testing various out-of-process functionality, such as on crash behavior. [1] https://www.google.com/url?hl=en&q=https://groups.google.com/a/chromium.org/d/msgid/services-dev/CAHri2_SHP26hm-a-295OCX5fMQZQqpopDxqLzi%252BpZXLzVnVN1w%2540mail.gmail.com?utm_medium%3Demail%26utm_source%3Dfooter&source=gmail&ust=1521721921151000&usg=AFQjCNH-pgZMrFjovDxxAE9ejd9v0eHHZg Change-Id: I3af4760b1dedaa9211c135d5b11d33e78da772ac Bug: 672469 Reviewed-on: https://chromium-review.googlesource.com/973861 Commit-Queue: Olga Sharonova <olka@chromium.org> Reviewed-by: Dale Curtis <dalecurtis@chromium.org> Reviewed-by: Max Morin <maxmorin@chromium.org> Reviewed-by: Ken Rockot <rockot@chromium.org> Cr-Commit-Position: refs/heads/master@{#546477} [modify] https://crrev.com/5772174d5f9fcaff06d5b47df2df9112949a2290/media/base/media_switches.cc [modify] https://crrev.com/5772174d5f9fcaff06d5b47df2df9112949a2290/media/base/media_switches.h [modify] https://crrev.com/5772174d5f9fcaff06d5b47df2df9112949a2290/services/audio/BUILD.gn [add] https://crrev.com/5772174d5f9fcaff06d5b47df2df9112949a2290/services/audio/owning_audio_manager_accessor.cc [add] https://crrev.com/5772174d5f9fcaff06d5b47df2df9112949a2290/services/audio/owning_audio_manager_accessor.h [modify] https://crrev.com/5772174d5f9fcaff06d5b47df2df9112949a2290/services/audio/service.h [add] https://crrev.com/5772174d5f9fcaff06d5b47df2df9112949a2290/services/audio/service_main.cc [add] https://crrev.com/5772174d5f9fcaff06d5b47df2df9112949a2290/services/audio/test/standalone_service_test.cc [modify] https://crrev.com/5772174d5f9fcaff06d5b47df2df9112949a2290/services/service_manager/public/cpp/service_test.cc [modify] https://crrev.com/5772174d5f9fcaff06d5b47df2df9112949a2290/services/service_manager/public/cpp/service_test.h
,
Apr 9 2018
The following revision refers to this bug: https://chromium.googlesource.com/chromium/src.git/+/acef01cbb35d643fdcdb1a22b261349dfb49fcb3 commit acef01cbb35d643fdcdb1a22b261349dfb49fcb3 Author: Olga Sharonova <olka@chromium.org> Date: Mon Apr 09 20:10:10 2018 media::AudioSystem: disconnect from Audio service when not in use. Also added mojo::InterfacePtr<>::IsExpectingResponse(). Bug: 672469, 792441 Change-Id: I9c508cafae84b393e226834c4236724d59641829 Reviewed-on: https://chromium-review.googlesource.com/998166 Commit-Queue: Olga Sharonova <olka@chromium.org> Reviewed-by: Max Morin <maxmorin@chromium.org> Reviewed-by: Ken Rockot <rockot@chromium.org> Cr-Commit-Position: refs/heads/master@{#549254} [modify] https://crrev.com/acef01cbb35d643fdcdb1a22b261349dfb49fcb3/mojo/public/cpp/bindings/interface_ptr.h [modify] https://crrev.com/acef01cbb35d643fdcdb1a22b261349dfb49fcb3/services/audio/public/cpp/audio_system_to_service_adapter.cc [modify] https://crrev.com/acef01cbb35d643fdcdb1a22b261349dfb49fcb3/services/audio/public/cpp/audio_system_to_service_adapter.h [modify] https://crrev.com/acef01cbb35d643fdcdb1a22b261349dfb49fcb3/services/audio/test/audio_system_to_service_adapter_test.cc
,
Apr 12 2018
The following revision refers to this bug: https://chromium.googlesource.com/chromium/src.git/+/488accfc5949582c5280e4930ac91a1382b25ae0 commit 488accfc5949582c5280e4930ac91a1382b25ae0 Author: Jonas Olsson <jonasolsson@chromium.org> Date: Thu Apr 12 10:44:46 2018 Measure stream creation times in Mojo audio IPC Media.Audio.Render.[Input|Output]DeviceStreamCreationTime measures the time from stream creation starting until the StreamCreated callback gets triggered. Bug: chromium:672469 Cq-Include-Trybots: luci.chromium.try:android_optional_gpu_tests_rel;luci.chromium.try:linux_optional_gpu_tests_rel;luci.chromium.try:mac_optional_gpu_tests_rel;master.tryserver.chromium.win:win_optional_gpu_tests_rel Change-Id: I32f50b8cf19afea7b97ae415fce17308085567bf Reviewed-on: https://chromium-review.googlesource.com/1000855 Reviewed-by: Max Morin <maxmorin@chromium.org> Reviewed-by: Olga Sharonova <olka@chromium.org> Reviewed-by: Steven Holte <holte@chromium.org> Commit-Queue: Jonas Olsson <jonasolsson@chromium.org> Cr-Commit-Position: refs/heads/master@{#550138} [modify] https://crrev.com/488accfc5949582c5280e4930ac91a1382b25ae0/content/renderer/media/mojo_audio_input_ipc.cc [modify] https://crrev.com/488accfc5949582c5280e4930ac91a1382b25ae0/content/renderer/media/mojo_audio_input_ipc.h [modify] https://crrev.com/488accfc5949582c5280e4930ac91a1382b25ae0/content/renderer/media/mojo_audio_output_ipc.cc [modify] https://crrev.com/488accfc5949582c5280e4930ac91a1382b25ae0/content/renderer/media/mojo_audio_output_ipc.h [modify] https://crrev.com/488accfc5949582c5280e4930ac91a1382b25ae0/tools/metrics/histograms/histograms.xml
,
Apr 17 2018
The following revision refers to this bug: https://chromium.googlesource.com/chromium/src.git/+/3b0840b3200a5fe012e9b0536dd85f7a99e34893 commit 3b0840b3200a5fe012e9b0536dd85f7a99e34893 Author: Jonas Olsson <jonasolsson@chromium.org> Date: Tue Apr 17 08:41:17 2018 move OutputDeviceAuthorizationTime stat to IPC layer Bug: chromium:672469 Cq-Include-Trybots: luci.chromium.try:android_optional_gpu_tests_rel;luci.chromium.try:linux_optional_gpu_tests_rel;luci.chromium.try:mac_optional_gpu_tests_rel;luci.chromium.try:win_optional_gpu_tests_rel Change-Id: I33a9e06feddf52699c47a8d64e17eca8ed797bf6 Reviewed-on: https://chromium-review.googlesource.com/1013460 Commit-Queue: Jonas Olsson <jonasolsson@chromium.org> Reviewed-by: Max Morin <maxmorin@chromium.org> Reviewed-by: Olga Sharonova <olka@chromium.org> Cr-Commit-Position: refs/heads/master@{#551281} [modify] https://crrev.com/3b0840b3200a5fe012e9b0536dd85f7a99e34893/content/renderer/media/mojo_audio_output_ipc.cc [modify] https://crrev.com/3b0840b3200a5fe012e9b0536dd85f7a99e34893/content/renderer/media/mojo_audio_output_ipc.h [modify] https://crrev.com/3b0840b3200a5fe012e9b0536dd85f7a99e34893/media/audio/audio_output_device.cc [modify] https://crrev.com/3b0840b3200a5fe012e9b0536dd85f7a99e34893/media/audio/audio_output_device.h
,
Apr 18 2018
,
Apr 18 2018
,
Apr 19 2018
,
Apr 24 2018
The following revision refers to this bug: https://chromium.googlesource.com/chromium/src.git/+/6de52a15197807f5d3b6d47b63a14b1712e8f838 commit 6de52a15197807f5d3b6d47b63a14b1712e8f838 Author: Jonas Olsson <jonasolsson@chromium.org> Date: Tue Apr 24 14:40:26 2018 Add startup timing stat to audio input and output device. Bug: chromium:672469 Cq-Include-Trybots: luci.chromium.try:android_optional_gpu_tests_rel;luci.chromium.try:linux_optional_gpu_tests_rel;luci.chromium.try:mac_optional_gpu_tests_rel;luci.chromium.try:win_optional_gpu_tests_rel Change-Id: I857ff57164c1d58637247ec1615b2f8817d6edbd Reviewed-on: https://chromium-review.googlesource.com/1009944 Commit-Queue: Jonas Olsson <jonasolsson@chromium.org> Reviewed-by: Max Morin <maxmorin@chromium.org> Reviewed-by: Jesse Doherty <jwd@chromium.org> Reviewed-by: Olga Sharonova <olka@chromium.org> Cr-Commit-Position: refs/heads/master@{#553097} [modify] https://crrev.com/6de52a15197807f5d3b6d47b63a14b1712e8f838/media/audio/audio_input_device.cc [modify] https://crrev.com/6de52a15197807f5d3b6d47b63a14b1712e8f838/media/audio/audio_output_device.cc [modify] https://crrev.com/6de52a15197807f5d3b6d47b63a14b1712e8f838/tools/metrics/histograms/histograms.xml
,
Apr 24 2018
The following revision refers to this bug: https://chromium.googlesource.com/chromium/src.git/+/11d68c0c0d7b63da029470bfa0fa223b4f418660 commit 11d68c0c0d7b63da029470bfa0fa223b4f418660 Author: Olga Sharonova <olka@chromium.org> Date: Tue Apr 24 20:39:58 2018 Out of process Audio service behind a flag Audio service runs in an unsandboxed utility process behind a flag. Not all the content dependencies on AudioManager are removed yet, so: ***when Audio process is enabled***, the state is weird: 1) 2 instances of AudioManager are running: * one hosted in the BrowserMainLoop (provides audio streams), * another living in the audio process (provides audio system information and debug recording interfaces). 2) It also means that debug audio recording not working (because there are no audio streams going through the audio process). When Audio process is disabled (default), Audio service runs embedded in content and everything works properly (the CL has no effect). The goal of this CL(if it is landable) is to simplify local manual testing when developing the audio service. Change-Id: I5382ba60efa924a314f77803fed119e3d3ebda70 BUG: 672469 Reviewed-on: https://chromium-review.googlesource.com/1016983 Commit-Queue: Olga Sharonova <olka@chromium.org> Reviewed-by: Dale Curtis <dalecurtis@chromium.org> Reviewed-by: Kinuko Yasuda <kinuko@chromium.org> Reviewed-by: Ken Rockot <rockot@chromium.org> Reviewed-by: Max Morin <maxmorin@chromium.org> Cr-Commit-Position: refs/heads/master@{#553260} [modify] https://crrev.com/11d68c0c0d7b63da029470bfa0fa223b4f418660/content/browser/browser_main_loop.cc [modify] https://crrev.com/11d68c0c0d7b63da029470bfa0fa223b4f418660/content/browser/service_manager/service_manager_context.cc [modify] https://crrev.com/11d68c0c0d7b63da029470bfa0fa223b4f418660/content/public/common/content_features.cc [modify] https://crrev.com/11d68c0c0d7b63da029470bfa0fa223b4f418660/content/public/common/content_features.h [modify] https://crrev.com/11d68c0c0d7b63da029470bfa0fa223b4f418660/content/utility/BUILD.gn [modify] https://crrev.com/11d68c0c0d7b63da029470bfa0fa223b4f418660/content/utility/DEPS [modify] https://crrev.com/11d68c0c0d7b63da029470bfa0fa223b4f418660/content/utility/utility_service_factory.cc [modify] https://crrev.com/11d68c0c0d7b63da029470bfa0fa223b4f418660/services/audio/public/cpp/audio_system_factory.cc [modify] https://crrev.com/11d68c0c0d7b63da029470bfa0fa223b4f418660/services/audio/service_factory.cc [modify] https://crrev.com/11d68c0c0d7b63da029470bfa0fa223b4f418660/services/audio/service_factory.h [modify] https://crrev.com/11d68c0c0d7b63da029470bfa0fa223b4f418660/services/audio/service_main.cc
,
Apr 25 2018
The following revision refers to this bug: https://chromium.googlesource.com/chromium/src.git/+/85caabcce4bf8019531c514aa29b5c8224aed266 commit 85caabcce4bf8019531c514aa29b5c8224aed266 Author: Jonas Olsson <jonasolsson@chromium.org> Date: Wed Apr 25 09:59:05 2018 Remove task_runner from audio_input_device, as the ipc object is threadsafe now Bug: chromium:672469 Cq-Include-Trybots: luci.chromium.try:android_optional_gpu_tests_rel;luci.chromium.try:linux_optional_gpu_tests_rel;luci.chromium.try:mac_optional_gpu_tests_rel;luci.chromium.try:win_optional_gpu_tests_rel Change-Id: I1e24e99df4a6d9dc0480aeb460115bafdceeafd5 Reviewed-on: https://chromium-review.googlesource.com/1018475 Commit-Queue: Jonas Olsson <jonasolsson@chromium.org> Reviewed-by: John Abd-El-Malek <jam@chromium.org> Reviewed-by: Max Morin <maxmorin@chromium.org> Reviewed-by: Olga Sharonova <olka@chromium.org> Cr-Commit-Position: refs/heads/master@{#553499} [modify] https://crrev.com/85caabcce4bf8019531c514aa29b5c8224aed266/base/threading/thread_restrictions.h [modify] https://crrev.com/85caabcce4bf8019531c514aa29b5c8224aed266/content/renderer/media/audio_device_factory.cc [modify] https://crrev.com/85caabcce4bf8019531c514aa29b5c8224aed266/media/audio/audio_input_device.cc [modify] https://crrev.com/85caabcce4bf8019531c514aa29b5c8224aed266/media/audio/audio_input_device.h [modify] https://crrev.com/85caabcce4bf8019531c514aa29b5c8224aed266/media/audio/audio_input_device_unittest.cc
,
May 8 2018
The following revision refers to this bug: https://chromium.googlesource.com/chromium/src.git/+/4cc719bfcc21809f9f8aa3ec6a2db907a2dd70e0 commit 4cc719bfcc21809f9f8aa3ec6a2db907a2dd70e0 Author: Marina Ciocea <marinaciocea@chromium.org> Date: Tue May 08 11:30:00 2018 Fix AudioInputDevice destructor crash. Remove audio thread reset before ScopedAllowBlocking. Bug: 672469 Cq-Include-Trybots: luci.chromium.try:android_optional_gpu_tests_rel;luci.chromium.try:linux_optional_gpu_tests_rel;luci.chromium.try:mac_optional_gpu_tests_rel;luci.chromium.try:win_optional_gpu_tests_rel Change-Id: I8e0ca007d87aa3dc1a7b520cdc8e6976e79e3448 Reviewed-on: https://chromium-review.googlesource.com/1049665 Reviewed-by: Olga Sharonova <olka@chromium.org> Commit-Queue: Olga Sharonova <olka@chromium.org> Cr-Commit-Position: refs/heads/master@{#556759} [modify] https://crrev.com/4cc719bfcc21809f9f8aa3ec6a2db907a2dd70e0/media/audio/audio_input_device.cc
,
May 17 2018
The following revision refers to this bug: https://chromium.googlesource.com/chromium/src.git/+/a3bd958dc2cf2a726126eaa5420bbdb3afd281aa commit a3bd958dc2cf2a726126eaa5420bbdb3afd281aa Author: Yuri Wiitala <miu@chromium.org> Date: Thu May 17 23:14:41 2018 Fix 'forced tab unmute' behavior when using OOP Audio Service The new Audio Service uses separate infrastructure for muting and tab capture. The legacy implementation, however, did not; and there was some logic in chrome/browser/ui/tab_utils.cc mitigating that. This change conditionally allows the mute state of a tab to be toggled/updated independently of tab capture. It also adds TODOs to mark the logic that should be deleted once the Audio Service launches. Bug: 843103 , 824019 ,672469 Change-Id: Ie21f4895717b5769808b87676f723a9ed5a30af4 Reviewed-on: https://chromium-review.googlesource.com/1065065 Reviewed-by: Xiangjun Zhang <xjz@chromium.org> Commit-Queue: Yuri Wiitala <miu@chromium.org> Cr-Commit-Position: refs/heads/master@{#559727} [modify] https://crrev.com/a3bd958dc2cf2a726126eaa5420bbdb3afd281aa/chrome/browser/extensions/api/tab_capture/tab_capture_apitest.cc [modify] https://crrev.com/a3bd958dc2cf2a726126eaa5420bbdb3afd281aa/chrome/browser/ui/tabs/tab_utils.cc [modify] https://crrev.com/a3bd958dc2cf2a726126eaa5420bbdb3afd281aa/chrome/test/data/extensions/api_test/tab_capture/api_tests.js
,
Sep 10
Just to update the latest behavior of this issue in the latest channels of the magic signature - [Shutdown hang] media::AudioManager::Shutdown, which is merged into this issue in the C#9. Still seeing 18 crashes from 18 clients so far on latest Beta - 69.0.3497.81 on Windows OS. This crash is ranked as #26 in 'Browser' beta crashes. 71.0.3547.0 0.01% 3 - Canary 70.0.3538.9 0.02% 13 - Dev 69.0.3497.81 0.60% 338 - Beta/ Stable Link to the list of builds: ------------------------- https://crash.corp.google.com/browse?q=product_name%3D%27Chrome%27+AND+expanded_custom_data.ChromeCrashProto.ptype%3D%27browser%27+AND+expanded_custom_data.ChromeCrashProto.magic_signature_1.name%3D%27%5BShutdown+hang%5D+media%3A%3AAudioManager%3A%3AShutdown%27#-productname:1000,productversion:100,-magicsignature:50,-magicsignature2:50,-stablesignature:50,-magicsignaturesorted:50 Thanks!
,
Nov 28
Just to update the latest behavior of this issue in the latest channels of the magic signature - [Shutdown hang] media::AudioManager::Shutdown, which is merged into this issue in the C#9. Still seeing 38 crashes from 34 clients so far on latest Beta - 71.0.3578.62 on Windows OS. This crash is ranked as #16 in 'Browser' beta crashes. 72.0.3610.2 0.05% 33- Dev 71.0.3578.62 0.06% 38 - Beta 70.0.3538.110 0.96% 647 - Stable 70.0.3538.102 10.01% 6739 70.0.3538.77 13.61% 9164 - Previous Stable Link to the list of builds: ------------------------- https://crash.corp.google.com/browse?q=product_name%3D%27Chrome%27+AND+expanded_custom_data.ChromeCrashProto.ptype%3D%27browser%27+AND+expanded_custom_data.ChromeCrashProto.magic_signature_1.name%3D%27%5BShutdown+hang%5D+media%3A%3AAudioManager%3A%3AShutdown%27#-productname:1000,productversion:100,-magicsignature:50,-magicsignature2:50,-stablesignature:50,-magicsignaturesorted:50 Thanks! |
|||||||||||||||||||||
►
Sign in to add a comment |
|||||||||||||||||||||
Comment 1 by olka@chromium.org
, Dec 12 2016