Comment 1 for bug 1648280

Revision history for this message
RJ Skerry-Ryan (rryan) wrote :

gettimeofday appears to take about 8 microseconds on average. The "ts" here is a walltime nanosecond counter (though I think the precision is microseconds, not nanos since the last 3 numbers are always zero).

Notably, I'm not broadcasting at all and EngineNetworkStream is still doing this work.

  0 383 gettimeofday:return (tid 1488971) ts:1481161656405619000 gettimeofday
              libsystem_kernel.dylib`__gettimeofday+0xa
              mixxx`EngineNetworkStream::getWriteExpected()+0x17
              mixxx`SoundDeviceNetwork::writeProcess()+0xd4
              mixxx`SoundManager::writeProcess()+0xb9
              mixxx`SoundDevicePortAudio::callbackProcessClkRef(unsigned int, float*, float const*, PaStreamCallbackTimeInfo const*, unsigned long)+0x751
              mixxx`(anonymous namespace)::paV19CallbackClkRef(void const*, void*, unsigned long, PaStreamCallbackTimeInfo const*, unsigned long, void*)+0x23
              libportaudio.2.dylib`AdaptingOutputOnlyProcess+0xe7
              libportaudio.2.dylib`PaUtil_EndBufferProcessing+0x1c4
              libportaudio.2.dylib`AudioIOProc+0x392
              CoreAudio`AUConverterBase::RenderBus(unsigned int&, AudioTimeStamp const&, unsigned int, unsigned int)+0x2c5
              CoreAudio`AUBase::DoRenderBus(unsigned int&, AudioTimeStamp const&, unsigned int, AUOutputElement*, unsigned int, AudioBufferList&)+0x9a
              CoreAudio`AUBase::DoRender(unsigned int&, AudioTimeStamp const&, unsigned int, unsigned int, AudioBufferList&)+0x1f8
              CoreAudio`AUHAL::AUIOProc(unsigned int, AudioTimeStamp const*, AudioBufferList const*, AudioTimeStamp const*, AudioBufferList*, AudioTimeStamp const*, void*)+0x6f2
              CoreAudio`HALC_ProxyIOContext::IOWorkLoop()+0x9e7
              CoreAudio`HALC_ProxyIOContext::IOThreadEntry(void*)+0x58
              CoreAudio`HALB_IOThread::Entry(void*)+0x4b
              libsystem_pthread.dylib`_pthread_body+0x83
              libsystem_pthread.dylib`_pthread_body
              libsystem_pthread.dylib`thread_start+0xd

  0 382 gettimeofday:entry (tid 1488971) ts:1481161656407042000 gettimeofday
              libsystem_kernel.dylib`__gettimeofday+0xa
              mixxx`EngineNetworkStream::getWriteExpected()+0x17
              mixxx`SoundDeviceNetwork::writeProcess()+0xd4
              mixxx`SoundManager::writeProcess()+0xb9
              mixxx`SoundDevicePortAudio::callbackProcessClkRef(unsigned int, float*, float const*, PaStreamCallbackTimeInfo const*, unsigned long)+0x751
              mixxx`(anonymous namespace)::paV19CallbackClkRef(void const*, void*, unsigned long, PaStreamCallbackTimeInfo const*, unsigned long, void*)+0x23
              libportaudio.2.dylib`AdaptingOutputOnlyProcess+0xe7
              libportaudio.2.dylib`PaUtil_EndBufferProcessing+0x1c4
              libportaudio.2.dylib`AudioIOProc+0x392
              CoreAudio`AUConverterBase::RenderBus(unsigned int&, AudioTimeStamp const&, unsigned int, unsigned int)+0x2c5
              CoreAudio`AUBase::DoRenderBus(unsigned int&, AudioTimeStamp const&, unsigned int, AUOutputElement*, unsigned int, AudioBufferList&)+0x9a
              CoreAudio`AUBase::DoRender(unsigned int&, AudioTimeStamp const&, unsigned int, unsigned int, AudioBufferList&)+0x1f8
              CoreAudio`AUHAL::AUIOProc(unsigned int, AudioTimeStamp const*, AudioBufferList const*, AudioTimeStamp const*, AudioBufferList*, AudioTimeStamp const*, void*)+0x6f2
              CoreAudio`HALC_ProxyIOContext::IOWorkLoop()+0x9e7
              CoreAudio`HALC_ProxyIOContext::IOThreadEntry(void*)+0x58
              CoreAudio`HALB_IOThread::Entry(void*)+0x4b
              libsystem_pthread.dylib`_pthread_body+0x83
              libsystem_pthread.dylib`_pthread_body
              libsystem_pthread.dylib`thread_start+0xd