[Mac] Audio and Video element creation up to 300x slower than other browsers
<rdar://problem/62451019>
Created attachment 412353 [details] Patch
Comment on attachment 412353 [details] Patch View in context: https://bugs.webkit.org/attachment.cgi?id=412353&action=review > Source/WebCore/platform/audio/mac/AudioSessionMac.mm:104 > + bool hasSampleRateObserver { false }; > + Optional<double> sampleRate; > + bool hasBufferSizeObserver { false }; > + Optional<size_t> bufferSize; Nit: the object would be slightly smaller if the `Optional<size_t>` were declared above the bools
Comment on attachment 412353 [details] Patch View in context: https://bugs.webkit.org/attachment.cgi?id=412353&action=review > Source/WebCore/platform/audio/mac/AudioSessionMac.mm:128 > + if (result) Nit. Probably "if (result != noErr)" is better? > Source/WebCore/platform/audio/mac/AudioSessionMac.mm:409 > + if (!result) Nit. Probably "if (result == noErr)" is better?
Created attachment 412437 [details] Patch for landing
Committed r269077: <https://trac.webkit.org/changeset/269077> All reviewed patches have been landed. Closing bug and clearing flags on attachment 412437 [details].