Bug 85848

Summary: [Chromium] Use ThrottledTextureUploader with threaded compositing.
Product: WebKit Reporter: David Reveman <reveman>
Component: WebKit Misc.Assignee: David Reveman <reveman>
Status: RESOLVED FIXED    
Severity: Normal CC: cc-bugs, enne, jamesr, nduca, webkit.review.bot
Priority: P2    
Version: 528+ (Nightly build)   
Hardware: Unspecified   
OS: Unspecified   
Bug Depends on:    
Bug Blocks: 85893    
Attachments:
Description Flags
Patch
none
Patch
none
Patch none

Description David Reveman 2012-05-07 17:36:42 PDT
Can land as soon as http://code.google.com/p/chromium/issues/detail?id=123414 is fixed.
Comment 1 David Reveman 2012-05-07 17:43:27 PDT
Created attachment 140638 [details]
Patch
Comment 2 James Robinson 2012-05-07 18:00:30 PDT
Comment on attachment 140638 [details]
Patch

View in context: https://bugs.webkit.org/attachment.cgi?id=140638&action=review

> Source/WebCore/platform/graphics/chromium/cc/CCThreadProxy.cpp:808
> +    OwnPtr<TextureUploader> uploader = ThrottledTextureUploader::create(m_contextBeforeInitializationOnImplThread.get());

seems odd to create this uploader before we check if initialization is going to succeed or not. Is this ordering intentional - i.e. do we need an uploader to make it through initialization?
Comment 3 David Reveman 2012-05-08 10:17:01 PDT
(In reply to comment #2)
> (From update of attachment 140638 [details])
> View in context: https://bugs.webkit.org/attachment.cgi?id=140638&action=review
> 
> > Source/WebCore/platform/graphics/chromium/cc/CCThreadProxy.cpp:808
> > +    OwnPtr<TextureUploader> uploader = ThrottledTextureUploader::create(m_contextBeforeInitializationOnImplThread.get());
> 
> seems odd to create this uploader before we check if initialization is going to succeed or not. Is this ordering intentional - i.e. do we need an uploader to make it through initialization?

Good point. This is odd and need to be fixed. We don't need the uploader to make it through initialization but I also find it a bit odd to give the LRC an uploader instance post initialization that has certain requirements for when to be destroyed.

I think the best solution is to do land this change: https://bugs.webkit.org/show_bug.cgi?id=85893 which makes the change required to enable the throttled uploader:
s/layerRenderer()->unthrottledTextureUploader()/layerRenderer()->throttledTextureUploader()/ in CCThreadProxy::scheduledActionUpdateMoreResources().
Comment 4 David Reveman 2012-05-08 10:23:56 PDT
Created attachment 140737 [details]
Patch
Comment 5 David Reveman 2012-05-11 12:45:45 PDT
Created attachment 141478 [details]
Patch

Rebase
Comment 6 Adrienne Walker 2012-05-11 17:07:55 PDT
Comment on attachment 141478 [details]
Patch

R=me, since the Chromium side fix is in now and the unit tests all passed.
Comment 7 David Reveman 2012-05-15 19:39:20 PDT
Comment on attachment 141478 [details]
Patch

Finished the testing I wanted to do. I think this is ready to land.
Comment 8 WebKit Review Bot 2012-05-16 11:31:13 PDT
Comment on attachment 141478 [details]
Patch

Clearing flags on attachment: 141478

Committed r117312: <http://trac.webkit.org/changeset/117312>
Comment 9 WebKit Review Bot 2012-05-16 11:31:18 PDT
All reviewed patches have been landed.  Closing bug.