Uploaded image for project: 'Qt'
  1. Qt
  2. QTBUG-121420

intensive playing sounds with QSound leads to Crash on ios

    XMLWordPrintable

Details

    • iOS/tvOS/watchOS

    Description

      Application crashing when audio is used, It doesn't matter if QSound or QSoundEffect is used it always crashing for ios. Same works for android.  It's crashing mainly when we use more intensive playing sounds (very short sound).

      Attached simple example where playing many sounds in short time and after short time (often less than 1 minute) code crashing. Always in the same place CoreAudioOutput::audioDeviceIdle() AURemoteIO::IOThread EXC_BREAKPOINT

      Run this code on iphone or ipad  and keep it running for few minutes to observe the crash with following stack:

      Crashed: AURemoteIO::IOThread
      0 caulk 0x1c6c caulk::thread::join() + 100
      1 libEmbeddedSystemAUs.dylib 0xd538 std::__1::__shared_ptr_emplace<AURemoteIO::IOThread, std::__1::allocator<AURemoteIO::IOThread> >::__on_zero_shared()
      2 libEmbeddedSystemAUs.dylib 0x9ba00 std::__1::shared_ptr<AURemoteIO::IOThread>::operator=[abi:v15006](std::__1::shared_ptr<AURemoteIO::IOThread>&&)
      3 libEmbeddedSystemAUs.dylib 0x16b88 AURemoteIO::Stop()
      4 libEmbeddedSystemAUs.dylib 0xbf94 ausdk::AUMethodStop(void*)
      5 PokerOmaha 0x4e7050 CoreAudioOutput::audioDeviceIdle() + 4342673488
      6 PokerOmaha 0x4e6fc0 CoreAudioOutput::renderCallback(void*, unsigned int*, AudioTimeStamp const*, unsigned int, unsigned int, AudioBufferList*) + 4342673344
      7 libEmbeddedSystemAUs.dylib 0x21198 ausdk::AUInputElement::PullInput(unsigned int&, AudioTimeStamp const&, unsigned int, unsigned int)
      8 libEmbeddedSystemAUs.dylib 0xae84 AUInputFormatConverter2::InputProc(OpaqueAudioConverter*, unsigned int*, AudioBufferList*, AudioStreamPacketDescription**, void*)
      9 AudioToolboxCore 0xe9534 caulk::expected<unsigned int, int> caulk::function_ref<caulk::expected<unsigned int, int> (ACAudioSpan&)>::functor_invoker<acv2::_AudioConverterFillComplexBuffer(OpaqueAudioConverter*, int (*)(OpaqueAudioConverter*, unsigned int*, AudioBufferList*, AudioStreamPacketDescription**, void*), void*, unsigned int*, AudioBufferList*, AudioStreamPacketDescription*, AudioStreamPacketDependencyInfo*)::$_1>(caulk::details::erased_callable<caulk::expected<unsigned int, int> (ACAudioSpan&)> const&, ACAudioSpan&) + 180
      10 AudioToolboxCore 0x6ef74 acv2::AudioConverterChain::ObtainInput(acv2::AudioConverterBase&, unsigned int) + 832
      11 AudioToolboxCore 0x1d2680 acv2::CBRConverter::ProduceOutput(ACAudioSpan&) + 48
      12 AudioToolboxCore 0x6ef00 acv2::AudioConverterChain::ObtainInput(acv2::AudioConverterBase&, unsigned int) + 716
      13 AudioToolboxCore 0x1850d0 acv2::Resampler2Wrapper::ProduceOutput(ACAudioSpan&) + 200
      14 AudioToolboxCore 0x6ef00 acv2::AudioConverterChain::ObtainInput(acv2::AudioConverterBase&, unsigned int) + 716
      15 AudioToolboxCore 0x1d2680 acv2::CBRConverter::ProduceOutput(ACAudioSpan&) + 48
      16 AudioToolboxCore 0x6e7ac acv2::AudioConverterChain::ProduceOutput(caulk::function_ref<caulk::expected<unsigned int, int> (ACAudioSpan&)>, ACBaseAudioSpan&) + 148
      17 AudioToolboxCore 0xe90c0 acv2::_AudioConverterFillComplexBuffer(OpaqueAudioConverter*, int (*)(OpaqueAudioConverter*, unsigned int*, AudioBufferList*, AudioStreamPacketDescription**, void*), void*, unsigned int*, AudioBufferList*, AudioStreamPacketDescription*, AudioStreamPacketDependencyInfo*) + 436
      18 libEmbeddedSystemAUs.dylib 0x15a00 AUConverterBase::RenderBus(unsigned int&, AudioTimeStamp const&, unsigned int, unsigned int)
      19 libEmbeddedSystemAUs.dylib 0x10034 AURemoteIO::RenderBus(unsigned int&, AudioTimeStamp const&, unsigned int, unsigned int)
      20 libEmbeddedSystemAUs.dylib 0x172c ausdk::AUBase::DoRender(unsigned int&, AudioTimeStamp const&, unsigned int, unsigned int, AudioBufferList&)
      21 libEmbeddedSystemAUs.dylib 0x2148 AURemoteIO::PerformIO(unsigned int, unsigned int, unsigned int, AudioTimeStamp const&, AudioTimeStamp const&, AudioBufferList const*, AudioBufferList*, int&)
      22 libEmbeddedSystemAUs.dylib 0xa388 _XPerformIO
      23 libAudioToolboxUtility.dylib 0x1fd8 mshMIGPerform + 260
      24 libAudioToolboxUtility.dylib 0x1730 MSHMIGDispatchMessage + 36
      25 libEmbeddedSystemAUs.dylib 0x9c43c void* caulk::thread_proxy<std::__1::tuple<caulk::thread::attributes, AURemoteIO::IOThread::IOThread(AURemoteIO&, caulk::thread::attributes const&, caulk::mach::os_workgroup_managed const&)::'lambda'(), std::__1::tuple<> > >(void*)
      26 libsystem_pthread.dylib 0x30ec _pthread_start + 116
      27 libsystem_pthread.dylib 0x172c thread_start + 8 

      Attachments

        No reviews matched the request. Check your Options in the drop-down menu of this sections header.

        Activity

          People

            tpochep Timur Pocheptsov
            irfan.omair@digia.com Irfan Omair
            Votes:
            1 Vote for this issue
            Watchers:
            4 Start watching this issue

            Dates

              Created:
              Updated:

              Gerrit Reviews

                There are no open Gerrit changes