[chromium] Add additional memory management fields to WebGraphicsContext3D
Created attachment 169378 [details] Patch
Comment on attachment 169378 [details] Patch Add new fields to WebGraphicsMemoryAllocation to allow for specifying limits for when visible and not, and to allow for specifying priority cutoffs (e.g, to allow specifying that backgrounded tabs should retain only their visible textures). Add sendManagedMemoryStatsCHROMIUM to WebGraphicsContext3D, and add WebGraphicsManagedMemoryStats structure, to allow the GPU memory manager to make more informed choices.
Please wait for approval from abarth@webkit.org, dglazkov@chromium.org, fishd@chromium.org, jamesr@chromium.org or tkent@chromium.org before submitting, as this patch contains changes to the Chromium public API. See also https://trac.webkit.org/wiki/ChromiumWebKitAPI.
Some additional context: The old fields of the structure, gpuResourceSizeInBytes and suggestHaveBackbuffer are left in place so that this can roll in and not break anything. When I've changed the Chromium side, I'll delete these variables. I put a some extra things into these structures (in particular, the allocation counter and acks) in case they are helpful. If, when I have the whole thing wired up, they aren't helpful, I'll get rid of them (along with the deprecated fields). The strategy here is to avoid iterating in both WebKit and Chromium.
Created attachment 169383 [details] Patch
Ping.
Comment on attachment 169383 [details] Patch View in context: https://bugs.webkit.org/attachment.cgi?id=169383&action=review I really dislike adding things "just in case". Let's figure out what we actually need and do that. If we don't know whether we need something yet, we definitely do not. > Source/Platform/chromium/public/WebGraphicsMemoryAllocation.h:92 > +struct WebGraphicsManagedMemoryStats { WebKit API requires one header per type. see http://trac.webkit.org/wiki/ChromiumWebKitAPI
Created attachment 170204 [details] Patch
I've put the structures in separate files. I've removed the counter/ack from the patch. I think it's fairly likely that these will be used in testing (if not in actual policy), but we can burn that bridge when we get there. All other fields have concrete plans to be used.
Ping. I'd like to get this in before M24 branches.
Comment on attachment 170204 [details] Patch R=me
Comment on attachment 170204 [details] Patch Clearing flags on attachment: 170204 Committed r132686: <http://trac.webkit.org/changeset/132686>
All reviewed patches have been landed. Closing bug.