WebKit Bugzilla
Attachment 368372 Details for
Bug 197335
: Reduce the number of copies made during SourceBufferPrivateAVFObjC::append() using SharedBuffer
Home
|
New
|
Browse
|
Search
|
[?]
|
Reports
|
Requests
|
Help
|
New Account
|
Log In
Remember
[x]
|
Forgot Password
Login:
[x]
[patch]
Patch
bug-197335-20190426180204.patch (text/plain), 2.56 KB, created by
Jer Noble
on 2019-04-26 18:02:11 PDT
(
hide
)
Description:
Patch
Filename:
MIME Type:
Creator:
Jer Noble
Created:
2019-04-26 18:02:11 PDT
Size:
2.56 KB
patch
obsolete
>Subversion Revision: 244418 >diff --git a/Source/WebCore/ChangeLog b/Source/WebCore/ChangeLog >index 01eb24f69749c14d45b1fc1c74a55c788cb86f24..0e453f5fbce197d1b2a24a0238b501a1f42ff54d 100644 >--- a/Source/WebCore/ChangeLog >+++ b/Source/WebCore/ChangeLog >@@ -1,3 +1,14 @@ >+2019-04-26 Jer Noble <jer.noble@apple.com> >+ >+ Reduce the number of copies made during SourceBufferPrivateAVFObjC::append() using SharedBuffer >+ https://bugs.webkit.org/show_bug.cgi?id=197335 >+ <rdar://problem/49175604> >+ >+ Rubber-stamped by Alex Christensen. >+ >+ * platform/graphics/avfoundation/objc/SourceBufferPrivateAVFObjC.mm: >+ (WebCore::SourceBufferPrivateAVFObjC::append): >+ > 2019-04-19 Jer Noble <jer.noble@apple.com> > > REGRESSION(r243958): Unnecessary deactivation of AudioSession (PLT Regression) >diff --git a/Source/WebCore/platform/graphics/avfoundation/objc/SourceBufferPrivateAVFObjC.mm b/Source/WebCore/platform/graphics/avfoundation/objc/SourceBufferPrivateAVFObjC.mm >index cb94d66592f5757d803d107d00a21801431858d7..43f0457ddc731c9b2a1aba00683e138d8d3e846f 100644 >--- a/Source/WebCore/platform/graphics/avfoundation/objc/SourceBufferPrivateAVFObjC.mm >+++ b/Source/WebCore/platform/graphics/avfoundation/objc/SourceBufferPrivateAVFObjC.mm >@@ -728,16 +728,12 @@ void SourceBufferPrivateAVFObjC::append(Vector<unsigned char>&& data) > { > DEBUG_LOG(LOGIDENTIFIER, "data length = ", data.size()); > >- // FIXME: Avoid the data copy by wrapping around the Vector<> object. >- RetainPtr<NSData> nsData = adoptNS([[NSData alloc] initWithBytes:data.data() length:data.size()]); >- WeakPtr<SourceBufferPrivateAVFObjC> weakThis = m_appendWeakFactory.createWeakPtr(*this); >- RetainPtr<AVStreamDataParser> parser = m_parser; >- RetainPtr<WebAVStreamDataParserListener> delegate = m_delegate; >- > m_parsingSucceeded = true; > dispatch_group_enter(m_isAppendingGroup.get()); > >- dispatch_async(globalDataParserQueue(), [nsData, weakThis, parser, delegate, isAppendingGroup = m_isAppendingGroup, parserStateWasReset = m_parserStateWasReset] { >+ dispatch_async(globalDataParserQueue(), [data = WTFMove(data), weakThis = m_appendWeakFactory.createWeakPtr(*this), parser = m_parser, delegate = m_delegate, isAppendingGroup = m_isAppendingGroup, parserStateWasReset = m_parserStateWasReset] () mutable { >+ auto sharedData = SharedBuffer::create(WTFMove(data)); >+ auto nsData = sharedData->createNSData(); > if (parserStateWasReset) > [parser appendStreamData:nsData.get() withFlags:AVStreamDataParserStreamDataDiscontinuity]; > else
You cannot view the attachment while viewing its details because your browser does not support IFRAMEs.
View the attachment on a separate page
.
View Attachment As Diff
View Attachment As Raw
Actions:
View
|
Formatted Diff
|
Diff
Attachments on
bug 197335
: 368372