Subpixel rendering: Simple compositing container layer (isSimpleContainerCompositingLayer) paints to wrong position.
https://bugs.webkit.org/show_bug.cgi?id=129861

Reviewed by Simon Fraser.

This patch ensures that both the simple and non-simple cases paint to the same position.
Simple compositing container layer codepath needs to take the fractional device pixel offset
into account when painting. Without the fractional value, the final paint rounding could push the
paint offset to a different position.
retina example:
compositing top-left: 0px 0px.
fractional offset: 0.3px 0.3px
painting coords without offseting: 0px 0px
                   with offseting: 0.5px 0.5px

Source/WebCore:

Tests: compositing/hidpi-simple-container-layer-on-device-pixel.html

* WebCore.exp.in:
* platform/graphics/GraphicsLayer.h:
(WebCore::GraphicsLayer::contentsRect):
(WebCore::GraphicsLayer::setContentsRect):
(WebCore::GraphicsLayer::contentsClippingRect):
(WebCore::GraphicsLayer::setContentsClippingRect):
* platform/graphics/ca/GraphicsLayerCA.cpp:
(WebCore::GraphicsLayerCA::setContentsRect):
(WebCore::GraphicsLayerCA::setContentsClippingRect):
(WebCore::GraphicsLayerCA::updateContentsRects):
* platform/graphics/ca/GraphicsLayerCA.h:
* rendering/RenderLayerBacking.cpp:
(WebCore::RenderLayerBacking::updateGraphicsLayerGeometry):
(WebCore::RenderLayerBacking::updateDirectlyCompositedBackgroundColor):
(WebCore::RenderLayerBacking::updateDirectlyCompositedBackgroundImage):
(WebCore::RenderLayerBacking::contentOffsetInCompostingLayer):
(WebCore::RenderLayerBacking::backgroundBoxForPainting):
* rendering/RenderLayerBacking.h:

LayoutTests:

* compositing/hidpi-simple-container-layer-on-device-pixel-expected.html: Added.
* compositing/hidpi-simple-container-layer-on-device-pixel.html: Added.


git-svn-id: http://svn.webkit.org/repository/webkit/trunk@165341 268f45cc-cd09-0410-ab3c-d52691b4dbfc
[WK2] Improve the network process low memory handler.
<https://webkit.org/b/129977>

Split the network process low memory handler into platform-specific
and shared parts. The shared part tells FastMalloc to release freed
pages back to the OS.

For Mac, added a call to purge the in-memory part of CFURLCache.
Remove the malloc_zone_pressure_relief() since that is now taken care
of by the shared MemoryPressureHandler code.

Reviewed by Darin Adler.

* NetworkProcess/NetworkProcess.cpp:
(WebKit::NetworkProcess::initializeNetworkProcess):
(WebKit::NetworkProcess::lowMemoryHandler):
(WebKit::NetworkProcess::platformLowMemoryHandler):
* NetworkProcess/NetworkProcess.h:
* NetworkProcess/mac/NetworkProcessMac.mm:
(WebKit::NetworkProcess::platformLowMemoryHandler):
(WebKit::NetworkProcess::platformInitializeNetworkProcess):

git-svn-id: http://svn.webkit.org/repository/webkit/trunk@165342 268f45cc-cd09-0410-ab3c-d52691b4dbfc
Clean up PlatformLayer.h
https://bugs.webkit.org/show_bug.cgi?id=129967

Reviewed by Martin Robinson.

* platform/graphics/PlatformLayer.h:
Remove duplicated declaration of PlatformLayer when using TextureMapper.


git-svn-id: http://svn.webkit.org/repository/webkit/trunk@165343 268f45cc-cd09-0410-ab3c-d52691b4dbfc