summaryrefslogtreecommitdiffstats
path: root/extensions/DEPS
diff options
context:
space:
mode:
authorananta <ananta@chromium.org>2015-04-30 14:58:42 -0700
committerCommit bot <commit-bot@chromium.org>2015-04-30 22:00:24 +0000
commitbbca53aa082320e13909d995a9af66bed7de69a8 (patch)
tree6c34908ef45851931653e963ba5bd805a37590e3 /extensions/DEPS
parent74f38717c9c07028dd5661b5ea5588daa04b57d9 (diff)
downloadchromium_src-bbca53aa082320e13909d995a9af66bed7de69a8.zip
chromium_src-bbca53aa082320e13909d995a9af66bed7de69a8.tar.gz
chromium_src-bbca53aa082320e13909d995a9af66bed7de69a8.tar.bz2
Ensure that the DirectWrite font cache works in Chrome canary on Windows 8+ with AppContainer protection.
The DirectWrite font cache is mapped as a shared section by the renderer processes. The browser creates the section. On Windows 8+ with AppContainer protection the renderers are unable to open this shared section as the BaseNamedObjects object directory is virtualized to \Sessions\SessionId\AppContainerNamedObjects. This effectively means that the renderers now fallback to the old method of enumerating all fonts while DirectWrite builds up its font cache. This hurts performance. Proposed fix is as below :- 1. When the renderer process is launched we get notified in the RenderProcessHost::OnProcessLaunched method. We send a control IPC message here ViewMsg_FontCacheSectionHandle which contains the duplicated font cache section handle. 2. The ViewMsg_FontCacheSectionHandle message is handled by RenderThreadImpl. It ensures that the shared handle is set by calling a helper function SetFontCacheSectionHandle. This function then triggers the setting of the DirectWrite font factory in skia. 3. Some of the code in the WarmupDirectWrite function is no longer needed like the code to create the font factory and create some fonts to warm up DirectWrite. This is because DirectWrite in the renderer now uses the custom font collection which means that most of the code now can run in the sandbox. The only parts which need to run outside the sandbox are the loading of the dwrite.dll and the code in the FontCollectionLoader which reads fonts from the registry. 4. The GetPreSandboxWarmupFontMgr helper function has been renamed to GetDirectWriteFontManager. The UMA metric DirectWrite.Fonts.LoadTime.Cached should be available if the font cache is loaded in the renderer. BUG=481285 R=cpu Review URL: https://codereview.chromium.org/1105763004 Cr-Commit-Position: refs/heads/master@{#327804}
Diffstat (limited to 'extensions/DEPS')
-rw-r--r--extensions/DEPS2
1 files changed, 2 insertions, 0 deletions
diff --git a/extensions/DEPS b/extensions/DEPS
index 285b7d3..61251ff 100644
--- a/extensions/DEPS
+++ b/extensions/DEPS
@@ -13,6 +13,8 @@ include_rules = [
"+grit/extensions_renderer_resources.h",
"+grit/extensions_resources.h",
"+testing",
+ "+sandbox/win/src/sandbox.h",
+ "+sandbox/win/src/sandbox_policy.h",
"+third_party/mojo/src/mojo/public",
"+third_party/skia/include",