diff --git a/DEPS b/DEPS
index 4467768..f9e3459 100644
--- a/DEPS
+++ b/DEPS
@@ -40,11 +40,11 @@
   # Three lines of non-changing comments so that
   # the commit queue can handle CLs rolling Skia
   # and whatever else without interference from each other.
-  'skia_revision': '8b1360dcfab9ae748361268284068049cd3796a7',
+  'skia_revision': '9194706e8cf1ed72f07b2ed9207d81120f2135ad',
   # Three lines of non-changing comments so that
   # the commit queue can handle CLs rolling V8
   # and whatever else without interference from each other.
-  'v8_revision': '93cfbf404f5d217520b3b7bb2e28400830ceaf70',
+  'v8_revision': 'a60594edb85c34ee346f1159243cfefcddc99673',
   # Three lines of non-changing comments so that
   # the commit queue can handle CLs rolling swarming_client
   # and whatever else without interference from each other.
@@ -64,7 +64,7 @@
   # Three lines of non-changing comments so that
   # the commit queue can handle CLs rolling PDFium
   # and whatever else without interference from each other.
-  'pdfium_revision': '131c0eb2e34ece6ede6288842cb3004ec3c600d4',
+  'pdfium_revision': '56ec0818c3ed195c8de2daba951ddbcb4dc7d7bc',
   # Three lines of non-changing comments so that
   # the commit queue can handle CLs rolling openmax_dl
   # and whatever else without interference from each other.
@@ -92,11 +92,11 @@
   # Three lines of non-changing comments so that
   # the commit queue can handle CLs rolling freetype
   # and whatever else without interference from each other.
-  'freetype_revision': '7e50824288fac5a36c2938fdb3e1c949ea53f982',
+  'freetype_revision': 'f2e121ab11d1c9deb460d844d94f1d9fe6074f35',
   # Three lines of non-changing comments so that
   # the commit queue can handle CLs rolling catapult
   # and whatever else without interference from each other.
-  'catapult_revision': 'f465506fe2a7da345365007b37c388052fb14a16',
+  'catapult_revision': '99ec8187805e3ab807dac86c1ef0a1b07be9d1a6',
   # Three lines of non-changing comments so that
   # the commit queue can handle CLs rolling libFuzzer
   # and whatever else without interference from each other.
@@ -211,7 +211,7 @@
     Var('chromium_git') + '/external/selenium/py.git' + '@' + '5fd78261a75fe08d27ca4835fb6c5ce4b42275bd',
 
   'src/third_party/libvpx/source/libvpx':
-    Var('chromium_git') + '/webm/libvpx.git' + '@' +  '30c261b1ebe8f06d687cac5b3b442d51a7839d00',
+    Var('chromium_git') + '/webm/libvpx.git' + '@' +  '9a2dd7e67ed20a7389db618f1a8a25d5b3a3c89c',
 
   'src/third_party/ffmpeg':
     Var('chromium_git') + '/chromium/third_party/ffmpeg.git' + '@' + '1e201feaa3260336aa63545c9471b76e5aef2e0a',
diff --git a/android_webview/glue/java/src/com/android/webview/chromium/ContentSettingsAdapter.java b/android_webview/glue/java/src/com/android/webview/chromium/ContentSettingsAdapter.java
index c209e28..de025d6 100644
--- a/android_webview/glue/java/src/com/android/webview/chromium/ContentSettingsAdapter.java
+++ b/android_webview/glue/java/src/com/android/webview/chromium/ContentSettingsAdapter.java
@@ -182,12 +182,13 @@
 
     @Override
     public void setDefaultZoom(ZoomDensity zoom) {
-        mAwSettings.setDefaultZoom(zoom);
+        // Intentional no-op
     }
 
     @Override
     public ZoomDensity getDefaultZoom() {
-        return mAwSettings.getDefaultZoom();
+        // Intentional no-op
+        return ZoomDensity.MEDIUM;
     }
 
     @Override
diff --git a/android_webview/java/src/org/chromium/android_webview/AwSettings.java b/android_webview/java/src/org/chromium/android_webview/AwSettings.java
index 8d595a7..23752a1 100644
--- a/android_webview/java/src/org/chromium/android_webview/AwSettings.java
+++ b/android_webview/java/src/org/chromium/android_webview/AwSettings.java
@@ -15,7 +15,6 @@
 import android.webkit.WebSettings;
 import android.webkit.WebSettings.LayoutAlgorithm;
 import android.webkit.WebSettings.PluginState;
-import android.webkit.WebSettings.ZoomDensity;
 
 import org.chromium.base.BuildInfo;
 import org.chromium.base.ThreadUtils;
@@ -671,17 +670,6 @@
         }
     }
 
-    public void setDefaultZoom(ZoomDensity zoom) {
-        if (zoom != ZoomDensity.MEDIUM) {
-            Log.w(LOGTAG, "setDefaultZoom not supported, zoom=" + zoom);
-        }
-    }
-
-    public ZoomDensity getDefaultZoom() {
-        // Intentional no-op.
-        return ZoomDensity.MEDIUM;
-    }
-
     @CalledByNative
     private int getTextSizePercentLocked() {
         assert Thread.holdsLock(mAwSettingsLock);
diff --git a/base/files/file_path_watcher_linux.cc b/base/files/file_path_watcher_linux.cc
index 9686624b..1c1bb3eb3 100644
--- a/base/files/file_path_watcher_linux.cc
+++ b/base/files/file_path_watcher_linux.cc
@@ -187,6 +187,12 @@
   std::unordered_map<InotifyReader::Watch, FilePath> recursive_paths_by_watch_;
   std::map<FilePath, InotifyReader::Watch> recursive_watches_by_path_;
 
+  // Read only while INotifyReader::lock_ is held, and used to post asynchronous
+  // notifications to the Watcher on its home task_runner(). Ideally this should
+  // be const, but since it is initialized from |weak_factory_|, which must
+  // appear after it, that is not possible.
+  WeakPtr<FilePathWatcherImpl> weak_ptr_;
+
   WeakPtrFactory<FilePathWatcherImpl> weak_factory_;
 
   DISALLOW_COPY_AND_ASSIGN(FilePathWatcherImpl);
@@ -313,7 +319,9 @@
 }
 
 FilePathWatcherImpl::FilePathWatcherImpl()
-    : recursive_(false), weak_factory_(this) {}
+    : recursive_(false), weak_factory_(this) {
+  weak_ptr_ = weak_factory_.GetWeakPtr();
+}
 
 FilePathWatcherImpl::~FilePathWatcherImpl() {
   DCHECK(!task_runner() || task_runner()->RunsTasksInCurrentSequence());
@@ -332,8 +340,7 @@
   task_runner()->PostTask(
       FROM_HERE,
       BindOnce(&FilePathWatcherImpl::OnFilePathChangedOnOriginSequence,
-               weak_factory_.GetWeakPtr(), fired_watch, child, created, deleted,
-               is_dir));
+               weak_ptr_, fired_watch, child, created, deleted, is_dir));
 }
 
 void FilePathWatcherImpl::OnFilePathChangedOnOriginSequence(
diff --git a/base/process/process_metrics.cc b/base/process/process_metrics.cc
index f24901c..a0c4174 100644
--- a/base/process/process_metrics.cc
+++ b/base/process/process_metrics.cc
@@ -59,14 +59,6 @@
 #endif  // !defined(OS_MACOSX) || defined(OS_IOS)
 }
 
-double ProcessMetrics::GetPlatformIndependentCPUUsage() {
-#if defined(OS_WIN)
-  return GetCPUUsage() * processor_count_;
-#else
-  return GetCPUUsage();
-#endif
-}
-
 #if defined(OS_MACOSX) || defined(OS_LINUX) || defined(OS_AIX)
 int ProcessMetrics::CalculateIdleWakeupsPerSecond(
     uint64_t absolute_idle_wakeups) {
diff --git a/base/process/process_metrics.h b/base/process/process_metrics.h
index 644b4632..ca550e9 100644
--- a/base/process/process_metrics.h
+++ b/base/process/process_metrics.h
@@ -203,23 +203,24 @@
                       size_t* locked_bytes) const;
 #endif
 
-  // Returns the CPU usage in percent since the last time this method or
-  // GetPlatformIndependentCPUUsage() was called. The first time this method
-  // is called it returns 0 and will return the actual CPU info on subsequent
-  // calls. On Windows, the CPU usage value is for all CPUs. So if you have
-  // 2 CPUs and your process is using all the cycles of 1 CPU and not the other
-  // CPU, this method returns 50.
-  double GetCPUUsage();
+  // Returns the percentage of time spent executing, across all threads of the
+  // process, in the interval since the last time the method was called. Since
+  // this considers the total execution time across all threads in a process,
+  // the result can easily exceed 100% in multi-thread processes running on
+  // multi-core systems. In general the result is therefore a value in the
+  // range 0% to SysInfo::NumberOfProcessors() * 100%.
+  //
+  // To obtain the percentage of total available CPU resources consumed by this
+  // process over the interval, the caller must divide by NumberOfProcessors().
+  //
+  // Since this API measures usage over an interval, it will return zero on the
+  // first call, and an actual value only on the second and subsequent calls.
+  double GetPlatformIndependentCPUUsage();
 
   // Returns the number of average idle cpu wakeups per second since the last
   // call.
   int GetIdleWakeupsPerSecond();
 
-  // Same as GetCPUUsage(), but will return consistent values on all platforms
-  // (cancelling the Windows exception mentioned above) by returning a value in
-  // the range of 0 to (100 * numCPUCores) everywhere.
-  double GetPlatformIndependentCPUUsage();
-
   // Retrieves accounting information for all I/O operations performed by the
   // process.
   // If IO information is retrieved successfully, the function returns true
@@ -274,8 +275,6 @@
   ProcessHandle process_;
 #endif
 
-  int processor_count_;
-
   // Used to store the previous times and CPU usage counts so we can
   // compute the CPU usage between calls.
   TimeTicks last_cpu_time_;
diff --git a/base/process/process_metrics_freebsd.cc b/base/process/process_metrics_freebsd.cc
index 4f5adf7..10d0868 100644
--- a/base/process/process_metrics_freebsd.cc
+++ b/base/process/process_metrics_freebsd.cc
@@ -11,13 +11,11 @@
 
 #include "base/macros.h"
 #include "base/memory/ptr_util.h"
-#include "base/sys_info.h"
 
 namespace base {
 
 ProcessMetrics::ProcessMetrics(ProcessHandle process)
     : process_(process),
-      processor_count_(SysInfo::NumberOfProcessors()),
       last_system_time_(0),
       last_cpu_(0) {}
 
@@ -84,7 +82,7 @@
   return true;
 }
 
-double ProcessMetrics::GetCPUUsage() {
+double ProcessMetrics::GetPlatformIndependentCPUUsage() {
   struct kinfo_proc info;
   int mib[] = { CTL_KERN, KERN_PROC, KERN_PROC_PID, process_ };
   size_t length = sizeof(info);
diff --git a/base/process/process_metrics_fuchsia.cc b/base/process/process_metrics_fuchsia.cc
index 6fcdb5ce..a5234c4 100644
--- a/base/process/process_metrics_fuchsia.cc
+++ b/base/process/process_metrics_fuchsia.cc
@@ -19,7 +19,7 @@
   return nullptr;
 }
 
-double ProcessMetrics::GetCPUUsage() {
+double ProcessMetrics::GetPlatformIndependentCPUUsage() {
   NOTIMPLEMENTED();  // TODO(fuchsia): https://crbug.com/706592.
   return 0.0;
 }
diff --git a/base/process/process_metrics_ios.cc b/base/process/process_metrics_ios.cc
index 2ed65ab3..31c812de 100644
--- a/base/process/process_metrics_ios.cc
+++ b/base/process/process_metrics_ios.cc
@@ -38,7 +38,7 @@
   return WrapUnique(new ProcessMetrics(process));
 }
 
-double ProcessMetrics::GetCPUUsage() {
+double ProcessMetrics::GetPlatformIndependentCPUUsage() {
   NOTIMPLEMENTED();
   return 0;
 }
diff --git a/base/process/process_metrics_linux.cc b/base/process/process_metrics_linux.cc
index d6b28bd4..6a32964 100644
--- a/base/process/process_metrics_linux.cc
+++ b/base/process/process_metrics_linux.cc
@@ -24,7 +24,6 @@
 #include "base/strings/string_split.h"
 #include "base/strings/string_tokenizer.h"
 #include "base/strings/string_util.h"
-#include "base/sys_info.h"
 #include "base/threading/thread_restrictions.h"
 #include "build/build_config.h"
 
@@ -256,7 +255,7 @@
   return GetWorkingSetKBytesStatm(ws_usage);
 }
 
-double ProcessMetrics::GetCPUUsage() {
+double ProcessMetrics::GetPlatformIndependentCPUUsage() {
   TimeTicks time = TimeTicks::Now();
 
   if (last_cpu_ == 0) {
@@ -405,7 +404,6 @@
       last_absolute_idle_wakeups_(0),
 #endif
       last_cpu_(0) {
-  processor_count_ = SysInfo::NumberOfProcessors();
 }
 
 #if defined(OS_CHROMEOS)
diff --git a/base/process/process_metrics_mac.cc b/base/process/process_metrics_mac.cc
index 710f096..d3d8bb4 100644
--- a/base/process/process_metrics_mac.cc
+++ b/base/process/process_metrics_mac.cc
@@ -19,7 +19,6 @@
 #include "base/memory/ptr_util.h"
 #include "base/numerics/safe_conversions.h"
 #include "base/numerics/safe_math.h"
-#include "base/sys_info.h"
 
 namespace base {
 
@@ -309,7 +308,7 @@
   (r)->tv_usec = (a)->microseconds;       \
 } while (0)
 
-double ProcessMetrics::GetCPUUsage() {
+double ProcessMetrics::GetPlatformIndependentCPUUsage() {
   mach_port_t task = TaskForPid(process_);
   if (task == MACH_PORT_NULL)
     return 0;
@@ -407,7 +406,6 @@
       last_system_time_(0),
       last_absolute_idle_wakeups_(0),
       port_provider_(port_provider) {
-  processor_count_ = SysInfo::NumberOfProcessors();
 }
 
 mach_port_t ProcessMetrics::TaskForPid(ProcessHandle process) const {
diff --git a/base/process/process_metrics_openbsd.cc b/base/process/process_metrics_openbsd.cc
index d8fbe7e..c863313 100644
--- a/base/process/process_metrics_openbsd.cc
+++ b/base/process/process_metrics_openbsd.cc
@@ -11,7 +11,6 @@
 
 #include "base/macros.h"
 #include "base/memory/ptr_util.h"
-#include "base/sys_info.h"
 
 namespace base {
 
@@ -112,7 +111,7 @@
   return info.p_pctcpu;
 }
 
-double ProcessMetrics::GetCPUUsage() {
+double ProcessMetrics::GetPlatformIndependentCPUUsage() {
   TimeTicks time = TimeTicks::Now();
 
   if (last_cpu_ == 0) {
@@ -140,7 +139,6 @@
 
 ProcessMetrics::ProcessMetrics(ProcessHandle process)
     : process_(process),
-      processor_count_(SysInfo::NumberOfProcessors()),
       last_system_time_(0),
       last_cpu_(0) {}
 
diff --git a/base/process/process_metrics_unittest.cc b/base/process/process_metrics_unittest.cc
index a09b664..2a18715 100644
--- a/base/process/process_metrics_unittest.cc
+++ b/base/process/process_metrics_unittest.cc
@@ -361,15 +361,15 @@
 
 #if defined(OS_LINUX) || defined(OS_CHROMEOS)
 
-// Test that ProcessMetrics::GetCPUUsage() doesn't return negative values when
-// the number of threads running on the process decreases between two successive
-// calls to it.
+// Test that ProcessMetrics::GetPlatformIndependentCPUUsage() doesn't return
+// negative values when the number of threads running on the process decreases
+// between two successive calls to it.
 TEST_F(SystemMetricsTest, TestNoNegativeCpuUsage) {
   ProcessHandle handle = GetCurrentProcessHandle();
   std::unique_ptr<ProcessMetrics> metrics(
       ProcessMetrics::CreateProcessMetrics(handle));
 
-  EXPECT_GE(metrics->GetCPUUsage(), 0.0);
+  EXPECT_GE(metrics->GetPlatformIndependentCPUUsage(), 0.0);
   Thread thread1("thread1");
   Thread thread2("thread2");
   Thread thread3("thread3");
@@ -390,16 +390,16 @@
   thread2.task_runner()->PostTask(FROM_HERE, BindOnce(&BusyWork, &vec2));
   thread3.task_runner()->PostTask(FROM_HERE, BindOnce(&BusyWork, &vec3));
 
-  EXPECT_GE(metrics->GetCPUUsage(), 0.0);
+  EXPECT_GE(metrics->GetPlatformIndependentCPUUsage(), 0.0);
 
   thread1.Stop();
-  EXPECT_GE(metrics->GetCPUUsage(), 0.0);
+  EXPECT_GE(metrics->GetPlatformIndependentCPUUsage(), 0.0);
 
   thread2.Stop();
-  EXPECT_GE(metrics->GetCPUUsage(), 0.0);
+  EXPECT_GE(metrics->GetPlatformIndependentCPUUsage(), 0.0);
 
   thread3.Stop();
-  EXPECT_GE(metrics->GetCPUUsage(), 0.0);
+  EXPECT_GE(metrics->GetPlatformIndependentCPUUsage(), 0.0);
 }
 
 #endif  // defined(OS_LINUX) || defined(OS_CHROMEOS)
diff --git a/base/process/process_metrics_win.cc b/base/process/process_metrics_win.cc
index 9de34496..214d14793 100644
--- a/base/process/process_metrics_win.cc
+++ b/base/process/process_metrics_win.cc
@@ -279,7 +279,7 @@
   return li.QuadPart;
 }
 
-double ProcessMetrics::GetCPUUsage() {
+double ProcessMetrics::GetPlatformIndependentCPUUsage() {
   FILETIME creation_time;
   FILETIME exit_time;
   FILETIME kernel_time;
@@ -292,9 +292,7 @@
     // not yet received the notification.
     return 0;
   }
-  int64_t system_time =
-      (FileTimeToUTC(kernel_time) + FileTimeToUTC(user_time)) /
-      processor_count_;
+  int64_t system_time = FileTimeToUTC(kernel_time) + FileTimeToUTC(user_time);
   TimeTicks time = TimeTicks::Now();
 
   if (last_system_time_ == 0) {
@@ -315,15 +313,14 @@
   last_system_time_ = system_time;
   last_cpu_time_ = time;
 
-  return static_cast<double>(system_time_delta * 100.0) / time_delta;
+  return static_cast<double>(system_time_delta) / time_delta;
 }
 
 bool ProcessMetrics::GetIOCounters(IoCounters* io_counters) const {
   return GetProcessIoCounters(process_.Get(), io_counters) != FALSE;
 }
 
-ProcessMetrics::ProcessMetrics(ProcessHandle process)
-    : processor_count_(SysInfo::NumberOfProcessors()), last_system_time_(0) {
+ProcessMetrics::ProcessMetrics(ProcessHandle process) : last_system_time_(0) {
   if (process) {
     HANDLE duplicate_handle;
     BOOL result = ::DuplicateHandle(::GetCurrentProcess(), process,
diff --git a/base/synchronization/waitable_event_mac.cc b/base/synchronization/waitable_event_mac.cc
index 382c1d1b..7429147 100644
--- a/base/synchronization/waitable_event_mac.cc
+++ b/base/synchronization/waitable_event_mac.cc
@@ -15,6 +15,7 @@
 #include "base/mac/mach_logging.h"
 #include "base/mac/scoped_dispatch_object.h"
 #include "base/posix/eintr_wrapper.h"
+#include "base/threading/scoped_blocking_call.h"
 #include "base/threading/thread_restrictions.h"
 #include "build/build_config.h"
 
@@ -111,6 +112,7 @@
 
 bool WaitableEvent::TimedWaitUntil(const TimeTicks& end_time) {
   ThreadRestrictions::AssertWaitAllowed();
+  ScopedBlockingCall scoped_blocking_call(BlockingType::MAY_BLOCK);
   // Record the event that this thread is blocking upon (for hang diagnosis).
   debug::ScopedEventWaitActivity event_activity(this);
 
@@ -166,7 +168,7 @@
 size_t WaitableEvent::WaitMany(WaitableEvent** raw_waitables, size_t count) {
   ThreadRestrictions::AssertWaitAllowed();
   DCHECK(count) << "Cannot wait on no events";
-
+  ScopedBlockingCall scoped_blocking_call(BlockingType::MAY_BLOCK);
   // Record an event (the first) that this thread is blocking upon.
   debug::ScopedEventWaitActivity event_activity(raw_waitables[0]);
 
diff --git a/base/synchronization/waitable_event_posix.cc b/base/synchronization/waitable_event_posix.cc
index 846fa067..f2653511 100644
--- a/base/synchronization/waitable_event_posix.cc
+++ b/base/synchronization/waitable_event_posix.cc
@@ -13,6 +13,7 @@
 #include "base/synchronization/condition_variable.h"
 #include "base/synchronization/lock.h"
 #include "base/synchronization/waitable_event.h"
+#include "base/threading/scoped_blocking_call.h"
 #include "base/threading/thread_restrictions.h"
 
 // -----------------------------------------------------------------------------
@@ -166,6 +167,7 @@
 
 bool WaitableEvent::TimedWaitUntil(const TimeTicks& end_time) {
   base::ThreadRestrictions::AssertWaitAllowed();
+  ScopedBlockingCall scoped_blocking_call(BlockingType::MAY_BLOCK);
   // Record the event that this thread is blocking upon (for hang diagnosis).
   base::debug::ScopedEventWaitActivity event_activity(this);
 
@@ -241,7 +243,7 @@
                                size_t count) {
   base::ThreadRestrictions::AssertWaitAllowed();
   DCHECK(count) << "Cannot wait on no events";
-
+  ScopedBlockingCall scoped_blocking_call(BlockingType::MAY_BLOCK);
   // Record an event (the first) that this thread is blocking upon.
   base::debug::ScopedEventWaitActivity event_activity(raw_waitables[0]);
 
diff --git a/base/synchronization/waitable_event_win.cc b/base/synchronization/waitable_event_win.cc
index 993dbb12..2aec4fd 100644
--- a/base/synchronization/waitable_event_win.cc
+++ b/base/synchronization/waitable_event_win.cc
@@ -13,6 +13,7 @@
 #include "base/debug/activity_tracker.h"
 #include "base/logging.h"
 #include "base/numerics/safe_conversions.h"
+#include "base/threading/scoped_blocking_call.h"
 #include "base/threading/thread_restrictions.h"
 #include "base/time/time.h"
 
@@ -53,6 +54,7 @@
 
 void WaitableEvent::Wait() {
   base::ThreadRestrictions::AssertWaitAllowed();
+  ScopedBlockingCall scoped_blocking_call(BlockingType::MAY_BLOCK);
   // Record the event that this thread is blocking upon (for hang diagnosis).
   base::debug::ScopedEventWaitActivity event_activity(this);
 
@@ -66,6 +68,8 @@
 
 // Helper function called from TimedWait and TimedWaitUntil.
 bool WaitUntil(HANDLE handle, const TimeTicks& now, const TimeTicks& end_time) {
+  ScopedBlockingCall scoped_blocking_call(BlockingType::MAY_BLOCK);
+
   TimeDelta delta = end_time - now;
   DCHECK_GT(delta, TimeDelta());
 
@@ -132,6 +136,7 @@
   DCHECK(count) << "Cannot wait on no events";
 
   base::ThreadRestrictions::AssertWaitAllowed();
+  ScopedBlockingCall scoped_blocking_call(BlockingType::MAY_BLOCK);
   // Record an event (the first) that this thread is blocking upon.
   base::debug::ScopedEventWaitActivity event_activity(events[0]);
 
diff --git a/base/task_scheduler/scheduler_worker_pool_impl.cc b/base/task_scheduler/scheduler_worker_pool_impl.cc
index ce3a0cf..68a75d4 100644
--- a/base/task_scheduler/scheduler_worker_pool_impl.cc
+++ b/base/task_scheduler/scheduler_worker_pool_impl.cc
@@ -133,6 +133,10 @@
   // BlockingScopeExited() is called. Access synchronized by |outer_->lock_|.
   TimeTicks may_block_start_time_;
 
+  // Whether this worker is currently running a task (i.e. GetWork() has
+  // returned a non-empty sequence and DidRunTask() hasn't been called yet).
+  bool is_running_task_ = false;
+
   DISALLOW_COPY_AND_ASSIGN(SchedulerWorkerDelegateImpl);
 };
 
@@ -339,6 +343,7 @@
 scoped_refptr<Sequence>
 SchedulerWorkerPoolImpl::SchedulerWorkerDelegateImpl::GetWork(
     SchedulerWorker* worker) {
+  DCHECK(!is_running_task_);
   {
     AutoSchedulerLock auto_lock(outer_->lock_);
 
@@ -407,10 +412,17 @@
     DCHECK(!outer_->idle_workers_stack_.Contains(worker));
   }
 #endif
+
+  is_running_task_ = true;
   return sequence;
 }
 
 void SchedulerWorkerPoolImpl::SchedulerWorkerDelegateImpl::DidRunTask() {
+  DCHECK(may_block_start_time_.is_null());
+  DCHECK(!incremented_worker_capacity_since_blocked_);
+  DCHECK(is_running_task_);
+  is_running_task_ = false;
+
   ++num_tasks_since_last_wait_;
   ++num_tasks_since_last_detach_;
 }
@@ -508,6 +520,11 @@
 
 void SchedulerWorkerPoolImpl::SchedulerWorkerDelegateImpl::BlockingStarted(
     BlockingType blocking_type) {
+  // Blocking calls made outside of tasks should not influence the capacity
+  // count as no task is running.
+  if (!is_running_task_)
+    return;
+
   switch (blocking_type) {
     case BlockingType::MAY_BLOCK:
       MayBlockEntered();
@@ -540,11 +557,17 @@
 }
 
 void SchedulerWorkerPoolImpl::SchedulerWorkerDelegateImpl::BlockingEnded() {
+  // Ignore blocking calls made outside of tasks.
+  if (!is_running_task_)
+    return;
+
   AutoSchedulerLock auto_lock(outer_->lock_);
-  if (incremented_worker_capacity_since_blocked_)
+  if (incremented_worker_capacity_since_blocked_) {
     outer_->DecrementWorkerCapacityLockRequired();
-  else if (!may_block_start_time_.is_null())
+  } else {
+    DCHECK(!may_block_start_time_.is_null());
     --outer_->num_pending_may_block_workers_;
+  }
 
   incremented_worker_capacity_since_blocked_ = false;
   may_block_start_time_ = TimeTicks();
diff --git a/base/task_scheduler/scheduler_worker_pool_impl_unittest.cc b/base/task_scheduler/scheduler_worker_pool_impl_unittest.cc
index 2a5b0a23..adb4168 100644
--- a/base/task_scheduler/scheduler_worker_pool_impl_unittest.cc
+++ b/base/task_scheduler/scheduler_worker_pool_impl_unittest.cc
@@ -846,7 +846,14 @@
                 NestedScopedBlockingCall nested_scoped_blocking_call(
                     nested_blocking_type);
                 blocking_thread_running_closure->Run();
-                blocking_thread_continue_->Wait();
+
+                {
+                  // Use ScopedClearBlockingObserverForTesting to avoid
+                  // affecting the worker capacity with this WaitableEvent.
+                  internal::ScopedClearBlockingObserverForTesting
+                      scoped_clear_blocking_observer;
+                  blocking_thread_continue_->Wait();
+                }
 
               },
               Unretained(&blocking_thread_running_closure),
@@ -933,10 +940,24 @@
                WaitableEvent* thread_running, WaitableEvent* thread_can_block,
                WaitableEvent* thread_continue) {
               thread_running->Signal();
-              thread_can_block->Wait();
+              {
+                // Use ScopedClearBlockingObserverForTesting to avoid affecting
+                // the worker capacity with this WaitableEvent.
+                internal::ScopedClearBlockingObserverForTesting
+                    scoped_clear_blocking_observer;
+                thread_can_block->Wait();
+              }
+
               NestedScopedBlockingCall nested_scoped_blocking_call(
                   nested_blocking_type);
-              thread_continue->Wait();
+
+              {
+                // Use ScopedClearBlockingObserverForTesting to avoid affecting
+                // the worker capacity with this WaitableEvent.
+                internal::ScopedClearBlockingObserverForTesting
+                    scoped_clear_blocking_observer;
+                thread_continue->Wait();
+              }
             },
             GetParam(), Unretained(&thread_running),
             Unretained(&thread_can_block), Unretained(&thread_continue)));
@@ -963,7 +984,15 @@
                                [](Closure* extra_threads_running_barrier,
                                   WaitableEvent* extra_threads_continue) {
                                  extra_threads_running_barrier->Run();
-                                 extra_threads_continue->Wait();
+                                 {
+                                   // Use ScopedClearBlockingObserverForTesting
+                                   // to avoid affecting the worker capacity
+                                   // with this WaitableEvent.
+                                   internal::
+                                       ScopedClearBlockingObserverForTesting
+                                           scoped_clear_blocking_observer;
+                                   extra_threads_continue->Wait();
+                                 }
                                },
                                Unretained(&extra_threads_running_barrier),
                                Unretained(&extra_threads_continue)));
@@ -1012,14 +1041,19 @@
       BindOnce(&WaitableEvent::Signal, Unretained(&thread_running)));
   // Posting these tasks should cause new workers to be created.
   for (size_t i = 0; i < kNumWorkersInWorkerPool; ++i) {
-    task_runner_->PostTask(FROM_HERE, BindOnce(
-                                          [](Closure* thread_running_barrier,
-                                             WaitableEvent* thread_continue) {
-                                            thread_running_barrier->Run();
-                                            thread_continue->Wait();
-                                          },
-                                          Unretained(&thread_running_barrier),
-                                          Unretained(&thread_continue)));
+    auto callback = BindOnce(
+        [](Closure* thread_running_barrier, WaitableEvent* thread_continue) {
+          thread_running_barrier->Run();
+          {
+            // Use ScopedClearBlockingObserver ForTesting to avoid affecting the
+            // worker capacity with this WaitableEvent.
+            internal::ScopedClearBlockingObserverForTesting
+                scoped_clear_blocking_observer;
+            thread_continue->Wait();
+          }
+        },
+        Unretained(&thread_running_barrier), Unretained(&thread_continue));
+    task_runner_->PostTask(FROM_HERE, std::move(callback));
   }
   thread_running.Wait();
 
@@ -1122,8 +1156,17 @@
   // Saturate the pool so that a MAY_BLOCK ScopedBlockingCall would increment
   // the worker capacity.
   for (size_t i = 0; i < kNumWorkersInWorkerPool - 1; ++i) {
-    task_runner->PostTask(
-        FROM_HERE, BindOnce(&WaitableEvent::Wait, Unretained(&can_return)));
+    task_runner->PostTask(FROM_HERE,
+                          BindOnce(
+                              [](WaitableEvent* can_return) {
+                                // Use ScopedClearBlockingObserverForTesting to
+                                // avoid affecting the worker capacity with this
+                                // WaitableEvent.
+                                internal::ScopedClearBlockingObserverForTesting
+                                    scoped_clear_blocking_observer;
+                                can_return->Wait();
+                              },
+                              Unretained(&can_return)));
   }
 
   WaitableEvent can_instantiate_will_block(
@@ -1141,10 +1184,22 @@
              WaitableEvent* did_instantiate_will_block,
              WaitableEvent* can_return) {
             ScopedBlockingCall may_block(BlockingType::MAY_BLOCK);
-            can_instantiate_will_block->Wait();
+            {
+              // Use ScopedClearBlockingObserverForTesting to avoid affecting
+              // the worker capacity with this WaitableEvent.
+              internal::ScopedClearBlockingObserverForTesting
+                  scoped_clear_blocking_observer;
+              can_instantiate_will_block->Wait();
+            }
             ScopedBlockingCall will_block(BlockingType::WILL_BLOCK);
             did_instantiate_will_block->Signal();
-            can_return->Wait();
+            {
+              // Use ScopedClearBlockingObserverForTesting to avoid affecting
+              // the worker capacity with this WaitableEvent.
+              internal::ScopedClearBlockingObserverForTesting
+                  scoped_clear_blocking_observer;
+              can_return->Wait();
+            }
           },
           Unretained(&can_instantiate_will_block),
           Unretained(&did_instantiate_will_block), Unretained(&can_return)));
diff --git a/base/threading/scoped_blocking_call.cc b/base/threading/scoped_blocking_call.cc
index 6cb4f7f..1d2931c 100644
--- a/base/threading/scoped_blocking_call.cc
+++ b/base/threading/scoped_blocking_call.cc
@@ -20,19 +20,6 @@
 
 }  // namespace
 
-namespace internal {
-
-void SetBlockingObserverForCurrentThread(BlockingObserver* blocking_observer) {
-  DCHECK(!tls_blocking_observer.Get().Get());
-  tls_blocking_observer.Get().Set(blocking_observer);
-}
-
-void ClearBlockingObserverForTesting() {
-  tls_blocking_observer.Get().Set(nullptr);
-}
-
-}  // namespace internal
-
 ScopedBlockingCall::ScopedBlockingCall(BlockingType blocking_type)
     : blocking_observer_(tls_blocking_observer.Get().Get()),
       previous_scoped_blocking_call_(tls_last_scoped_blocking_call.Get().Get()),
@@ -58,4 +45,28 @@
     blocking_observer_->BlockingEnded();
 }
 
+namespace internal {
+
+void SetBlockingObserverForCurrentThread(BlockingObserver* blocking_observer) {
+  DCHECK(!tls_blocking_observer.Get().Get());
+  tls_blocking_observer.Get().Set(blocking_observer);
+}
+
+void ClearBlockingObserverForTesting() {
+  tls_blocking_observer.Get().Set(nullptr);
+}
+
+ScopedClearBlockingObserverForTesting::ScopedClearBlockingObserverForTesting()
+    : blocking_observer_(tls_blocking_observer.Get().Get()) {
+  tls_blocking_observer.Get().Set(nullptr);
+}
+
+ScopedClearBlockingObserverForTesting::
+    ~ScopedClearBlockingObserverForTesting() {
+  DCHECK(!tls_blocking_observer.Get().Get());
+  tls_blocking_observer.Get().Set(blocking_observer_);
+}
+
+}  // namespace internal
+
 }  // namespace base
diff --git a/base/threading/scoped_blocking_call.h b/base/threading/scoped_blocking_call.h
index 281a10e..c8c4b36 100644
--- a/base/threading/scoped_blocking_call.h
+++ b/base/threading/scoped_blocking_call.h
@@ -79,6 +79,20 @@
 
 BASE_EXPORT void ClearBlockingObserverForTesting();
 
+// Unregisters the |blocking_observer| on the current thread within its scope.
+// Used in TaskScheduler tests to prevent calls to //base sync primitives from
+// affecting the thread pool capacity.
+class BASE_EXPORT ScopedClearBlockingObserverForTesting {
+ public:
+  ScopedClearBlockingObserverForTesting();
+  ~ScopedClearBlockingObserverForTesting();
+
+ private:
+  BlockingObserver* const blocking_observer_;
+
+  DISALLOW_COPY_AND_ASSIGN(ScopedClearBlockingObserverForTesting);
+};
+
 }  // namespace internal
 
 }  // namespace base
diff --git a/build/config/android/config.gni b/build/config/android/config.gni
index d0091f0..e74ee86 100644
--- a/build/config/android/config.gni
+++ b/build/config/android/config.gni
@@ -177,6 +177,12 @@
   # We need a second declare_args block to make sure we are using the overridden
   # value of the arguments set above.
   declare_args() {
+    if (defined(default_android_sdk_platform_version)) {
+      android_sdk_platform_version = default_android_sdk_platform_version
+    } else {
+      android_sdk_platform_version = android_sdk_version
+    }
+
     # Speed up dexing using dx --incremental.
     enable_incremental_dx = is_java_debug
   }
@@ -218,7 +224,8 @@
   # than just the current one) since these are needed by the Android toolchain
   # file to define toolchains for all possible targets in one pass.
 
-  android_sdk = "${android_sdk_root}/platforms/android-${android_sdk_version}"
+  android_sdk =
+      "${android_sdk_root}/platforms/android-${android_sdk_platform_version}"
 
   # Path to the Android NDK and SDK.
   android_ndk_include_dir = "$android_ndk_root/usr/include"
diff --git a/cc/tiles/gpu_image_decode_cache.cc b/cc/tiles/gpu_image_decode_cache.cc
index a66ffdf..168c634 100644
--- a/cc/tiles/gpu_image_decode_cache.cc
+++ b/cc/tiles/gpu_image_decode_cache.cc
@@ -29,12 +29,12 @@
 #include "third_party/skia/include/core/SkRefCnt.h"
 #include "third_party/skia/include/core/SkSurface.h"
 #include "third_party/skia/include/gpu/GrContext.h"
-#include "third_party/skia/include/gpu/GrTexture.h"
 #include "ui/gfx/skia_util.h"
 #include "ui/gl/trace_util.h"
 
 namespace cc {
 namespace {
+
 // The number or entries to keep in the cache, depending on the memory state of
 // the system. This limit can be breached by in-use cache items, which cannot
 // be deleted.
@@ -42,21 +42,14 @@
 static const int kThrottledMaxItemsInCache = 100;
 static const int kSuspendedMaxItemsInCache = 0;
 
-// lock_count │ used  │ result state
-// ═══════════╪═══════╪══════════════════
-//  1         │ false │ WASTED_ONCE
-//  1         │ true  │ USED_ONCE
-//  >1        │ false │ WASTED_RELOCKED
-//  >1        │ true  │ USED_RELOCKED
-// Note that it's important not to reorder the following enum, since the
-// numerical values are used in the histogram code.
-enum ImageUsageState : int {
-  IMAGE_USAGE_STATE_WASTED_ONCE,
-  IMAGE_USAGE_STATE_USED_ONCE,
-  IMAGE_USAGE_STATE_WASTED_RELOCKED,
-  IMAGE_USAGE_STATE_USED_RELOCKED,
-  IMAGE_USAGE_STATE_COUNT
-};
+// The factor by which to reduce the GPU memory size of the cache when in the
+// THROTTLED memory state.
+static const int kThrottledCacheSizeReductionFactor = 2;
+
+// The maximum size in bytes of GPU memory in the cache while SUSPENDED or not
+// visible. This limit can be breached by in-use cache items, which cannot be
+// deleted.
+static const int kSuspendedOrInvisibleMaxGpuImageBytes = 0;
 
 // Returns true if an image would not be drawn and should therefore be
 // skipped rather than decoded.
@@ -155,14 +148,6 @@
   return decode_pixmap.readPixels(*target_pixmap);
 }
 
-// Returns the GL texture ID backing the given SkImage.
-GrGLuint GlIdFromSkImage(SkImage* image) {
-  DCHECK(image->isTextureBacked());
-  const GrGLTextureInfo* info = skia::GrBackendObjectToGrGLTextureInfo(
-      image->getTextureHandle(true /* flushPendingGrContextIO */));
-  return info->fID;
-}
-
 }  // namespace
 
 // static
@@ -291,87 +276,78 @@
   DISALLOW_COPY_AND_ASSIGN(ImageUploadTaskImpl);
 };
 
-GpuImageDecodeCache::ImageDataBase::ImageDataBase() = default;
-GpuImageDecodeCache::ImageDataBase::~ImageDataBase() = default;
-
-void GpuImageDecodeCache::ImageDataBase::OnSetLockedData(bool out_of_raster) {
-  DCHECK_EQ(usage_stats_.lock_count, 1);
-  DCHECK(!is_locked_);
-  usage_stats_.first_lock_out_of_raster = out_of_raster;
-  is_locked_ = true;
-}
-
-void GpuImageDecodeCache::ImageDataBase::OnResetData() {
-  is_locked_ = false;
-  usage_stats_ = UsageStats();
-}
-
-void GpuImageDecodeCache::ImageDataBase::OnLock() {
-  DCHECK(!is_locked_);
-  is_locked_ = true;
-  ++usage_stats_.lock_count;
-}
-
-void GpuImageDecodeCache::ImageDataBase::OnUnlock() {
-  DCHECK(is_locked_);
-  is_locked_ = false;
-  if (usage_stats_.lock_count == 1)
-    usage_stats_.first_lock_wasted = !usage_stats_.used;
-}
-
-int GpuImageDecodeCache::ImageDataBase::UsageState() const {
-  ImageUsageState state = IMAGE_USAGE_STATE_WASTED_ONCE;
-  if (usage_stats_.lock_count == 1) {
-    if (usage_stats_.used)
-      state = IMAGE_USAGE_STATE_USED_ONCE;
-    else
-      state = IMAGE_USAGE_STATE_WASTED_ONCE;
-  } else {
-    if (usage_stats_.used)
-      state = IMAGE_USAGE_STATE_USED_RELOCKED;
-    else
-      state = IMAGE_USAGE_STATE_WASTED_RELOCKED;
-  }
-
-  return state;
-}
-
 GpuImageDecodeCache::DecodedImageData::DecodedImageData() = default;
 GpuImageDecodeCache::DecodedImageData::~DecodedImageData() {
   ResetData();
 }
 
 bool GpuImageDecodeCache::DecodedImageData::Lock() {
-  if (data_->Lock())
-    OnLock();
+  DCHECK(!is_locked_);
+  is_locked_ = data_->Lock();
+  if (is_locked_)
+    ++usage_stats_.lock_count;
   return is_locked_;
 }
 
 void GpuImageDecodeCache::DecodedImageData::Unlock() {
+  DCHECK(is_locked_);
   data_->Unlock();
-  OnUnlock();
+  if (usage_stats_.lock_count == 1)
+    usage_stats_.first_lock_wasted = !usage_stats_.used;
+  is_locked_ = false;
 }
 
 void GpuImageDecodeCache::DecodedImageData::SetLockedData(
     std::unique_ptr<base::DiscardableMemory> data,
     bool out_of_raster) {
+  DCHECK(!is_locked_);
   DCHECK(data);
   DCHECK(!data_);
+  DCHECK_EQ(usage_stats_.lock_count, 1);
   data_ = std::move(data);
-  OnSetLockedData(out_of_raster);
+  is_locked_ = true;
+  usage_stats_.first_lock_out_of_raster = out_of_raster;
 }
 
 void GpuImageDecodeCache::DecodedImageData::ResetData() {
+  DCHECK(!is_locked_);
   if (data_)
     ReportUsageStats();
   data_ = nullptr;
-  OnResetData();
+  usage_stats_ = UsageStats();
 }
 
 void GpuImageDecodeCache::DecodedImageData::ReportUsageStats() const {
-  UMA_HISTOGRAM_ENUMERATION("Renderer4.GpuImageDecodeState",
-                            static_cast<ImageUsageState>(UsageState()),
-                            IMAGE_USAGE_STATE_COUNT);
+  // lock_count │ used  │ result state
+  // ═══════════╪═══════╪══════════════════
+  //  1         │ false │ WASTED_ONCE
+  //  1         │ true  │ USED_ONCE
+  //  >1        │ false │ WASTED_RELOCKED
+  //  >1        │ true  │ USED_RELOCKED
+  // Note that it's important not to reorder the following enums, since the
+  // numerical values are used in the histogram code.
+  enum State : int {
+    DECODED_IMAGE_STATE_WASTED_ONCE,
+    DECODED_IMAGE_STATE_USED_ONCE,
+    DECODED_IMAGE_STATE_WASTED_RELOCKED,
+    DECODED_IMAGE_STATE_USED_RELOCKED,
+    DECODED_IMAGE_STATE_COUNT
+  } state = DECODED_IMAGE_STATE_WASTED_ONCE;
+
+  if (usage_stats_.lock_count == 1) {
+    if (usage_stats_.used)
+      state = DECODED_IMAGE_STATE_USED_ONCE;
+    else
+      state = DECODED_IMAGE_STATE_WASTED_ONCE;
+  } else {
+    if (usage_stats_.used)
+      state = DECODED_IMAGE_STATE_USED_RELOCKED;
+    else
+      state = DECODED_IMAGE_STATE_WASTED_RELOCKED;
+  }
+
+  UMA_HISTOGRAM_ENUMERATION("Renderer4.GpuImageDecodeState", state,
+                            DECODED_IMAGE_STATE_COUNT);
   UMA_HISTOGRAM_BOOLEAN("Renderer4.GpuImageDecodeState.FirstLockWasted",
                         usage_stats_.first_lock_wasted);
   if (usage_stats_.first_lock_out_of_raster)
@@ -382,33 +358,23 @@
 
 GpuImageDecodeCache::UploadedImageData::UploadedImageData() = default;
 GpuImageDecodeCache::UploadedImageData::~UploadedImageData() {
-  DCHECK(!image());
+  SetImage(nullptr);
 }
 
 void GpuImageDecodeCache::UploadedImageData::SetImage(sk_sp<SkImage> image) {
-  DCHECK(!image_);
-  DCHECK(image);
-  image_ = std::move(image);
-  if (image_->isTextureBacked())
-    gl_id_ = GlIdFromSkImage(image_.get());
-  OnSetLockedData(false /* out_of_raster */);
-}
-
-void GpuImageDecodeCache::UploadedImageData::ResetImage() {
-  if (image_)
+  DCHECK(!image_ || !image);
+  if (image_) {
     ReportUsageStats();
-
-  image_ = nullptr;
-  gl_id_ = 0;
-  OnResetData();
+    usage_stats_ = UsageStats();
+  }
+  image_ = std::move(image);
 }
 
 void GpuImageDecodeCache::UploadedImageData::ReportUsageStats() const {
-  UMA_HISTOGRAM_ENUMERATION("Renderer4.GpuImageUploadState",
-                            static_cast<ImageUsageState>(UsageState()),
-                            IMAGE_USAGE_STATE_COUNT);
-  UMA_HISTOGRAM_BOOLEAN("Renderer4.GpuImageUploadState.FirstLockWasted",
-                        usage_stats_.first_lock_wasted);
+  UMA_HISTOGRAM_BOOLEAN("Renderer4.GpuImageUploadState.Used",
+                        usage_stats_.used);
+  UMA_HISTOGRAM_BOOLEAN("Renderer4.GpuImageUploadState.FirstRefWasted",
+                        usage_stats_.first_ref_wasted);
 }
 
 GpuImageDecodeCache::ImageData::ImageData(
@@ -434,17 +400,21 @@
 
 GpuImageDecodeCache::GpuImageDecodeCache(viz::ContextProvider* context,
                                          SkColorType color_type,
-                                         size_t max_working_set_bytes)
+                                         size_t max_working_set_bytes,
+                                         size_t max_cache_bytes)
     : color_type_(color_type),
       context_(context),
       persistent_cache_(PersistentCache::NO_AUTO_EVICT),
-      max_working_set_bytes_(max_working_set_bytes) {
+      max_working_set_bytes_(max_working_set_bytes),
+      normal_max_cache_bytes_(max_cache_bytes) {
+  DCHECK_GE(max_working_set_bytes_, normal_max_cache_bytes_);
+
   // Acquire the context_lock so that we can safely retrieve the
   // GrContextThreadSafeProxy. This proxy can then be used with no lock held.
   {
     viz::ContextProvider::ScopedContextLock context_lock(context_);
     context_threadsafe_proxy_ = sk_sp<GrContextThreadSafeProxy>(
-        context_->GrContext()->threadSafeProxy());
+        context->GrContext()->threadSafeProxy());
   }
 
   // In certain cases, ThreadTaskRunnerHandle isn't set (Android Webview).
@@ -516,6 +486,11 @@
     // We have already tried and failed to decode this image, so just return.
     *task = nullptr;
     return false;
+  } else if (image_data->upload.image()) {
+    // The image is already uploaded, ref and return.
+    RefImage(draw_image);
+    *task = nullptr;
+    return true;
   } else if (task_type == DecodeTaskType::PART_OF_UPLOAD_TASK &&
              image_data->upload.task) {
     // We had an existing upload task, ref the image and return the task.
@@ -546,14 +521,6 @@
   // it is their responsibility to release it by calling UnrefImage.
   RefImage(draw_image);
 
-  // If we already have an image and it is locked (or lock-able), just return
-  // that.
-  if (image_data->upload.image() &&
-      TryLockImage(HaveContextLock::kNo, draw_image, image_data)) {
-    *task = nullptr;
-    return true;
-  }
-
   if (task_type == DecodeTaskType::PART_OF_UPLOAD_TASK) {
     // Ref image and create a upload and decode tasks. We will release this ref
     // in UploadTaskCompleted.
@@ -617,8 +584,7 @@
   UnrefImageDecode(draw_image);
 
   sk_sp<SkImage> image = image_data->upload.image();
-  if (image)
-    image_data->upload.mark_used();
+  image_data->upload.mark_used();
   DCHECK(image || image_data->decode.decode_failure);
 
   SkSize scale_factor = CalculateScaleFactorForMipLevel(
@@ -648,7 +614,7 @@
   // We are mid-draw and holding the context lock, ensure we clean up any
   // textures (especially at-raster), which may have just been marked for
   // deletion by UnrefImage.
-  RunPendingContextThreadOperations();
+  DeletePendingImages();
 }
 
 void GpuImageDecodeCache::ReduceCacheUsage() {
@@ -656,14 +622,6 @@
                "GpuImageDecodeCache::ReduceCacheUsage");
   base::AutoLock lock(lock_);
   EnsureCapacity(0);
-
-  // This is typically called when no tasks are running (between scheduling
-  // tasks). Try to lock and run pending operations if possible, but don't
-  // block on it.
-  if (context_->GetLock()->Try()) {
-    RunPendingContextThreadOperations();
-    context_->GetLock()->Release();
-  }
 }
 
 void GpuImageDecodeCache::SetShouldAggressivelyFreeResources(
@@ -674,15 +632,17 @@
   if (aggressively_free_resources) {
     viz::ContextProvider::ScopedContextLock context_lock(context_);
     base::AutoLock lock(lock_);
-    aggressively_freeing_resources_ = aggressively_free_resources;
+    // We want to keep as little in our cache as possible. Set our memory limit
+    // to zero and EnsureCapacity to clean up memory.
+    cached_bytes_limit_ = kSuspendedOrInvisibleMaxGpuImageBytes;
     EnsureCapacity(0);
 
     // We are holding the context lock, so finish cleaning up deleted images
     // now.
-    RunPendingContextThreadOperations();
+    DeletePendingImages();
   } else {
     base::AutoLock lock(lock_);
-    aggressively_freeing_resources_ = aggressively_free_resources;
+    cached_bytes_limit_ = normal_max_cache_bytes_;
   }
 }
 
@@ -694,14 +654,17 @@
       // Orphan the entry so it will be deleted once no longer in use.
       entry.second->is_orphaned = true;
     } else if (entry.second->upload.image()) {
-      DeleteImage(entry.second.get());
+      bytes_used_ -= entry.second->size;
+      images_pending_deletion_.push_back(entry.second->upload.image());
+      entry.second->upload.SetImage(nullptr);
+      entry.second->upload.budgeted = false;
     }
   }
   persistent_cache_.Clear();
 }
 
 size_t GpuImageDecodeCache::GetMaximumMemoryLimitBytes() const {
-  return max_working_set_bytes_;
+  return normal_max_cache_bytes_;
 }
 
 void GpuImageDecodeCache::NotifyImageUnused(
@@ -712,7 +675,11 @@
         it->second->upload.ref_count != 0) {
       it->second->is_orphaned = true;
     } else if (it->second->upload.image()) {
-      DeleteImage(it->second.get());
+      DCHECK(!it->second->decode.is_locked());
+      bytes_used_ -= it->second->size;
+      images_pending_deletion_.push_back(it->second->upload.image());
+      it->second->upload.SetImage(nullptr);
+      it->second->upload.budgeted = false;
     }
     persistent_cache_.Erase(it);
   }
@@ -733,7 +700,7 @@
         "cc/image_memory/cache_0x%" PRIXPTR, reinterpret_cast<uintptr_t>(this));
     MemoryAllocatorDump* dump = pmd->CreateAllocatorDump(dump_name);
     dump->AddScalar(MemoryAllocatorDump::kNameSize,
-                    MemoryAllocatorDump::kUnitsBytes, working_set_bytes_);
+                    MemoryAllocatorDump::kUnitsBytes, bytes_used_);
 
     // Early out, no need for more detail in a BACKGROUND dump.
     return true;
@@ -761,7 +728,8 @@
     }
 
     // If we have an uploaded image (that is actually on the GPU, not just a
-    // CPU wrapper), upload it here.
+    // CPU
+    // wrapper), upload it here.
     if (image_data->upload.image() &&
         image_data->mode == DecodedDataMode::GPU) {
       std::string gpu_dump_name = base::StringPrintf(
@@ -771,17 +739,15 @@
       dump->AddScalar(MemoryAllocatorDump::kNameSize,
                       MemoryAllocatorDump::kUnitsBytes, image_data->size);
 
-      // Dump the "locked_size" as an additional column.
-      size_t locked_size =
-          image_data->upload.is_locked() ? image_data->size : 0u;
-      dump->AddScalar("locked_size", MemoryAllocatorDump::kUnitsBytes,
-                      locked_size);
-
       // Create a global shred GUID to associate this data with its GPU
-      // process counterpart.
+      // process
+      // counterpart.
+      GLuint gl_id = skia::GrBackendObjectToGrGLTextureInfo(
+                         image_data->upload.image()->getTextureHandle(
+                             false /* flushPendingGrContextIO */))
+                         ->fID;
       MemoryAllocatorDumpGuid guid = gl::GetGLTextureClientGUIDForTracing(
-          context_->ContextSupport()->ShareGroupTracingGUID(),
-          image_data->upload.gl_id());
+          context_->ContextSupport()->ShareGroupTracingGUID(), gl_id);
 
       // kImportance is somewhat arbitrary - we chose 3 to be higher than the
       // value used in the GPU process (1), and Skia (2), causing us to appear
@@ -983,61 +949,68 @@
       persistent_cache_.Erase(found_persistent);
   }
 
-  // If we have no refs on an uploaded image, it should be unlocked. Do this
-  // before any attempts to delete the image.
-  if (image_data->mode == DecodedDataMode::GPU &&
-      image_data->upload.ref_count == 0 && image_data->upload.is_locked()) {
-    UnlockImage(image_data);
-  }
-
   // Don't keep around orphaned images.
   if (image_data->is_orphaned && !has_any_refs) {
-    DeleteImage(image_data);
+    images_pending_deletion_.push_back(std::move(image_data->upload.image()));
+    image_data->upload.SetImage(nullptr);
   }
 
   // Don't keep CPU images if they are unused, these images can be recreated by
   // re-locking discardable (rather than requiring a full upload like GPU
   // images).
   if (image_data->mode == DecodedDataMode::CPU && !has_any_refs) {
-    DeleteImage(image_data);
+    images_pending_deletion_.push_back(image_data->upload.image());
+    image_data->upload.SetImage(nullptr);
   }
 
   if (image_data->is_at_raster && !has_any_refs) {
-    // We have an at-raster image with no refs. Convert it to not-at-raster and
-    // cache it unlocked.
+    // We have an at-raster image which has reached zero refs. If it won't fit
+    // in our cache, delete the image to allow it to fit.
+    if (image_data->upload.image() && !CanFitInCache(image_data->size)) {
+      images_pending_deletion_.push_back(image_data->upload.image());
+      image_data->upload.SetImage(nullptr);
+    }
+
+    // We now have an at-raster image which will fit in our cache. Convert it
+    // to not-at-raster.
     image_data->is_at_raster = false;
-    DCHECK(!image_data->upload.budgeted);
+    if (image_data->upload.image()) {
+      bytes_used_ += image_data->size;
+      image_data->upload.budgeted = true;
+    }
   }
 
-  // If we have image that should be budgeted, but isn't, budget it now.
+  // If we have image refs on a non-at-raster image, it must be budgeted, as it
+  // is either uploaded or pending upload.
   if (image_data->upload.ref_count > 0 && !image_data->upload.budgeted &&
       !image_data->is_at_raster) {
     // We should only be taking non-at-raster refs on images that fit in cache.
     DCHECK(CanFitInWorkingSet(image_data->size));
 
-    working_set_bytes_ += image_data->size;
+    bytes_used_ += image_data->size;
     image_data->upload.budgeted = true;
   }
 
   // If we have no image refs on an image, it should only be budgeted if it has
   // an uploaded image. If no image exists (upload was cancelled), we should
   // un-budget the image.
-  if (image_data->upload.ref_count == 0 && image_data->upload.budgeted) {
-    DCHECK_GE(working_set_bytes_, image_data->size);
-    working_set_bytes_ -= image_data->size;
+  if (image_data->upload.ref_count == 0 && image_data->upload.budgeted &&
+      !image_data->upload.image()) {
+    DCHECK_GE(bytes_used_, image_data->size);
+    bytes_used_ -= image_data->size;
     image_data->upload.budgeted = false;
   }
 
-  // We should unlock the decoded image memory for the image in two cases:
+  // We should unlock the discardable memory for the image in two cases:
   // 1) The image is no longer being used (no decode or upload refs).
   // 2) This is a GPU backed image that has already been uploaded (no decode
   //    refs, and we actually already have an image).
-  bool should_unlock_decode =
+  bool should_unlock_discardable =
       !has_any_refs ||
       (image_data->mode == DecodedDataMode::GPU &&
        !image_data->decode.ref_count && image_data->upload.image());
 
-  if (should_unlock_decode && image_data->decode.is_locked()) {
+  if (should_unlock_discardable && image_data->decode.is_locked()) {
     DCHECK(image_data->decode.data());
     image_data->decode.Unlock();
   }
@@ -1048,8 +1021,7 @@
 #if DCHECK_IS_ON()
   // Sanity check the above logic.
   if (image_data->upload.image()) {
-    DCHECK(image_data->is_at_raster || image_data->upload.budgeted ||
-           !image_data->upload.is_locked());
+    DCHECK(image_data->is_at_raster || image_data->upload.budgeted);
     if (image_data->mode == DecodedDataMode::CPU)
       DCHECK(image_data->decode.is_locked());
   } else {
@@ -1066,11 +1038,18 @@
                "GpuImageDecodeCache::EnsureCapacity");
   lock_.AssertAcquired();
 
-  if (CanFitInWorkingSet(required_size) && !ExceedsPreferredCount())
+  // While we only care whether |required_size| fits in our working set, we
+  // also want to keep our cache under-budget if possible. Working set size
+  // will always match or exceed cache size, so keeping the cache under budget
+  // may be impossible.
+  if (CanFitInCache(required_size) && !ExceedsPreferredCount())
     return true;
 
   // While we are over memory or preferred item capacity, we iterate through
-  // our set of cached image data in LRU order, removing unreferenced images.
+  // our set of cached image data in LRU order. For each image, we can do two
+  // things: 1) We can free the uploaded image, reducing the memory usage of
+  // the cache and 2) we can remove the entry entirely, reducing the count of
+  // elements in the cache.
   for (auto it = persistent_cache_.rbegin(); it != persistent_cache_.rend();) {
     if (it->second->decode.ref_count != 0 ||
         it->second->upload.ref_count != 0) {
@@ -1085,23 +1064,52 @@
     // upload.
     DCHECK(!it->second->upload.budgeted || it->second->upload.image());
 
-    // Free the uploaded image if it exists.
-    if (it->second->upload.image())
-      DeleteImage(it->second.get());
+    // Free the uploaded image if possible.
+    if (it->second->upload.image()) {
+      DCHECK(it->second->upload.budgeted);
+      DCHECK_GE(bytes_used_, it->second->size);
+      bytes_used_ -= it->second->size;
+      images_pending_deletion_.push_back(it->second->upload.image());
+      it->second->upload.SetImage(nullptr);
+      it->second->upload.budgeted = false;
+    }
 
-    it = persistent_cache_.Erase(it);
+    // Free the entire entry if necessary.
+    if (ExceedsPreferredCount()) {
+      it = persistent_cache_.Erase(it);
+    } else {
+      ++it;
+    }
 
-    if (CanFitInWorkingSet(required_size) && !ExceedsPreferredCount())
+    if (CanFitInCache(required_size) && !ExceedsPreferredCount())
       return true;
   }
 
-  return false;
+  return CanFitInWorkingSet(required_size);
+}
+
+bool GpuImageDecodeCache::CanFitInCache(size_t size) const {
+  lock_.AssertAcquired();
+
+  size_t bytes_limit;
+  if (memory_state_ == base::MemoryState::NORMAL) {
+    bytes_limit = cached_bytes_limit_;
+  } else if (memory_state_ == base::MemoryState::THROTTLED) {
+    bytes_limit = cached_bytes_limit_ / kThrottledCacheSizeReductionFactor;
+  } else {
+    DCHECK_EQ(base::MemoryState::SUSPENDED, memory_state_);
+    bytes_limit = kSuspendedOrInvisibleMaxGpuImageBytes;
+  }
+
+  base::CheckedNumeric<uint32_t> new_size(bytes_used_);
+  new_size += size;
+  return new_size.IsValid() && new_size.ValueOrDie() <= bytes_limit;
 }
 
 bool GpuImageDecodeCache::CanFitInWorkingSet(size_t size) const {
   lock_.AssertAcquired();
 
-  base::CheckedNumeric<uint32_t> new_size(working_set_bytes_);
+  base::CheckedNumeric<uint32_t> new_size(bytes_used_);
   new_size += size;
   return new_size.IsValid() && new_size.ValueOrDie() <= max_working_set_bytes_;
 }
@@ -1110,9 +1118,7 @@
   lock_.AssertAcquired();
 
   size_t items_limit;
-  if (aggressively_freeing_resources_) {
-    items_limit = kSuspendedMaxItemsInCache;
-  } else if (memory_state_ == base::MemoryState::NORMAL) {
+  if (memory_state_ == base::MemoryState::NORMAL) {
     items_limit = kNormalMaxItemsInCache;
   } else if (memory_state_ == base::MemoryState::THROTTLED) {
     items_limit = kThrottledMaxItemsInCache;
@@ -1136,8 +1142,7 @@
     return;
   }
 
-  if (image_data->upload.image() &&
-      TryLockImage(HaveContextLock::kNo, draw_image, image_data)) {
+  if (image_data->upload.image()) {
     // We already have an uploaded image, no reason to decode.
     return;
   }
@@ -1215,18 +1220,12 @@
   context_->GetLock()->AssertAcquired();
   lock_.AssertAcquired();
 
-  // We are about to upload a new image and are holding the context lock.
-  // Ensure that any images which have been marked for deletion are actually
-  // cleaned up so we don't exceed our memory limit during this upload.
-  RunPendingContextThreadOperations();
-
   if (image_data->decode.decode_failure) {
     // We were unnable to decode this image. Don't try to upload.
     return;
   }
 
-  if (image_data->upload.image() &&
-      TryLockImage(HaveContextLock::kYes, draw_image, image_data)) {
+  if (image_data->upload.image()) {
     // Someone has uploaded this image before us (at raster).
     return;
   }
@@ -1236,6 +1235,11 @@
   DCHECK_GT(image_data->decode.ref_count, 0u);
   DCHECK_GT(image_data->upload.ref_count, 0u);
 
+  // We are about to upload a new image and are holding the context lock.
+  // Ensure that any images which have been marked for deletion are actually
+  // cleaned up so we don't exceed our memory limit during this upload.
+  DeletePendingImages();
+
   sk_sp<SkImage> uploaded_image;
   {
     base::AutoUnlock unlock(lock_);
@@ -1261,10 +1265,8 @@
 
   // TODO(crbug.com/740737): uploaded_image is sometimes null for reasons that
   // need investigation.
-  if (!uploaded_image)
-    return;
 
-  if (draw_image.target_color_space().IsValid()) {
+  if (uploaded_image && draw_image.target_color_space().IsValid()) {
     TRACE_EVENT0("cc", "GpuImageDecodeCache::UploadImage - color conversion");
     uploaded_image = uploaded_image->makeColorSpace(
         draw_image.target_color_space().ToSkColorSpace(),
@@ -1273,18 +1275,8 @@
 
   // At-raster may have decoded this while we were unlocked. If so, ignore our
   // result.
-  if (!image_data->upload.image()) {
+  if (!image_data->upload.image())
     image_data->upload.SetImage(std::move(uploaded_image));
-
-    // If we have a new GPU-backed image, initialize it for use in the GPU
-    // discardable system.
-    if (image_data->mode == DecodedDataMode::GPU) {
-      // Notify the discardable system of this image so it will count against
-      // budgets.
-      context_->ContextGL()->InitializeDiscardableTextureCHROMIUM(
-          image_data->upload.gl_id());
-    }
-  }
 }
 
 scoped_refptr<GpuImageDecodeCache::ImageData>
@@ -1318,53 +1310,9 @@
       new ImageData(mode, data_size, draw_image.target_color_space(), params));
 }
 
-void GpuImageDecodeCache::DeleteImage(ImageData* image_data) {
-  if (image_data->mode == DecodedDataMode::GPU && image_data->upload.image()) {
-    DCHECK(!image_data->upload.is_locked());
-    images_pending_deletion_.push_back(image_data->upload.image());
-  }
-  image_data->upload.ResetImage();
-}
-
-void GpuImageDecodeCache::UnlockImage(ImageData* image_data) {
-  DCHECK_EQ(DecodedDataMode::GPU, image_data->mode);
-  images_pending_unlock_.push_back(image_data->upload.image().get());
-  image_data->upload.OnUnlock();
-}
-
-// We always run pending operations in the following order:
-//   Lock > Unlock > Delete
-// This ensures that:
-//   a) We never fully unlock an image that's pending lock (lock before unlock)
-//   b) We never delete an image that has pending locks/unlocks.
-// As this can be run at-raster, to unlock/delete an image that was just used,
-// we need to call GlIdFromSkImage, which flushes pending IO on the image,
-// rather than just using a cached GL ID.
-void GpuImageDecodeCache::RunPendingContextThreadOperations() {
+void GpuImageDecodeCache::DeletePendingImages() {
   context_->GetLock()->AssertAcquired();
   lock_.AssertAcquired();
-
-  for (auto* image : images_pending_complete_lock_) {
-    context_->ContextSupport()->CompleteLockDiscardableTexureOnContextThread(
-        GlIdFromSkImage(image));
-  }
-  images_pending_complete_lock_.clear();
-
-  for (auto* image : images_pending_unlock_) {
-    context_->ContextGL()->UnlockDiscardableTextureCHROMIUM(
-        GlIdFromSkImage(image));
-  }
-  images_pending_unlock_.clear();
-
-  for (auto& image : images_pending_deletion_) {
-    // We *always* abandon images, to prevent Skia from caching/re-using them.
-    // TODO(ericrk): Handle this in a better way. crbug.com/735736
-    uint32_t texture_id = GlIdFromSkImage(image.get());
-    if (context_->ContextGL()->LockDiscardableTextureCHROMIUM(texture_id)) {
-      context_->ContextGL()->DeleteTextures(1, &texture_id);
-    }
-    image->getTexture()->abandon();
-  }
   images_pending_deletion_.clear();
 }
 
@@ -1378,39 +1326,6 @@
                            draw_image.target_color_space().ToSkColorSpace());
 }
 
-bool GpuImageDecodeCache::TryLockImage(HaveContextLock have_context_lock,
-                                       const DrawImage& draw_image,
-                                       ImageData* data) {
-  if (data->upload.is_locked())
-    return true;
-
-  if (have_context_lock == HaveContextLock::kYes &&
-      context_->ContextGL()->LockDiscardableTextureCHROMIUM(
-          data->upload.gl_id())) {
-    // If |have_context_lock|, we can immediately lock the image and send
-    // the lock command to the GPU process.
-    data->upload.OnLock();
-    return true;
-  } else if (context_->ContextSupport()
-                 ->ThreadSafeShallowLockDiscardableTexture(
-                     data->upload.gl_id())) {
-    // If !|have_context_lock|, we use ThreadsafeShallowLockDiscardableTexture.
-    // This takes a reference to the image, ensuring that it can't be deleted
-    // by the service, but delays sending a lock command over the command
-    // buffer. This command must be sent before the image is used, but is now
-    // guaranteed to succeed. We will send this command via
-    // CompleteLockDiscardableTextureOnContextThread in UploadImageIfNecessary,
-    // which is guaranteed to run before the texture is used.
-    data->upload.OnLock();
-    images_pending_complete_lock_.push_back(data->upload.image().get());
-    return true;
-  }
-
-  // Couldn't lock, abandon the image.
-  DeleteImage(data);
-  return false;
-}
-
 // Tries to find an ImageData that can be used to draw the provided
 // |draw_image|. First looks for an exact entry in our |in_use_cache_|. If one
 // cannot be found, it looks for a compatible entry in our |persistent_cache_|.
diff --git a/cc/tiles/gpu_image_decode_cache.h b/cc/tiles/gpu_image_decode_cache.h
index c2cb8da..4a84583 100644
--- a/cc/tiles/gpu_image_decode_cache.h
+++ b/cc/tiles/gpu_image_decode_cache.h
@@ -17,7 +17,6 @@
 #include "cc/cc_export.h"
 #include "cc/tiles/image_decode_cache.h"
 #include "third_party/skia/include/core/SkRefCnt.h"
-#include "third_party/skia/include/gpu/gl/GrGLTypes.h"
 
 namespace viz {
 class ContextProvider;
@@ -40,13 +39,14 @@
 //
 // Decoded and Uploaded image data share a single cache entry. Depending on how
 // far we've progressed, this cache entry may contain CPU-side decoded data,
-// GPU-side uploaded data, or both. CPU-side decoded data is stored in software
-// discardable memory and is only locked for short periods of time (until the
-// upload completes). Uploaded GPU data is stored in GPU discardable memory and
-// remains locked for the duration of the raster tasks which depend on it.
+// GPU-side uploaded data, or both. Because CPU-side decoded data is stored in
+// discardable memory, and is only locked for short periods of time (until the
+// upload completes), this memory is not counted against our sized cache
+// limits. Uploaded GPU memory, being non-discardable, always counts against
+// our limits.
 //
-// In cases where the size of locked GPU images exceeds our working set limits,
-// we operate in an "at-raster" mode. In this mode, there are no decode/upload
+// In cases where the number of images needed exceeds our cache limits, we
+// operate in an "at-raster" mode. In this mode, there are no decode/upload
 // tasks, and images are decoded/uploaded as needed, immediately before being
 // used in raster. Cache entries for at-raster tasks are marked as such, which
 // prevents future tasks from taking a dependency on them and extending their
@@ -104,7 +104,8 @@
 
   explicit GpuImageDecodeCache(viz::ContextProvider* context,
                                SkColorType color_type,
-                               size_t max_working_set_bytes);
+                               size_t max_working_set_bytes,
+                               size_t max_cache_bytes);
   ~GpuImageDecodeCache() override;
 
   // ImageDecodeCache overrides.
@@ -146,14 +147,14 @@
   void OnImageUploadTaskCompleted(const DrawImage& image);
 
   // For testing only.
-  void SetWorkingSetLimitForTesting(size_t limit) {
+  void SetAllByteLimitsForTesting(size_t limit) {
+    cached_bytes_limit_ = limit;
     max_working_set_bytes_ = limit;
   }
-  size_t GetWorkingSetBytesForTesting() const { return working_set_bytes_; }
+  size_t GetBytesUsedForTesting() const { return bytes_used_; }
   size_t GetNumCacheEntriesForTesting() const {
     return persistent_cache_.size();
   }
-  size_t GetInUseCacheEntriesForTesting() const { return in_use_cache_.size(); }
   size_t GetDrawImageSizeForTesting(const DrawImage& image);
   void SetImageDecodingFailedForTesting(const DrawImage& image);
   bool DiscardableIsLockedForTesting(const DrawImage& image);
@@ -162,26 +163,30 @@
  private:
   enum class DecodedDataMode { GPU, CPU };
 
-  // Stores stats tracked by both DecodedImageData and UploadedImageData.
-  struct ImageDataBase {
-    ImageDataBase();
-    ~ImageDataBase();
+  // Stores the CPU-side decoded bits of an image and supporting fields.
+  struct DecodedImageData {
+    DecodedImageData();
+    ~DecodedImageData();
 
     bool is_locked() const { return is_locked_; }
-    void OnSetLockedData(bool out_of_raster);
-    void OnResetData();
-    void OnLock();
-    void OnUnlock();
-    void mark_used() {
-      DCHECK(is_locked_);
-      usage_stats_.used = true;
-    }
+    bool Lock();
+    void Unlock();
+    void SetLockedData(std::unique_ptr<base::DiscardableMemory> data,
+                       bool out_of_raster);
+    void ResetData();
+    base::DiscardableMemory* data() const { return data_.get(); }
+    void mark_used() { usage_stats_.used = true; }
 
     uint32_t ref_count = 0;
-    // If non-null, this is the pending task to populate this data.
+    // Set to true if the image was corrupt and could not be decoded.
+    bool decode_failure = false;
+    // If non-null, this is the pending decode task for this image.
     scoped_refptr<TileTask> task;
+    // Similar to above, but only is generated if there is no associated upload
+    // generated for this task (ie, this is an out-of-raster request for decode.
+    scoped_refptr<TileTask> stand_alone_task;
 
-   protected:
+   private:
     struct UsageStats {
       int lock_count = 1;
       bool used = false;
@@ -189,56 +194,45 @@
       bool first_lock_wasted = false;
     };
 
-    // Returns the usage state (see cc file) for histogram logging.
-    int UsageState() const;
+    void ReportUsageStats() const;
 
+    std::unique_ptr<base::DiscardableMemory> data_;
     bool is_locked_ = false;
     UsageStats usage_stats_;
   };
 
-  // Stores the CPU-side decoded bits of an image and supporting fields.
-  struct DecodedImageData : public ImageDataBase {
-    DecodedImageData();
-    ~DecodedImageData();
-
-    bool Lock();
-    void Unlock();
-
-    void SetLockedData(std::unique_ptr<base::DiscardableMemory> data,
-                       bool out_of_raster);
-    void ResetData();
-    base::DiscardableMemory* data() const { return data_.get(); }
-
-    bool decode_failure = false;
-    // Similar to |task|, but only is generated if there is no associated upload
-    // generated for this task (ie, this is an out-of-raster request for decode.
-    scoped_refptr<TileTask> stand_alone_task;
-
-   private:
-    void ReportUsageStats() const;
-
-    std::unique_ptr<base::DiscardableMemory> data_;
-  };
-
   // Stores the GPU-side image and supporting fields.
-  struct UploadedImageData : public ImageDataBase {
+  struct UploadedImageData {
     UploadedImageData();
     ~UploadedImageData();
 
     void SetImage(sk_sp<SkImage> image);
-    void ResetImage();
     const sk_sp<SkImage>& image() const { return image_; }
-    GrGLuint gl_id() const { return gl_id_; }
 
-    // True if the image is counting against our working set limits.
+    void mark_used() { usage_stats_.used = true; }
+    void notify_ref_reached_zero() {
+      if (++usage_stats_.ref_reached_zero_count == 1)
+        usage_stats_.first_ref_wasted = !usage_stats_.used;
+    }
+
+    // True if the image is counting against our memory limits.
     bool budgeted = false;
+    uint32_t ref_count = 0;
+    // If non-null, this is the pending upload task for this image.
+    scoped_refptr<TileTask> task;
 
    private:
+    struct UsageStats {
+      bool used = false;
+      bool first_ref_wasted = false;
+      int ref_reached_zero_count = 0;
+    };
+
     void ReportUsageStats() const;
 
     // May be null if image not yet uploaded / prepared.
     sk_sp<SkImage> image_;
-    GrGLuint gl_id_ = 0;
+    UsageStats usage_stats_;
   };
 
   struct ImageData : public base::RefCountedThreadSafe<ImageData> {
@@ -328,6 +322,7 @@
   // freeing unreferenced cache entries to make room.
   bool EnsureCapacity(size_t required_size);
   bool CanFitInWorkingSet(size_t size) const;
+  bool CanFitInCache(size_t size) const;
   bool ExceedsPreferredCount() const;
 
   void DecodeImageIfNecessary(const DrawImage& draw_image,
@@ -348,31 +343,10 @@
   bool IsCompatible(const ImageData* image_data,
                     const DrawImage& draw_image) const;
 
-  // Helper to delete an image and remove it from the cache. Ensures that
-  // the image is unlocked and Skia cleanup is handled on the right thread.
-  void DeleteImage(ImageData* image_data);
-
-  // Helper to unlock an image, indicating that it is no longer actively
-  // being used. An image must be locked via TryLockImage below before it
-  // can be used again.
-  void UnlockImage(ImageData* image_data);
-
-  // Attempts to lock an image for use. If locking fails (the image is deleted
-  // on the service side), this function will delete the local reference to the
-  // image and return false.
-  enum class HaveContextLock { kYes, kNo };
-  bool TryLockImage(HaveContextLock have_context_lock,
-                    const DrawImage& draw_image,
-                    ImageData* data);
-
-  // Requires that the |context_| lock be held when calling.
+  // The following two functions also require the |context_| lock to be held.
   void UploadImageIfNecessary(const DrawImage& draw_image,
                               ImageData* image_data);
-
-  // Runs pending operations that required the |context_| lock to be held, but
-  // were queued up during a time when the |context_| lock was unavailable.
-  // These including deleting, unlocking, and locking textures.
-  void RunPendingContextThreadOperations();
+  void DeletePendingImages();
 
   const SkColorType color_type_;
   viz::ContextProvider* context_;
@@ -396,15 +370,15 @@
       std::unordered_map<InUseCacheKey, InUseCacheEntry, InUseCacheKeyHash>;
   InUseCache in_use_cache_;
 
-  size_t max_working_set_bytes_ = 0;
-  size_t working_set_bytes_ = 0;
+  size_t max_working_set_bytes_;
+  const size_t normal_max_cache_bytes_;
+  size_t cached_bytes_limit_ = normal_max_cache_bytes_;
+  size_t bytes_used_ = 0;
   base::MemoryState memory_state_ = base::MemoryState::NORMAL;
-  bool aggressively_freeing_resources_ = false;
 
-  // We can't modify GPU backed SkImages without holding the context lock, so
-  // we queue up operations to run the next time the lock is held.
-  std::vector<SkImage*> images_pending_complete_lock_;
-  std::vector<SkImage*> images_pending_unlock_;
+  // We can't release GPU backed SkImages without holding the context lock,
+  // so we add them to this list and defer deletion until the next time the lock
+  // is held.
   std::vector<sk_sp<SkImage>> images_pending_deletion_;
 };
 
diff --git a/cc/tiles/gpu_image_decode_cache_unittest.cc b/cc/tiles/gpu_image_decode_cache_unittest.cc
index 511d80c..e8ad345 100644
--- a/cc/tiles/gpu_image_decode_cache_unittest.cc
+++ b/cc/tiles/gpu_image_decode_cache_unittest.cc
@@ -4,14 +4,11 @@
 
 #include "cc/tiles/gpu_image_decode_cache.h"
 
-#include "base/memory/ptr_util.h"
 #include "cc/paint/draw_image.h"
 #include "cc/paint/paint_image_builder.h"
 #include "cc/test/skia_common.h"
 #include "cc/test/test_context_provider.h"
-#include "cc/test/test_gles2_interface.h"
 #include "cc/test/test_tile_task_runner.h"
-#include "cc/test/test_web_graphics_context_3d.h"
 #include "testing/gtest/include/gtest/gtest.h"
 #include "third_party/skia/include/core/SkImageGenerator.h"
 #include "third_party/skia/include/core/SkRefCnt.h"
@@ -19,173 +16,19 @@
 namespace cc {
 namespace {
 
-class FakeDiscardableManager {
- public:
-  void Initialize(GLuint texture_id) {
-    EXPECT_EQ(textures_.end(), textures_.find(texture_id));
-    textures_[texture_id] = kHandleLockedStart;
-    live_textures_count_++;
-  }
-  void Unlock(GLuint texture_id) {
-    EXPECT_NE(textures_.end(), textures_.find(texture_id));
-    EXPECT_GE(textures_[texture_id], kHandleLockedStart);
-    textures_[texture_id]--;
-  }
-  bool Lock(GLuint texture_id) {
-    EnforceLimit();
-
-    EXPECT_NE(textures_.end(), textures_.find(texture_id));
-    if (textures_[texture_id] >= kHandleUnlocked) {
-      textures_[texture_id]++;
-      return true;
-    }
-    return false;
-  }
-
-  void DeleteImage(GLuint texture_id) {
-    EXPECT_NE(textures_.end(), textures_.find(texture_id));
-    EXPECT_EQ(textures_[texture_id], kHandleUnlocked);
-    textures_[texture_id] = kHandleDeleted;
-    live_textures_count_--;
-  }
-
-  void set_cached_textures_limit(size_t limit) {
-    cached_textures_limit_ = limit;
-  }
-
- private:
-  void EnforceLimit() {
-    for (auto it = textures_.begin(); it != textures_.end(); ++it) {
-      if (live_textures_count_ <= cached_textures_limit_)
-        return;
-      if (it->second != kHandleUnlocked)
-        continue;
-
-      it->second = kHandleDeleted;
-      live_textures_count_--;
-    }
-  }
-
-  const int32_t kHandleDeleted = 0;
-  const int32_t kHandleUnlocked = 1;
-  const int32_t kHandleLockedStart = 2;
-
-  std::map<GLuint, int32_t> textures_;
-  size_t live_textures_count_ = 0;
-  size_t cached_textures_limit_ = std::numeric_limits<size_t>::max();
-};
-
-class FakeDiscardableGLES2Interface : public TestGLES2Interface,
-                                      public TestContextSupport {
- public:
-  explicit FakeDiscardableGLES2Interface(
-      FakeDiscardableManager* discardable_manager)
-      : extension_string_("GL_EXT_texture_format_BGRA8888 GL_OES_rgb8_rgba8"),
-        discardable_manager_(discardable_manager) {}
-
-  void InitializeDiscardableTextureCHROMIUM(GLuint texture_id) override {
-    discardable_manager_->Initialize(texture_id);
-  }
-  void UnlockDiscardableTextureCHROMIUM(GLuint texture_id) override {
-    discardable_manager_->Unlock(texture_id);
-  }
-  bool LockDiscardableTextureCHROMIUM(GLuint texture_id) override {
-    return discardable_manager_->Lock(texture_id);
-  }
-
-  void DeleteTextures(GLsizei n, const GLuint* textures) override {}
-
-  bool ThreadSafeShallowLockDiscardableTexture(uint32_t texture_id) override {
-    return discardable_manager_->Lock(texture_id);
-  }
-  void CompleteLockDiscardableTexureOnContextThread(
-      uint32_t texture_id) override {}
-
-  // TestGLES2Interface:
-  const GLubyte* GetString(GLenum name) override {
-    switch (name) {
-      case GL_EXTENSIONS:
-        return reinterpret_cast<const GLubyte*>(extension_string_.c_str());
-      case GL_VERSION:
-        return reinterpret_cast<const GLubyte*>("4.0 Null GL");
-      case GL_SHADING_LANGUAGE_VERSION:
-        return reinterpret_cast<const GLubyte*>("4.20.8 Null GLSL");
-      case GL_VENDOR:
-        return reinterpret_cast<const GLubyte*>("Null Vendor");
-      case GL_RENDERER:
-        return reinterpret_cast<const GLubyte*>("The Null (Non-)Renderer");
-    }
-    return nullptr;
-  }
-  void GetIntegerv(GLenum name, GLint* params) override {
-    switch (name) {
-      case GL_MAX_COMBINED_TEXTURE_IMAGE_UNITS:
-        *params = 8;
-        return;
-      case GL_MAX_RENDERBUFFER_SIZE:
-        *params = 2048;
-        return;
-      default:
-        break;
-    }
-    TestGLES2Interface::GetIntegerv(name, params);
-  }
-
- private:
-  const std::string extension_string_;
-  FakeDiscardableManager* discardable_manager_;
-};
-
-class DiscardableTextureMockContextProvider : public TestContextProvider {
- public:
-  static scoped_refptr<DiscardableTextureMockContextProvider> Create(
-      FakeDiscardableManager* discardable_manager) {
-    return new DiscardableTextureMockContextProvider(
-        base::MakeUnique<FakeDiscardableGLES2Interface>(discardable_manager),
-        base::MakeUnique<FakeDiscardableGLES2Interface>(discardable_manager),
-        TestWebGraphicsContext3D::Create());
-  }
-
- private:
-  ~DiscardableTextureMockContextProvider() override {}
-  DiscardableTextureMockContextProvider(
-      std::unique_ptr<TestContextSupport> support,
-      std::unique_ptr<TestGLES2Interface> gl,
-      std::unique_ptr<TestWebGraphicsContext3D> context)
-      : TestContextProvider(std::move(support),
-                            std::move(gl),
-                            std::move(context)) {}
-};
-
 gfx::ColorSpace DefaultColorSpace() {
   return gfx::ColorSpace::CreateSRGB();
 }
 
 size_t kGpuMemoryLimitBytes = 96 * 1024 * 1024;
-
-class GpuImageDecodeCacheTest : public ::testing::TestWithParam<SkColorType> {
+class TestGpuImageDecodeCache : public GpuImageDecodeCache {
  public:
-  void SetUp() override {
-    context_provider_ =
-        DiscardableTextureMockContextProvider::Create(&discardable_manager_);
-    context_provider_->BindToCurrentThread();
-  }
-  std::unique_ptr<GpuImageDecodeCache> CreateCache() {
-    return base::WrapUnique(new GpuImageDecodeCache(
-        context_provider_.get(), GetParam(), kGpuMemoryLimitBytes));
-  }
-
-  DiscardableTextureMockContextProvider* context_provider() {
-    return context_provider_.get();
-  }
-
-  void SetDiscardableTexturesLimit(size_t limit) {
-    discardable_manager_.set_cached_textures_limit(limit);
-  }
-
- private:
-  FakeDiscardableManager discardable_manager_;
-  scoped_refptr<DiscardableTextureMockContextProvider> context_provider_;
+  explicit TestGpuImageDecodeCache(viz::ContextProvider* context,
+                                   SkColorType color_type)
+      : GpuImageDecodeCache(context,
+                            color_type,
+                            kGpuMemoryLimitBytes,
+                            kGpuMemoryLimitBytes) {}
 };
 
 SkMatrix CreateMatrix(const SkSize& scale, bool is_decomposable) {
@@ -200,8 +43,12 @@
   return matrix;
 }
 
+using GpuImageDecodeCacheTest = ::testing::TestWithParam<SkColorType>;
+
 TEST_P(GpuImageDecodeCacheTest, GetTaskForImageSameImage) {
-  auto cache = CreateCache();
+  auto context_provider = TestContextProvider::Create();
+  context_provider->BindToCurrentThread();
+  TestGpuImageDecodeCache cache(context_provider.get(), GetParam());
   PaintImage image = CreateDiscardablePaintImage(gfx::Size(100, 100));
   bool is_decomposable = true;
   SkFilterQuality quality = kHigh_SkFilterQuality;
@@ -211,7 +58,7 @@
                        CreateMatrix(SkSize::Make(1.5f, 1.5f), is_decomposable),
                        DefaultColorSpace());
   scoped_refptr<TileTask> task;
-  bool need_unref = cache->GetTaskForImageAndRef(
+  bool need_unref = cache.GetTaskForImageAndRef(
       draw_image, ImageDecodeCache::TracingInfo(), &task);
   EXPECT_TRUE(need_unref);
   EXPECT_TRUE(task);
@@ -221,7 +68,7 @@
       CreateMatrix(SkSize::Make(1.5f, 1.5f), is_decomposable),
       DefaultColorSpace());
   scoped_refptr<TileTask> another_task;
-  need_unref = cache->GetTaskForImageAndRef(
+  need_unref = cache.GetTaskForImageAndRef(
       another_draw_image, ImageDecodeCache::TracingInfo(), &another_task);
   EXPECT_TRUE(need_unref);
   EXPECT_TRUE(task.get() == another_task.get());
@@ -229,12 +76,14 @@
   TestTileTaskRunner::ProcessTask(task->dependencies()[0].get());
   TestTileTaskRunner::ProcessTask(task.get());
 
-  cache->UnrefImage(draw_image);
-  cache->UnrefImage(draw_image);
+  cache.UnrefImage(draw_image);
+  cache.UnrefImage(draw_image);
 }
 
 TEST_P(GpuImageDecodeCacheTest, GetTaskForImageSmallerScale) {
-  auto cache = CreateCache();
+  auto context_provider = TestContextProvider::Create();
+  context_provider->BindToCurrentThread();
+  TestGpuImageDecodeCache cache(context_provider.get(), GetParam());
   PaintImage image = CreateDiscardablePaintImage(gfx::Size(100, 100));
   bool is_decomposable = true;
   SkFilterQuality quality = kHigh_SkFilterQuality;
@@ -244,7 +93,7 @@
                        CreateMatrix(SkSize::Make(1.5f, 1.5f), is_decomposable),
                        DefaultColorSpace());
   scoped_refptr<TileTask> task;
-  bool need_unref = cache->GetTaskForImageAndRef(
+  bool need_unref = cache.GetTaskForImageAndRef(
       draw_image, ImageDecodeCache::TracingInfo(), &task);
   EXPECT_TRUE(need_unref);
   EXPECT_TRUE(task);
@@ -254,7 +103,7 @@
       CreateMatrix(SkSize::Make(0.5f, 0.5f), is_decomposable),
       DefaultColorSpace());
   scoped_refptr<TileTask> another_task;
-  need_unref = cache->GetTaskForImageAndRef(
+  need_unref = cache.GetTaskForImageAndRef(
       another_draw_image, ImageDecodeCache::TracingInfo(), &another_task);
   EXPECT_TRUE(need_unref);
   EXPECT_TRUE(task.get() == another_task.get());
@@ -262,12 +111,14 @@
   TestTileTaskRunner::ProcessTask(task->dependencies()[0].get());
   TestTileTaskRunner::ProcessTask(task.get());
 
-  cache->UnrefImage(draw_image);
-  cache->UnrefImage(another_draw_image);
+  cache.UnrefImage(draw_image);
+  cache.UnrefImage(another_draw_image);
 }
 
 TEST_P(GpuImageDecodeCacheTest, GetTaskForImageLowerQuality) {
-  auto cache = CreateCache();
+  auto context_provider = TestContextProvider::Create();
+  context_provider->BindToCurrentThread();
+  TestGpuImageDecodeCache cache(context_provider.get(), GetParam());
   PaintImage image = CreateDiscardablePaintImage(gfx::Size(100, 100));
   bool is_decomposable = true;
   SkMatrix matrix = CreateMatrix(SkSize::Make(0.4f, 0.4f), is_decomposable);
@@ -275,7 +126,7 @@
   DrawImage draw_image(image, SkIRect::MakeWH(image.width(), image.height()),
                        kHigh_SkFilterQuality, matrix, DefaultColorSpace());
   scoped_refptr<TileTask> task;
-  bool need_unref = cache->GetTaskForImageAndRef(
+  bool need_unref = cache.GetTaskForImageAndRef(
       draw_image, ImageDecodeCache::TracingInfo(), &task);
   EXPECT_TRUE(need_unref);
   EXPECT_TRUE(task);
@@ -284,7 +135,7 @@
       image, SkIRect::MakeWH(image.width(), image.height()),
       kLow_SkFilterQuality, matrix, DefaultColorSpace());
   scoped_refptr<TileTask> another_task;
-  need_unref = cache->GetTaskForImageAndRef(
+  need_unref = cache.GetTaskForImageAndRef(
       another_draw_image, ImageDecodeCache::TracingInfo(), &another_task);
   EXPECT_TRUE(need_unref);
   EXPECT_TRUE(task.get() == another_task.get());
@@ -292,12 +143,14 @@
   TestTileTaskRunner::ProcessTask(task->dependencies()[0].get());
   TestTileTaskRunner::ProcessTask(task.get());
 
-  cache->UnrefImage(draw_image);
-  cache->UnrefImage(another_draw_image);
+  cache.UnrefImage(draw_image);
+  cache.UnrefImage(another_draw_image);
 }
 
 TEST_P(GpuImageDecodeCacheTest, GetTaskForImageDifferentImage) {
-  auto cache = CreateCache();
+  auto context_provider = TestContextProvider::Create();
+  context_provider->BindToCurrentThread();
+  TestGpuImageDecodeCache cache(context_provider.get(), GetParam());
   bool is_decomposable = true;
   SkFilterQuality quality = kHigh_SkFilterQuality;
 
@@ -307,7 +160,7 @@
       quality, CreateMatrix(SkSize::Make(0.5f, 0.5f), is_decomposable),
       DefaultColorSpace());
   scoped_refptr<TileTask> first_task;
-  bool need_unref = cache->GetTaskForImageAndRef(
+  bool need_unref = cache.GetTaskForImageAndRef(
       first_draw_image, ImageDecodeCache::TracingInfo(), &first_task);
   EXPECT_TRUE(need_unref);
   EXPECT_TRUE(first_task);
@@ -319,7 +172,7 @@
       CreateMatrix(SkSize::Make(0.25f, 0.25f), is_decomposable),
       DefaultColorSpace());
   scoped_refptr<TileTask> second_task;
-  need_unref = cache->GetTaskForImageAndRef(
+  need_unref = cache.GetTaskForImageAndRef(
       second_draw_image, ImageDecodeCache::TracingInfo(), &second_task);
   EXPECT_TRUE(need_unref);
   EXPECT_TRUE(second_task);
@@ -330,12 +183,14 @@
   TestTileTaskRunner::ProcessTask(second_task->dependencies()[0].get());
   TestTileTaskRunner::ProcessTask(second_task.get());
 
-  cache->UnrefImage(first_draw_image);
-  cache->UnrefImage(second_draw_image);
+  cache.UnrefImage(first_draw_image);
+  cache.UnrefImage(second_draw_image);
 }
 
 TEST_P(GpuImageDecodeCacheTest, GetTaskForImageLargerScale) {
-  auto cache = CreateCache();
+  auto context_provider = TestContextProvider::Create();
+  context_provider->BindToCurrentThread();
+  TestGpuImageDecodeCache cache(context_provider.get(), GetParam());
   bool is_decomposable = true;
   SkFilterQuality quality = kHigh_SkFilterQuality;
 
@@ -345,7 +200,7 @@
       quality, CreateMatrix(SkSize::Make(0.5f, 0.5f), is_decomposable),
       DefaultColorSpace());
   scoped_refptr<TileTask> first_task;
-  bool need_unref = cache->GetTaskForImageAndRef(
+  bool need_unref = cache.GetTaskForImageAndRef(
       first_draw_image, ImageDecodeCache::TracingInfo(), &first_task);
   EXPECT_TRUE(need_unref);
   EXPECT_TRUE(first_task);
@@ -353,14 +208,14 @@
   TestTileTaskRunner::ProcessTask(first_task->dependencies()[0].get());
   TestTileTaskRunner::ProcessTask(first_task.get());
 
-  cache->UnrefImage(first_draw_image);
+  cache.UnrefImage(first_draw_image);
 
   DrawImage second_draw_image(
       first_image, SkIRect::MakeWH(first_image.width(), first_image.height()),
       quality, CreateMatrix(SkSize::Make(1.0f, 1.0f), is_decomposable),
       DefaultColorSpace());
   scoped_refptr<TileTask> second_task;
-  need_unref = cache->GetTaskForImageAndRef(
+  need_unref = cache.GetTaskForImageAndRef(
       second_draw_image, ImageDecodeCache::TracingInfo(), &second_task);
   EXPECT_TRUE(need_unref);
   EXPECT_TRUE(second_task);
@@ -371,7 +226,7 @@
       quality, CreateMatrix(SkSize::Make(0.5f, 0.5f), is_decomposable),
       DefaultColorSpace());
   scoped_refptr<TileTask> third_task;
-  need_unref = cache->GetTaskForImageAndRef(
+  need_unref = cache.GetTaskForImageAndRef(
       third_draw_image, ImageDecodeCache::TracingInfo(), &third_task);
   EXPECT_TRUE(need_unref);
   EXPECT_TRUE(third_task.get() == second_task.get());
@@ -379,12 +234,14 @@
   TestTileTaskRunner::ProcessTask(second_task->dependencies()[0].get());
   TestTileTaskRunner::ProcessTask(second_task.get());
 
-  cache->UnrefImage(second_draw_image);
-  cache->UnrefImage(third_draw_image);
+  cache.UnrefImage(second_draw_image);
+  cache.UnrefImage(third_draw_image);
 }
 
 TEST_P(GpuImageDecodeCacheTest, GetTaskForImageLargerScaleNoReuse) {
-  auto cache = CreateCache();
+  auto context_provider = TestContextProvider::Create();
+  context_provider->BindToCurrentThread();
+  TestGpuImageDecodeCache cache(context_provider.get(), GetParam());
   bool is_decomposable = true;
   SkFilterQuality quality = kHigh_SkFilterQuality;
 
@@ -394,7 +251,7 @@
       quality, CreateMatrix(SkSize::Make(0.5f, 0.5f), is_decomposable),
       DefaultColorSpace());
   scoped_refptr<TileTask> first_task;
-  bool need_unref = cache->GetTaskForImageAndRef(
+  bool need_unref = cache.GetTaskForImageAndRef(
       first_draw_image, ImageDecodeCache::TracingInfo(), &first_task);
   EXPECT_TRUE(need_unref);
   EXPECT_TRUE(first_task);
@@ -404,7 +261,7 @@
       quality, CreateMatrix(SkSize::Make(1.0f, 1.0f), is_decomposable),
       DefaultColorSpace());
   scoped_refptr<TileTask> second_task;
-  need_unref = cache->GetTaskForImageAndRef(
+  need_unref = cache.GetTaskForImageAndRef(
       second_draw_image, ImageDecodeCache::TracingInfo(), &second_task);
   EXPECT_TRUE(need_unref);
   EXPECT_TRUE(second_task);
@@ -415,7 +272,7 @@
       quality, CreateMatrix(SkSize::Make(0.5f, 0.5f), is_decomposable),
       DefaultColorSpace());
   scoped_refptr<TileTask> third_task;
-  need_unref = cache->GetTaskForImageAndRef(
+  need_unref = cache.GetTaskForImageAndRef(
       third_draw_image, ImageDecodeCache::TracingInfo(), &third_task);
   EXPECT_TRUE(need_unref);
   EXPECT_TRUE(third_task.get() == first_task.get());
@@ -425,13 +282,15 @@
   TestTileTaskRunner::ProcessTask(second_task->dependencies()[0].get());
   TestTileTaskRunner::ProcessTask(second_task.get());
 
-  cache->UnrefImage(first_draw_image);
-  cache->UnrefImage(second_draw_image);
-  cache->UnrefImage(third_draw_image);
+  cache.UnrefImage(first_draw_image);
+  cache.UnrefImage(second_draw_image);
+  cache.UnrefImage(third_draw_image);
 }
 
 TEST_P(GpuImageDecodeCacheTest, GetTaskForImageHigherQuality) {
-  auto cache = CreateCache();
+  auto context_provider = TestContextProvider::Create();
+  context_provider->BindToCurrentThread();
+  TestGpuImageDecodeCache cache(context_provider.get(), GetParam());
   bool is_decomposable = true;
   SkMatrix matrix = CreateMatrix(SkSize::Make(0.4f, 0.4f), is_decomposable);
 
@@ -440,7 +299,7 @@
       first_image, SkIRect::MakeWH(first_image.width(), first_image.height()),
       kLow_SkFilterQuality, matrix, DefaultColorSpace());
   scoped_refptr<TileTask> first_task;
-  bool need_unref = cache->GetTaskForImageAndRef(
+  bool need_unref = cache.GetTaskForImageAndRef(
       first_draw_image, ImageDecodeCache::TracingInfo(), &first_task);
   EXPECT_TRUE(need_unref);
   EXPECT_TRUE(first_task);
@@ -448,13 +307,13 @@
   TestTileTaskRunner::ProcessTask(first_task->dependencies()[0].get());
   TestTileTaskRunner::ProcessTask(first_task.get());
 
-  cache->UnrefImage(first_draw_image);
+  cache.UnrefImage(first_draw_image);
 
   DrawImage second_draw_image(
       first_image, SkIRect::MakeWH(first_image.width(), first_image.height()),
       kHigh_SkFilterQuality, matrix, DefaultColorSpace());
   scoped_refptr<TileTask> second_task;
-  need_unref = cache->GetTaskForImageAndRef(
+  need_unref = cache.GetTaskForImageAndRef(
       second_draw_image, ImageDecodeCache::TracingInfo(), &second_task);
   EXPECT_TRUE(need_unref);
   EXPECT_TRUE(second_task);
@@ -463,11 +322,13 @@
   TestTileTaskRunner::ProcessTask(second_task->dependencies()[0].get());
   TestTileTaskRunner::ProcessTask(second_task.get());
 
-  cache->UnrefImage(second_draw_image);
+  cache.UnrefImage(second_draw_image);
 }
 
 TEST_P(GpuImageDecodeCacheTest, GetTaskForImageAlreadyDecodedAndLocked) {
-  auto cache = CreateCache();
+  auto context_provider = TestContextProvider::Create();
+  context_provider->BindToCurrentThread();
+  TestGpuImageDecodeCache cache(context_provider.get(), GetParam());
   bool is_decomposable = true;
   SkFilterQuality quality = kHigh_SkFilterQuality;
 
@@ -477,7 +338,7 @@
                        CreateMatrix(SkSize::Make(0.5f, 0.5f), is_decomposable),
                        DefaultColorSpace());
   scoped_refptr<TileTask> task;
-  bool need_unref = cache->GetTaskForImageAndRef(
+  bool need_unref = cache.GetTaskForImageAndRef(
       draw_image, ImageDecodeCache::TracingInfo(), &task);
   EXPECT_TRUE(need_unref);
   EXPECT_TRUE(task);
@@ -495,7 +356,7 @@
   // Get the image again - we should have an upload task, but no dependent
   // decode task, as the decode was already locked.
   scoped_refptr<TileTask> another_task;
-  need_unref = cache->GetTaskForImageAndRef(
+  need_unref = cache.GetTaskForImageAndRef(
       draw_image, ImageDecodeCache::TracingInfo(), &another_task);
   EXPECT_TRUE(need_unref);
   EXPECT_TRUE(another_task);
@@ -506,12 +367,14 @@
   // Finally, complete the original decode task.
   TestTileTaskRunner::CompleteTask(task->dependencies()[0].get());
 
-  cache->UnrefImage(draw_image);
-  cache->UnrefImage(draw_image);
+  cache.UnrefImage(draw_image);
+  cache.UnrefImage(draw_image);
 }
 
 TEST_P(GpuImageDecodeCacheTest, GetTaskForImageAlreadyDecodedNotLocked) {
-  auto cache = CreateCache();
+  auto context_provider = TestContextProvider::Create();
+  context_provider->BindToCurrentThread();
+  TestGpuImageDecodeCache cache(context_provider.get(), GetParam());
   bool is_decomposable = true;
   SkFilterQuality quality = kHigh_SkFilterQuality;
 
@@ -521,7 +384,7 @@
                        CreateMatrix(SkSize::Make(0.5f, 0.5f), is_decomposable),
                        DefaultColorSpace());
   scoped_refptr<TileTask> task;
-  bool need_unref = cache->GetTaskForImageAndRef(
+  bool need_unref = cache.GetTaskForImageAndRef(
       draw_image, ImageDecodeCache::TracingInfo(), &task);
   EXPECT_TRUE(need_unref);
   EXPECT_TRUE(task);
@@ -536,12 +399,12 @@
   TestTileTaskRunner::CompleteTask(task.get());
 
   // Unref the image.
-  cache->UnrefImage(draw_image);
+  cache.UnrefImage(draw_image);
 
   // Get the image again - we should have an upload task and a dependent decode
   // task - this dependent task will typically just re-lock the image.
   scoped_refptr<TileTask> another_task;
-  need_unref = cache->GetTaskForImageAndRef(
+  need_unref = cache.GetTaskForImageAndRef(
       draw_image, ImageDecodeCache::TracingInfo(), &another_task);
   EXPECT_TRUE(need_unref);
   EXPECT_TRUE(another_task);
@@ -551,11 +414,13 @@
   TestTileTaskRunner::ProcessTask(another_task->dependencies()[0].get());
   TestTileTaskRunner::ProcessTask(another_task.get());
 
-  cache->UnrefImage(draw_image);
+  cache.UnrefImage(draw_image);
 }
 
 TEST_P(GpuImageDecodeCacheTest, GetTaskForImageAlreadyUploaded) {
-  auto cache = CreateCache();
+  auto context_provider = TestContextProvider::Create();
+  context_provider->BindToCurrentThread();
+  TestGpuImageDecodeCache cache(context_provider.get(), GetParam());
   bool is_decomposable = true;
   SkFilterQuality quality = kHigh_SkFilterQuality;
 
@@ -565,7 +430,7 @@
                        CreateMatrix(SkSize::Make(0.5f, 0.5f), is_decomposable),
                        DefaultColorSpace());
   scoped_refptr<TileTask> task;
-  bool need_unref = cache->GetTaskForImageAndRef(
+  bool need_unref = cache.GetTaskForImageAndRef(
       draw_image, ImageDecodeCache::TracingInfo(), &task);
   EXPECT_TRUE(need_unref);
   EXPECT_TRUE(task);
@@ -575,20 +440,23 @@
   TestTileTaskRunner::ProcessTask(task->dependencies()[0].get());
   TestTileTaskRunner::ScheduleTask(task.get());
   TestTileTaskRunner::RunTask(task.get());
-  TestTileTaskRunner::CompleteTask(task.get());
 
   scoped_refptr<TileTask> another_task;
-  need_unref = cache->GetTaskForImageAndRef(
+  need_unref = cache.GetTaskForImageAndRef(
       draw_image, ImageDecodeCache::TracingInfo(), &another_task);
   EXPECT_TRUE(need_unref);
   EXPECT_FALSE(another_task);
 
-  cache->UnrefImage(draw_image);
-  cache->UnrefImage(draw_image);
+  TestTileTaskRunner::CompleteTask(task.get());
+
+  cache.UnrefImage(draw_image);
+  cache.UnrefImage(draw_image);
 }
 
 TEST_P(GpuImageDecodeCacheTest, GetTaskForImageCanceledGetsNewTask) {
-  auto cache = CreateCache();
+  auto context_provider = TestContextProvider::Create();
+  context_provider->BindToCurrentThread();
+  TestGpuImageDecodeCache cache(context_provider.get(), GetParam());
   bool is_decomposable = true;
   SkFilterQuality quality = kHigh_SkFilterQuality;
 
@@ -598,7 +466,7 @@
                        CreateMatrix(SkSize::Make(0.5f, 0.5f), is_decomposable),
                        DefaultColorSpace());
   scoped_refptr<TileTask> task;
-  bool need_unref = cache->GetTaskForImageAndRef(
+  bool need_unref = cache.GetTaskForImageAndRef(
       draw_image, ImageDecodeCache::TracingInfo(), &task);
   EXPECT_TRUE(need_unref);
   EXPECT_TRUE(task);
@@ -606,7 +474,7 @@
   TestTileTaskRunner::ProcessTask(task->dependencies()[0].get());
 
   scoped_refptr<TileTask> another_task;
-  need_unref = cache->GetTaskForImageAndRef(
+  need_unref = cache.GetTaskForImageAndRef(
       draw_image, ImageDecodeCache::TracingInfo(), &another_task);
   EXPECT_TRUE(need_unref);
   EXPECT_TRUE(another_task.get() == task.get());
@@ -616,12 +484,12 @@
   TestTileTaskRunner::CompleteTask(task.get());
 
   // Fully cancel everything (so the raster would unref things).
-  cache->UnrefImage(draw_image);
-  cache->UnrefImage(draw_image);
+  cache.UnrefImage(draw_image);
+  cache.UnrefImage(draw_image);
 
   // Here a new task is created.
   scoped_refptr<TileTask> third_task;
-  need_unref = cache->GetTaskForImageAndRef(
+  need_unref = cache.GetTaskForImageAndRef(
       draw_image, ImageDecodeCache::TracingInfo(), &third_task);
   EXPECT_TRUE(need_unref);
   EXPECT_TRUE(third_task);
@@ -630,11 +498,13 @@
   TestTileTaskRunner::ProcessTask(third_task->dependencies()[0].get());
   TestTileTaskRunner::ProcessTask(third_task.get());
 
-  cache->UnrefImage(draw_image);
+  cache.UnrefImage(draw_image);
 }
 
 TEST_P(GpuImageDecodeCacheTest, GetTaskForImageCanceledWhileReffedGetsNewTask) {
-  auto cache = CreateCache();
+  auto context_provider = TestContextProvider::Create();
+  context_provider->BindToCurrentThread();
+  TestGpuImageDecodeCache cache(context_provider.get(), GetParam());
   bool is_decomposable = true;
   SkFilterQuality quality = kHigh_SkFilterQuality;
 
@@ -644,7 +514,7 @@
                        CreateMatrix(SkSize::Make(0.5f, 0.5f), is_decomposable),
                        DefaultColorSpace());
   scoped_refptr<TileTask> task;
-  bool need_unref = cache->GetTaskForImageAndRef(
+  bool need_unref = cache.GetTaskForImageAndRef(
       draw_image, ImageDecodeCache::TracingInfo(), &task);
   EXPECT_TRUE(need_unref);
   EXPECT_TRUE(task);
@@ -653,7 +523,7 @@
   TestTileTaskRunner::ProcessTask(task->dependencies()[0].get());
 
   scoped_refptr<TileTask> another_task;
-  need_unref = cache->GetTaskForImageAndRef(
+  need_unref = cache.GetTaskForImageAndRef(
       draw_image, ImageDecodeCache::TracingInfo(), &another_task);
   EXPECT_TRUE(need_unref);
   EXPECT_TRUE(another_task.get() == task.get());
@@ -663,13 +533,13 @@
   TestTileTaskRunner::CompleteTask(task.get());
 
   // 2 Unrefs, so that the decode is unlocked as well.
-  cache->UnrefImage(draw_image);
-  cache->UnrefImage(draw_image);
+  cache.UnrefImage(draw_image);
+  cache.UnrefImage(draw_image);
 
   // Note that here, everything is reffed, but a new task is created. This is
   // possible with repeated schedule/cancel operations.
   scoped_refptr<TileTask> third_task;
-  need_unref = cache->GetTaskForImageAndRef(
+  need_unref = cache.GetTaskForImageAndRef(
       draw_image, ImageDecodeCache::TracingInfo(), &third_task);
   EXPECT_TRUE(need_unref);
   EXPECT_TRUE(third_task);
@@ -680,11 +550,13 @@
   TestTileTaskRunner::ProcessTask(third_task.get());
 
   // Unref!
-  cache->UnrefImage(draw_image);
+  cache.UnrefImage(draw_image);
 }
 
 TEST_P(GpuImageDecodeCacheTest, NoTaskForImageAlreadyFailedDecoding) {
-  auto cache = CreateCache();
+  auto context_provider = TestContextProvider::Create();
+  context_provider->BindToCurrentThread();
+  TestGpuImageDecodeCache cache(context_provider.get(), GetParam());
   bool is_decomposable = true;
   SkFilterQuality quality = kHigh_SkFilterQuality;
 
@@ -694,7 +566,7 @@
                        CreateMatrix(SkSize::Make(0.5f, 0.5f), is_decomposable),
                        DefaultColorSpace());
   scoped_refptr<TileTask> task;
-  bool need_unref = cache->GetTaskForImageAndRef(
+  bool need_unref = cache.GetTaskForImageAndRef(
       draw_image, ImageDecodeCache::TracingInfo(), &task);
   EXPECT_TRUE(need_unref);
   EXPECT_TRUE(task);
@@ -704,19 +576,21 @@
   TestTileTaskRunner::CancelTask(task.get());
   TestTileTaskRunner::CompleteTask(task.get());
 
-  cache->SetImageDecodingFailedForTesting(draw_image);
+  cache.SetImageDecodingFailedForTesting(draw_image);
 
   scoped_refptr<TileTask> another_task;
-  need_unref = cache->GetTaskForImageAndRef(
+  need_unref = cache.GetTaskForImageAndRef(
       draw_image, ImageDecodeCache::TracingInfo(), &another_task);
   EXPECT_FALSE(need_unref);
   EXPECT_EQ(another_task.get(), nullptr);
 
-  cache->UnrefImage(draw_image);
+  cache.UnrefImage(draw_image);
 }
 
 TEST_P(GpuImageDecodeCacheTest, GetDecodedImageForDraw) {
-  auto cache = CreateCache();
+  auto context_provider = TestContextProvider::Create();
+  context_provider->BindToCurrentThread();
+  TestGpuImageDecodeCache cache(context_provider.get(), GetParam());
   bool is_decomposable = true;
   SkFilterQuality quality = kHigh_SkFilterQuality;
 
@@ -726,7 +600,7 @@
                        CreateMatrix(SkSize::Make(0.5f, 0.5f), is_decomposable),
                        DefaultColorSpace());
   scoped_refptr<TileTask> task;
-  bool need_unref = cache->GetTaskForImageAndRef(
+  bool need_unref = cache.GetTaskForImageAndRef(
       draw_image, ImageDecodeCache::TracingInfo(), &task);
   EXPECT_TRUE(need_unref);
   EXPECT_TRUE(task);
@@ -736,20 +610,23 @@
 
   // Must hold context lock before calling GetDecodedImageForDraw /
   // DrawWithImageFinished.
-  viz::ContextProvider::ScopedContextLock context_lock(context_provider());
+  viz::ContextProvider::ScopedContextLock context_lock(context_provider.get());
   DecodedDrawImage decoded_draw_image =
-      cache->GetDecodedImageForDraw(draw_image);
+      cache.GetDecodedImageForDraw(draw_image);
+  EXPECT_EQ(decoded_draw_image.filter_quality(), kMedium_SkFilterQuality);
   EXPECT_TRUE(decoded_draw_image.image());
   EXPECT_TRUE(decoded_draw_image.image()->isTextureBacked());
   EXPECT_FALSE(decoded_draw_image.is_at_raster_decode());
-  EXPECT_FALSE(cache->DiscardableIsLockedForTesting(draw_image));
+  EXPECT_FALSE(cache.DiscardableIsLockedForTesting(draw_image));
 
-  cache->DrawWithImageFinished(draw_image, decoded_draw_image);
-  cache->UnrefImage(draw_image);
+  cache.DrawWithImageFinished(draw_image, decoded_draw_image);
+  cache.UnrefImage(draw_image);
 }
 
 TEST_P(GpuImageDecodeCacheTest, GetLargeDecodedImageForDraw) {
-  auto cache = CreateCache();
+  auto context_provider = TestContextProvider::Create();
+  context_provider->BindToCurrentThread();
+  TestGpuImageDecodeCache cache(context_provider.get(), GetParam());
   bool is_decomposable = true;
   SkFilterQuality quality = kHigh_SkFilterQuality;
 
@@ -759,7 +636,7 @@
                        CreateMatrix(SkSize::Make(1.0f, 1.0f), is_decomposable),
                        DefaultColorSpace());
   scoped_refptr<TileTask> task;
-  bool need_unref = cache->GetTaskForImageAndRef(
+  bool need_unref = cache.GetTaskForImageAndRef(
       draw_image, ImageDecodeCache::TracingInfo(), &task);
   EXPECT_TRUE(need_unref);
   EXPECT_TRUE(task);
@@ -769,25 +646,28 @@
 
   // Must hold context lock before calling GetDecodedImageForDraw /
   // DrawWithImageFinished.
-  viz::ContextProvider::ScopedContextLock context_lock(context_provider());
+  viz::ContextProvider::ScopedContextLock context_lock(context_provider.get());
   DecodedDrawImage decoded_draw_image =
-      cache->GetDecodedImageForDraw(draw_image);
+      cache.GetDecodedImageForDraw(draw_image);
+  EXPECT_EQ(decoded_draw_image.filter_quality(), kMedium_SkFilterQuality);
   EXPECT_TRUE(decoded_draw_image.image());
   EXPECT_FALSE(decoded_draw_image.image()->isTextureBacked());
   EXPECT_FALSE(decoded_draw_image.is_at_raster_decode());
-  EXPECT_TRUE(cache->DiscardableIsLockedForTesting(draw_image));
+  EXPECT_TRUE(cache.DiscardableIsLockedForTesting(draw_image));
 
-  cache->DrawWithImageFinished(draw_image, decoded_draw_image);
-  cache->UnrefImage(draw_image);
-  EXPECT_FALSE(cache->DiscardableIsLockedForTesting(draw_image));
+  cache.DrawWithImageFinished(draw_image, decoded_draw_image);
+  cache.UnrefImage(draw_image);
+  EXPECT_FALSE(cache.DiscardableIsLockedForTesting(draw_image));
 }
 
 TEST_P(GpuImageDecodeCacheTest, GetDecodedImageForDrawAtRasterDecode) {
-  auto cache = CreateCache();
+  auto context_provider = TestContextProvider::Create();
+  context_provider->BindToCurrentThread();
+  TestGpuImageDecodeCache cache(context_provider.get(), GetParam());
   bool is_decomposable = true;
   SkFilterQuality quality = kHigh_SkFilterQuality;
 
-  cache->SetWorkingSetLimitForTesting(0);
+  cache.SetAllByteLimitsForTesting(0);
 
   PaintImage image = CreateDiscardablePaintImage(gfx::Size(100, 100));
   DrawImage draw_image(image, SkIRect::MakeWH(image.width(), image.height()),
@@ -796,26 +676,29 @@
                        DefaultColorSpace());
 
   scoped_refptr<TileTask> task;
-  bool need_unref = cache->GetTaskForImageAndRef(
+  bool need_unref = cache.GetTaskForImageAndRef(
       draw_image, ImageDecodeCache::TracingInfo(), &task);
   EXPECT_FALSE(need_unref);
   EXPECT_FALSE(task);
 
   // Must hold context lock before calling GetDecodedImageForDraw /
   // DrawWithImageFinished.
-  viz::ContextProvider::ScopedContextLock context_lock(context_provider());
+  viz::ContextProvider::ScopedContextLock context_lock(context_provider.get());
   DecodedDrawImage decoded_draw_image =
-      cache->GetDecodedImageForDraw(draw_image);
+      cache.GetDecodedImageForDraw(draw_image);
+  EXPECT_EQ(decoded_draw_image.filter_quality(), kMedium_SkFilterQuality);
   EXPECT_TRUE(decoded_draw_image.image());
   EXPECT_TRUE(decoded_draw_image.image()->isTextureBacked());
   EXPECT_TRUE(decoded_draw_image.is_at_raster_decode());
-  EXPECT_FALSE(cache->DiscardableIsLockedForTesting(draw_image));
+  EXPECT_FALSE(cache.DiscardableIsLockedForTesting(draw_image));
 
-  cache->DrawWithImageFinished(draw_image, decoded_draw_image);
+  cache.DrawWithImageFinished(draw_image, decoded_draw_image);
 }
 
 TEST_P(GpuImageDecodeCacheTest, GetDecodedImageForDrawLargerScale) {
-  auto cache = CreateCache();
+  auto context_provider = TestContextProvider::Create();
+  context_provider->BindToCurrentThread();
+  TestGpuImageDecodeCache cache(context_provider.get(), GetParam());
   bool is_decomposable = true;
   SkFilterQuality quality = kHigh_SkFilterQuality;
 
@@ -825,7 +708,7 @@
                        CreateMatrix(SkSize::Make(0.5f, 0.5f), is_decomposable),
                        DefaultColorSpace());
   scoped_refptr<TileTask> task;
-  bool need_unref = cache->GetTaskForImageAndRef(
+  bool need_unref = cache.GetTaskForImageAndRef(
       draw_image, ImageDecodeCache::TracingInfo(), &task);
   EXPECT_TRUE(need_unref);
   EXPECT_TRUE(task);
@@ -838,7 +721,7 @@
       CreateMatrix(SkSize::Make(1.5f, 1.5f), is_decomposable),
       DefaultColorSpace());
   scoped_refptr<TileTask> larger_task;
-  bool larger_need_unref = cache->GetTaskForImageAndRef(
+  bool larger_need_unref = cache.GetTaskForImageAndRef(
       larger_draw_image, ImageDecodeCache::TracingInfo(), &larger_task);
   EXPECT_TRUE(larger_need_unref);
   EXPECT_TRUE(larger_task);
@@ -848,31 +731,37 @@
 
   // Must hold context lock before calling GetDecodedImageForDraw /
   // DrawWithImageFinished.
-  viz::ContextProvider::ScopedContextLock context_lock(context_provider());
+  viz::ContextProvider::ScopedContextLock context_lock(context_provider.get());
   DecodedDrawImage decoded_draw_image =
-      cache->GetDecodedImageForDraw(draw_image);
+      cache.GetDecodedImageForDraw(draw_image);
+  // |draw_image| had a low filter quality, so expect that to be respected.
+  EXPECT_EQ(decoded_draw_image.filter_quality(), kLow_SkFilterQuality);
   EXPECT_TRUE(decoded_draw_image.image());
   EXPECT_TRUE(decoded_draw_image.image()->isTextureBacked());
   EXPECT_FALSE(decoded_draw_image.is_at_raster_decode());
-  EXPECT_FALSE(cache->DiscardableIsLockedForTesting(draw_image));
+  EXPECT_FALSE(cache.DiscardableIsLockedForTesting(draw_image));
 
   DecodedDrawImage larger_decoded_draw_image =
-      cache->GetDecodedImageForDraw(larger_draw_image);
+      cache.GetDecodedImageForDraw(larger_draw_image);
+  EXPECT_EQ(larger_decoded_draw_image.filter_quality(),
+            kMedium_SkFilterQuality);
   EXPECT_TRUE(larger_decoded_draw_image.image());
   EXPECT_TRUE(larger_decoded_draw_image.image()->isTextureBacked());
   EXPECT_FALSE(larger_decoded_draw_image.is_at_raster_decode());
-  EXPECT_FALSE(cache->DiscardableIsLockedForTesting(draw_image));
+  EXPECT_FALSE(cache.DiscardableIsLockedForTesting(draw_image));
 
   EXPECT_FALSE(decoded_draw_image.image() == larger_decoded_draw_image.image());
 
-  cache->DrawWithImageFinished(draw_image, decoded_draw_image);
-  cache->UnrefImage(draw_image);
-  cache->DrawWithImageFinished(larger_draw_image, larger_decoded_draw_image);
-  cache->UnrefImage(larger_draw_image);
+  cache.DrawWithImageFinished(draw_image, decoded_draw_image);
+  cache.UnrefImage(draw_image);
+  cache.DrawWithImageFinished(larger_draw_image, larger_decoded_draw_image);
+  cache.UnrefImage(larger_draw_image);
 }
 
 TEST_P(GpuImageDecodeCacheTest, GetDecodedImageForDrawHigherQuality) {
-  auto cache = CreateCache();
+  auto context_provider = TestContextProvider::Create();
+  context_provider->BindToCurrentThread();
+  TestGpuImageDecodeCache cache(context_provider.get(), GetParam());
   bool is_decomposable = true;
   SkMatrix matrix = CreateMatrix(SkSize::Make(0.5f, 0.5f), is_decomposable);
 
@@ -880,7 +769,7 @@
   DrawImage draw_image(image, SkIRect::MakeWH(image.width(), image.height()),
                        kLow_SkFilterQuality, matrix, DefaultColorSpace());
   scoped_refptr<TileTask> task;
-  bool need_unref = cache->GetTaskForImageAndRef(
+  bool need_unref = cache.GetTaskForImageAndRef(
       draw_image, ImageDecodeCache::TracingInfo(), &task);
   EXPECT_TRUE(need_unref);
   EXPECT_TRUE(task);
@@ -892,7 +781,7 @@
       image, SkIRect::MakeWH(image.width(), image.height()),
       kHigh_SkFilterQuality, matrix, DefaultColorSpace());
   scoped_refptr<TileTask> hq_task;
-  bool hq_needs_unref = cache->GetTaskForImageAndRef(
+  bool hq_needs_unref = cache.GetTaskForImageAndRef(
       higher_quality_draw_image, ImageDecodeCache::TracingInfo(), &hq_task);
   EXPECT_TRUE(hq_needs_unref);
   EXPECT_TRUE(hq_task);
@@ -902,32 +791,37 @@
 
   // Must hold context lock before calling GetDecodedImageForDraw /
   // DrawWithImageFinished.
-  viz::ContextProvider::ScopedContextLock context_lock(context_provider());
+  viz::ContextProvider::ScopedContextLock context_lock(context_provider.get());
   DecodedDrawImage decoded_draw_image =
-      cache->GetDecodedImageForDraw(draw_image);
+      cache.GetDecodedImageForDraw(draw_image);
+  EXPECT_EQ(decoded_draw_image.filter_quality(), kLow_SkFilterQuality);
   EXPECT_TRUE(decoded_draw_image.image());
   EXPECT_TRUE(decoded_draw_image.image()->isTextureBacked());
   EXPECT_FALSE(decoded_draw_image.is_at_raster_decode());
-  EXPECT_FALSE(cache->DiscardableIsLockedForTesting(draw_image));
+  EXPECT_FALSE(cache.DiscardableIsLockedForTesting(draw_image));
 
   DecodedDrawImage larger_decoded_draw_image =
-      cache->GetDecodedImageForDraw(higher_quality_draw_image);
+      cache.GetDecodedImageForDraw(higher_quality_draw_image);
+  EXPECT_EQ(larger_decoded_draw_image.filter_quality(),
+            kMedium_SkFilterQuality);
   EXPECT_TRUE(larger_decoded_draw_image.image());
   EXPECT_TRUE(larger_decoded_draw_image.image()->isTextureBacked());
   EXPECT_FALSE(larger_decoded_draw_image.is_at_raster_decode());
-  EXPECT_FALSE(cache->DiscardableIsLockedForTesting(draw_image));
+  EXPECT_FALSE(cache.DiscardableIsLockedForTesting(draw_image));
 
   EXPECT_FALSE(decoded_draw_image.image() == larger_decoded_draw_image.image());
 
-  cache->DrawWithImageFinished(draw_image, decoded_draw_image);
-  cache->UnrefImage(draw_image);
-  cache->DrawWithImageFinished(higher_quality_draw_image,
-                               larger_decoded_draw_image);
-  cache->UnrefImage(higher_quality_draw_image);
+  cache.DrawWithImageFinished(draw_image, decoded_draw_image);
+  cache.UnrefImage(draw_image);
+  cache.DrawWithImageFinished(higher_quality_draw_image,
+                              larger_decoded_draw_image);
+  cache.UnrefImage(higher_quality_draw_image);
 }
 
 TEST_P(GpuImageDecodeCacheTest, GetDecodedImageForDrawNegative) {
-  auto cache = CreateCache();
+  auto context_provider = TestContextProvider::Create();
+  context_provider->BindToCurrentThread();
+  TestGpuImageDecodeCache cache(context_provider.get(), GetParam());
   bool is_decomposable = true;
   SkFilterQuality quality = kHigh_SkFilterQuality;
 
@@ -937,7 +831,7 @@
                        CreateMatrix(SkSize::Make(-0.5f, 0.5f), is_decomposable),
                        DefaultColorSpace());
   scoped_refptr<TileTask> task;
-  bool need_unref = cache->GetTaskForImageAndRef(
+  bool need_unref = cache.GetTaskForImageAndRef(
       draw_image, ImageDecodeCache::TracingInfo(), &task);
   EXPECT_TRUE(need_unref);
   EXPECT_TRUE(task);
@@ -947,22 +841,25 @@
 
   // Must hold context lock before calling GetDecodedImageForDraw /
   // DrawWithImageFinished.
-  viz::ContextProvider::ScopedContextLock context_lock(context_provider());
+  viz::ContextProvider::ScopedContextLock context_lock(context_provider.get());
   DecodedDrawImage decoded_draw_image =
-      cache->GetDecodedImageForDraw(draw_image);
+      cache.GetDecodedImageForDraw(draw_image);
+  EXPECT_EQ(decoded_draw_image.filter_quality(), kMedium_SkFilterQuality);
   EXPECT_TRUE(decoded_draw_image.image());
   EXPECT_EQ(decoded_draw_image.image()->width(), 50);
   EXPECT_EQ(decoded_draw_image.image()->height(), 50);
   EXPECT_TRUE(decoded_draw_image.image()->isTextureBacked());
   EXPECT_FALSE(decoded_draw_image.is_at_raster_decode());
-  EXPECT_FALSE(cache->DiscardableIsLockedForTesting(draw_image));
+  EXPECT_FALSE(cache.DiscardableIsLockedForTesting(draw_image));
 
-  cache->DrawWithImageFinished(draw_image, decoded_draw_image);
-  cache->UnrefImage(draw_image);
+  cache.DrawWithImageFinished(draw_image, decoded_draw_image);
+  cache.UnrefImage(draw_image);
 }
 
 TEST_P(GpuImageDecodeCacheTest, GetLargeScaledDecodedImageForDraw) {
-  auto cache = CreateCache();
+  auto context_provider = TestContextProvider::Create();
+  context_provider->BindToCurrentThread();
+  TestGpuImageDecodeCache cache(context_provider.get(), GetParam());
   bool is_decomposable = true;
   SkFilterQuality quality = kHigh_SkFilterQuality;
 
@@ -972,7 +869,7 @@
                        CreateMatrix(SkSize::Make(0.5f, 0.5f), is_decomposable),
                        DefaultColorSpace());
   scoped_refptr<TileTask> task;
-  bool need_unref = cache->GetTaskForImageAndRef(
+  bool need_unref = cache.GetTaskForImageAndRef(
       draw_image, ImageDecodeCache::TracingInfo(), &task);
   EXPECT_TRUE(need_unref);
   EXPECT_TRUE(task);
@@ -982,9 +879,9 @@
 
   // Must hold context lock before calling GetDecodedImageForDraw /
   // DrawWithImageFinished.
-  viz::ContextProvider::ScopedContextLock context_lock(context_provider());
+  viz::ContextProvider::ScopedContextLock context_lock(context_provider.get());
   DecodedDrawImage decoded_draw_image =
-      cache->GetDecodedImageForDraw(draw_image);
+      cache.GetDecodedImageForDraw(draw_image);
   EXPECT_TRUE(decoded_draw_image.image());
   // The mip level scale should never go below 0 in any dimension.
   EXPECT_EQ(1, decoded_draw_image.image()->width());
@@ -992,19 +889,21 @@
   EXPECT_EQ(decoded_draw_image.filter_quality(), kMedium_SkFilterQuality);
   EXPECT_FALSE(decoded_draw_image.image()->isTextureBacked());
   EXPECT_FALSE(decoded_draw_image.is_at_raster_decode());
-  EXPECT_TRUE(cache->DiscardableIsLockedForTesting(draw_image));
+  EXPECT_TRUE(cache.DiscardableIsLockedForTesting(draw_image));
 
-  cache->DrawWithImageFinished(draw_image, decoded_draw_image);
-  cache->UnrefImage(draw_image);
-  EXPECT_FALSE(cache->DiscardableIsLockedForTesting(draw_image));
+  cache.DrawWithImageFinished(draw_image, decoded_draw_image);
+  cache.UnrefImage(draw_image);
+  EXPECT_FALSE(cache.DiscardableIsLockedForTesting(draw_image));
 }
 
 TEST_P(GpuImageDecodeCacheTest, AtRasterUsedDirectlyIfSpaceAllows) {
-  auto cache = CreateCache();
+  auto context_provider = TestContextProvider::Create();
+  context_provider->BindToCurrentThread();
+  TestGpuImageDecodeCache cache(context_provider.get(), GetParam());
   bool is_decomposable = true;
   SkFilterQuality quality = kHigh_SkFilterQuality;
 
-  cache->SetWorkingSetLimitForTesting(0);
+  cache.SetAllByteLimitsForTesting(0);
 
   PaintImage image = CreateDiscardablePaintImage(gfx::Size(100, 100));
   DrawImage draw_image(image, SkIRect::MakeWH(image.width(), image.height()),
@@ -1013,42 +912,45 @@
                        DefaultColorSpace());
 
   scoped_refptr<TileTask> task;
-  bool need_unref = cache->GetTaskForImageAndRef(
+  bool need_unref = cache.GetTaskForImageAndRef(
       draw_image, ImageDecodeCache::TracingInfo(), &task);
   EXPECT_FALSE(need_unref);
   EXPECT_FALSE(task);
 
   // Must hold context lock before calling GetDecodedImageForDraw /
   // DrawWithImageFinished.
-  viz::ContextProvider::ScopedContextLock context_lock(context_provider());
+  viz::ContextProvider::ScopedContextLock context_lock(context_provider.get());
   DecodedDrawImage decoded_draw_image =
-      cache->GetDecodedImageForDraw(draw_image);
+      cache.GetDecodedImageForDraw(draw_image);
+  EXPECT_EQ(decoded_draw_image.filter_quality(), kMedium_SkFilterQuality);
   EXPECT_TRUE(decoded_draw_image.image());
   EXPECT_TRUE(decoded_draw_image.image()->isTextureBacked());
   EXPECT_TRUE(decoded_draw_image.is_at_raster_decode());
-  EXPECT_FALSE(cache->DiscardableIsLockedForTesting(draw_image));
+  EXPECT_FALSE(cache.DiscardableIsLockedForTesting(draw_image));
 
-  cache->SetWorkingSetLimitForTesting(96 * 1024 * 1024);
+  cache.SetAllByteLimitsForTesting(96 * 1024 * 1024);
 
   // Finish our draw after increasing the memory limit, image should be added to
   // cache.
-  cache->DrawWithImageFinished(draw_image, decoded_draw_image);
+  cache.DrawWithImageFinished(draw_image, decoded_draw_image);
 
   scoped_refptr<TileTask> another_task;
-  bool another_task_needs_unref = cache->GetTaskForImageAndRef(
-      draw_image, ImageDecodeCache::TracingInfo(), &another_task);
+  bool another_task_needs_unref = cache.GetTaskForImageAndRef(
+      draw_image, ImageDecodeCache::TracingInfo(), &task);
   EXPECT_TRUE(another_task_needs_unref);
   EXPECT_FALSE(another_task);
-  cache->UnrefImage(draw_image);
+  cache.UnrefImage(draw_image);
 }
 
 TEST_P(GpuImageDecodeCacheTest,
        GetDecodedImageForDrawAtRasterDecodeMultipleTimes) {
-  auto cache = CreateCache();
+  auto context_provider = TestContextProvider::Create();
+  context_provider->BindToCurrentThread();
+  TestGpuImageDecodeCache cache(context_provider.get(), GetParam());
   bool is_decomposable = true;
   SkFilterQuality quality = kHigh_SkFilterQuality;
 
-  cache->SetWorkingSetLimitForTesting(0);
+  cache.SetAllByteLimitsForTesting(0);
 
   PaintImage image = CreateDiscardablePaintImage(gfx::Size(100, 100));
   DrawImage draw_image(image, SkIRect::MakeWH(image.width(), image.height()),
@@ -1058,26 +960,29 @@
 
   // Must hold context lock before calling GetDecodedImageForDraw /
   // DrawWithImageFinished.
-  viz::ContextProvider::ScopedContextLock context_lock(context_provider());
+  viz::ContextProvider::ScopedContextLock context_lock(context_provider.get());
   DecodedDrawImage decoded_draw_image =
-      cache->GetDecodedImageForDraw(draw_image);
+      cache.GetDecodedImageForDraw(draw_image);
+  EXPECT_EQ(decoded_draw_image.filter_quality(), kMedium_SkFilterQuality);
   EXPECT_TRUE(decoded_draw_image.image());
   EXPECT_TRUE(decoded_draw_image.image()->isTextureBacked());
   EXPECT_TRUE(decoded_draw_image.is_at_raster_decode());
-  EXPECT_FALSE(cache->DiscardableIsLockedForTesting(draw_image));
+  EXPECT_FALSE(cache.DiscardableIsLockedForTesting(draw_image));
 
   DecodedDrawImage another_decoded_draw_image =
-      cache->GetDecodedImageForDraw(draw_image);
+      cache.GetDecodedImageForDraw(draw_image);
   EXPECT_EQ(decoded_draw_image.image()->uniqueID(),
             another_decoded_draw_image.image()->uniqueID());
 
-  cache->DrawWithImageFinished(draw_image, decoded_draw_image);
-  cache->DrawWithImageFinished(draw_image, another_decoded_draw_image);
+  cache.DrawWithImageFinished(draw_image, decoded_draw_image);
+  cache.DrawWithImageFinished(draw_image, another_decoded_draw_image);
 }
 
 TEST_P(GpuImageDecodeCacheTest,
        GetLargeDecodedImageForDrawAtRasterDecodeMultipleTimes) {
-  auto cache = CreateCache();
+  auto context_provider = TestContextProvider::Create();
+  context_provider->BindToCurrentThread();
+  TestGpuImageDecodeCache cache(context_provider.get(), GetParam());
   bool is_decomposable = true;
   SkFilterQuality quality = kHigh_SkFilterQuality;
 
@@ -1089,30 +994,35 @@
 
   // Must hold context lock before calling GetDecodedImageForDraw /
   // DrawWithImageFinished.
-  viz::ContextProvider::ScopedContextLock context_lock(context_provider());
+  viz::ContextProvider::ScopedContextLock context_lock(context_provider.get());
   DecodedDrawImage decoded_draw_image =
-      cache->GetDecodedImageForDraw(draw_image);
+      cache.GetDecodedImageForDraw(draw_image);
+  EXPECT_EQ(decoded_draw_image.filter_quality(), kMedium_SkFilterQuality);
   EXPECT_TRUE(decoded_draw_image.image());
   EXPECT_FALSE(decoded_draw_image.image()->isTextureBacked());
   EXPECT_TRUE(decoded_draw_image.is_at_raster_decode());
-  EXPECT_TRUE(cache->DiscardableIsLockedForTesting(draw_image));
+  EXPECT_TRUE(cache.DiscardableIsLockedForTesting(draw_image));
 
-  cache->DrawWithImageFinished(draw_image, decoded_draw_image);
-  EXPECT_FALSE(cache->DiscardableIsLockedForTesting(draw_image));
+  cache.DrawWithImageFinished(draw_image, decoded_draw_image);
+  EXPECT_FALSE(cache.DiscardableIsLockedForTesting(draw_image));
 
   DecodedDrawImage second_decoded_draw_image =
-      cache->GetDecodedImageForDraw(draw_image);
+      cache.GetDecodedImageForDraw(draw_image);
+  EXPECT_EQ(second_decoded_draw_image.filter_quality(),
+            kMedium_SkFilterQuality);
   EXPECT_TRUE(second_decoded_draw_image.image());
   EXPECT_FALSE(second_decoded_draw_image.image()->isTextureBacked());
   EXPECT_TRUE(second_decoded_draw_image.is_at_raster_decode());
-  EXPECT_TRUE(cache->DiscardableIsLockedForTesting(draw_image));
+  EXPECT_TRUE(cache.DiscardableIsLockedForTesting(draw_image));
 
-  cache->DrawWithImageFinished(draw_image, second_decoded_draw_image);
-  EXPECT_FALSE(cache->DiscardableIsLockedForTesting(draw_image));
+  cache.DrawWithImageFinished(draw_image, second_decoded_draw_image);
+  EXPECT_FALSE(cache.DiscardableIsLockedForTesting(draw_image));
 }
 
 TEST_P(GpuImageDecodeCacheTest, ZeroSizedImagesAreSkipped) {
-  auto cache = CreateCache();
+  auto context_provider = TestContextProvider::Create();
+  context_provider->BindToCurrentThread();
+  TestGpuImageDecodeCache cache(context_provider.get(), GetParam());
   bool is_decomposable = true;
   SkFilterQuality quality = kHigh_SkFilterQuality;
 
@@ -1123,23 +1033,25 @@
                        DefaultColorSpace());
 
   scoped_refptr<TileTask> task;
-  bool need_unref = cache->GetTaskForImageAndRef(
+  bool need_unref = cache.GetTaskForImageAndRef(
       draw_image, ImageDecodeCache::TracingInfo(), &task);
   EXPECT_FALSE(task);
   EXPECT_FALSE(need_unref);
 
   // Must hold context lock before calling GetDecodedImageForDraw /
   // DrawWithImageFinished.
-  viz::ContextProvider::ScopedContextLock context_lock(context_provider());
+  viz::ContextProvider::ScopedContextLock context_lock(context_provider.get());
   DecodedDrawImage decoded_draw_image =
-      cache->GetDecodedImageForDraw(draw_image);
+      cache.GetDecodedImageForDraw(draw_image);
   EXPECT_FALSE(decoded_draw_image.image());
 
-  cache->DrawWithImageFinished(draw_image, decoded_draw_image);
+  cache.DrawWithImageFinished(draw_image, decoded_draw_image);
 }
 
 TEST_P(GpuImageDecodeCacheTest, NonOverlappingSrcRectImagesAreSkipped) {
-  auto cache = CreateCache();
+  auto context_provider = TestContextProvider::Create();
+  context_provider->BindToCurrentThread();
+  TestGpuImageDecodeCache cache(context_provider.get(), GetParam());
   bool is_decomposable = true;
   SkFilterQuality quality = kHigh_SkFilterQuality;
 
@@ -1150,23 +1062,25 @@
       DefaultColorSpace());
 
   scoped_refptr<TileTask> task;
-  bool need_unref = cache->GetTaskForImageAndRef(
+  bool need_unref = cache.GetTaskForImageAndRef(
       draw_image, ImageDecodeCache::TracingInfo(), &task);
   EXPECT_FALSE(task);
   EXPECT_FALSE(need_unref);
 
   // Must hold context lock before calling GetDecodedImageForDraw /
   // DrawWithImageFinished.
-  viz::ContextProvider::ScopedContextLock context_lock(context_provider());
+  viz::ContextProvider::ScopedContextLock context_lock(context_provider.get());
   DecodedDrawImage decoded_draw_image =
-      cache->GetDecodedImageForDraw(draw_image);
+      cache.GetDecodedImageForDraw(draw_image);
   EXPECT_FALSE(decoded_draw_image.image());
 
-  cache->DrawWithImageFinished(draw_image, decoded_draw_image);
+  cache.DrawWithImageFinished(draw_image, decoded_draw_image);
 }
 
 TEST_P(GpuImageDecodeCacheTest, CanceledTasksDoNotCountAgainstBudget) {
-  auto cache = CreateCache();
+  auto context_provider = TestContextProvider::Create();
+  context_provider->BindToCurrentThread();
+  TestGpuImageDecodeCache cache(context_provider.get(), GetParam());
   bool is_decomposable = true;
   SkFilterQuality quality = kHigh_SkFilterQuality;
 
@@ -1177,9 +1091,9 @@
       DefaultColorSpace());
 
   scoped_refptr<TileTask> task;
-  bool need_unref = cache->GetTaskForImageAndRef(
+  bool need_unref = cache.GetTaskForImageAndRef(
       draw_image, ImageDecodeCache::TracingInfo(), &task);
-  EXPECT_NE(0u, cache->GetWorkingSetBytesForTesting());
+  EXPECT_NE(0u, cache.GetBytesUsedForTesting());
   EXPECT_TRUE(task);
   EXPECT_TRUE(need_unref);
 
@@ -1188,12 +1102,14 @@
   TestTileTaskRunner::CancelTask(task.get());
   TestTileTaskRunner::CompleteTask(task.get());
 
-  cache->UnrefImage(draw_image);
-  EXPECT_EQ(0u, cache->GetWorkingSetBytesForTesting());
+  cache.UnrefImage(draw_image);
+  EXPECT_EQ(0u, cache.GetBytesUsedForTesting());
 }
 
 TEST_P(GpuImageDecodeCacheTest, ShouldAggressivelyFreeResources) {
-  auto cache = CreateCache();
+  auto context_provider = TestContextProvider::Create();
+  context_provider->BindToCurrentThread();
+  TestGpuImageDecodeCache cache(context_provider.get(), GetParam());
   bool is_decomposable = true;
   SkFilterQuality quality = kHigh_SkFilterQuality;
 
@@ -1204,7 +1120,7 @@
                        DefaultColorSpace());
   scoped_refptr<TileTask> task;
   {
-    bool need_unref = cache->GetTaskForImageAndRef(
+    bool need_unref = cache.GetTaskForImageAndRef(
         draw_image, ImageDecodeCache::TracingInfo(), &task);
     EXPECT_TRUE(need_unref);
     EXPECT_TRUE(task);
@@ -1213,49 +1129,51 @@
   TestTileTaskRunner::ProcessTask(task->dependencies()[0].get());
   TestTileTaskRunner::ProcessTask(task.get());
 
-  cache->UnrefImage(draw_image);
+  cache.UnrefImage(draw_image);
 
-  // We should now have data image in our cache->
-  EXPECT_GT(cache->GetNumCacheEntriesForTesting(), 0u);
+  // We should now have data image in our cache.
+  EXPECT_GT(cache.GetBytesUsedForTesting(), 0u);
 
   // Tell our cache to aggressively free resources.
-  cache->SetShouldAggressivelyFreeResources(true);
-  EXPECT_EQ(0u, cache->GetNumCacheEntriesForTesting());
+  cache.SetShouldAggressivelyFreeResources(true);
+  EXPECT_EQ(0u, cache.GetBytesUsedForTesting());
 
   // Attempting to upload a new image should succeed, but the image should not
   // be cached past its use.
   {
-    bool need_unref = cache->GetTaskForImageAndRef(
+    bool need_unref = cache.GetTaskForImageAndRef(
         draw_image, ImageDecodeCache::TracingInfo(), &task);
     EXPECT_TRUE(need_unref);
     EXPECT_TRUE(task);
 
     TestTileTaskRunner::ProcessTask(task->dependencies()[0].get());
     TestTileTaskRunner::ProcessTask(task.get());
-    cache->UnrefImage(draw_image);
+    cache.UnrefImage(draw_image);
 
-    EXPECT_EQ(cache->GetNumCacheEntriesForTesting(), 0u);
+    EXPECT_EQ(cache.GetBytesUsedForTesting(), 0u);
   }
 
   // We now tell the cache to not aggressively free resources. The image may
   // now be cached past its use.
-  cache->SetShouldAggressivelyFreeResources(false);
+  cache.SetShouldAggressivelyFreeResources(false);
   {
-    bool need_unref = cache->GetTaskForImageAndRef(
+    bool need_unref = cache.GetTaskForImageAndRef(
         draw_image, ImageDecodeCache::TracingInfo(), &task);
     EXPECT_TRUE(need_unref);
     EXPECT_TRUE(task);
 
     TestTileTaskRunner::ProcessTask(task->dependencies()[0].get());
     TestTileTaskRunner::ProcessTask(task.get());
-    cache->UnrefImage(draw_image);
+    cache.UnrefImage(draw_image);
 
-    EXPECT_GT(cache->GetNumCacheEntriesForTesting(), 0u);
+    EXPECT_GT(cache.GetBytesUsedForTesting(), 0u);
   }
 }
 
 TEST_P(GpuImageDecodeCacheTest, OrphanedImagesFreeOnReachingZeroRefs) {
-  auto cache = CreateCache();
+  auto context_provider = TestContextProvider::Create();
+  context_provider->BindToCurrentThread();
+  TestGpuImageDecodeCache cache(context_provider.get(), GetParam());
   bool is_decomposable = true;
   SkFilterQuality quality = kHigh_SkFilterQuality;
 
@@ -1266,14 +1184,14 @@
       quality, CreateMatrix(SkSize::Make(0.5f, 0.5f), is_decomposable),
       DefaultColorSpace());
   scoped_refptr<TileTask> first_task;
-  bool need_unref = cache->GetTaskForImageAndRef(
+  bool need_unref = cache.GetTaskForImageAndRef(
       first_draw_image, ImageDecodeCache::TracingInfo(), &first_task);
   EXPECT_TRUE(need_unref);
   EXPECT_TRUE(first_task);
 
   // The budget should account for exactly one image.
-  EXPECT_EQ(cache->GetWorkingSetBytesForTesting(),
-            cache->GetDrawImageSizeForTesting(first_draw_image));
+  EXPECT_EQ(cache.GetBytesUsedForTesting(),
+            cache.GetDrawImageSizeForTesting(first_draw_image));
 
   // Create a larger version of |first_image|, this should immediately free the
   // memory used by |first_image| for the smaller scale.
@@ -1282,7 +1200,7 @@
       quality, CreateMatrix(SkSize::Make(1.0f, 1.0f), is_decomposable),
       DefaultColorSpace());
   scoped_refptr<TileTask> second_task;
-  need_unref = cache->GetTaskForImageAndRef(
+  need_unref = cache.GetTaskForImageAndRef(
       second_draw_image, ImageDecodeCache::TracingInfo(), &second_task);
   EXPECT_TRUE(need_unref);
   EXPECT_TRUE(second_task);
@@ -1291,21 +1209,28 @@
   TestTileTaskRunner::ProcessTask(second_task->dependencies()[0].get());
   TestTileTaskRunner::ProcessTask(second_task.get());
 
-  cache->UnrefImage(second_draw_image);
+  cache.UnrefImage(second_draw_image);
+
+  // The budget should account for both images one image.
+  EXPECT_EQ(cache.GetBytesUsedForTesting(),
+            cache.GetDrawImageSizeForTesting(second_draw_image) +
+                cache.GetDrawImageSizeForTesting(first_draw_image));
 
   // Unref the first image, it was orphaned, so it should be immediately
   // deleted.
   TestTileTaskRunner::ProcessTask(first_task->dependencies()[0].get());
   TestTileTaskRunner::ProcessTask(first_task.get());
-  cache->UnrefImage(first_draw_image);
+  cache.UnrefImage(first_draw_image);
 
-  // The cache should have exactly one image.
-  EXPECT_EQ(1u, cache->GetNumCacheEntriesForTesting());
-  EXPECT_EQ(0u, cache->GetInUseCacheEntriesForTesting());
+  // The budget should account for exactly one image.
+  EXPECT_EQ(cache.GetBytesUsedForTesting(),
+            cache.GetDrawImageSizeForTesting(second_draw_image));
 }
 
 TEST_P(GpuImageDecodeCacheTest, OrphanedZeroRefImagesImmediatelyDeleted) {
-  auto cache = CreateCache();
+  auto context_provider = TestContextProvider::Create();
+  context_provider->BindToCurrentThread();
+  TestGpuImageDecodeCache cache(context_provider.get(), GetParam());
   bool is_decomposable = true;
   SkFilterQuality quality = kHigh_SkFilterQuality;
 
@@ -1316,18 +1241,18 @@
       quality, CreateMatrix(SkSize::Make(0.5f, 0.5f), is_decomposable),
       DefaultColorSpace());
   scoped_refptr<TileTask> first_task;
-  bool need_unref = cache->GetTaskForImageAndRef(
+  bool need_unref = cache.GetTaskForImageAndRef(
       first_draw_image, ImageDecodeCache::TracingInfo(), &first_task);
   EXPECT_TRUE(need_unref);
   EXPECT_TRUE(first_task);
 
   TestTileTaskRunner::ProcessTask(first_task->dependencies()[0].get());
   TestTileTaskRunner::ProcessTask(first_task.get());
-  cache->UnrefImage(first_draw_image);
+  cache.UnrefImage(first_draw_image);
 
   // The budget should account for exactly one image.
-  EXPECT_EQ(cache->GetNumCacheEntriesForTesting(), 1u);
-  EXPECT_EQ(cache->GetInUseCacheEntriesForTesting(), 0u);
+  EXPECT_EQ(cache.GetBytesUsedForTesting(),
+            cache.GetDrawImageSizeForTesting(first_draw_image));
 
   // Create a larger version of |first_image|, this should immediately free the
   // memory used by |first_image| for the smaller scale.
@@ -1336,7 +1261,7 @@
       quality, CreateMatrix(SkSize::Make(1.0f, 1.0f), is_decomposable),
       DefaultColorSpace());
   scoped_refptr<TileTask> second_task;
-  need_unref = cache->GetTaskForImageAndRef(
+  need_unref = cache.GetTaskForImageAndRef(
       second_draw_image, ImageDecodeCache::TracingInfo(), &second_task);
   EXPECT_TRUE(need_unref);
   EXPECT_TRUE(second_task);
@@ -1345,15 +1270,17 @@
   TestTileTaskRunner::ProcessTask(second_task->dependencies()[0].get());
   TestTileTaskRunner::ProcessTask(second_task.get());
 
-  cache->UnrefImage(second_draw_image);
+  cache.UnrefImage(second_draw_image);
 
   // The budget should account for exactly one image.
-  EXPECT_EQ(cache->GetNumCacheEntriesForTesting(), 1u);
-  EXPECT_EQ(cache->GetInUseCacheEntriesForTesting(), 0u);
+  EXPECT_EQ(cache.GetBytesUsedForTesting(),
+            cache.GetDrawImageSizeForTesting(second_draw_image));
 }
 
 TEST_P(GpuImageDecodeCacheTest, QualityCappedAtMedium) {
-  auto cache = CreateCache();
+  auto context_provider = TestContextProvider::Create();
+  context_provider->BindToCurrentThread();
+  TestGpuImageDecodeCache cache(context_provider.get(), GetParam());
   PaintImage image = CreateDiscardablePaintImage(gfx::Size(100, 100));
   bool is_decomposable = true;
   SkMatrix matrix = CreateMatrix(SkSize::Make(0.4f, 0.4f), is_decomposable);
@@ -1363,7 +1290,7 @@
                            SkIRect::MakeWH(image.width(), image.height()),
                            kLow_SkFilterQuality, matrix, DefaultColorSpace());
   scoped_refptr<TileTask> low_task;
-  bool need_unref = cache->GetTaskForImageAndRef(
+  bool need_unref = cache.GetTaskForImageAndRef(
       low_draw_image, ImageDecodeCache::TracingInfo(), &low_task);
   EXPECT_TRUE(need_unref);
   EXPECT_TRUE(low_task);
@@ -1374,7 +1301,7 @@
       image, SkIRect::MakeWH(image.width(), image.height()),
       kMedium_SkFilterQuality, matrix, DefaultColorSpace());
   scoped_refptr<TileTask> medium_task;
-  need_unref = cache->GetTaskForImageAndRef(
+  need_unref = cache.GetTaskForImageAndRef(
       medium_draw_image, ImageDecodeCache::TracingInfo(), &medium_task);
   EXPECT_TRUE(need_unref);
   EXPECT_TRUE(medium_task.get());
@@ -1385,7 +1312,7 @@
       image, SkIRect::MakeWH(image.width(), image.height()),
       kHigh_SkFilterQuality, matrix, DefaultColorSpace());
   scoped_refptr<TileTask> large_task;
-  need_unref = cache->GetTaskForImageAndRef(
+  need_unref = cache.GetTaskForImageAndRef(
       large_draw_image, ImageDecodeCache::TracingInfo(), &large_task);
   EXPECT_TRUE(need_unref);
   EXPECT_TRUE(medium_task.get() == large_task.get());
@@ -1395,15 +1322,17 @@
   TestTileTaskRunner::ProcessTask(medium_task->dependencies()[0].get());
   TestTileTaskRunner::ProcessTask(medium_task.get());
 
-  cache->UnrefImage(low_draw_image);
-  cache->UnrefImage(medium_draw_image);
-  cache->UnrefImage(large_draw_image);
+  cache.UnrefImage(low_draw_image);
+  cache.UnrefImage(medium_draw_image);
+  cache.UnrefImage(large_draw_image);
 }
 
 // Ensure that switching to a mipped version of an image after the initial
 // cache entry creation doesn't cause a buffer overflow/crash.
 TEST_P(GpuImageDecodeCacheTest, GetDecodedImageForDrawMipUsageChange) {
-  auto cache = CreateCache();
+  auto context_provider = TestContextProvider::Create();
+  context_provider->BindToCurrentThread();
+  TestGpuImageDecodeCache cache(context_provider.get(), GetParam());
   bool is_decomposable = true;
   SkFilterQuality quality = kHigh_SkFilterQuality;
 
@@ -1414,7 +1343,7 @@
                        CreateMatrix(SkSize::Make(1.0f, 1.0f), is_decomposable),
                        DefaultColorSpace());
   scoped_refptr<TileTask> task;
-  bool need_unref = cache->GetTaskForImageAndRef(
+  bool need_unref = cache.GetTaskForImageAndRef(
       draw_image, ImageDecodeCache::TracingInfo(), &task);
   EXPECT_TRUE(need_unref);
   EXPECT_TRUE(task);
@@ -1425,11 +1354,11 @@
   TestTileTaskRunner::CancelTask(task.get());
   TestTileTaskRunner::CompleteTask(task.get());
 
-  cache->UnrefImage(draw_image);
+  cache.UnrefImage(draw_image);
 
   // Must hold context lock before calling GetDecodedImageForDraw /
   // DrawWithImageFinished.
-  viz::ContextProvider::ScopedContextLock context_lock(context_provider());
+  viz::ContextProvider::ScopedContextLock context_lock(context_provider.get());
 
   // Do an at-raster decode of the above image that *does* require mips.
   DrawImage draw_image_mips(
@@ -1437,12 +1366,14 @@
       CreateMatrix(SkSize::Make(0.6f, 0.6f), is_decomposable),
       DefaultColorSpace());
   DecodedDrawImage decoded_draw_image =
-      cache->GetDecodedImageForDraw(draw_image_mips);
-  cache->DrawWithImageFinished(draw_image_mips, decoded_draw_image);
+      cache.GetDecodedImageForDraw(draw_image_mips);
+  cache.DrawWithImageFinished(draw_image_mips, decoded_draw_image);
 }
 
 TEST_P(GpuImageDecodeCacheTest, MemoryStateSuspended) {
-  auto cache = CreateCache();
+  auto context_provider = TestContextProvider::Create();
+  context_provider->BindToCurrentThread();
+  TestGpuImageDecodeCache cache(context_provider.get(), GetParam());
 
   // First Insert an image into our cache.
   PaintImage image = CreateDiscardablePaintImage(gfx::Size(1, 1));
@@ -1451,58 +1382,68 @@
   DrawImage draw_image(image, SkIRect::MakeWH(image.width(), image.height()),
                        kLow_SkFilterQuality, matrix, DefaultColorSpace());
   scoped_refptr<TileTask> task;
-  bool need_unref = cache->GetTaskForImageAndRef(
+  bool need_unref = cache.GetTaskForImageAndRef(
       draw_image, ImageDecodeCache::TracingInfo(), &task);
   EXPECT_TRUE(need_unref);
   EXPECT_TRUE(task);
 
   TestTileTaskRunner::ProcessTask(task->dependencies()[0].get());
   TestTileTaskRunner::ProcessTask(task.get());
-  cache->UnrefImage(draw_image);
+  cache.UnrefImage(draw_image);
 
   // The image should be cached.
-  EXPECT_EQ(cache->GetNumCacheEntriesForTesting(), 1u);
+  EXPECT_GT(cache.GetBytesUsedForTesting(), 0u);
+  EXPECT_EQ(cache.GetNumCacheEntriesForTesting(), 1u);
+
+  // Set us to the not visible state (prerequisite for SUSPENDED).
+  cache.SetShouldAggressivelyFreeResources(true);
+
+  // Image should be cached, but not using memory budget.
+  EXPECT_EQ(cache.GetBytesUsedForTesting(), 0u);
+  EXPECT_EQ(cache.GetNumCacheEntriesForTesting(), 1u);
 
   // Set us to the SUSPENDED state with purging.
-  cache->OnPurgeMemory();
-  cache->OnMemoryStateChange(base::MemoryState::SUSPENDED);
+  cache.OnPurgeMemory();
+  cache.OnMemoryStateChange(base::MemoryState::SUSPENDED);
 
   // Nothing should be cached.
-  EXPECT_EQ(cache->GetWorkingSetBytesForTesting(), 0u);
-  EXPECT_EQ(cache->GetNumCacheEntriesForTesting(), 0u);
+  EXPECT_EQ(cache.GetBytesUsedForTesting(), 0u);
+  EXPECT_EQ(cache.GetNumCacheEntriesForTesting(), 0u);
 
   // Attempts to get a task for the image will still succeed, as SUSPENDED
   // doesn't impact working set size.
-  need_unref = cache->GetTaskForImageAndRef(
+  need_unref = cache.GetTaskForImageAndRef(
       draw_image, ImageDecodeCache::TracingInfo(), &task);
   EXPECT_TRUE(need_unref);
   EXPECT_TRUE(task);
 
   TestTileTaskRunner::ProcessTask(task->dependencies()[0].get());
   TestTileTaskRunner::ProcessTask(task.get());
-  cache->UnrefImage(draw_image);
+  cache.UnrefImage(draw_image);
 
   // Nothing should be cached.
-  EXPECT_EQ(cache->GetWorkingSetBytesForTesting(), 0u);
-  EXPECT_EQ(cache->GetNumCacheEntriesForTesting(), 0u);
+  EXPECT_EQ(cache.GetBytesUsedForTesting(), 0u);
+  EXPECT_EQ(cache.GetNumCacheEntriesForTesting(), 0u);
 
   // Restore us to visible and NORMAL memory state.
-  cache->OnMemoryStateChange(base::MemoryState::NORMAL);
-  cache->SetShouldAggressivelyFreeResources(false);
+  cache.OnMemoryStateChange(base::MemoryState::NORMAL);
+  cache.SetShouldAggressivelyFreeResources(false);
 
   // We should now be able to create a task again (space available).
-  need_unref = cache->GetTaskForImageAndRef(
+  need_unref = cache.GetTaskForImageAndRef(
       draw_image, ImageDecodeCache::TracingInfo(), &task);
   EXPECT_TRUE(need_unref);
   EXPECT_TRUE(task);
 
   TestTileTaskRunner::ProcessTask(task->dependencies()[0].get());
   TestTileTaskRunner::ProcessTask(task.get());
-  cache->UnrefImage(draw_image);
+  cache.UnrefImage(draw_image);
 }
 
 TEST_P(GpuImageDecodeCacheTest, OutOfRasterDecodeTask) {
-  auto cache = CreateCache();
+  auto context_provider = TestContextProvider::Create();
+  context_provider->BindToCurrentThread();
+  TestGpuImageDecodeCache cache(context_provider.get(), GetParam());
 
   PaintImage image = CreateDiscardablePaintImage(gfx::Size(1, 1));
   bool is_decomposable = true;
@@ -1512,22 +1453,25 @@
 
   scoped_refptr<TileTask> task;
   bool need_unref =
-      cache->GetOutOfRasterDecodeTaskForImageAndRef(draw_image, &task);
+      cache.GetOutOfRasterDecodeTaskForImageAndRef(draw_image, &task);
   EXPECT_TRUE(need_unref);
   EXPECT_TRUE(task);
-  EXPECT_TRUE(cache->IsInInUseCacheForTesting(draw_image));
+  EXPECT_TRUE(cache.IsInInUseCacheForTesting(draw_image));
 
   // Run the decode task.
   TestTileTaskRunner::ProcessTask(task.get());
 
   // The image should remain in the cache till we unref it.
-  EXPECT_TRUE(cache->IsInInUseCacheForTesting(draw_image));
-  cache->UnrefImage(draw_image);
+  EXPECT_TRUE(cache.IsInInUseCacheForTesting(draw_image));
+  cache.UnrefImage(draw_image);
 }
 
 TEST_P(GpuImageDecodeCacheTest, ZeroCacheNormalWorkingSet) {
-  SetDiscardableTexturesLimit(0);
-  auto cache = CreateCache();
+  // Setup - Image cache has a normal working set, but zero cache size.
+  auto context_provider = TestContextProvider::Create();
+  context_provider->BindToCurrentThread();
+  GpuImageDecodeCache cache(context_provider.get(), kN32_SkColorType,
+                            kGpuMemoryLimitBytes, 0);
   bool is_decomposable = true;
   SkFilterQuality quality = kHigh_SkFilterQuality;
 
@@ -1539,7 +1483,7 @@
                        CreateMatrix(SkSize::Make(1.0f, 1.0f), is_decomposable),
                        DefaultColorSpace());
   scoped_refptr<TileTask> task;
-  bool need_unref = cache->GetTaskForImageAndRef(
+  bool need_unref = cache.GetTaskForImageAndRef(
       draw_image, ImageDecodeCache::TracingInfo(), &task);
   EXPECT_TRUE(need_unref);
   EXPECT_TRUE(task);
@@ -1552,22 +1496,19 @@
 
   // Request the same image - it should be cached.
   scoped_refptr<TileTask> task2;
-  need_unref = cache->GetTaskForImageAndRef(
+  need_unref = cache.GetTaskForImageAndRef(
       draw_image, ImageDecodeCache::TracingInfo(), &task2);
   EXPECT_TRUE(need_unref);
   EXPECT_FALSE(task2);
 
   // Unref both images.
-  cache->UnrefImage(draw_image);
-  cache->UnrefImage(draw_image);
-
-  // Ensure the unref is processed:
-  cache->ReduceCacheUsage();
+  cache.UnrefImage(draw_image);
+  cache.UnrefImage(draw_image);
 
   // Get the image again. As it was fully unreffed, it is no longer in the
   // working set and will be evicted due to 0 cache size.
   scoped_refptr<TileTask> task3;
-  need_unref = cache->GetTaskForImageAndRef(
+  need_unref = cache.GetTaskForImageAndRef(
       draw_image, ImageDecodeCache::TracingInfo(), &task3);
   EXPECT_TRUE(need_unref);
   EXPECT_TRUE(task3);
@@ -1577,13 +1518,17 @@
   TestTileTaskRunner::ProcessTask(task3->dependencies()[0].get());
   TestTileTaskRunner::ProcessTask(task3.get());
 
-  cache->UnrefImage(draw_image);
+  cache.UnrefImage(draw_image);
 }
 
 TEST_P(GpuImageDecodeCacheTest, SmallCacheNormalWorkingSet) {
-  // Cache will fit one image.
-  SetDiscardableTexturesLimit(1);
-  auto cache = CreateCache();
+  // Cache will fit one (but not two) 100x100 images.
+  size_t cache_size = 190 * 100 * 4;
+
+  auto context_provider = TestContextProvider::Create();
+  context_provider->BindToCurrentThread();
+  GpuImageDecodeCache cache(context_provider.get(), kN32_SkColorType,
+                            kGpuMemoryLimitBytes, cache_size);
   bool is_decomposable = true;
   SkFilterQuality quality = kHigh_SkFilterQuality;
 
@@ -1602,7 +1547,7 @@
   // Add an image to the cache and un-ref it.
   {
     scoped_refptr<TileTask> task;
-    bool need_unref = cache->GetTaskForImageAndRef(
+    bool need_unref = cache.GetTaskForImageAndRef(
         draw_image, ImageDecodeCache::TracingInfo(), &task);
     EXPECT_TRUE(need_unref);
     EXPECT_TRUE(task);
@@ -1612,23 +1557,23 @@
     // Run the task and unref the image.
     TestTileTaskRunner::ProcessTask(task->dependencies()[0].get());
     TestTileTaskRunner::ProcessTask(task.get());
-    cache->UnrefImage(draw_image);
+    cache.UnrefImage(draw_image);
   }
 
   // Request the same image - it should be cached.
   {
     scoped_refptr<TileTask> task;
-    bool need_unref = cache->GetTaskForImageAndRef(
+    bool need_unref = cache.GetTaskForImageAndRef(
         draw_image, ImageDecodeCache::TracingInfo(), &task);
     EXPECT_TRUE(need_unref);
     EXPECT_FALSE(task);
-    cache->UnrefImage(draw_image);
+    cache.UnrefImage(draw_image);
   }
 
-  // Add a new image to the cache It should push out the old one.
+  // Add a new image to the cache. It should push out the old one.
   {
     scoped_refptr<TileTask> task;
-    bool need_unref = cache->GetTaskForImageAndRef(
+    bool need_unref = cache.GetTaskForImageAndRef(
         draw_image2, ImageDecodeCache::TracingInfo(), &task);
     EXPECT_TRUE(need_unref);
     EXPECT_TRUE(task);
@@ -1638,24 +1583,24 @@
     // Run the task and unref the image.
     TestTileTaskRunner::ProcessTask(task->dependencies()[0].get());
     TestTileTaskRunner::ProcessTask(task.get());
-    cache->UnrefImage(draw_image2);
+    cache.UnrefImage(draw_image2);
   }
 
   // Request the second image - it should be cached.
   {
     scoped_refptr<TileTask> task;
-    bool need_unref = cache->GetTaskForImageAndRef(
+    bool need_unref = cache.GetTaskForImageAndRef(
         draw_image2, ImageDecodeCache::TracingInfo(), &task);
     EXPECT_TRUE(need_unref);
     EXPECT_FALSE(task);
-    cache->UnrefImage(draw_image2);
+    cache.UnrefImage(draw_image2);
   }
 
   // Request the first image - it should have been evicted and return a new
   // task.
   {
     scoped_refptr<TileTask> task;
-    bool need_unref = cache->GetTaskForImageAndRef(
+    bool need_unref = cache.GetTaskForImageAndRef(
         draw_image, ImageDecodeCache::TracingInfo(), &task);
     EXPECT_TRUE(need_unref);
     EXPECT_TRUE(task);
@@ -1665,12 +1610,14 @@
     // Run the task and unref the image.
     TestTileTaskRunner::ProcessTask(task->dependencies()[0].get());
     TestTileTaskRunner::ProcessTask(task.get());
-    cache->UnrefImage(draw_image);
+    cache.UnrefImage(draw_image);
   }
 }
 
 TEST_P(GpuImageDecodeCacheTest, ClearCache) {
-  auto cache = CreateCache();
+  auto context_provider = TestContextProvider::Create();
+  context_provider->BindToCurrentThread();
+  TestGpuImageDecodeCache cache(context_provider.get(), GetParam());
   bool is_decomposable = true;
   SkFilterQuality quality = kHigh_SkFilterQuality;
 
@@ -1681,27 +1628,31 @@
         CreateMatrix(SkSize::Make(1.0f, 1.0f), is_decomposable),
         DefaultColorSpace());
     scoped_refptr<TileTask> task;
-    bool need_unref = cache->GetTaskForImageAndRef(
+    bool need_unref = cache.GetTaskForImageAndRef(
         draw_image, ImageDecodeCache::TracingInfo(), &task);
     EXPECT_TRUE(need_unref);
     EXPECT_TRUE(task);
     TestTileTaskRunner::ProcessTask(task->dependencies()[0].get());
     TestTileTaskRunner::ProcessTask(task.get());
-    cache->UnrefImage(draw_image);
+    cache.UnrefImage(draw_image);
   }
 
-  // We should now have images in our cache.
-  EXPECT_EQ(cache->GetNumCacheEntriesForTesting(), 10u);
+  // We should now have data image in our cache.
+  EXPECT_GT(cache.GetBytesUsedForTesting(), 0u);
+  EXPECT_EQ(cache.GetNumCacheEntriesForTesting(), 10u);
 
   // Tell our cache to clear resources.
-  cache->ClearCache();
+  cache.ClearCache();
 
   // We should now have nothing in our cache.
-  EXPECT_EQ(cache->GetNumCacheEntriesForTesting(), 0u);
+  EXPECT_EQ(cache.GetBytesUsedForTesting(), 0u);
+  EXPECT_EQ(cache.GetNumCacheEntriesForTesting(), 0u);
 }
 
 TEST_P(GpuImageDecodeCacheTest, ClearCacheInUse) {
-  auto cache = CreateCache();
+  auto context_provider = TestContextProvider::Create();
+  context_provider->BindToCurrentThread();
+  TestGpuImageDecodeCache cache(context_provider.get(), GetParam());
   bool is_decomposable = true;
   SkFilterQuality quality = kHigh_SkFilterQuality;
 
@@ -1712,7 +1663,7 @@
                        CreateMatrix(SkSize::Make(1.0f, 1.0f), is_decomposable),
                        DefaultColorSpace());
   scoped_refptr<TileTask> task;
-  bool need_unref = cache->GetTaskForImageAndRef(
+  bool need_unref = cache.GetTaskForImageAndRef(
       draw_image, ImageDecodeCache::TracingInfo(), &task);
   EXPECT_TRUE(need_unref);
   EXPECT_TRUE(task);
@@ -1720,24 +1671,26 @@
   TestTileTaskRunner::ProcessTask(task.get());
 
   // We should now have data image in our cache.
-  EXPECT_GT(cache->GetWorkingSetBytesForTesting(), 0u);
-  EXPECT_EQ(cache->GetNumCacheEntriesForTesting(), 1u);
+  EXPECT_GT(cache.GetBytesUsedForTesting(), 0u);
+  EXPECT_EQ(cache.GetNumCacheEntriesForTesting(), 1u);
 
   // Tell our cache to clear resources.
-  cache->ClearCache();
+  cache.ClearCache();
   // We should still have data, as we can't clear the in-use entry.
-  EXPECT_GT(cache->GetWorkingSetBytesForTesting(), 0u);
+  EXPECT_GT(cache.GetBytesUsedForTesting(), 0u);
   // But the num (persistent) entries should be 0, as the entry is orphaned.
-  EXPECT_EQ(cache->GetNumCacheEntriesForTesting(), 0u);
+  EXPECT_EQ(cache.GetNumCacheEntriesForTesting(), 0u);
 
   // Unref the image, it should immidiately delete, leaving our cache empty.
-  cache->UnrefImage(draw_image);
-  EXPECT_EQ(cache->GetWorkingSetBytesForTesting(), 0u);
-  EXPECT_EQ(cache->GetNumCacheEntriesForTesting(), 0u);
+  cache.UnrefImage(draw_image);
+  EXPECT_EQ(cache.GetBytesUsedForTesting(), 0u);
+  EXPECT_EQ(cache.GetNumCacheEntriesForTesting(), 0u);
 }
 
 TEST_P(GpuImageDecodeCacheTest, GetTaskForImageDifferentColorSpace) {
-  auto cache = CreateCache();
+  auto context_provider = TestContextProvider::Create();
+  context_provider->BindToCurrentThread();
+  TestGpuImageDecodeCache cache(context_provider.get(), GetParam());
   bool is_decomposable = true;
   SkFilterQuality quality = kHigh_SkFilterQuality;
 
@@ -1750,7 +1703,7 @@
       quality, CreateMatrix(SkSize::Make(1.0f, 1.0f), is_decomposable),
       color_space_a);
   scoped_refptr<TileTask> first_task;
-  bool need_unref = cache->GetTaskForImageAndRef(
+  bool need_unref = cache.GetTaskForImageAndRef(
       first_draw_image, ImageDecodeCache::TracingInfo(), &first_task);
   EXPECT_TRUE(need_unref);
   EXPECT_TRUE(first_task);
@@ -1760,7 +1713,7 @@
       quality, CreateMatrix(SkSize::Make(1.0f, 1.0f), is_decomposable),
       color_space_b);
   scoped_refptr<TileTask> second_task;
-  need_unref = cache->GetTaskForImageAndRef(
+  need_unref = cache.GetTaskForImageAndRef(
       second_draw_image, ImageDecodeCache::TracingInfo(), &second_task);
   EXPECT_TRUE(need_unref);
   EXPECT_TRUE(second_task);
@@ -1771,7 +1724,7 @@
       quality, CreateMatrix(SkSize::Make(1.0f, 1.0f), is_decomposable),
       color_space_a);
   scoped_refptr<TileTask> third_task;
-  need_unref = cache->GetTaskForImageAndRef(
+  need_unref = cache.GetTaskForImageAndRef(
       third_draw_image, ImageDecodeCache::TracingInfo(), &third_task);
   EXPECT_TRUE(need_unref);
   EXPECT_TRUE(third_task.get() == first_task.get());
@@ -1781,13 +1734,15 @@
   TestTileTaskRunner::ProcessTask(second_task->dependencies()[0].get());
   TestTileTaskRunner::ProcessTask(second_task.get());
 
-  cache->UnrefImage(first_draw_image);
-  cache->UnrefImage(second_draw_image);
-  cache->UnrefImage(third_draw_image);
+  cache.UnrefImage(first_draw_image);
+  cache.UnrefImage(second_draw_image);
+  cache.UnrefImage(third_draw_image);
 }
 
 TEST_P(GpuImageDecodeCacheTest, RemoveUnusedImage) {
-  auto cache = CreateCache();
+  auto context_provider = TestContextProvider::Create();
+  context_provider->BindToCurrentThread();
+  TestGpuImageDecodeCache cache(context_provider.get(), GetParam());
   bool is_decomposable = true;
   SkFilterQuality quality = kHigh_SkFilterQuality;
   std::vector<PaintImage::FrameKey> frame_keys;
@@ -1800,22 +1755,23 @@
         DefaultColorSpace());
     frame_keys.push_back(draw_image.frame_key());
     scoped_refptr<TileTask> task;
-    bool need_unref = cache->GetTaskForImageAndRef(
+    bool need_unref = cache.GetTaskForImageAndRef(
         draw_image, ImageDecodeCache::TracingInfo(), &task);
     EXPECT_TRUE(need_unref);
     EXPECT_TRUE(task);
     TestTileTaskRunner::ProcessTask(task->dependencies()[0].get());
     TestTileTaskRunner::ProcessTask(task.get());
-    cache->UnrefImage(draw_image);
+    cache.UnrefImage(draw_image);
   }
 
-  // We should now have images in our cache.
-  EXPECT_EQ(cache->GetNumCacheEntriesForTesting(), 10u);
+  // We should now have data image in our cache.
+  EXPECT_GT(cache.GetBytesUsedForTesting(), 0u);
+  EXPECT_EQ(cache.GetNumCacheEntriesForTesting(), 10u);
 
   // Remove unused ids.
   for (uint32_t i = 0; i < 10; ++i) {
-    cache->NotifyImageUnused(frame_keys[i]);
-    EXPECT_EQ(cache->GetNumCacheEntriesForTesting(), (10 - i - 1));
+    cache.NotifyImageUnused(frame_keys[i]);
+    EXPECT_EQ(cache.GetNumCacheEntriesForTesting(), (10 - i - 1));
   }
 }
 
diff --git a/cc/trees/layer_tree_host_impl.cc b/cc/trees/layer_tree_host_impl.cc
index 3a33775..86d05b6 100644
--- a/cc/trees/layer_tree_host_impl.cc
+++ b/cc/trees/layer_tree_host_impl.cc
@@ -2327,7 +2327,8 @@
         layer_tree_frame_sink_->worker_context_provider(),
         viz::ResourceFormatToClosestSkColorType(
             settings_.preferred_tile_format),
-        settings_.decoded_image_working_set_budget_bytes);
+        settings_.decoded_image_working_set_budget_bytes,
+        settings_.decoded_image_cache_budget_bytes);
   } else {
     image_decode_cache_ = std::make_unique<SoftwareImageDecodeCache>(
         viz::ResourceFormatToClosestSkColorType(
diff --git a/cc/trees/layer_tree_host_unittest.cc b/cc/trees/layer_tree_host_unittest.cc
index 3a384c0..6ceb018 100644
--- a/cc/trees/layer_tree_host_unittest.cc
+++ b/cc/trees/layer_tree_host_unittest.cc
@@ -7604,6 +7604,7 @@
 
     // Set to 0 to force at-raster GPU image decode.
     settings->decoded_image_working_set_budget_bytes = 0;
+    settings->decoded_image_cache_budget_bytes = 0;
   }
 
   void SetupTree() override {
diff --git a/cc/trees/layer_tree_settings.h b/cc/trees/layer_tree_settings.h
index e9ddd25..d045f67 100644
--- a/cc/trees/layer_tree_settings.h
+++ b/cc/trees/layer_tree_settings.h
@@ -87,6 +87,7 @@
   int max_staging_buffer_usage_in_bytes = 32 * 1024 * 1024;
   ManagedMemoryPolicy gpu_memory_policy;
   ManagedMemoryPolicy software_memory_policy;
+  size_t decoded_image_cache_budget_bytes = 128 * 1024 * 1024;
   size_t decoded_image_working_set_budget_bytes = 128 * 1024 * 1024;
   int max_preraster_distance_in_screen_pixels = 1000;
   viz::ResourceFormat preferred_tile_format;
diff --git a/chrome/android/java/src/org/chromium/chrome/browser/init/AsyncInitializationActivity.java b/chrome/android/java/src/org/chromium/chrome/browser/init/AsyncInitializationActivity.java
index 8e280121..5af02e6f 100644
--- a/chrome/android/java/src/org/chromium/chrome/browser/init/AsyncInitializationActivity.java
+++ b/chrome/android/java/src/org/chromium/chrome/browser/init/AsyncInitializationActivity.java
@@ -397,10 +397,13 @@
     @Override
     public void onResume() {
         super.onResume();
-        mNativeInitializationController.onResume();
-        if (mLaunchBehindWorkaround != null) mLaunchBehindWorkaround.onResume();
+
+        // Start by setting the launch as cold or warm. It will be used in some resume handlers.
         mIsWarmOnResume = !mFirstResumePending || hadWarmStart();
         mFirstResumePending = false;
+
+        mNativeInitializationController.onResume();
+        if (mLaunchBehindWorkaround != null) mLaunchBehindWorkaround.onResume();
     }
 
     @CallSuper
diff --git a/chrome/browser/about_flags.cc b/chrome/browser/about_flags.cc
index 3db2b47f..6108089b 100644
--- a/chrome/browser/about_flags.cc
+++ b/chrome/browser/about_flags.cc
@@ -1055,8 +1055,8 @@
 
 const FeatureEntry::Choice kEnableOutOfProcessHeapProfilingChoices[] = {
     {flags_ui::kGenericExperimentChoiceDisabled, "", ""},
-    {flag_descriptions::kEnableOutOfProcessHeapProfilingModeBrowser,
-     switches::kMemlog, switches::kMemlogModeBrowser},
+    {flag_descriptions::kEnableOutOfProcessHeapProfilingModeMinimal,
+     switches::kMemlog, switches::kMemlogModeMinimal},
     {flag_descriptions::kEnableOutOfProcessHeapProfilingModeAll,
      switches::kMemlog, switches::kMemlogModeAll}};
 
diff --git a/chrome/browser/chromeos/lock_screen_apps/state_controller.cc b/chrome/browser/chromeos/lock_screen_apps/state_controller.cc
index b09f9eb9..910a220 100644
--- a/chrome/browser/chromeos/lock_screen_apps/state_controller.cc
+++ b/chrome/browser/chromeos/lock_screen_apps/state_controller.cc
@@ -31,6 +31,7 @@
 #include "components/prefs/pref_service.h"
 #include "components/safe_browsing/common/safe_browsing_prefs.h"
 #include "components/session_manager/core/session_manager.h"
+#include "components/user_manager/user.h"
 #include "content/public/browser/web_contents.h"
 #include "content/public/common/service_manager_connection.h"
 #include "crypto/symmetric_key.h"
@@ -138,6 +139,16 @@
 }
 
 void StateController::SetPrimaryProfile(Profile* profile) {
+  const user_manager::User* user =
+      chromeos::ProfileHelper::Get()->GetUserByProfile(profile);
+  if (!user || !user->HasGaiaAccount()) {
+    if (!ready_callback_.is_null()) {
+      ready_callback_.Run();
+      ready_callback_.Reset();
+    }
+    return;
+  }
+
   g_browser_process->profile_manager()->CreateProfileAsync(
       chromeos::ProfileHelper::GetLockScreenAppProfilePath(),
       base::Bind(&StateController::OnProfilesReady,
diff --git a/chrome/browser/chromeos/lock_screen_apps/state_controller_unittest.cc b/chrome/browser/chromeos/lock_screen_apps/state_controller_unittest.cc
index 3ece893..c85efc8 100644
--- a/chrome/browser/chromeos/lock_screen_apps/state_controller_unittest.cc
+++ b/chrome/browser/chromeos/lock_screen_apps/state_controller_unittest.cc
@@ -19,6 +19,8 @@
 #include "chrome/browser/chromeos/lock_screen_apps/app_manager.h"
 #include "chrome/browser/chromeos/lock_screen_apps/focus_cycler_delegate.h"
 #include "chrome/browser/chromeos/lock_screen_apps/state_observer.h"
+#include "chrome/browser/chromeos/login/users/fake_chrome_user_manager.h"
+#include "chrome/browser/chromeos/login/users/scoped_user_manager_enabler.h"
 #include "chrome/browser/chromeos/note_taking_helper.h"
 #include "chrome/browser/chromeos/profiles/profile_helper.h"
 #include "chrome/browser/extensions/extension_service.h"
@@ -378,7 +380,10 @@
 class LockScreenAppStateTest : public BrowserWithTestWindowTest {
  public:
   LockScreenAppStateTest()
-      : profile_manager_(TestingBrowserProcess::GetGlobal()) {}
+      : fake_user_manager_(new chromeos::FakeChromeUserManager),
+        user_manager_enabler_(fake_user_manager_),
+        profile_manager_(TestingBrowserProcess::GetGlobal()) {}
+
   ~LockScreenAppStateTest() override = default;
 
   void SetUp() override {
@@ -452,6 +457,9 @@
   }
 
   TestingProfile* CreateProfile() override {
+    const AccountId account_id(AccountId::FromUserEmail(kPrimaryProfileName));
+    AddTestUser(account_id);
+    fake_user_manager()->LoginUser(account_id);
     return profile_manager_.CreateTestingProfile(kPrimaryProfileName);
   }
 
@@ -467,6 +475,12 @@
     }
   }
 
+  // Adds test user for the primary profile - virtual so test fixture can
+  // override the test user type.
+  virtual void AddTestUser(const AccountId& account_id) {
+    fake_user_manager()->AddUser(account_id);
+  }
+
   void InitExtensionSystem(Profile* profile) {
     extensions::TestExtensionSystem* extension_system =
         static_cast<extensions::TestExtensionSystem*>(
@@ -570,6 +584,10 @@
            TrayActionState::kActive;
   }
 
+  chromeos::FakeChromeUserManager* fake_user_manager() {
+    return fake_user_manager_;
+  }
+
   TestingProfile* lock_screen_profile() { return lock_screen_profile_; }
 
   chromeos::FakePowerManagerClient* power_manager_client() {
@@ -599,6 +617,9 @@
 
  private:
   std::unique_ptr<base::test::ScopedCommandLine> command_line_;
+
+  chromeos::FakeChromeUserManager* fake_user_manager_;
+  chromeos::ScopedUserManagerEnabler user_manager_enabler_;
   TestingProfileManager profile_manager_;
   TestingProfile* lock_screen_profile_ = nullptr;
 
@@ -636,8 +657,31 @@
   DISALLOW_COPY_AND_ASSIGN(LockScreenAppStateTest);
 };
 
+class LockScreenAppStateKioskUserTest : public LockScreenAppStateTest {
+ public:
+  LockScreenAppStateKioskUserTest() {}
+  ~LockScreenAppStateKioskUserTest() override {}
+
+  void AddTestUser(const AccountId& account_id) override {
+    fake_user_manager()->AddKioskAppUser(account_id);
+  }
+
+ private:
+  DISALLOW_COPY_AND_ASSIGN(LockScreenAppStateKioskUserTest);
+};
+
 }  // namespace
 
+TEST_F(LockScreenAppStateKioskUserTest, SetPrimaryProfile) {
+  ASSERT_EQ(TestAppManager::State::kNotInitialized, app_manager()->state());
+  SetPrimaryProfileAndWaitUntilReady();
+
+  EXPECT_EQ(TestAppManager::State::kNotInitialized, app_manager()->state());
+  EXPECT_EQ(TrayActionState::kNotAvailable,
+            state_controller()->GetLockScreenNoteState());
+  EXPECT_EQ(0u, observer()->observed_states().size());
+}
+
 TEST_F(LockScreenAppStateNotSupportedTest, NoInstance) {
   EXPECT_FALSE(lock_screen_apps::StateController::IsEnabled());
 }
diff --git a/chrome/browser/chromeos/resource_reporter/resource_reporter.cc b/chrome/browser/chromeos/resource_reporter/resource_reporter.cc
index 15331c7..cc5e033 100644
--- a/chrome/browser/chromeos/resource_reporter/resource_reporter.cc
+++ b/chrome/browser/chromeos/resource_reporter/resource_reporter.cc
@@ -144,7 +144,9 @@
   task_records_.reserve(task_ids.size());
 
   for (const auto& id : task_ids) {
-    const double cpu_usage = observed_task_manager()->GetCpuUsage(id);
+    const double cpu_usage =
+        (observed_task_manager()->GetPlatformIndependentCPUUsage(id) /
+         base::SysInfo::NumberOfProcessors());
     const int64_t memory_usage =
         observed_task_manager()->GetPhysicalMemoryUsage(id);
 
diff --git a/chrome/browser/chromeos/resource_reporter/resource_reporter_unittest.cc b/chrome/browser/chromeos/resource_reporter/resource_reporter_unittest.cc
index 5711382..89ca2a00 100644
--- a/chrome/browser/chromeos/resource_reporter/resource_reporter_unittest.cc
+++ b/chrome/browser/chromeos/resource_reporter/resource_reporter_unittest.cc
@@ -14,6 +14,7 @@
 #include "base/memory/memory_pressure_monitor.h"
 #include "base/run_loop.h"
 #include "base/strings/utf_string_conversions.h"
+#include "base/sys_info.h"
 #include "base/timer/mock_timer.h"
 #include "chrome/browser/chromeos/resource_reporter/resource_reporter.h"
 #include "chrome/browser/task_manager/test_task_manager.h"
@@ -67,8 +68,13 @@
   ~DummyTaskManager() override {}
 
   // task_manager::TestTaskManager:
-  double GetCpuUsage(TaskId task_id) const override {
-    return tasks_.at(task_id)->cpu_percent;
+  double GetPlatformIndependentCPUUsage(TaskId task_id) const override {
+    // |cpu_percent| expresses the expected value that the metrics reporter
+    // should give for this Task's group, which is a percentage-of-total,
+    // so we need to multiply up by the number of cores, to have TaskManager
+    // return the correct percentage-of-core CPU usage.
+    return tasks_.at(task_id)->cpu_percent *
+           base::SysInfo::NumberOfProcessors();
   }
   int64_t GetPhysicalMemoryUsage(TaskId task_id) const override {
     return tasks_.at(task_id)->memory_bytes;
@@ -288,10 +294,11 @@
   }
 
   // Make sure you have the right info about the Browser and GPU process.
-  EXPECT_EQ(resource_reporter()->last_browser_process_cpu_, kBrowserProcessCpu);
+  EXPECT_DOUBLE_EQ(resource_reporter()->last_browser_process_cpu_,
+                   kBrowserProcessCpu);
   EXPECT_EQ(resource_reporter()->last_browser_process_memory_,
             kBrowserProcessMemory);
-  EXPECT_EQ(resource_reporter()->last_gpu_process_cpu_, kGpuProcessCpu);
+  EXPECT_DOUBLE_EQ(resource_reporter()->last_gpu_process_cpu_, kGpuProcessCpu);
   EXPECT_EQ(resource_reporter()->last_gpu_process_memory_, kGpuProcessMemory);
 }
 
diff --git a/chrome/browser/chromeos/system_logs/single_debug_daemon_log_source.cc b/chrome/browser/chromeos/system_logs/single_debug_daemon_log_source.cc
index f22b571..a74e5cc 100644
--- a/chrome/browser/chromeos/system_logs/single_debug_daemon_log_source.cc
+++ b/chrome/browser/chromeos/system_logs/single_debug_daemon_log_source.cc
@@ -23,6 +23,10 @@
       return "modetest";
     case SupportedSource::kLsusb:
       return "lsusb";
+    case SupportedSource::kLspci:
+      return "lspci";
+    case SupportedSource::kIfconfig:
+      return "ifconfig";
   }
   NOTREACHED();
   return "";
diff --git a/chrome/browser/chromeos/system_logs/single_debug_daemon_log_source.h b/chrome/browser/chromeos/system_logs/single_debug_daemon_log_source.h
index b7d63111..49aa030 100644
--- a/chrome/browser/chromeos/system_logs/single_debug_daemon_log_source.h
+++ b/chrome/browser/chromeos/system_logs/single_debug_daemon_log_source.h
@@ -22,6 +22,12 @@
 
     // For "lsusb" command.
     kLsusb,
+
+    // For "lspci" command.
+    kLspci,
+
+    // For "ifconfig" command.
+    kIfconfig,
   };
 
   explicit SingleDebugDaemonLogSource(SupportedSource source);
diff --git a/chrome/browser/chromeos/system_logs/single_log_file_log_source.cc b/chrome/browser/chromeos/system_logs/single_log_file_log_source.cc
index e94185d..24b51948 100644
--- a/chrome/browser/chromeos/system_logs/single_log_file_log_source.cc
+++ b/chrome/browser/chromeos/system_logs/single_log_file_log_source.cc
@@ -46,6 +46,14 @@
       return base::FilePath("atrus.log");
     case SupportedSource::kNetLog:
       return base::FilePath("net.log");
+    case SupportedSource::kEventLog:
+      return base::FilePath("eventlog.txt");
+    case SupportedSource::kUpdateEngineLog:
+      return base::FilePath("update_engine.log");
+    case SupportedSource::kPowerManagerLatest:
+      return base::FilePath("power_manager/power_manager.LATEST");
+    case SupportedSource::kPowerManagerPrevious:
+      return base::FilePath("power_manager/power_manager.PREVIOUS");
   }
   NOTREACHED();
   return base::FilePath();
@@ -90,6 +98,12 @@
     case SupportedSource::kNetLog:
       return true;
     case SupportedSource::kUiLatest:
+    // The below sources should be made to return true, but their timestamps are
+    // not in the right format.
+    case SupportedSource::kEventLog:
+    case SupportedSource::kUpdateEngineLog:
+    case SupportedSource::kPowerManagerLatest:
+    case SupportedSource::kPowerManagerPrevious:
       return false;
   }
   NOTREACHED();
diff --git a/chrome/browser/chromeos/system_logs/single_log_file_log_source.h b/chrome/browser/chromeos/system_logs/single_log_file_log_source.h
index e180158..79deca8 100644
--- a/chrome/browser/chromeos/system_logs/single_log_file_log_source.h
+++ b/chrome/browser/chromeos/system_logs/single_log_file_log_source.h
@@ -35,6 +35,18 @@
 
     // For /var/log/net.log.
     kNetLog,
+
+    // For /var/log/eventlog.txt.
+    kEventLog,
+
+    // For /var/log/update_engine.log.
+    kUpdateEngineLog,
+
+    // For /var/log/power_manager/power_manager.LATEST.
+    kPowerManagerLatest,
+
+    // For /var/log/power_manager/power_manager.PREVIOUS.
+    kPowerManagerPrevious,
   };
 
   explicit SingleLogFileLogSource(SupportedSource source);
diff --git a/chrome/browser/component_updater/chrome_component_updater_configurator.cc b/chrome/browser/component_updater/chrome_component_updater_configurator.cc
index 1eecd2c..43204b1c 100644
--- a/chrome/browser/component_updater/chrome_component_updater_configurator.cc
+++ b/chrome/browser/component_updater/chrome_component_updater_configurator.cc
@@ -22,6 +22,7 @@
 #include "components/component_updater/configurator_impl.h"
 #include "components/prefs/pref_registry_simple.h"
 #include "components/prefs/pref_service.h"
+#include "components/update_client/activity_data_service.h"
 #include "components/update_client/update_query_params.h"
 
 #if defined(OS_WIN)
@@ -62,6 +63,7 @@
   bool EnabledBackgroundDownloader() const override;
   bool EnabledCupSigning() const override;
   PrefService* GetPrefService() const override;
+  update_client::ActivityDataService* GetActivityDataService() const override;
   bool IsPerUserInstall() const override;
   std::vector<uint8_t> GetRunActionKeyHash() const override;
 
@@ -179,10 +181,14 @@
 }
 
 PrefService* ChromeConfigurator::GetPrefService() const {
-  DCHECK(pref_service_);
   return pref_service_;
 }
 
+update_client::ActivityDataService* ChromeConfigurator::GetActivityDataService()
+    const {
+  return nullptr;
+}
+
 bool ChromeConfigurator::IsPerUserInstall() const {
   return component_updater::IsPerUserInstall();
 }
diff --git a/chrome/browser/extensions/api/feedback_private/chrome_feedback_private_delegate.cc b/chrome/browser/extensions/api/feedback_private/chrome_feedback_private_delegate.cc
index 5c3f4fc..eacd28e7 100644
--- a/chrome/browser/extensions/api/feedback_private/chrome_feedback_private_delegate.cc
+++ b/chrome/browser/extensions/api/feedback_private/chrome_feedback_private_delegate.cc
@@ -107,25 +107,34 @@
 std::unique_ptr<system_logs::SystemLogsSource>
 ChromeFeedbackPrivateDelegate::CreateSingleLogSource(
     api::feedback_private::LogSource source_type) const {
+  using SupportedLogFileSource =
+      system_logs::SingleLogFileLogSource::SupportedSource;
+  using SupportedDebugDaemonSource =
+      system_logs::SingleDebugDaemonLogSource::SupportedSource;
+
   switch (source_type) {
+    // These map to SupportedLogFileSources.
     case api::feedback_private::LOG_SOURCE_MESSAGES:
       return base::MakeUnique<system_logs::SingleLogFileLogSource>(
-          system_logs::SingleLogFileLogSource::SupportedSource::kMessages);
+          SupportedLogFileSource::kMessages);
     case api::feedback_private::LOG_SOURCE_UILATEST:
       return base::MakeUnique<system_logs::SingleLogFileLogSource>(
-          system_logs::SingleLogFileLogSource::SupportedSource::kUiLatest);
-    case api::feedback_private::LOG_SOURCE_DRMMODETEST:
-      return base::MakeUnique<system_logs::SingleDebugDaemonLogSource>(
-          system_logs::SingleDebugDaemonLogSource::SupportedSource::kModetest);
-    case api::feedback_private::LOG_SOURCE_LSUSB:
-      return base::MakeUnique<system_logs::SingleDebugDaemonLogSource>(
-          system_logs::SingleDebugDaemonLogSource::SupportedSource::kLsusb);
+          SupportedLogFileSource::kUiLatest);
     case api::feedback_private::LOG_SOURCE_ATRUSLOG:
       return base::MakeUnique<system_logs::SingleLogFileLogSource>(
-          system_logs::SingleLogFileLogSource::SupportedSource::kAtrusLog);
+          SupportedLogFileSource::kAtrusLog);
     case api::feedback_private::LOG_SOURCE_NETLOG:
       return base::MakeUnique<system_logs::SingleLogFileLogSource>(
-          system_logs::SingleLogFileLogSource::SupportedSource::kNetLog);
+          SupportedLogFileSource::kNetLog);
+
+    // These map to SupportedDebugDaemonSources.
+    case api::feedback_private::LOG_SOURCE_DRMMODETEST:
+      return base::MakeUnique<system_logs::SingleDebugDaemonLogSource>(
+          SupportedDebugDaemonSource::kModetest);
+    case api::feedback_private::LOG_SOURCE_LSUSB:
+      return base::MakeUnique<system_logs::SingleDebugDaemonLogSource>(
+          SupportedDebugDaemonSource::kLsusb);
+
     case api::feedback_private::LOG_SOURCE_NONE:
     default:
       NOTREACHED() << "Unknown log source type.";
diff --git a/chrome/browser/extensions/api/processes/processes_api.cc b/chrome/browser/extensions/api/processes/processes_api.cc
index 910f103..4e96a3a8 100644
--- a/chrome/browser/extensions/api/processes/processes_api.cc
+++ b/chrome/browser/extensions/api/processes/processes_api.cc
@@ -137,8 +137,8 @@
   if (!include_optional)
     return;
 
-  out_process->cpu.reset(new double(task_manager->GetCpuUsage(id)));
-
+  out_process->cpu.reset(
+      new double(task_manager->GetPlatformIndependentCPUUsage(id)));
   out_process->network.reset(new double(static_cast<double>(
       task_manager->GetProcessTotalNetworkUsage(id))));
 
diff --git a/chrome/browser/extensions/updater/chrome_update_client_config.cc b/chrome/browser/extensions/updater/chrome_update_client_config.cc
index efd9984..60a719d 100644
--- a/chrome/browser/extensions/updater/chrome_update_client_config.cc
+++ b/chrome/browser/extensions/updater/chrome_update_client_config.cc
@@ -2,29 +2,94 @@
 // Use of this source code is governed by a BSD-style license that can be
 // found in the LICENSE file.
 
+#include "chrome/browser/extensions/updater/chrome_update_client_config.h"
+
+#include <algorithm>
+
 #include "base/command_line.h"
 #include "base/version.h"
 #include "chrome/browser/component_updater/component_patcher_operation_out_of_process.h"
 #include "chrome/browser/component_updater/component_updater_utils.h"
-#include "chrome/browser/extensions/updater/chrome_update_client_config.h"
 #include "chrome/browser/google/google_brand.h"
 #include "chrome/browser/update_client/chrome_update_query_params_delegate.h"
 #include "chrome/common/channel_info.h"
 #include "components/prefs/pref_service.h"
+#include "components/update_client/activity_data_service.h"
 #include "components/update_client/update_query_params.h"
 #include "content/public/browser/browser_context.h"
 #include "content/public/browser/storage_partition.h"
+#include "extensions/browser/extension_prefs.h"
 
 namespace extensions {
 
+namespace {
+
+class ExtensionActivityDataService final
+    : public update_client::ActivityDataService {
+ public:
+  explicit ExtensionActivityDataService(ExtensionPrefs* extension_prefs);
+  ~ExtensionActivityDataService() override {}
+
+  // update_client::ActivityDataService:
+  bool GetActiveBit(const std::string& id) const override;
+  int GetDaysSinceLastActive(const std::string& id) const override;
+  int GetDaysSinceLastRollCall(const std::string& id) const override;
+  void ClearActiveBit(const std::string& id) override;
+
+ private:
+  // This member is not owned by this class, it's owned by a profile keyed
+  // service.
+  ExtensionPrefs* extension_prefs_;
+
+  DISALLOW_COPY_AND_ASSIGN(ExtensionActivityDataService);
+};
+
+// Calculates the value to use for the ping days parameter.
+int CalculatePingDays(const base::Time& last_ping_day) {
+  return last_ping_day.is_null()
+             ? update_client::kDaysFirstTime
+             : std::max((base::Time::Now() - last_ping_day).InDays(), 0);
+}
+
+ExtensionActivityDataService::ExtensionActivityDataService(
+    ExtensionPrefs* extension_prefs)
+    : extension_prefs_(extension_prefs) {
+  DCHECK(extension_prefs_);
+}
+
+bool ExtensionActivityDataService::GetActiveBit(const std::string& id) const {
+  return extension_prefs_->GetActiveBit(id);
+}
+
+int ExtensionActivityDataService::GetDaysSinceLastActive(
+    const std::string& id) const {
+  return CalculatePingDays(extension_prefs_->LastActivePingDay(id));
+}
+
+int ExtensionActivityDataService::GetDaysSinceLastRollCall(
+    const std::string& id) const {
+  return CalculatePingDays(extension_prefs_->LastPingDay(id));
+}
+
+void ExtensionActivityDataService::ClearActiveBit(const std::string& id) {
+  extension_prefs_->SetActiveBit(id, false);
+}
+
+}  // namespace
+
 // For privacy reasons, requires encryption of the component updater
 // communication with the update backend.
 ChromeUpdateClientConfig::ChromeUpdateClientConfig(
     content::BrowserContext* context)
     : impl_(base::CommandLine::ForCurrentProcess(),
-            content::BrowserContext::GetDefaultStoragePartition(context)->
-                GetURLRequestContext(),
-            true) {}
+            content::BrowserContext::GetDefaultStoragePartition(context)
+                ->GetURLRequestContext(),
+            true),
+      pref_service_(ExtensionPrefs::Get(context)->pref_service()),
+      activity_data_service_(std::make_unique<ExtensionActivityDataService>(
+          ExtensionPrefs::Get(context))) {
+  DCHECK(pref_service_);
+}
 
 int ChromeUpdateClientConfig::InitialDelay() const {
   return impl_.InitialDelay();
@@ -111,7 +176,12 @@
 }
 
 PrefService* ChromeUpdateClientConfig::GetPrefService() const {
-  return nullptr;
+  return pref_service_;
+}
+
+update_client::ActivityDataService*
+ChromeUpdateClientConfig::GetActivityDataService() const {
+  return activity_data_service_.get();
 }
 
 bool ChromeUpdateClientConfig::IsPerUserInstall() const {
diff --git a/chrome/browser/extensions/updater/chrome_update_client_config.h b/chrome/browser/extensions/updater/chrome_update_client_config.h
index b44ffad2..2de53221 100644
--- a/chrome/browser/extensions/updater/chrome_update_client_config.h
+++ b/chrome/browser/extensions/updater/chrome_update_client_config.h
@@ -7,6 +7,7 @@
 
 #include <stdint.h>
 
+#include <memory>
 #include <string>
 #include <vector>
 
@@ -19,6 +20,10 @@
 class BrowserContext;
 }
 
+namespace update_client {
+class ActivityDataService;
+}
+
 namespace extensions {
 
 class ChromeUpdateClientConfig : public update_client::Configurator {
@@ -47,6 +52,7 @@
   bool EnabledBackgroundDownloader() const override;
   bool EnabledCupSigning() const override;
   PrefService* GetPrefService() const override;
+  update_client::ActivityDataService* GetActivityDataService() const override;
   bool IsPerUserInstall() const override;
   std::vector<uint8_t> GetRunActionKeyHash() const override;
 
@@ -56,6 +62,8 @@
 
  private:
   component_updater::ConfiguratorImpl impl_;
+  PrefService* pref_service_;
+  std::unique_ptr<update_client::ActivityDataService> activity_data_service_;
 
   DISALLOW_COPY_AND_ASSIGN(ChromeUpdateClientConfig);
 };
diff --git a/chrome/browser/flag_descriptions.cc b/chrome/browser/flag_descriptions.cc
index 16683da..47a2fc9 100644
--- a/chrome/browser/flag_descriptions.cc
+++ b/chrome/browser/flag_descriptions.cc
@@ -428,8 +428,8 @@
 const char kEnableOutOfProcessHeapProfilingDescription[] =
     "Creates a profiling service that records stacktraces for all live, "
     "malloced objects.";
-const char kEnableOutOfProcessHeapProfilingModeBrowser[] =
-    "Profile only the browser process.";
+const char kEnableOutOfProcessHeapProfilingModeMinimal[] =
+    "Profile only the browser and GPU processes.";
 const char kEnableOutOfProcessHeapProfilingModeAll[] = "Profile all processes.";
 
 const char kEnablePictureInPictureName[] = "Enable picture in picture.";
diff --git a/chrome/browser/flag_descriptions.h b/chrome/browser/flag_descriptions.h
index 7e7707b..19ed2368 100644
--- a/chrome/browser/flag_descriptions.h
+++ b/chrome/browser/flag_descriptions.h
@@ -279,7 +279,7 @@
 
 extern const char kEnableOutOfProcessHeapProfilingName[];
 extern const char kEnableOutOfProcessHeapProfilingDescription[];
-extern const char kEnableOutOfProcessHeapProfilingModeBrowser[];
+extern const char kEnableOutOfProcessHeapProfilingModeMinimal[];
 extern const char kEnableOutOfProcessHeapProfilingModeAll[];
 
 extern const char kEnablePictureInPictureName[];
diff --git a/chrome/browser/media/router/discovery/mdns/cast_media_sink_service.cc b/chrome/browser/media/router/discovery/mdns/cast_media_sink_service.cc
index c5ba8952b..c6f00bb 100644
--- a/chrome/browser/media/router/discovery/mdns/cast_media_sink_service.cc
+++ b/chrome/browser/media/router/discovery/mdns/cast_media_sink_service.cc
@@ -89,18 +89,22 @@
 
 CastMediaSinkService::CastMediaSinkService(
     const OnSinksDiscoveredCallback& callback,
-    content::BrowserContext* browser_context)
-    : MediaSinkService(callback) {
+    content::BrowserContext* browser_context,
+    const scoped_refptr<base::SequencedTaskRunner>& task_runner)
+    : MediaSinkService(callback), task_runner_(task_runner) {
   // TODO(crbug.com/749305): Migrate the discovery code to use sequences.
   DCHECK_CURRENTLY_ON(content::BrowserThread::UI);
+  DCHECK(task_runner_);
 }
 
 CastMediaSinkService::CastMediaSinkService(
     const OnSinksDiscoveredCallback& callback,
+    const scoped_refptr<base::SequencedTaskRunner>& task_runner,
     std::unique_ptr<CastMediaSinkServiceImpl,
                     content::BrowserThread::DeleteOnIOThread>
         cast_media_sink_service_impl)
     : MediaSinkService(callback),
+      task_runner_(task_runner),
       cast_media_sink_service_impl_(std::move(cast_media_sink_service_impl)) {}
 
 CastMediaSinkService::~CastMediaSinkService() {}
@@ -116,13 +120,12 @@
         base::BindRepeating(&CastMediaSinkService::OnSinksDiscoveredOnIOThread,
                             this),
         cast_channel::CastSocketService::GetInstance(),
-        DiscoveryNetworkMonitor::GetInstance()));
+        DiscoveryNetworkMonitor::GetInstance(), task_runner_));
   }
 
-  content::BrowserThread::PostTask(
-      content::BrowserThread::IO, FROM_HERE,
-      base::BindOnce(&CastMediaSinkServiceImpl::Start,
-                     cast_media_sink_service_impl_->AsWeakPtr()));
+  task_runner_->PostTask(
+      FROM_HERE, base::BindOnce(&CastMediaSinkServiceImpl::Start,
+                                cast_media_sink_service_impl_->AsWeakPtr()));
 
   dns_sd_registry_ = DnsSdRegistry::GetInstance();
   dns_sd_registry_->AddObserver(this);
@@ -139,10 +142,9 @@
   dns_sd_registry_->RemoveObserver(this);
   dns_sd_registry_ = nullptr;
 
-  content::BrowserThread::PostTask(
-      content::BrowserThread::IO, FROM_HERE,
-      base::BindOnce(&CastMediaSinkServiceImpl::Stop,
-                     cast_media_sink_service_impl_->AsWeakPtr()));
+  task_runner_->PostTask(
+      FROM_HERE, base::BindOnce(&CastMediaSinkServiceImpl::Stop,
+                                cast_media_sink_service_impl_->AsWeakPtr()));
 
   cast_media_sink_service_impl_.reset();
 }
@@ -155,8 +157,18 @@
 }
 
 void CastMediaSinkService::ForceDiscovery() {
+  DCHECK_CURRENTLY_ON(content::BrowserThread::UI);
   if (dns_sd_registry_)
     dns_sd_registry_->ForceDiscovery();
+
+  if (!cast_media_sink_service_impl_)
+    return;
+
+  DVLOG(2) << "ForceDiscovery on " << cast_sinks_.size() << " sinks";
+  task_runner_->PostTask(
+      FROM_HERE,
+      base::BindOnce(&CastMediaSinkServiceImpl::AttemptConnection,
+                     cast_media_sink_service_impl_->AsWeakPtr(), cast_sinks_));
 }
 
 void CastMediaSinkService::OnDnsSdEvent(
@@ -167,7 +179,7 @@
   DVLOG(2) << "CastMediaSinkService::OnDnsSdEvent found " << services.size()
            << " services";
 
-  std::vector<MediaSinkInternal> cast_sinks;
+  cast_sinks_.clear();
 
   for (const auto& service : services) {
     // Create Cast sink from mDNS service description.
@@ -178,14 +190,13 @@
       continue;
     }
 
-    cast_sinks.push_back(std::move(cast_sink));
+    cast_sinks_.push_back(std::move(cast_sink));
   }
 
-  content::BrowserThread::PostTask(
-      content::BrowserThread::IO, FROM_HERE,
+  task_runner_->PostTask(
+      FROM_HERE,
       base::BindOnce(&CastMediaSinkServiceImpl::OpenChannels,
-                     cast_media_sink_service_impl_->AsWeakPtr(),
-                     std::move(cast_sinks)));
+                     cast_media_sink_service_impl_->AsWeakPtr(), cast_sinks_));
 }
 
 void CastMediaSinkService::OnDialSinkAdded(const MediaSinkInternal& sink) {
diff --git a/chrome/browser/media/router/discovery/mdns/cast_media_sink_service.h b/chrome/browser/media/router/discovery/mdns/cast_media_sink_service.h
index a75ce45..16f0bad 100644
--- a/chrome/browser/media/router/discovery/mdns/cast_media_sink_service.h
+++ b/chrome/browser/media/router/discovery/mdns/cast_media_sink_service.h
@@ -34,14 +34,18 @@
       public DnsSdRegistry::DnsSdObserver,
       public base::RefCountedThreadSafe<CastMediaSinkService> {
  public:
-  CastMediaSinkService(const OnSinksDiscoveredCallback& callback,
-                       content::BrowserContext* browser_context);
+  CastMediaSinkService(
+      const OnSinksDiscoveredCallback& callback,
+      content::BrowserContext* browser_context,
+      const scoped_refptr<base::SequencedTaskRunner>& task_runner);
 
   // Used by unit tests.
-  CastMediaSinkService(const OnSinksDiscoveredCallback& callback,
-                       std::unique_ptr<CastMediaSinkServiceImpl,
-                                       content::BrowserThread::DeleteOnIOThread>
-                           cast_media_sink_service_impl);
+  CastMediaSinkService(
+      const OnSinksDiscoveredCallback& callback,
+      const scoped_refptr<base::SequencedTaskRunner>& task_runner,
+      std::unique_ptr<CastMediaSinkServiceImpl,
+                      content::BrowserThread::DeleteOnIOThread>
+          cast_media_sink_service_impl);
 
   // mDNS service types.
   static const char kCastServiceType[];
@@ -83,11 +87,17 @@
   // and lives as long as the browser process.
   DnsSdRegistry* dns_sd_registry_ = nullptr;
 
+  // Task runner for the IO thread.
+  scoped_refptr<base::SequencedTaskRunner> task_runner_;
+
   // Created on the UI thread and destroyed on the IO thread.
   std::unique_ptr<CastMediaSinkServiceImpl,
                   content::BrowserThread::DeleteOnIOThread>
       cast_media_sink_service_impl_;
 
+  // List of cast sinks found in current round of mDNS discovery.
+  std::vector<MediaSinkInternal> cast_sinks_;
+
   DISALLOW_COPY_AND_ASSIGN(CastMediaSinkService);
 };
 
diff --git a/chrome/browser/media/router/discovery/mdns/cast_media_sink_service_impl.cc b/chrome/browser/media/router/discovery/mdns/cast_media_sink_service_impl.cc
index 53918c6..8df39fa 100644
--- a/chrome/browser/media/router/discovery/mdns/cast_media_sink_service_impl.cc
+++ b/chrome/browser/media/router/discovery/mdns/cast_media_sink_service_impl.cc
@@ -84,13 +84,14 @@
 CastMediaSinkServiceImpl::CastMediaSinkServiceImpl(
     const OnSinksDiscoveredCallback& callback,
     cast_channel::CastSocketService* cast_socket_service,
-    DiscoveryNetworkMonitor* network_monitor)
+    DiscoveryNetworkMonitor* network_monitor,
+    const scoped_refptr<base::SequencedTaskRunner>& task_runner)
     : MediaSinkServiceBase(callback),
       cast_socket_service_(cast_socket_service),
       network_monitor_(network_monitor),
       backoff_policy_(&kBackoffPolicy),
-      task_runner_(content::BrowserThread::GetTaskRunnerForThread(
-          content::BrowserThread::IO)) {
+      task_runner_(task_runner),
+      net_log_(g_browser_process->net_log()) {
   DETACH_FROM_SEQUENCE(sequence_checker_);
   DCHECK(cast_socket_service_);
   DCHECK(network_monitor_);
@@ -166,7 +167,6 @@
            << " [channel_id]: " << socket.id();
 
   net::IPEndPoint ip_endpoint = socket.ip_endpoint();
-
   // Need a PostTask() here because RemoveSocket() will release the memory of
   // |socket|. Need to make sure all tasks on |socket| finish before deleting
   // the object.
@@ -245,7 +245,7 @@
            << " name: " << cast_sink.sink().name();
 
   cast_socket_service_->OpenSocket(
-      ip_endpoint, g_browser_process->net_log(),
+      ip_endpoint, net_log_,
       base::BindOnce(&CastMediaSinkServiceImpl::OnChannelOpened, AsWeakPtr(),
                      cast_sink, std::move(backoff_entry)),
       this);
@@ -345,4 +345,17 @@
               base::MakeUnique<net::BackoffEntry>(backoff_policy_));
 }
 
+void CastMediaSinkServiceImpl::AttemptConnection(
+    const std::vector<MediaSinkInternal>& cast_sinks) {
+  DCHECK_CALLED_ON_VALID_SEQUENCE(sequence_checker_);
+
+  for (const auto& cast_sink : cast_sinks) {
+    const net::IPEndPoint& ip_endpoint = cast_sink.cast_data().ip_endpoint;
+    if (!base::ContainsKey(current_sinks_map_, ip_endpoint.address())) {
+      OpenChannel(ip_endpoint, cast_sink,
+                  base::MakeUnique<net::BackoffEntry>(backoff_policy_));
+    }
+  }
+}
+
 }  // namespace media_router
diff --git a/chrome/browser/media/router/discovery/mdns/cast_media_sink_service_impl.h b/chrome/browser/media/router/discovery/mdns/cast_media_sink_service_impl.h
index 34fe2bcf..3073a18 100644
--- a/chrome/browser/media/router/discovery/mdns/cast_media_sink_service_impl.h
+++ b/chrome/browser/media/router/discovery/mdns/cast_media_sink_service_impl.h
@@ -40,9 +40,11 @@
   // Initial delay (in seconds) used by backoff policy.
   static constexpr int kDelayInSeconds = 15;
 
-  CastMediaSinkServiceImpl(const OnSinksDiscoveredCallback& callback,
-                           cast_channel::CastSocketService* cast_socket_service,
-                           DiscoveryNetworkMonitor* network_monitor);
+  CastMediaSinkServiceImpl(
+      const OnSinksDiscoveredCallback& callback,
+      cast_channel::CastSocketService* cast_socket_service,
+      DiscoveryNetworkMonitor* network_monitor,
+      const scoped_refptr<base::SequencedTaskRunner>& task_runner);
   ~CastMediaSinkServiceImpl() override;
 
   void SetTaskRunnerForTest(
@@ -62,6 +64,11 @@
 
   void OnDialSinkAdded(const MediaSinkInternal& sink);
 
+  // Tries to open cast channels for sinks found by current round of mDNS
+  // discovery, but without opened cast channels.
+  // |cast_sinks|: list of sinks found by current round of mDNS discovery.
+  void AttemptConnection(const std::vector<MediaSinkInternal>& cast_sinks);
+
  private:
   friend class CastMediaSinkServiceImplTest;
   FRIEND_TEST_ALL_PREFIXES(CastMediaSinkServiceImplTest,
@@ -99,6 +106,7 @@
                            CacheDialDiscoveredSinks);
   FRIEND_TEST_ALL_PREFIXES(CastMediaSinkServiceImplTest,
                            DualDiscoveryDoesntDuplicateCacheItems);
+  FRIEND_TEST_ALL_PREFIXES(CastMediaSinkServiceImplTest, TestAttemptConnection);
 
   // CastSocket::Observer implementation.
   void OnError(const cast_channel::CastSocket& socket,
@@ -186,6 +194,9 @@
 
   scoped_refptr<base::SequencedTaskRunner> task_runner_;
 
+  // Owned by |g_browser_process|.
+  net::NetLog* const net_log_;
+
   SEQUENCE_CHECKER(sequence_checker_);
 
   DISALLOW_COPY_AND_ASSIGN(CastMediaSinkServiceImpl);
diff --git a/chrome/browser/media/router/discovery/mdns/cast_media_sink_service_impl_unittest.cc b/chrome/browser/media/router/discovery/mdns/cast_media_sink_service_impl_unittest.cc
index 5a05acf9..c303459 100644
--- a/chrome/browser/media/router/discovery/mdns/cast_media_sink_service_impl_unittest.cc
+++ b/chrome/browser/media/router/discovery/mdns/cast_media_sink_service_impl_unittest.cc
@@ -72,10 +72,11 @@
   CastMediaSinkServiceImplTest()
       : thread_bundle_(content::TestBrowserThreadBundle::IO_MAINLOOP),
         mock_cast_socket_service_(new cast_channel::MockCastSocketService()),
+        mock_time_task_runner_(new base::TestMockTimeTaskRunner()),
         media_sink_service_impl_(mock_sink_discovered_cb_.Get(),
                                  mock_cast_socket_service_.get(),
-                                 discovery_network_monitor_.get()),
-        mock_time_task_runner_(new base::TestMockTimeTaskRunner()) {}
+                                 discovery_network_monitor_.get(),
+                                 mock_time_task_runner_.get()) {}
 
   void SetUp() override {
     fake_network_info_.clear();
@@ -127,9 +128,9 @@
       mock_sink_discovered_cb_;
   std::unique_ptr<cast_channel::MockCastSocketService>
       mock_cast_socket_service_;
-  CastMediaSinkServiceImpl media_sink_service_impl_;
   base::MockTimer* mock_timer_;
   scoped_refptr<base::TestMockTimeTaskRunner> mock_time_task_runner_;
+  CastMediaSinkServiceImpl media_sink_service_impl_;
 
   DISALLOW_COPY_AND_ASSIGN(CastMediaSinkServiceImplTest);
 };
@@ -395,6 +396,8 @@
               OpenSocketInternal(ip_endpoint1, _, _, _));
   mock_time_task_runner_->FastForwardBy(base::TimeDelta::FromSeconds(16));
   EXPECT_TRUE(media_sink_service_impl_.current_sinks_map_.empty());
+
+  base::RunLoop().RunUntilIdle();
 }
 
 TEST_F(CastMediaSinkServiceImplTest, TestOnChannelErrorNoRetryForMissingSink) {
@@ -488,6 +491,27 @@
   EXPECT_TRUE(base::ContainsValue(sinks, cast_sink3));
 }
 
+TEST_F(CastMediaSinkServiceImplTest, TestAttemptConnection) {
+  auto cast_sink1 = CreateCastSink(1);
+  auto cast_sink2 = CreateCastSink(2);
+  net::IPEndPoint ip_endpoint1 = CreateIPEndPoint(1);
+  net::IPEndPoint ip_endpoint2 = CreateIPEndPoint(2);
+
+  // Find Cast sink 1
+  media_sink_service_impl_.current_sinks_map_[ip_endpoint1.address()] =
+      cast_sink1;
+
+  EXPECT_CALL(*mock_cast_socket_service_,
+              OpenSocketInternal(ip_endpoint1, _, _, _))
+      .Times(0);
+  EXPECT_CALL(*mock_cast_socket_service_,
+              OpenSocketInternal(ip_endpoint2, _, _, _));
+
+  // Attempt to connect to Cast sink 1, 2
+  std::vector<MediaSinkInternal> sinks{cast_sink1, cast_sink2};
+  media_sink_service_impl_.AttemptConnection(sinks);
+}
+
 TEST_F(CastMediaSinkServiceImplTest, CacheSinksForKnownNetwork) {
   fake_network_info_ = fake_ethernet_info_;
   net::NetworkChangeNotifier::NotifyObserversOfNetworkChangeForTests(
diff --git a/chrome/browser/media/router/discovery/mdns/cast_media_sink_service_unittest.cc b/chrome/browser/media/router/discovery/mdns/cast_media_sink_service_unittest.cc
index a729f0f..dfc18fc 100644
--- a/chrome/browser/media/router/discovery/mdns/cast_media_sink_service_unittest.cc
+++ b/chrome/browser/media/router/discovery/mdns/cast_media_sink_service_unittest.cc
@@ -6,6 +6,7 @@
 #include "base/run_loop.h"
 #include "base/strings/stringprintf.h"
 #include "base/test/mock_callback.h"
+#include "base/test/test_simple_task_runner.h"
 #include "base/timer/mock_timer.h"
 #include "chrome/browser/media/router/discovery/mdns/cast_media_sink_service_impl.h"
 #include "chrome/browser/media/router/discovery/mdns/mock_dns_sd_registry.h"
@@ -56,10 +57,12 @@
   MockCastMediaSinkServiceImpl(
       const OnSinksDiscoveredCallback& callback,
       cast_channel::CastSocketService* cast_socket_service,
-      DiscoveryNetworkMonitor* network_monitor)
+      DiscoveryNetworkMonitor* network_monitor,
+      const scoped_refptr<base::SingleThreadTaskRunner>& task_runner)
       : CastMediaSinkServiceImpl(callback,
                                  cast_socket_service,
-                                 network_monitor) {}
+                                 network_monitor,
+                                 task_runner) {}
   ~MockCastMediaSinkServiceImpl() override {}
 
   MOCK_METHOD0(Start, void());
@@ -71,12 +74,15 @@
  public:
   CastMediaSinkServiceTest()
       : mock_cast_socket_service_(new cast_channel::MockCastSocketService()),
+        task_runner_(new base::TestSimpleTaskRunner()),
         mock_media_sink_service_impl_(
             new MockCastMediaSinkServiceImpl(mock_sink_discovered_io_cb_.Get(),
                                              mock_cast_socket_service_.get(),
-                                             discovery_network_monitor_)),
+                                             discovery_network_monitor_,
+                                             task_runner_)),
         media_sink_service_(new CastMediaSinkService(
             mock_sink_discovered_ui_cb_.Get(),
+            task_runner_,
             std::unique_ptr<CastMediaSinkServiceImpl,
                             content::BrowserThread::DeleteOnIOThread>(
                 mock_media_sink_service_impl_))),
@@ -98,6 +104,7 @@
       mock_sink_discovered_ui_cb_;
   std::unique_ptr<cast_channel::MockCastSocketService>
       mock_cast_socket_service_;
+  scoped_refptr<base::TestSimpleTaskRunner> task_runner_;
   MockCastMediaSinkServiceImpl* mock_media_sink_service_impl_;
 
   scoped_refptr<CastMediaSinkService> media_sink_service_;
@@ -181,7 +188,7 @@
       .WillOnce(SaveArg<0>(&sinks));
 
   // Invoke OpenChannels on the IO thread.
-  base::RunLoop().RunUntilIdle();
+  task_runner_->RunUntilIdle();
   // Verify sink content
   EXPECT_EQ(2u, sinks.size());
 
diff --git a/chrome/browser/media/router/mojo/media_router_mojo_impl.cc b/chrome/browser/media/router/mojo/media_router_mojo_impl.cc
index df6c5853..206e36e2 100644
--- a/chrome/browser/media/router/mojo/media_router_mojo_impl.cc
+++ b/chrome/browser/media/router/mojo/media_router_mojo_impl.cc
@@ -833,7 +833,9 @@
       cast_media_sink_service_ = new CastMediaSinkService(
           base::Bind(&MediaRouterMojoImpl::ProvideSinks,
                      weak_factory_.GetWeakPtr(), "cast"),
-          context_);
+          context_,
+          content::BrowserThread::GetTaskRunnerForThread(
+              content::BrowserThread::IO));
     }
     cast_media_sink_service_->Start();
   }
diff --git a/chrome/browser/profiling_host/background_profiling_triggers.cc b/chrome/browser/profiling_host/background_profiling_triggers.cc
index d627ab6..4046e2e 100644
--- a/chrome/browser/profiling_host/background_profiling_triggers.cc
+++ b/chrome/browser/profiling_host/background_profiling_triggers.cc
@@ -15,8 +15,9 @@
 // Check memory usage every hour. Trigger slow report if needed.
 const int kRepeatingCheckMemoryDelayInHours = 1;
 const int kSecondReportRepeatingCheckMemoryDelayInHours = 12;
-const size_t kBrowserProcessMallocTriggerKb = 600 * 1024;    // 600 Meg
-const size_t kRendererProcessMallocTriggerKb = 2000 * 1024;  // 2 Gig
+const size_t kBrowserProcessMallocTriggerKb = 600 * 1024;    // 600 MB
+const size_t kGPUProcessMallocTriggerKb = 1000 * 1024;       // 1 GB
+const size_t kRendererProcessMallocTriggerKb = 2000 * 1024;  // 2 GB
 }  // namespace
 
 BackgroundProfilingTriggers::BackgroundProfilingTriggers(
@@ -62,12 +63,19 @@
 
     if (proc->process_type ==
             memory_instrumentation::mojom::ProcessType::BROWSER &&
-        (mode == profiling::ProfilingProcessHost::Mode::kBrowser ||
+        (mode == profiling::ProfilingProcessHost::Mode::kMinimal ||
          mode == profiling::ProfilingProcessHost::Mode::kAll)) {
       trigger_report =
           proc->os_dump->private_footprint_kb > kBrowserProcessMallocTriggerKb;
     }
 
+    if (proc->process_type == memory_instrumentation::mojom::ProcessType::GPU &&
+        (mode == profiling::ProfilingProcessHost::Mode::kMinimal ||
+         mode == profiling::ProfilingProcessHost::Mode::kAll)) {
+      trigger_report =
+          proc->os_dump->private_footprint_kb > kGPUProcessMallocTriggerKb;
+    }
+
     if (proc->process_type ==
             memory_instrumentation::mojom::ProcessType::RENDERER &&
         mode == profiling::ProfilingProcessHost::Mode::kAll) {
diff --git a/chrome/browser/profiling_host/background_profiling_triggers_unittest.cc b/chrome/browser/profiling_host/background_profiling_triggers_unittest.cc
index e16d3d65..601eee0 100644
--- a/chrome/browser/profiling_host/background_profiling_triggers_unittest.cc
+++ b/chrome/browser/profiling_host/background_profiling_triggers_unittest.cc
@@ -78,6 +78,8 @@
   PopulateMetrics(dump, 2, ProcessType::RENDERER, kProcessMallocTriggerKb,
                   kProcessMallocTriggerKb);
   PopulateMetrics(dump, 3, ProcessType::RENDERER, 1, 1);
+  PopulateMetrics(dump, 4, ProcessType::GPU, kProcessMallocTriggerKb,
+                  kProcessMallocTriggerKb);
   return dump;
 }
 
@@ -87,7 +89,7 @@
   TestBackgroundProfilingTriggers triggers;
 
   // Validate triggers for browser processes only.
-  triggers.host_.SetMode(ProfilingProcessHost::Mode::kBrowser);
+  triggers.host_.SetMode(ProfilingProcessHost::Mode::kMinimal);
 
   GlobalMemoryDumpPtr dump_empty(
       memory_instrumentation::mojom::GlobalMemoryDump::New());
@@ -101,17 +103,25 @@
   triggers.OnReceivedMemoryDump(true, std::move(dump_browser));
   EXPECT_TRUE(triggers.pids_.empty());
 
-  // A larger browser process must trigger a report. Renderers are not reported.
+  // A larger browser and GPU process must trigger a report. Renderers are not
+  // reported.
   triggers.OnReceivedMemoryDump(true, GetLargeMemoryDump());
-  EXPECT_THAT(triggers.pids_, testing::ElementsAre(1));
+  EXPECT_THAT(triggers.pids_, testing::ElementsAre(1, 4));
   triggers.Reset();
 
+  // A small gpu process doesn't trigger a report.
+  GlobalMemoryDumpPtr dump_gpu(
+      memory_instrumentation::mojom::GlobalMemoryDump::New());
+  PopulateMetrics(dump_gpu, 1, ProcessType::GPU, 1, 1);
+  triggers.OnReceivedMemoryDump(true, std::move(dump_gpu));
+  EXPECT_TRUE(triggers.pids_.empty());
+
   // Validate triggers for all processes.
   triggers.host_.SetMode(ProfilingProcessHost::Mode::kAll);
 
   // Both browser and renderer must be reported.
   triggers.OnReceivedMemoryDump(true, GetLargeMemoryDump());
-  EXPECT_THAT(triggers.pids_, testing::ElementsAre(1, 2));
+  EXPECT_THAT(triggers.pids_, testing::ElementsAre(1, 2, 4));
   triggers.Reset();
 
   // Validate triggers when off.
diff --git a/chrome/browser/profiling_host/memlog_browsertest.cc b/chrome/browser/profiling_host/memlog_browsertest.cc
index 2098ad9..54c4735 100644
--- a/chrome/browser/profiling_host/memlog_browsertest.cc
+++ b/chrome/browser/profiling_host/memlog_browsertest.cc
@@ -39,7 +39,7 @@
                         ::testing::Values(static_cast<const char*>(nullptr)));
 INSTANTIATE_TEST_CASE_P(BrowserOnly,
                         MemlogBrowserTest,
-                        ::testing::Values(switches::kMemlogModeBrowser));
+                        ::testing::Values(switches::kMemlogModeMinimal));
 INSTANTIATE_TEST_CASE_P(AllProcesses,
                         MemlogBrowserTest,
                         ::testing::Values(switches::kMemlogModeAll));
diff --git a/chrome/browser/profiling_host/profiling_process_host.cc b/chrome/browser/profiling_host/profiling_process_host.cc
index b7165ad..ee8b85b1 100644
--- a/chrome/browser/profiling_host/profiling_process_host.cc
+++ b/chrome/browser/profiling_host/profiling_process_host.cc
@@ -134,9 +134,11 @@
 
 void ProfilingProcessHost::BrowserChildProcessLaunchedAndConnected(
     const content::ChildProcessData& data) {
-  // Ignore newly launched child process if only profiling the browser.
-  if (mode_ == Mode::kBrowser)
+  // In minimal mode, only profile the GPU process.
+  if (mode_ == Mode::kMinimal &&
+      data.process_type != content::ProcessType::PROCESS_TYPE_GPU) {
     return;
+  }
 
   if (!content::BrowserThread::CurrentlyOn(content::BrowserThread::IO)) {
     content::BrowserThread::GetTaskRunnerForThread(content::BrowserThread::IO)
@@ -158,6 +160,7 @@
       mojo::MakeRequest(&memlog_client);
   BindInterface(host->GetHost(), std::move(request));
   base::ProcessId pid = base::GetProcId(data.handle);
+  LOG(ERROR) << "start profiling: " << pid;
   SendPipeToProfilingService(std::move(memlog_client), pid);
 }
 
@@ -165,8 +168,9 @@
     int type,
     const content::NotificationSource& source,
     const content::NotificationDetails& details) {
-  // Ignore newly launched renderer if only profiling the browser.
-  if (mode_ == Mode::kBrowser)
+  // Ignore newly launched renderer if only profiling a minimal set of
+  // processes.
+  if (mode_ == Mode::kMinimal)
     return;
 
   if (type != content::NOTIFICATION_RENDERER_PROCESS_CREATED)
@@ -195,15 +199,6 @@
 bool ProfilingProcessHost::OnMemoryDump(
     const base::trace_event::MemoryDumpArgs& args,
     base::trace_event::ProcessMemoryDump* pmd) {
-  // Dump the browser process, which happens to be this process.
-  if (GetCurrentMode() == Mode::kBrowser) {
-    memlog_->DumpProcessForTracing(
-        base::Process::Current().Pid(),
-        base::BindOnce(&ProfilingProcessHost::OnDumpProcessForTracingCallback,
-                       base::Unretained(this)));
-    return true;
-  }
-
   // Attempt to dump all processes. Some of these processes will not be profiled
   // [e.g. utility processes, including the profiling process]. The profiling
   // process will gracefully handle these failures.
@@ -294,8 +289,8 @@
     std::string mode = cmdline->GetSwitchValueASCII(switches::kMemlog);
     if (mode == switches::kMemlogModeAll)
       return Mode::kAll;
-    if (mode == switches::kMemlogModeBrowser)
-      return Mode::kBrowser;
+    if (mode == switches::kMemlogModeMinimal)
+      return Mode::kMinimal;
 
     DLOG(ERROR) << "Unsupported value: \"" << mode << "\" passed to --"
                 << switches::kMemlog;
diff --git a/chrome/browser/profiling_host/profiling_process_host.h b/chrome/browser/profiling_host/profiling_process_host.h
index 148d020b..8c2c27c4 100644
--- a/chrome/browser/profiling_host/profiling_process_host.h
+++ b/chrome/browser/profiling_host/profiling_process_host.h
@@ -52,8 +52,8 @@
     // No profiling enabled.
     kNone,
 
-    // Only profile the browser process.
-    kBrowser,
+    // Only profile the browser and GPU processes.
+    kMinimal,
 
     // Profile all processes.
     kAll,
diff --git a/chrome/browser/safe_browsing/chrome_cleaner/chrome_cleaner_dialog_controller_impl_browsertest_win.cc b/chrome/browser/safe_browsing/chrome_cleaner/chrome_cleaner_dialog_controller_impl_browsertest_win.cc
index 14d5301..893949d6 100644
--- a/chrome/browser/safe_browsing/chrome_cleaner/chrome_cleaner_dialog_controller_impl_browsertest_win.cc
+++ b/chrome/browser/safe_browsing/chrome_cleaner/chrome_cleaner_dialog_controller_impl_browsertest_win.cc
@@ -11,11 +11,15 @@
 #include "base/run_loop.h"
 #include "chrome/browser/profiles/profile_manager.h"
 #include "chrome/browser/safe_browsing/chrome_cleaner/chrome_cleaner_controller_win.h"
+#include "chrome/browser/safe_browsing/chrome_cleaner/srt_field_trial_win.h"
 #include "chrome/browser/ui/browser.h"
+#include "chrome/browser/ui/browser_finder.h"
 #include "chrome/browser/ui/browser_window.h"
 #include "chrome/test/base/in_process_browser_test.h"
+#include "components/component_updater/pref_names.h"
 #include "components/keep_alive_registry/keep_alive_types.h"
 #include "components/keep_alive_registry/scoped_keep_alive.h"
+#include "components/variations/variations_params_manager.h"
 #include "testing/gmock/include/gmock/gmock.h"
 #include "testing/gtest/include/gtest/gtest.h"
 
@@ -27,6 +31,8 @@
 using ::testing::StrictMock;
 using ::testing::Return;
 
+constexpr char kSRTPromptGroup[] = "SRTGroup";
+
 class MockChromeCleanerPromptDelegate : public ChromeCleanerPromptDelegate {
  public:
   MOCK_METHOD3(ShowChromeCleanerPrompt,
@@ -52,8 +58,24 @@
   MOCK_METHOD0(Reboot, void());
 };
 
-class ChromeCleanerPromptUserTest : public InProcessBrowserTest {
+// Parameters for this test:
+//  - const char* old_seed_: The old "Seed" Finch parameter saved in prefs.
+//  - const char* incoming_seed_: The new "Seed" Finch parameter.
+class ChromeCleanerPromptUserTest
+    : public InProcessBrowserTest,
+      public ::testing::WithParamInterface<
+          testing::tuple<const char*, const char*>> {
  public:
+  ChromeCleanerPromptUserTest() {
+    std::tie(old_seed_, incoming_seed_) = GetParam();
+  }
+
+  void SetUpCommandLine(base::CommandLine* command_line) override {
+    variations::testing::VariationParamsManager::AppendVariationParams(
+        kSRTPromptTrial, kSRTPromptGroup, {{"Seed", incoming_seed_}},
+        command_line);
+  }
+
   void SetUpInProcessBrowserTestFixture() override {
 // dialog_controller_ expects that the cleaner controller would be on
 // scanning state.
@@ -67,19 +89,35 @@
     dialog_controller_->SetPromptDelegateForTests(&mock_delegate_);
   }
 
+  void SetUpOnMainThread() override {
+    chrome::FindLastActive()->profile()->GetPrefs()->SetString(
+        prefs::kSwReporterPromptSeed, old_seed_);
+  }
+
+  void TearDownOnMainThread() override {
+    bool expect_seed_changed =
+        !incoming_seed_.empty() && (incoming_seed_ != old_seed_);
+    EXPECT_EQ(expect_seed_changed ? incoming_seed_ : old_seed_,
+              chrome::FindLastActive()->profile()->GetPrefs()->GetString(
+                  prefs::kSwReporterPromptSeed));
+  }
+
  protected:
   MockChromeCleanerController mock_cleaner_controller_;
   ChromeCleanerDialogControllerImpl* dialog_controller_;
   StrictMock<MockChromeCleanerPromptDelegate> mock_delegate_;
+
+  std::string old_seed_;
+  std::string incoming_seed_;
 };
 
-IN_PROC_BROWSER_TEST_F(ChromeCleanerPromptUserTest,
+IN_PROC_BROWSER_TEST_P(ChromeCleanerPromptUserTest,
                        OnInfectedBrowserAvailable) {
   EXPECT_CALL(mock_delegate_, ShowChromeCleanerPrompt(_, _, _)).Times(1);
   dialog_controller_->OnInfected(std::set<base::FilePath>());
 }
 
-IN_PROC_BROWSER_TEST_F(ChromeCleanerPromptUserTest,
+IN_PROC_BROWSER_TEST_P(ChromeCleanerPromptUserTest,
                        DISABLED_OnInfectedBrowserNotAvailable) {
   browser()->window()->Minimize();
   base::RunLoop().RunUntilIdle();
@@ -95,7 +133,7 @@
   run_loop.Run();
 }
 
-IN_PROC_BROWSER_TEST_F(ChromeCleanerPromptUserTest, AllBrowsersClosed) {
+IN_PROC_BROWSER_TEST_P(ChromeCleanerPromptUserTest, AllBrowsersClosed) {
   std::unique_ptr<ScopedKeepAlive> keep_alive =
       base::MakeUnique<ScopedKeepAlive>(KeepAliveOrigin::BROWSER,
                                         KeepAliveRestartOption::DISABLED);
@@ -114,5 +152,12 @@
   run_loop.Run();
 }
 
+INSTANTIATE_TEST_CASE_P(
+    WithVaryingSeeds,
+    ChromeCleanerPromptUserTest,
+    ::testing::Combine(
+        ::testing::Values("", "Seed1"),             // old_seed_
+        ::testing::Values("", "Seed1", "Seed2")));  // incoming_seed
+
 }  // namespace
 }  // namespace safe_browsing
diff --git a/chrome/browser/safe_browsing/chrome_cleaner/chrome_cleaner_dialog_controller_impl_win.cc b/chrome/browser/safe_browsing/chrome_cleaner/chrome_cleaner_dialog_controller_impl_win.cc
index 52dbed6..d0fb3c9 100644
--- a/chrome/browser/safe_browsing/chrome_cleaner/chrome_cleaner_dialog_controller_impl_win.cc
+++ b/chrome/browser/safe_browsing/chrome_cleaner/chrome_cleaner_dialog_controller_impl_win.cc
@@ -7,11 +7,14 @@
 #include "base/metrics/histogram_macros.h"
 #include "base/metrics/user_metrics.h"
 #include "base/metrics/user_metrics_action.h"
+#include "chrome/browser/profiles/profile.h"
 #include "chrome/browser/safe_browsing/chrome_cleaner/chrome_cleaner_navigation_util_win.h"
 #include "chrome/browser/safe_browsing/chrome_cleaner/srt_field_trial_win.h"
 #include "chrome/browser/ui/browser.h"
 #include "chrome/browser/ui/browser_dialogs.h"
 #include "chrome/browser/ui/browser_list.h"
+#include "components/component_updater/pref_names.h"
+#include "components/prefs/pref_service.h"
 #include "ui/base/window_open_disposition.h"
 
 namespace safe_browsing {
@@ -232,6 +235,19 @@
 }
 
 void ChromeCleanerDialogControllerImpl::ShowChromeCleanerPrompt() {
+  DCHECK(browser_);
+  Profile* profile = browser_->profile();
+  DCHECK(profile);
+  PrefService* prefs = profile->GetPrefs();
+  DCHECK(prefs);
+
+  // Don't show the prompt again if it's been shown before for this profile and
+  // for the current variations seed.
+  const std::string incoming_seed = GetIncomingSRTSeed();
+  const std::string old_seed = prefs->GetString(prefs::kSwReporterPromptSeed);
+  if (!incoming_seed.empty() && incoming_seed != old_seed)
+    prefs->SetString(prefs::kSwReporterPromptSeed, incoming_seed);
+
   prompt_delegate_->ShowChromeCleanerPrompt(browser_, this,
                                             cleaner_controller_);
   dialog_shown_ = true;
diff --git a/chrome/browser/safe_browsing/chrome_cleaner/reporter_runner_browsertest_win.cc b/chrome/browser/safe_browsing/chrome_cleaner/reporter_runner_browsertest_win.cc
index c2dd6833..3f698f6 100644
--- a/chrome/browser/safe_browsing/chrome_cleaner/reporter_runner_browsertest_win.cc
+++ b/chrome/browser/safe_browsing/chrome_cleaner/reporter_runner_browsertest_win.cc
@@ -50,7 +50,7 @@
 
 constexpr char kSRTPromptGroup[] = "SRTGroup";
 
-// Parameter for this test:
+// Parameters for this test:
 //  - bool in_browser_cleaner_ui_: indicates if InBrowserCleanerUI feature
 //    is enabled;
 //
@@ -333,8 +333,7 @@
 }
 
 IN_PROC_BROWSER_TEST_P(ReporterRunnerTest, CleanupNeeded) {
-  bool expect_prompt =
-      incoming_seed_.empty() ? true : incoming_seed_ != old_seed_;
+  bool expect_prompt = incoming_seed_.empty() || (incoming_seed_ != old_seed_);
 
   RunReporter(chrome_cleaner::kSwReporterCleanupNeeded);
   ExpectReporterLaunches(0, 1, expect_prompt);
diff --git a/chrome/browser/safe_browsing/chrome_cleaner/reporter_runner_win.cc b/chrome/browser/safe_browsing/chrome_cleaner/reporter_runner_win.cc
index 3059caf..58c7264 100644
--- a/chrome/browser/safe_browsing/chrome_cleaner/reporter_runner_win.cc
+++ b/chrome/browser/safe_browsing/chrome_cleaner/reporter_runner_win.cc
@@ -607,7 +607,8 @@
   DCHECK(prefs);
 
   // Don't show the prompt again if it's been shown before for this profile and
-  // for the current variations seed.
+  // for the current variations seed. The seed preference will be updated once
+  // the prompt is shown.
   const std::string incoming_seed = GetIncomingSRTSeed();
   const std::string old_seed = prefs->GetString(prefs::kSwReporterPromptSeed);
   if (!incoming_seed.empty() && incoming_seed == old_seed) {
@@ -616,9 +617,6 @@
     return;
   }
 
-  if (!incoming_seed.empty() && incoming_seed != old_seed)
-    prefs->SetString(prefs::kSwReporterPromptSeed, incoming_seed);
-
   if (g_testing_delegate_) {
     g_testing_delegate_->TriggerPrompt();
     return;
diff --git a/chrome/browser/ssl/ssl_browser_tests.cc b/chrome/browser/ssl/ssl_browser_tests.cc
index 713ffe2..94e91fc 100644
--- a/chrome/browser/ssl/ssl_browser_tests.cc
+++ b/chrome/browser/ssl/ssl_browser_tests.cc
@@ -44,6 +44,7 @@
 #include "chrome/browser/ssl/certificate_reporting_test_utils.h"
 #include "chrome/browser/ssl/chrome_ssl_host_state_delegate.h"
 #include "chrome/browser/ssl/common_name_mismatch_handler.h"
+#include "chrome/browser/ssl/mitm_software_blocking_page.h"
 #include "chrome/browser/ssl/security_state_tab_helper.h"
 #include "chrome/browser/ssl/ssl_blocking_page.h"
 #include "chrome/browser/ssl/ssl_error_assistant.pb.h"
@@ -138,10 +139,6 @@
 #include "chrome/browser/ssl/captive_portal_blocking_page.h"
 #endif
 
-#if !defined(OS_IOS)
-#include "chrome/browser/ssl/mitm_software_blocking_page.h"
-#endif
-
 #if defined(USE_NSS_CERTS)
 #include "chrome/browser/net/nss_context.h"
 #include "net/cert/nss_cert_database.h"
@@ -5383,8 +5380,6 @@
 
 #endif  // BUILDFLAG(ENABLE_CAPTIVE_PORTAL_DETECTION)
 
-// The MITM software interstitial is not yet supported on iOS.
-#if !defined(OS_IOS)
 namespace {
 
 char kTestHostName[] = "example.test";
@@ -5836,18 +5831,6 @@
       interstitial_page, expected_explanation));
 }
 
-#else
-
-// Tests that the MITM software interstitial does not render on iOS, where it
-// is disabled by build.
-IN_PROC_BROWSER_TEST_F(SSLUIMITMSoftwareEnabledTest,
-                       DisabledByBuild_NoMITMSoftwareInterstitial) {
-  SetUpCertVerifier(net::CERT_STATUS_AUTHORITY_INVALID);
-  TestNoMITMSoftwareInterstitial();
-}
-
-#endif  // #if !defined(OS_IOS)
-
 class SuperfishSSLUITest : public CertVerifierBrowserTest {
  public:
   SuperfishSSLUITest()
diff --git a/chrome/browser/ssl/ssl_error_handler.cc b/chrome/browser/ssl/ssl_error_handler.cc
index 5e1aa6b..3ef6909 100644
--- a/chrome/browser/ssl/ssl_error_handler.cc
+++ b/chrome/browser/ssl/ssl_error_handler.cc
@@ -22,6 +22,7 @@
 #include "chrome/browser/browser_process.h"
 #include "chrome/browser/profiles/profile.h"
 #include "chrome/browser/ssl/bad_clock_blocking_page.h"
+#include "chrome/browser/ssl/mitm_software_blocking_page.h"
 #include "chrome/browser/ssl/ssl_blocking_page.h"
 #include "chrome/browser/ssl/ssl_cert_reporter.h"
 #include "chrome/browser/ssl/ssl_error_assistant.pb.h"
@@ -38,6 +39,7 @@
 #include "content/public/browser/web_contents.h"
 #include "net/base/net_errors.h"
 #include "third_party/protobuf/src/google/protobuf/io/zero_copy_stream_impl_lite.h"
+#include "third_party/re2/src/re2/re2.h"
 #include "ui/base/resource/resource_bundle.h"
 
 #if BUILDFLAG(ENABLE_CAPTIVE_PORTAL_DETECTION)
@@ -47,24 +49,16 @@
 #include "chrome/browser/ssl/captive_portal_blocking_page.h"
 #endif
 
-#if !defined(OS_IOS)
-
 #if defined(OS_WIN)
 #include "base/win/win_util.h"
 #elif defined(OS_CHROMEOS)
 #include "chrome/browser/chromeos/policy/browser_policy_connector_chromeos.h"
 #endif  // #if defined(OS_WIN)
 
-#include "chrome/browser/ssl/mitm_software_blocking_page.h"
-#include "third_party/re2/src/re2/re2.h"
-#endif  // if !defined(OS_IOS)
-
 namespace {
 
-#if !defined(OS_IOS)
 const base::Feature kMITMSoftwareInterstitial{
     "MITMSoftwareInterstitial", base::FEATURE_DISABLED_BY_DEFAULT};
-#endif
 
 #if BUILDFLAG(ENABLE_CAPTIVE_PORTAL_DETECTION)
 const base::Feature kCaptivePortalInterstitial{
@@ -205,7 +199,6 @@
 }
 #endif
 
-#if !defined(OS_IOS)
 bool IsMITMSoftwareInterstitialEnabled() {
   return base::FeatureList::IsEnabled(kMITMSoftwareInterstitial);
 }
@@ -248,7 +241,6 @@
   }
   return mitm_software_list;
 }
-#endif
 
 // Reads the SSL error assistant configuration from the resource bundle.
 std::unique_ptr<chrome_browser_ssl::SSLErrorAssistantConfig>
@@ -284,13 +276,11 @@
   bool IsKnownCaptivePortalCert(const net::SSLInfo& ssl_info);
 #endif
 
-#if !defined(OS_IOS)
   // Returns the name of a known MITM software provider that matches the
   // certificate passed in as the |cert| parameter. Returns empty string if
   // there is no match.
   const std::string MatchKnownMITMSoftware(
       const scoped_refptr<net::X509Certificate> cert);
-#endif
 
   // Testing methods:
   void ResetForTesting();
@@ -320,7 +310,6 @@
 
   network_time::NetworkTimeTracker* network_time_tracker_ = nullptr;
 
-#if !defined(OS_IOS)
   // Error assistant configuration.
   std::unique_ptr<chrome_browser_ssl::SSLErrorAssistantConfig>
       error_assistant_proto_;
@@ -333,7 +322,6 @@
     ENTERPRISE_MANAGED_STATUS_FALSE
   };
   EnterpriseManaged is_enterprise_managed_for_testing_;
-#endif
 
 #if BUILDFLAG(ENABLE_CAPTIVE_PORTAL_DETECTION)
   // SPKI hashes belonging to certs treated as captive portals. Null until the
@@ -373,11 +361,10 @@
   timer_started_callback_ = nullptr;
   network_time_tracker_ = nullptr;
   testing_clock_ = nullptr;
-#if !defined(OS_IOS)
   error_assistant_proto_.reset();
   mitm_software_list_.reset();
   is_enterprise_managed_for_testing_ = ENTERPRISE_MANAGED_STATUS_NOT_SET;
-#endif
+
 #if BUILDFLAG(ENABLE_CAPTIVE_PORTAL_DETECTION)
   captive_portal_spki_hashes_.reset();
 #endif
@@ -412,16 +399,13 @@
 }
 
 bool ConfigSingleton::IsEnterpriseManagedFlagSetForTesting() const {
-#if !defined(OS_IOS)
   if (is_enterprise_managed_for_testing_ == ENTERPRISE_MANAGED_STATUS_NOT_SET) {
     return false;
   }
   return true;
-#endif
 }
 
 bool ConfigSingleton::IsEnterpriseManaged() const {
-#if !defined(OS_IOS)
   // Return the value of the testing flag if it's set.
   if (is_enterprise_managed_for_testing_ == ENTERPRISE_MANAGED_STATUS_TRUE) {
     return true;
@@ -441,12 +425,8 @@
 #endif  // #if defined(OS_WIN)
 
   return false;
-#else
-  NOTREACHED();
-#endif
 }
 
-#if !defined(OS_IOS)
 void ConfigSingleton::SetErrorAssistantProto(
     std::unique_ptr<chrome_browser_ssl::SSLErrorAssistantConfig> proto) {
   DCHECK_CURRENTLY_ON(content::BrowserThread::UI);
@@ -465,7 +445,6 @@
       LoadCaptivePortalCertHashes(*error_assistant_proto_);
 #endif  // ENABLE_CAPTIVE_PORTAL_DETECTION
 }
-#endif  // OS_IOS
 
 #if BUILDFLAG(ENABLE_CAPTIVE_PORTAL_DETECTION)
 bool ConfigSingleton::IsKnownCaptivePortalCert(const net::SSLInfo& ssl_info) {
@@ -490,8 +469,6 @@
 }
 #endif
 
-#if !defined(OS_IOS)
-
 bool RegexMatchesAny(const std::vector<std::string>& organization_names,
                      const std::string& pattern) {
   const re2::RE2 regex(pattern);
@@ -560,10 +537,8 @@
       }
     }
   }
-
   return std::string();
 }
-#endif
 
 class SSLErrorHandlerDelegateImpl : public SSLErrorHandler::Delegate {
  public:
@@ -677,15 +652,11 @@
 void SSLErrorHandlerDelegateImpl::ShowMITMSoftwareInterstitial(
     const std::string& mitm_software_name,
     bool is_enterprise_managed) {
-#if !defined(OS_IOS)
   // Show MITM software blocking page. The interstitial owns the blocking page.
   (new MITMSoftwareBlockingPage(
        web_contents_, cert_error_, request_url_, std::move(ssl_cert_reporter_),
        ssl_info_, mitm_software_name, is_enterprise_managed, callback_))
       ->Show();
-#else
-  NOTREACHED();
-#endif
 }
 
 void SSLErrorHandlerDelegateImpl::ShowSSLInterstitial() {
@@ -790,9 +761,7 @@
 
 void SSLErrorHandler::SetErrorAssistantProto(
     std::unique_ptr<chrome_browser_ssl::SSLErrorAssistantConfig> config_proto) {
-#if !defined(OS_IOS)
   g_config.Pointer()->SetErrorAssistantProto(std::move(config_proto));
-#endif
 }
 
 SSLErrorHandler::SSLErrorHandler(
@@ -845,7 +814,6 @@
   }
 #endif
 
-#if !defined(OS_IOS)
   // The MITM software interstitial is displayed if and only if:
   // - the error thrown is not overridable
   // - the only certificate error is CERT_STATUS_AUTHORITY_INVALID
@@ -861,7 +829,6 @@
       return;
     }
   }
-#endif
 
   if (IsSSLCommonNameMismatchHandlingEnabled() &&
       cert_error_ == net::ERR_CERT_COMMON_NAME_INVALID &&
@@ -941,7 +908,6 @@
 void SSLErrorHandler::ShowMITMSoftwareInterstitial(
     const std::string& mitm_software_name,
     bool is_enterprise_managed) {
-#if !defined(OS_IOS)
   // Show SSL blocking page. The interstitial owns the blocking page.
   RecordUMA(SHOW_MITM_SOFTWARE_INTERSTITIAL);
   delegate_->ShowMITMSoftwareInterstitial(mitm_software_name,
@@ -949,9 +915,6 @@
   // Once an interstitial is displayed, no need to keep the handler around.
   // This is the equivalent of "delete this".
   web_contents_->RemoveUserData(UserDataKey());
-#else
-  NOTREACHED();
-#endif
 }
 
 void SSLErrorHandler::ShowSSLInterstitial() {
diff --git a/chrome/browser/ssl/ssl_error_handler_unittest.cc b/chrome/browser/ssl/ssl_error_handler_unittest.cc
index afb448c..2b847c4 100644
--- a/chrome/browser/ssl/ssl_error_handler_unittest.cc
+++ b/chrome/browser/ssl/ssl_error_handler_unittest.cc
@@ -1155,8 +1155,6 @@
 
 #endif  // BUILDFLAG(ENABLE_CAPTIVE_PORTAL_DETECTION)
 
-#if !defined(OS_IOS)
-
 // Tests that if a certificate matches the issuer common name regex of a MITM
 // software entry but not the issuer organization name a MITM software
 // interstitial will not be displayed.
@@ -1382,18 +1380,3 @@
                                SSLErrorHandler::SHOW_MITM_SOFTWARE_INTERSTITIAL,
                                0);
 }
-
-#else
-
-// Tests that the MITM software interstitial is not triggered on iOS, where it
-// is disabled by build.
-TEST_F(SSLErrorAssistantTest, MITMSoftware_DisabledByBuild_NoInterstitial) {
-  SetMITMSoftwareFeatureEnabled(true);
-
-  ResetErrorHandlerFromString(kMisconfiguredFirewallCert,
-                              net::CERT_STATUS_AUTHORITY_INVALID);
-  InitMITMSoftwareList();
-  TestNoMITMSoftwareInterstitial();
-}
-
-#endif  // #if !defined(OS_IOS)
diff --git a/chrome/browser/task_manager/sampling/task_group.cc b/chrome/browser/task_manager/sampling/task_group.cc
index 874ead1..d5381dc 100644
--- a/chrome/browser/task_manager/sampling/task_group.cc
+++ b/chrome/browser/task_manager/sampling/task_group.cc
@@ -88,7 +88,7 @@
       shared_sampler_(shared_sampler),
       expected_on_bg_done_flags_(kBackgroundRefreshTypesMask),
       current_on_bg_done_flags_(0),
-      cpu_usage_(0.0),
+      platform_independent_cpu_usage_(0.0),
       gpu_memory_(-1),
       memory_state_(base::MemoryState::UNKNOWN),
       per_process_network_usage_rate_(-1),
@@ -291,7 +291,7 @@
 void TaskGroup::OnCpuRefreshDone(double cpu_usage) {
   DCHECK_CURRENTLY_ON(content::BrowserThread::UI);
 
-  cpu_usage_ = cpu_usage;
+  platform_independent_cpu_usage_ = cpu_usage;
   OnBackgroundRefreshTypeFinished(REFRESH_TYPE_CPU);
 }
 
diff --git a/chrome/browser/task_manager/sampling/task_group.h b/chrome/browser/task_manager/sampling/task_group.h
index a648d116..73f528c 100644
--- a/chrome/browser/task_manager/sampling/task_group.h
+++ b/chrome/browser/task_manager/sampling/task_group.h
@@ -69,7 +69,9 @@
   size_t num_tasks() const { return tasks().size(); }
   bool empty() const { return tasks().empty(); }
 
-  double cpu_usage() const { return cpu_usage_; }
+  double platform_independent_cpu_usage() const {
+    return platform_independent_cpu_usage_;
+  }
   base::Time start_time() const { return start_time_; }
   base::TimeDelta cpu_time() const { return cpu_time_; }
   int64_t private_bytes() const { return memory_usage_.private_bytes; }
@@ -158,7 +160,7 @@
   int64_t current_on_bg_done_flags_;
 
   // The per process resources usages.
-  double cpu_usage_;
+  double platform_independent_cpu_usage_;
   base::Time start_time_;     // Only calculated On Windows now.
   base::TimeDelta cpu_time_;  // Only calculated On Windows now.
   MemoryUsageStats memory_usage_;
diff --git a/chrome/browser/task_manager/sampling/task_group_sampler.cc b/chrome/browser/task_manager/sampling/task_group_sampler.cc
index ba90471..9d0d95f 100644
--- a/chrome/browser/task_manager/sampling/task_group_sampler.cc
+++ b/chrome/browser/task_manager/sampling/task_group_sampler.cc
@@ -118,7 +118,7 @@
 double TaskGroupSampler::RefreshCpuUsage() {
   DCHECK(worker_pool_sequenced_checker_.CalledOnValidSequence());
 
-  return process_metrics_->GetCPUUsage();
+  return process_metrics_->GetPlatformIndependentCPUUsage();
 }
 
 MemoryUsageStats TaskGroupSampler::RefreshMemoryUsage() {
diff --git a/chrome/browser/task_manager/sampling/task_manager_impl.cc b/chrome/browser/task_manager/sampling/task_manager_impl.cc
index 8032d4d..3b2783bf 100644
--- a/chrome/browser/task_manager/sampling/task_manager_impl.cc
+++ b/chrome/browser/task_manager/sampling/task_manager_impl.cc
@@ -96,8 +96,8 @@
   GetTaskByTaskId(task_id)->Kill();
 }
 
-double TaskManagerImpl::GetCpuUsage(TaskId task_id) const {
-  return GetTaskGroupByTaskId(task_id)->cpu_usage();
+double TaskManagerImpl::GetPlatformIndependentCPUUsage(TaskId task_id) const {
+  return GetTaskGroupByTaskId(task_id)->platform_independent_cpu_usage();
 }
 
 base::Time TaskManagerImpl::GetStartTime(TaskId task_id) const {
diff --git a/chrome/browser/task_manager/sampling/task_manager_impl.h b/chrome/browser/task_manager/sampling/task_manager_impl.h
index ded2668..cfa263ab 100644
--- a/chrome/browser/task_manager/sampling/task_manager_impl.h
+++ b/chrome/browser/task_manager/sampling/task_manager_impl.h
@@ -41,7 +41,7 @@
   void ActivateTask(TaskId task_id) override;
   bool IsTaskKillable(TaskId task_id) override;
   void KillTask(TaskId task_id) override;
-  double GetCpuUsage(TaskId task_id) const override;
+  double GetPlatformIndependentCPUUsage(TaskId task_id) const override;
   base::Time GetStartTime(TaskId task_id) const override;
   base::TimeDelta GetCpuTime(TaskId task_id) const override;
   int64_t GetPhysicalMemoryUsage(TaskId task_id) const override;
diff --git a/chrome/browser/task_manager/task_manager_interface.h b/chrome/browser/task_manager/task_manager_interface.h
index fcd9c32a..ec5d65f 100644
--- a/chrome/browser/task_manager/task_manager_interface.h
+++ b/chrome/browser/task_manager/task_manager_interface.h
@@ -73,9 +73,10 @@
   // Kills the task with |task_id|.
   virtual void KillTask(TaskId task_id) = 0;
 
-  // Returns the CPU usage in percent for the process on which the task with
-  // |task_id| is running during the current refresh cycle.
-  virtual double GetCpuUsage(TaskId task_id) const = 0;
+  // Returns the CPU usage of the process on which |task_id| is running, over
+  // the most recent refresh cycle. The value is in the range zero to
+  // base::SysInfo::NumberOfProcessors() * 100%.
+  virtual double GetPlatformIndependentCPUUsage(TaskId task_id) const = 0;
 
   // Returns the start time for the process on which the task
   // with |task_id| is running. Only implemented in Windows now.
diff --git a/chrome/browser/task_manager/test_task_manager.cc b/chrome/browser/task_manager/test_task_manager.cc
index 23d93ee..db80170 100644
--- a/chrome/browser/task_manager/test_task_manager.cc
+++ b/chrome/browser/task_manager/test_task_manager.cc
@@ -26,7 +26,7 @@
 void TestTaskManager::KillTask(TaskId task_id) {
 }
 
-double TestTaskManager::GetCpuUsage(TaskId task_id) const {
+double TestTaskManager::GetPlatformIndependentCPUUsage(TaskId task_id) const {
   return 0.0;
 }
 
diff --git a/chrome/browser/task_manager/test_task_manager.h b/chrome/browser/task_manager/test_task_manager.h
index bca4d0a6..06433ee 100644
--- a/chrome/browser/task_manager/test_task_manager.h
+++ b/chrome/browser/task_manager/test_task_manager.h
@@ -26,7 +26,7 @@
   void ActivateTask(TaskId task_id) override;
   bool IsTaskKillable(TaskId task_id) override;
   void KillTask(TaskId task_id) override;
-  double GetCpuUsage(TaskId task_id) const override;
+  double GetPlatformIndependentCPUUsage(TaskId task_id) const override;
   base::Time GetStartTime(TaskId task_id) const override;
   base::TimeDelta GetCpuTime(TaskId task_id) const override;
   int64_t GetPhysicalMemoryUsage(TaskId task_id) const override;
diff --git a/chrome/browser/ui/BUILD.gn b/chrome/browser/ui/BUILD.gn
index caf8d2d..1b1f539 100644
--- a/chrome/browser/ui/BUILD.gn
+++ b/chrome/browser/ui/BUILD.gn
@@ -80,6 +80,8 @@
     "blocked_content/popup_blocker_tab_helper.h",
     "blocked_content/popup_tracker.cc",
     "blocked_content/popup_tracker.h",
+    "blocked_content/scoped_visibility_tracker.cc",
+    "blocked_content/scoped_visibility_tracker.h",
     "bookmarks/bookmark_bar.h",
     "bookmarks/bookmark_bar_constants.h",
     "bookmarks/bookmark_bar_instructions_delegate.h",
diff --git a/chrome/browser/ui/app_list/search/arc/arc_playstore_search_provider.cc b/chrome/browser/ui/app_list/search/arc/arc_playstore_search_provider.cc
index 30bae24..54976f2 100644
--- a/chrome/browser/ui/app_list/search/arc/arc_playstore_search_provider.cc
+++ b/chrome/browser/ui/app_list/search/arc/arc_playstore_search_provider.cc
@@ -4,6 +4,7 @@
 
 #include "chrome/browser/ui/app_list/search/arc/arc_playstore_search_provider.h"
 
+#include <string>
 #include <utility>
 
 #include "base/metrics/histogram_macros.h"
@@ -33,9 +34,16 @@
   if (!result.package_name.has_value())
     return false;
 
-  return !extensions::util::GetEquivalentInstalledExtensions(
-              context, result.package_name.value())
-              .empty();
+  if (!extensions::util::GetEquivalentInstalledExtensions(
+           context, result.package_name.value())
+           .empty()) {
+    return true;
+  }
+
+  // TODO(crbug/763562): Remove this once we have a fix in Phonesky.
+  // Don't show installed Android apps.
+  const ArcAppListPrefs* arc_prefs = ArcAppListPrefs::Get(context);
+  return arc_prefs && arc_prefs->GetPackage(result.package_name.value());
 }
 }  // namespace
 
diff --git a/chrome/browser/ui/ash/ash_util.cc b/chrome/browser/ui/ash/ash_util.cc
index a7972dad..dc03105 100644
--- a/chrome/browser/ui/ash/ash_util.cc
+++ b/chrome/browser/ui/ash/ash_util.cc
@@ -9,11 +9,8 @@
 #include "ash/public/cpp/config.h"
 #include "ash/public/interfaces/event_properties.mojom.h"
 #include "ash/shell.h"
-#include "base/command_line.h"
 #include "base/macros.h"
-#include "build/build_config.h"
 #include "chrome/browser/chromeos/ash_config.h"
-#include "chrome/browser/ui/ash/ash_init.h"
 #include "content/public/common/service_names.mojom.h"
 #include "services/service_manager/public/cpp/binder_registry.h"
 #include "services/service_manager/public/cpp/service.h"
diff --git a/chrome/browser/ui/blocked_content/popup_blocker_browsertest.cc b/chrome/browser/ui/blocked_content/popup_blocker_browsertest.cc
index 3b20287..da155f07 100644
--- a/chrome/browser/ui/blocked_content/popup_blocker_browsertest.cc
+++ b/chrome/browser/ui/blocked_content/popup_blocker_browsertest.cc
@@ -348,6 +348,45 @@
   tester.ExpectTotalCount(kClickThroughPosition, 4);
 }
 
+IN_PROC_BROWSER_TEST_F(PopupBlockerBrowserTest, PopupMetrics) {
+  const char kPopupActions[] = "ContentSettings.Popups.BlockerActions";
+  base::HistogramTester tester;
+
+  const GURL url(
+      embedded_test_server()->GetURL("/popup_blocker/popup-many.html"));
+  ui_test_utils::NavigateToURL(browser(), url);
+  EXPECT_EQ(2, GetBlockedContentsCount());
+
+  tester.ExpectBucketCount(
+      kPopupActions,
+      static_cast<int>(PopupBlockerTabHelper::Action::kInitiated), 2);
+  tester.ExpectBucketCount(
+      kPopupActions, static_cast<int>(PopupBlockerTabHelper::Action::kBlocked),
+      2);
+
+  // Click through one of them.
+  auto* popup_blocker = PopupBlockerTabHelper::FromWebContents(
+      browser()->tab_strip_model()->GetActiveWebContents());
+  popup_blocker->ShowBlockedPopup(
+      popup_blocker->GetBlockedPopupRequests().begin()->first,
+      WindowOpenDisposition::NEW_BACKGROUND_TAB);
+
+  tester.ExpectBucketCount(
+      kPopupActions,
+      static_cast<int>(PopupBlockerTabHelper::Action::kClickedThrough), 1);
+
+  // Whitelist the site and navigate again.
+  HostContentSettingsMapFactory::GetForProfile(browser()->profile())
+      ->SetContentSettingDefaultScope(url, GURL(), CONTENT_SETTINGS_TYPE_POPUPS,
+                                      std::string(), CONTENT_SETTING_ALLOW);
+  ui_test_utils::NavigateToURL(browser(), url);
+  tester.ExpectBucketCount(
+      kPopupActions,
+      static_cast<int>(PopupBlockerTabHelper::Action::kInitiated), 4);
+  // 4 initiated popups, 2 blocked, and 1 clicked through.
+  tester.ExpectTotalCount(kPopupActions, 4 + 2 + 1);
+}
+
 IN_PROC_BROWSER_TEST_F(PopupBlockerBrowserTest, MultiplePopups) {
   GURL url(embedded_test_server()->GetURL("/popup_blocker/popup-many.html"));
   ui_test_utils::NavigateToURL(browser(), url);
diff --git a/chrome/browser/ui/blocked_content/popup_blocker_tab_helper.cc b/chrome/browser/ui/blocked_content/popup_blocker_tab_helper.cc
index d77b5886..5e3c488 100644
--- a/chrome/browser/ui/blocked_content/popup_blocker_tab_helper.cc
+++ b/chrome/browser/ui/blocked_content/popup_blocker_tab_helper.cc
@@ -14,6 +14,7 @@
 #include "chrome/browser/profiles/profile.h"
 #include "chrome/browser/subresource_filter/chrome_subresource_filter_client.h"
 #include "chrome/browser/ui/blocked_content/blocked_window_params.h"
+#include "chrome/browser/ui/blocked_content/popup_tracker.h"
 #include "chrome/browser/ui/browser_navigator.h"
 #include "chrome/browser/ui/browser_navigator_params.h"
 #include "chrome/common/chrome_render_frame.mojom.h"
@@ -110,6 +111,8 @@
   DCHECK(!open_url_params ||
          open_url_params->user_gesture == params.user_gesture);
 
+  LogAction(Action::kInitiated);
+
   const bool user_gesture = params.user_gesture;
   if (!web_contents)
     return false;
@@ -160,6 +163,7 @@
 void PopupBlockerTabHelper::AddBlockedPopup(
     const chrome::NavigateParams& params,
     const blink::mojom::WindowFeatures& window_features) {
+  LogAction(Action::kBlocked);
   if (blocked_popups_.size() >= kMaximumNumberOfPopups)
     return;
 
@@ -195,19 +199,23 @@
 #else
   chrome::Navigate(&popup->params);
 #endif
-  if (popup->params.disposition == WindowOpenDisposition::NEW_POPUP &&
-      popup->params.target_contents) {
-    content::RenderFrameHost* host =
-        popup->params.target_contents->GetMainFrame();
-    DCHECK(host);
-    chrome::mojom::ChromeRenderFrameAssociatedPtr client;
-    host->GetRemoteAssociatedInterfaces()->GetInterface(&client);
-    client->SetWindowFeatures(popup->window_features.Clone());
+  if (popup->params.target_contents) {
+    PopupTracker::CreateForWebContents(popup->params.target_contents);
+
+    if (popup->params.disposition == WindowOpenDisposition::NEW_POPUP) {
+      content::RenderFrameHost* host =
+          popup->params.target_contents->GetMainFrame();
+      DCHECK(host);
+      chrome::mojom::ChromeRenderFrameAssociatedPtr client;
+      host->GetRemoteAssociatedInterfaces()->GetInterface(&client);
+      client->SetWindowFeatures(popup->window_features.Clone());
+    }
   }
 
   blocked_popups_.erase(id);
   if (blocked_popups_.empty())
     PopupNotificationVisibilityChanged(false);
+  LogAction(Action::kClickedThrough);
 }
 
 size_t PopupBlockerTabHelper::GetBlockedPopupsCount() const {
@@ -237,3 +245,9 @@
 
   return PopupPosition::kMiddlePopup;
 }
+
+// static
+void PopupBlockerTabHelper::LogAction(Action action) {
+  UMA_HISTOGRAM_ENUMERATION("ContentSettings.Popups.BlockerActions", action,
+                            Action::kLast);
+}
diff --git a/chrome/browser/ui/blocked_content/popup_blocker_tab_helper.h b/chrome/browser/ui/blocked_content/popup_blocker_tab_helper.h
index f2c17e8..f5f077b 100644
--- a/chrome/browser/ui/blocked_content/popup_blocker_tab_helper.h
+++ b/chrome/browser/ui/blocked_content/popup_blocker_tab_helper.h
@@ -48,6 +48,24 @@
     // Any new values should go before this one.
     kLast,
   };
+
+  // This enum is backed by a histogram. Make sure enums.xml is updated if this
+  // is updated.
+  enum class Action : int {
+    // A popup was initiated and was sent to the popup blocker for
+    // consideration.
+    kInitiated,
+
+    // A popup was blocked by the popup blocker.
+    kBlocked,
+
+    // A previously blocked popup was clicked through.
+    kClickedThrough,
+
+    // Add new elements before this value.
+    kLast
+  };
+
   class Observer {
    public:
     virtual void BlockedPopupAdded(int32_t id, const GURL& url) {}
@@ -108,6 +126,8 @@
 
   PopupPosition GetPopupPosition(int32_t id) const;
 
+  static void LogAction(Action action);
+
   // Note, this container should be sorted based on the position in the popup
   // list, so it is keyed by an id which is continually increased.
   std::map<int32_t, std::unique_ptr<BlockedRequest>> blocked_popups_;
diff --git a/chrome/browser/ui/blocked_content/popup_tracker.cc b/chrome/browser/ui/blocked_content/popup_tracker.cc
index 75ae208d..a29da366 100644
--- a/chrome/browser/ui/blocked_content/popup_tracker.cc
+++ b/chrome/browser/ui/blocked_content/popup_tracker.cc
@@ -4,9 +4,51 @@
 
 #include "chrome/browser/ui/blocked_content/popup_tracker.h"
 
+#include "base/memory/ptr_util.h"
+#include "base/metrics/histogram_macros.h"
+#include "base/time/default_tick_clock.h"
+#include "chrome/browser/ui/blocked_content/scoped_visibility_tracker.h"
+#include "content/public/browser/navigation_handle.h"
+#include "content/public/browser/web_contents.h"
+
 DEFINE_WEB_CONTENTS_USER_DATA_KEY(PopupTracker);
 
-PopupTracker::~PopupTracker() = default;
+PopupTracker::~PopupTracker() {
+  if (first_load_visibility_tracker_) {
+    UMA_HISTOGRAM_LONG_TIMES(
+        "ContentSettings.Popups.FirstDocumentEngagementTime",
+        first_load_visibility_tracker_->GetForegroundDuration());
+  }
+}
 
 PopupTracker::PopupTracker(content::WebContents* web_contents)
     : content::WebContentsObserver(web_contents) {}
+
+void PopupTracker::DidFinishNavigation(
+    content::NavigationHandle* navigation_handle) {
+  if (!navigation_handle->HasCommitted() ||
+      navigation_handle->IsSameDocument()) {
+    return;
+  }
+
+  // The existence of |first_load_visibility_tracker_| is a proxy for whether
+  // we've committed the first navigation in this WebContents.
+  if (!first_load_visibility_tracker_) {
+    first_load_visibility_tracker_ = base::MakeUnique<ScopedVisibilityTracker>(
+        base::MakeUnique<base::DefaultTickClock>(),
+        web_contents()->IsVisible());
+  } else {
+    web_contents()->RemoveUserData(UserDataKey());
+    // Destroys this object.
+  }
+}
+
+void PopupTracker::WasShown() {
+  if (first_load_visibility_tracker_)
+    first_load_visibility_tracker_->OnShown();
+}
+
+void PopupTracker::WasHidden() {
+  if (first_load_visibility_tracker_)
+    first_load_visibility_tracker_->OnHidden();
+}
diff --git a/chrome/browser/ui/blocked_content/popup_tracker.h b/chrome/browser/ui/blocked_content/popup_tracker.h
index 959a06a..82bcf02 100644
--- a/chrome/browser/ui/blocked_content/popup_tracker.h
+++ b/chrome/browser/ui/blocked_content/popup_tracker.h
@@ -5,7 +5,10 @@
 #ifndef CHROME_BROWSER_UI_BLOCKED_CONTENT_POPUP_TRACKER_H_
 #define CHROME_BROWSER_UI_BLOCKED_CONTENT_POPUP_TRACKER_H_
 
+#include <memory>
+
 #include "base/macros.h"
+#include "base/time/time.h"
 #include "content/public/browser/web_contents_observer.h"
 #include "content/public/browser/web_contents_user_data.h"
 
@@ -13,9 +16,12 @@
 class WebContents;
 }
 
-// This class tracks new popups, and is used to log metrics.
-// TODO(csharrison): This class does nothing at the moment. Add some metrics
-// logging.
+class ScopedVisibilityTracker;
+
+// This class tracks new popups, and is used to log metrics on the visibility
+// time of the first document in the popup.
+// TODO(csharrison): Consider adding more metrics like total visibility for the
+// lifetime of the WebContents.
 class PopupTracker : public content::WebContentsObserver,
                      public content::WebContentsUserData<PopupTracker> {
  public:
@@ -26,6 +32,16 @@
 
   explicit PopupTracker(content::WebContents* web_contents);
 
+  // content::WebContentsObserver:
+  void DidFinishNavigation(
+      content::NavigationHandle* navigation_handle) override;
+  void WasShown() override;
+  void WasHidden() override;
+
+  // The |first_load_visibility_tracker_| tracks the time this WebContents is in
+  // the foreground for the duration of the first page load.
+  std::unique_ptr<ScopedVisibilityTracker> first_load_visibility_tracker_;
+
   DISALLOW_COPY_AND_ASSIGN(PopupTracker);
 };
 
diff --git a/chrome/browser/ui/blocked_content/popup_tracker_browsertest.cc b/chrome/browser/ui/blocked_content/popup_tracker_browsertest.cc
index 5ec9b94..08ba01b 100644
--- a/chrome/browser/ui/blocked_content/popup_tracker_browsertest.cc
+++ b/chrome/browser/ui/blocked_content/popup_tracker_browsertest.cc
@@ -7,23 +7,31 @@
 #include <string>
 
 #include "base/supports_user_data.h"
-#include "chrome/browser/chrome_notification_types.h"
+#include "base/test/histogram_tester.h"
+#include "build/build_config.h"
+#include "chrome/browser/content_settings/tab_specific_content_settings.h"
+#include "chrome/browser/profiles/profile.h"
+#include "chrome/browser/ui/blocked_content/popup_blocker_tab_helper.h"
 #include "chrome/browser/ui/browser.h"
 #include "chrome/browser/ui/browser_finder.h"
 #include "chrome/browser/ui/browser_list.h"
 #include "chrome/browser/ui/tabs/tab_strip_model.h"
 #include "chrome/test/base/in_process_browser_test.h"
 #include "chrome/test/base/ui_test_utils.h"
-#include "content/public/browser/notification_service.h"
 #include "content/public/browser/web_contents.h"
 #include "content/public/test/browser_test_utils.h"
+#include "content/public/test/test_navigation_observer.h"
 #include "content/public/test/test_utils.h"
 #include "net/test/embedded_test_server/embedded_test_server.h"
 #include "testing/gtest/include/gtest/gtest.h"
+#include "ui/base/window_open_disposition.h"
 #include "ui/events/keycodes/dom/dom_code.h"
 #include "ui/events/keycodes/dom/dom_key.h"
 #include "ui/events/keycodes/keyboard_codes.h"
 
+const char kPopupEngagement[] =
+    "ContentSettings.Popups.FirstDocumentEngagementTime";
+
 class PopupTrackerBrowserTest : public InProcessBrowserTest {
  public:
   PopupTrackerBrowserTest() {}
@@ -35,49 +43,135 @@
 };
 
 IN_PROC_BROWSER_TEST_F(PopupTrackerBrowserTest, NoPopup_NoTracker) {
+  base::HistogramTester tester;
   ui_test_utils::NavigateToURL(browser(),
                                embedded_test_server()->GetURL("/title1.html"));
   EXPECT_FALSE(PopupTracker::FromWebContents(
       browser()->tab_strip_model()->GetActiveWebContents()));
+
+  tester.ExpectTotalCount(kPopupEngagement, 0);
 }
 
 IN_PROC_BROWSER_TEST_F(PopupTrackerBrowserTest, WindowOpenPopup_HasTracker) {
+  base::HistogramTester tester;
   ui_test_utils::NavigateToURL(browser(),
                                embedded_test_server()->GetURL("/title1.html"));
-  std::string script = R"(
-    var opened = !!window.open();
-    window.domAutomationController.send(opened);
-  )";
-  bool opened_window = true;
-  EXPECT_TRUE(content::ExecuteScriptAndExtractBool(
-      browser()->tab_strip_model()->GetActiveWebContents(), script,
-      &opened_window));
-  EXPECT_TRUE(opened_window);
+
+  content::TestNavigationObserver navigation_observer(nullptr, 1);
+  navigation_observer.StartWatchingNewWebContents();
+
+  EXPECT_TRUE(content::ExecuteScript(
+      browser()->tab_strip_model()->GetActiveWebContents(),
+      "window.open('/title1.html')"));
+  navigation_observer.Wait();
+
   EXPECT_EQ(2, browser()->tab_strip_model()->count());
   EXPECT_TRUE(PopupTracker::FromWebContents(
       browser()->tab_strip_model()->GetActiveWebContents()));
+
+  // Close the popup and check metric.
+  content::WebContentsDestroyedWatcher destroyed_watcher(
+      browser()->tab_strip_model()->GetActiveWebContents());
+  browser()->tab_strip_model()->CloseAllTabs();
+  destroyed_watcher.Wait();
+
+  tester.ExpectTotalCount(kPopupEngagement, 1);
 }
 
 // OpenURLFromTab goes through a different code path than traditional popups
 // that use window.open(). Make sure the tracker is created in those cases.
-IN_PROC_BROWSER_TEST_F(PopupTrackerBrowserTest, OpenURLPopup_HasTracker) {
+IN_PROC_BROWSER_TEST_F(PopupTrackerBrowserTest, ControlClick_HasTracker) {
+  base::HistogramTester tester;
   ui_test_utils::NavigateToURL(
       browser(), embedded_test_server()->GetURL(
                      "/popup_blocker/popup-simulated-click-on-anchor.html"));
 
-  content::WindowedNotificationObserver wait_for_new_tab(
-      chrome::NOTIFICATION_TAB_ADDED,
-      content::NotificationService::AllSources());
+  // Mac uses command instead of control for the new tab action.
+  bool is_mac = false;
+#if defined(OS_MACOSX)
+  is_mac = true;
+#endif
+
+  content::TestNavigationObserver navigation_observer(nullptr, 1);
+  navigation_observer.StartWatchingNewWebContents();
+
+  SimulateKeyPress(browser()->tab_strip_model()->GetActiveWebContents(),
+                   ui::DomKey::ENTER, ui::DomCode::ENTER, ui::VKEY_RETURN,
+                   !is_mac /* control */, false /* shift */, false /* alt */,
+                   is_mac /* command */);
+  navigation_observer.Wait();
+
+  EXPECT_EQ(1u, chrome::GetBrowserCount(browser()->profile()));
+  content::WebContents* new_contents =
+      browser()->tab_strip_model()->GetWebContentsAt(1);
+  EXPECT_TRUE(PopupTracker::FromWebContents(new_contents));
+
+  // Close the popup and check metric.
+  content::WebContentsDestroyedWatcher destroyed_watcher(new_contents);
+  BrowserList::CloseAllBrowsersWithProfile(
+      Profile::FromBrowserContext(new_contents->GetBrowserContext()));
+  destroyed_watcher.Wait();
+
+  tester.ExpectTotalCount(kPopupEngagement, 1);
+}
+
+IN_PROC_BROWSER_TEST_F(PopupTrackerBrowserTest, ShiftClick_HasTracker) {
+  base::HistogramTester tester;
+  ui_test_utils::NavigateToURL(
+      browser(), embedded_test_server()->GetURL(
+                     "/popup_blocker/popup-simulated-click-on-anchor.html"));
+
+  content::TestNavigationObserver navigation_observer(nullptr, 1);
+  navigation_observer.StartWatchingNewWebContents();
 
   SimulateKeyPress(browser()->tab_strip_model()->GetActiveWebContents(),
                    ui::DomKey::ENTER, ui::DomCode::ENTER, ui::VKEY_RETURN,
                    false /* control */, true /* shift */, false /* alt */,
                    false /* command */);
-  wait_for_new_tab.Wait();
+  navigation_observer.Wait();
 
   EXPECT_EQ(2u, chrome::GetBrowserCount(browser()->profile()));
-  EXPECT_TRUE(PopupTracker::FromWebContents(BrowserList::GetInstance()
-                                                ->GetLastActive()
-                                                ->tab_strip_model()
-                                                ->GetActiveWebContents()));
+  content::WebContents* new_contents = BrowserList::GetInstance()
+                                           ->GetLastActive()
+                                           ->tab_strip_model()
+                                           ->GetActiveWebContents();
+  EXPECT_TRUE(PopupTracker::FromWebContents(new_contents));
+
+  // Close the popup and check metric.
+  content::WebContentsDestroyedWatcher destroyed_watcher(new_contents);
+  BrowserList::CloseAllBrowsersWithProfile(
+      Profile::FromBrowserContext(new_contents->GetBrowserContext()));
+  destroyed_watcher.Wait();
+
+  tester.ExpectTotalCount(kPopupEngagement, 1);
+}
+
+IN_PROC_BROWSER_TEST_F(PopupTrackerBrowserTest, WhitelistedPopup_HasTracker) {
+  base::HistogramTester tester;
+  content::WebContents* web_contents =
+      browser()->tab_strip_model()->GetActiveWebContents();
+
+  // Is blocked by the popup blocker.
+  ui_test_utils::NavigateToURL(
+      browser(),
+      embedded_test_server()->GetURL("/popup_blocker/popup-window-open.html"));
+  EXPECT_TRUE(TabSpecificContentSettings::FromWebContents(web_contents)
+                  ->IsContentBlocked(CONTENT_SETTINGS_TYPE_POPUPS));
+
+  // Click through to open the popup.
+  content::TestNavigationObserver navigation_observer(nullptr, 1);
+  navigation_observer.StartWatchingNewWebContents();
+  auto* popup_blocker = PopupBlockerTabHelper::FromWebContents(web_contents);
+  popup_blocker->ShowBlockedPopup(
+      popup_blocker->GetBlockedPopupRequests().begin()->first,
+      WindowOpenDisposition::NEW_FOREGROUND_TAB);
+  navigation_observer.Wait();
+
+  // Close the popup and check metric.
+  content::WebContentsDestroyedWatcher destroyed_watcher(
+      browser()->tab_strip_model()->GetActiveWebContents());
+  browser()->tab_strip_model()->CloseAllTabs();
+  destroyed_watcher.Wait();
+
+  tester.ExpectTotalCount(kPopupEngagement, 1);
 }
diff --git a/chrome/browser/ui/blocked_content/scoped_visibility_tracker.cc b/chrome/browser/ui/blocked_content/scoped_visibility_tracker.cc
new file mode 100644
index 0000000..2e2579210
--- /dev/null
+++ b/chrome/browser/ui/blocked_content/scoped_visibility_tracker.cc
@@ -0,0 +1,44 @@
+// Copyright 2017 The Chromium Authors. All rights reserved.
+// Use of this source code is governed by a BSD-style license that can be
+// found in the LICENSE file.
+
+#include "chrome/browser/ui/blocked_content/scoped_visibility_tracker.h"
+
+#include <utility>
+
+#include "base/time/tick_clock.h"
+
+ScopedVisibilityTracker::ScopedVisibilityTracker(
+    std::unique_ptr<base::TickClock> tick_clock,
+    bool is_shown)
+    : tick_clock_(std::move(tick_clock)) {
+  DCHECK(tick_clock_);
+  if (is_shown)
+    OnShown();
+}
+
+ScopedVisibilityTracker::~ScopedVisibilityTracker() {}
+
+void ScopedVisibilityTracker::OnShown() {
+  Update(true /* in_foreground */);
+}
+
+void ScopedVisibilityTracker::OnHidden() {
+  Update(false /* in_foreground */);
+}
+
+base::TimeDelta ScopedVisibilityTracker::GetForegroundDuration() {
+  Update(currently_in_foreground_);
+  return foreground_duration_;
+}
+
+void ScopedVisibilityTracker::Update(bool in_foreground) {
+  base::TimeTicks now = tick_clock_->NowTicks();
+  if (currently_in_foreground_)
+    foreground_duration_ += now - last_time_shown_;
+
+  if (in_foreground)
+    last_time_shown_ = now;
+
+  currently_in_foreground_ = in_foreground;
+}
diff --git a/chrome/browser/ui/blocked_content/scoped_visibility_tracker.h b/chrome/browser/ui/blocked_content/scoped_visibility_tracker.h
new file mode 100644
index 0000000..900ed77
--- /dev/null
+++ b/chrome/browser/ui/blocked_content/scoped_visibility_tracker.h
@@ -0,0 +1,42 @@
+// Copyright 2017 The Chromium Authors. All rights reserved.
+// Use of this source code is governed by a BSD-style license that can be
+// found in the LICENSE file.
+
+#ifndef CHROME_BROWSER_UI_BLOCKED_CONTENT_SCOPED_VISIBILITY_TRACKER_H_
+#define CHROME_BROWSER_UI_BLOCKED_CONTENT_SCOPED_VISIBILITY_TRACKER_H_
+
+#include <memory>
+
+#include "base/macros.h"
+#include "base/time/time.h"
+
+namespace base {
+class TickClock;
+}  // namespace base
+
+// This class tracks the total time it is visible, based on receiving
+// OnShown/OnHidden notifications, which are logically idempotent.
+class ScopedVisibilityTracker {
+ public:
+  ScopedVisibilityTracker(std::unique_ptr<base::TickClock> tick_clock,
+                          bool is_shown);
+  ~ScopedVisibilityTracker();
+
+  void OnShown();
+  void OnHidden();
+
+  base::TimeDelta GetForegroundDuration();
+
+ private:
+  void Update(bool in_foreground);
+
+  std::unique_ptr<base::TickClock> tick_clock_;
+
+  base::TimeTicks last_time_shown_;
+  base::TimeDelta foreground_duration_;
+  bool currently_in_foreground_ = false;
+
+  DISALLOW_COPY_AND_ASSIGN(ScopedVisibilityTracker);
+};
+
+#endif  // CHROME_BROWSER_UI_BLOCKED_CONTENT_SCOPED_VISIBILITY_TRACKER_H_
diff --git a/chrome/browser/ui/blocked_content/scoped_visibility_tracker_unittest.cc b/chrome/browser/ui/blocked_content/scoped_visibility_tracker_unittest.cc
new file mode 100644
index 0000000..61342d5
--- /dev/null
+++ b/chrome/browser/ui/blocked_content/scoped_visibility_tracker_unittest.cc
@@ -0,0 +1,84 @@
+// Copyright 2017 The Chromium Authors. All rights reserved.
+// Use of this source code is governed by a BSD-style license that can be
+// found in the LICENSE file.
+
+#include "chrome/browser/ui/blocked_content/scoped_visibility_tracker.h"
+
+#include <utility>
+
+#include "base/memory/ptr_util.h"
+#include "base/test/simple_test_tick_clock.h"
+#include "base/time/time.h"
+#include "testing/gtest/include/gtest/gtest.h"
+
+class ScopedVisibilityTrackerTest : public testing::Test {};
+
+TEST_F(ScopedVisibilityTrackerTest, NeverVisible) {
+  auto tick_clock = base::MakeUnique<base::SimpleTestTickClock>();
+  auto* raw_clock = tick_clock.get();
+  ScopedVisibilityTracker tracker(std::move(tick_clock), false /* is_shown */);
+
+  raw_clock->Advance(base::TimeDelta::FromMinutes(10));
+  EXPECT_EQ(base::TimeDelta::FromMinutes(0), tracker.GetForegroundDuration());
+}
+
+TEST_F(ScopedVisibilityTrackerTest, SimpleVisibility) {
+  auto tick_clock = base::MakeUnique<base::SimpleTestTickClock>();
+  auto* raw_clock = tick_clock.get();
+  ScopedVisibilityTracker tracker(std::move(tick_clock), true /* is_shown */);
+
+  raw_clock->Advance(base::TimeDelta::FromMinutes(10));
+  EXPECT_EQ(base::TimeDelta::FromMinutes(10), tracker.GetForegroundDuration());
+}
+
+TEST_F(ScopedVisibilityTrackerTest, HiddenThenShown) {
+  auto tick_clock = base::MakeUnique<base::SimpleTestTickClock>();
+  auto* raw_clock = tick_clock.get();
+  ScopedVisibilityTracker tracker(std::move(tick_clock), true /* is_shown */);
+
+  raw_clock->Advance(base::TimeDelta::FromMinutes(1));
+  EXPECT_EQ(base::TimeDelta::FromMinutes(1), tracker.GetForegroundDuration());
+
+  tracker.OnHidden();
+  raw_clock->Advance(base::TimeDelta::FromMinutes(2));
+  EXPECT_EQ(base::TimeDelta::FromMinutes(1), tracker.GetForegroundDuration());
+
+  tracker.OnShown();
+  raw_clock->Advance(base::TimeDelta::FromMinutes(3));
+  EXPECT_EQ(base::TimeDelta::FromMinutes(4), tracker.GetForegroundDuration());
+}
+
+TEST_F(ScopedVisibilityTrackerTest, InitiallyHidden) {
+  auto tick_clock = base::MakeUnique<base::SimpleTestTickClock>();
+  auto* raw_clock = tick_clock.get();
+  ScopedVisibilityTracker tracker(std::move(tick_clock), false /* is_shown */);
+
+  raw_clock->Advance(base::TimeDelta::FromMinutes(1));
+  EXPECT_EQ(base::TimeDelta::FromMinutes(0), tracker.GetForegroundDuration());
+
+  tracker.OnShown();
+  raw_clock->Advance(base::TimeDelta::FromMinutes(2));
+  EXPECT_EQ(base::TimeDelta::FromMinutes(2), tracker.GetForegroundDuration());
+}
+
+// The object should be robust to double hidden and shown notification
+TEST_F(ScopedVisibilityTrackerTest, DoubleNotifications) {
+  auto tick_clock = base::MakeUnique<base::SimpleTestTickClock>();
+  auto* raw_clock = tick_clock.get();
+  ScopedVisibilityTracker tracker(std::move(tick_clock), false /* is_shown */);
+
+  raw_clock->Advance(base::TimeDelta::FromMinutes(1));
+  EXPECT_EQ(base::TimeDelta::FromMinutes(0), tracker.GetForegroundDuration());
+
+  tracker.OnHidden();
+  raw_clock->Advance(base::TimeDelta::FromMinutes(1));
+  EXPECT_EQ(base::TimeDelta::FromMinutes(0), tracker.GetForegroundDuration());
+
+  tracker.OnShown();
+  raw_clock->Advance(base::TimeDelta::FromMinutes(2));
+  EXPECT_EQ(base::TimeDelta::FromMinutes(2), tracker.GetForegroundDuration());
+
+  tracker.OnShown();
+  raw_clock->Advance(base::TimeDelta::FromMinutes(2));
+  EXPECT_EQ(base::TimeDelta::FromMinutes(4), tracker.GetForegroundDuration());
+}
diff --git a/chrome/browser/ui/cocoa/browser_window_touch_bar.mm b/chrome/browser/ui/cocoa/browser_window_touch_bar.mm
index fa70cdf1..2c82fd8 100644
--- a/chrome/browser/ui/cocoa/browser_window_touch_bar.mm
+++ b/chrome/browser/ui/cocoa/browser_window_touch_bar.mm
@@ -157,13 +157,25 @@
 
   // The stop/reload button in the touch bar.
   base::scoped_nsobject<NSButton> reloadStopButton_;
+
+  // The back/forward segmented control in the touch bar.
+  base::scoped_nsobject<NSSegmentedControl> backForwardControl_;
+
+  // The starred button in the touch bar.
+  base::scoped_nsobject<NSButton> starredButton_;
 }
 
 // Creates and returns a touch bar for tab fullscreen mode.
 - (NSTouchBar*)createTabFullscreenTouchBar API_AVAILABLE(macos(10.12.2));
 
-// Creates and returns the back and forward segmented buttons.
-- (NSView*)backOrForwardTouchBarView;
+// Sets up the back and forward segmented control.
+- (void)setupBackForwardControl;
+
+// Methods to update controls on the touch bar. Called when creating the
+// touch bar or the page load state has been updated.
+- (void)updateReloadStopButton;
+- (void)updateBackForwardControl;
+- (void)updateStarredButton;
 
 // Creates and returns the search button.
 - (NSView*)searchTouchBarView API_AVAILABLE(macos(10.12));
@@ -243,7 +255,8 @@
   base::scoped_nsobject<NSCustomTouchBarItem> touchBarItem(
       [[ui::NSCustomTouchBarItem() alloc] initWithIdentifier:identifier]);
   if ([identifier hasSuffix:kBackForwardTouchId]) {
-    [touchBarItem setView:[self backOrForwardTouchBarView]];
+    [self updateBackForwardControl];
+    [touchBarItem setView:backForwardControl_.get()];
     [touchBarItem setCustomizationLabel:
                       l10n_util::GetNSString(
                           IDS_TOUCH_BAR_BACK_FORWARD_CUSTOMIZATION_LABEL)];
@@ -267,13 +280,8 @@
         setCustomizationLabel:l10n_util::GetNSString(
                                   IDS_TOUCH_BAR_NEW_TAB_CUSTOMIZATION_LABEL)];
   } else if ([identifier hasSuffix:kStarTouchId]) {
-    const gfx::VectorIcon& icon =
-        isStarred_ ? toolbar::kStarActiveIcon : toolbar::kStarIcon;
-    SkColor iconColor =
-        isStarred_ ? kTouchBarStarActiveColor : kTouchBarDefaultIconColor;
-    int tooltipId = isStarred_ ? IDS_TOOLTIP_STARRED : IDS_TOOLTIP_STAR;
-    [touchBarItem setView:CreateTouchBarButton(icon, self, IDC_BOOKMARK_PAGE,
-                                               tooltipId, iconColor)];
+    [self updateStarredButton];
+    [touchBarItem setView:starredButton_.get()];
     [touchBarItem
         setCustomizationLabel:l10n_util::GetNSString(
                                   IDS_TOUCH_BAR_BOOKMARK_CUSTOMIZATION_LABEL)];
@@ -349,7 +357,7 @@
   return touchBar.autorelease();
 }
 
-- (NSView*)backOrForwardTouchBarView {
+- (void)setupBackForwardControl {
   NSMutableArray* images = [NSMutableArray arrayWithArray:@[
     CreateNSImageFromIcon(vector_icons::kBackArrowIcon),
     CreateNSImageFromIcon(vector_icons::kForwardArrowIcon)
@@ -375,16 +383,10 @@
                     trackingMode:NSSegmentSwitchTrackingMomentary
                           target:self
                           action:@selector(backOrForward:)];
-  if (@available(macOS 10.10, *))
-    control.segmentStyle = NSSegmentStyleSeparated;
-  [control setEnabled:commandUpdater_->IsCommandEnabled(IDC_BACK)
-           forSegment:kBackSegmentIndex];
-  [control setEnabled:commandUpdater_->IsCommandEnabled(IDC_FORWARD)
-           forSegment:kForwardSegmentIndex];
 
   // Use the accessibility protocol to get the children.
-  // Use NSAccessibilityUnignoredDescendant to be sure we start with the correct
-  // object.
+  // Use NSAccessibilityUnignoredDescendant to be sure we start with
+  // the correct object.
   id segmentElement = NSAccessibilityUnignoredDescendant(control);
   NSArray* segments = [segmentElement
       accessibilityAttributeValue:NSAccessibilityChildrenAttribute];
@@ -395,7 +397,55 @@
   [[e nextObject]
       accessibilitySetOverrideValue:l10n_util::GetNSString(IDS_ACCNAME_FORWARD)
                        forAttribute:NSAccessibilityTitleAttribute];
-  return control;
+
+  backForwardControl_.reset([control retain]);
+}
+
+- (void)updateReloadStopButton {
+  const gfx::VectorIcon& icon =
+      isPageLoading_ ? kNavigateStopIcon : vector_icons::kReloadIcon;
+  int commandId = isPageLoading_ ? IDC_STOP : IDC_RELOAD;
+  int tooltipId = isPageLoading_ ? IDS_TOOLTIP_STOP : IDS_TOOLTIP_RELOAD;
+
+  if (!reloadStopButton_) {
+    reloadStopButton_.reset(
+        [CreateTouchBarButton(icon, self, commandId, tooltipId) retain]);
+    return;
+  }
+
+  [reloadStopButton_
+      setImage:CreateNSImageFromIcon(icon, kTouchBarDefaultIconColor)];
+  [reloadStopButton_ setTag:commandId];
+  [reloadStopButton_ setAccessibilityLabel:l10n_util::GetNSString(tooltipId)];
+}
+
+- (void)updateBackForwardControl {
+  if (!backForwardControl_)
+    [self setupBackForwardControl];
+
+  if (@available(macOS 10.10, *))
+    [backForwardControl_ setSegmentStyle:NSSegmentStyleSeparated];
+
+  [backForwardControl_ setEnabled:commandUpdater_->IsCommandEnabled(IDC_BACK)
+                       forSegment:kBackSegmentIndex];
+  [backForwardControl_ setEnabled:commandUpdater_->IsCommandEnabled(IDC_FORWARD)
+                       forSegment:kForwardSegmentIndex];
+}
+
+- (void)updateStarredButton {
+  const gfx::VectorIcon& icon =
+      isStarred_ ? toolbar::kStarActiveIcon : toolbar::kStarIcon;
+  SkColor iconColor =
+      isStarred_ ? kTouchBarStarActiveColor : kTouchBarDefaultIconColor;
+  int tooltipId = isStarred_ ? IDS_TOOLTIP_STARRED : IDS_TOOLTIP_STAR;
+  if (!starredButton_) {
+    starredButton_.reset([CreateTouchBarButton(icon, self, IDC_BOOKMARK_PAGE,
+                                               tooltipId, iconColor) retain]);
+    return;
+  }
+
+  [starredButton_ setImage:CreateNSImageFromIcon(icon, iconColor)];
+  [starredButton_ setAccessibilityLabel:l10n_util::GetNSString(tooltipId)];
 }
 
 - (NSView*)searchTouchBarView {
@@ -458,27 +508,11 @@
   commandUpdater_->ExecuteCommand(command);
 }
 
-- (void)updateReloadStopButton {
-  const gfx::VectorIcon& icon =
-      isPageLoading_ ? kNavigateStopIcon : vector_icons::kReloadIcon;
-  int commandId = isPageLoading_ ? IDC_STOP : IDC_RELOAD;
-  int tooltipId = isPageLoading_ ? IDS_TOOLTIP_STOP : IDS_TOOLTIP_RELOAD;
-
-  if (!reloadStopButton_) {
-    reloadStopButton_.reset(
-        [CreateTouchBarButton(icon, self, commandId, tooltipId) retain]);
-    return;
-  }
-
-  [reloadStopButton_
-      setImage:CreateNSImageFromIcon(icon, kTouchBarDefaultIconColor)];
-  [reloadStopButton_ setTag:commandId];
-  [reloadStopButton_ setAccessibilityLabel:l10n_util::GetNSString(tooltipId)];
-}
-
 - (void)setIsPageLoading:(BOOL)isPageLoading {
   isPageLoading_ = isPageLoading;
   [self updateReloadStopButton];
+  [self updateBackForwardControl];
+  [self updateStarredButton];
 }
 
 @end
diff --git a/chrome/browser/ui/passwords/manage_passwords_bubble_model.cc b/chrome/browser/ui/passwords/manage_passwords_bubble_model.cc
index 23230cb..895424d 100644
--- a/chrome/browser/ui/passwords/manage_passwords_bubble_model.cc
+++ b/chrome/browser/ui/passwords/manage_passwords_bubble_model.cc
@@ -407,6 +407,12 @@
   pending_password_.username_value = std::move(new_username);
 }
 
+void ManagePasswordsBubbleModel::OnPasswordSelected(
+    base::string16 new_password) {
+  DCHECK_EQ(password_manager::ui::PENDING_PASSWORD_STATE, state_);
+  pending_password_.password_value = std::move(new_password);
+}
+
 void ManagePasswordsBubbleModel::OnSaveClicked() {
   DCHECK_EQ(password_manager::ui::PENDING_PASSWORD_STATE, state_);
   interaction_keeper_->set_dismissal_reason(metrics_util::CLICKED_SAVE);
diff --git a/chrome/browser/ui/passwords/manage_passwords_bubble_model.h b/chrome/browser/ui/passwords/manage_passwords_bubble_model.h
index 03c9268..91bc7ca 100644
--- a/chrome/browser/ui/passwords/manage_passwords_bubble_model.h
+++ b/chrome/browser/ui/passwords/manage_passwords_bubble_model.h
@@ -50,6 +50,10 @@
   // in PendingView.
   void OnUsernameEdited(base::string16 new_username);
 
+  // Called by the view code when a password is selected from the dropdown list
+  // of the password selection feature in PendingView.
+  void OnPasswordSelected(base::string16 new_password);
+
   // Called by the view code when the save button is clicked by the user.
   void OnSaveClicked();
 
diff --git a/chrome/browser/ui/task_manager/task_manager_table_model.cc b/chrome/browser/ui/task_manager/task_manager_table_model.cc
index c8ad640..68e4e3cd 100644
--- a/chrome/browser/ui/task_manager/task_manager_table_model.cc
+++ b/chrome/browser/ui/task_manager/task_manager_table_model.cc
@@ -354,7 +354,7 @@
 
     case IDS_TASK_MANAGER_CPU_COLUMN:
       return stringifier_->GetCpuUsageText(
-          observed_task_manager()->GetCpuUsage(tasks_[row]));
+          observed_task_manager()->GetPlatformIndependentCPUUsage(tasks_[row]));
 
     case IDS_TASK_MANAGER_CPU_TIME_COLUMN:
       return stringifier_->GetCpuTimeText(
@@ -504,8 +504,10 @@
           observed_task_manager()->GetNetworkUsage(tasks_[row2]));
 
     case IDS_TASK_MANAGER_CPU_COLUMN:
-      return ValueCompare(observed_task_manager()->GetCpuUsage(tasks_[row1]),
-                          observed_task_manager()->GetCpuUsage(tasks_[row2]));
+      return ValueCompare(
+          observed_task_manager()->GetPlatformIndependentCPUUsage(tasks_[row1]),
+          observed_task_manager()->GetPlatformIndependentCPUUsage(
+              tasks_[row2]));
 
     case IDS_TASK_MANAGER_CPU_TIME_COLUMN:
       return ValueCompare(observed_task_manager()->GetCpuTime(tasks_[row1]),
diff --git a/chrome/browser/ui/views/frame/browser_frame_ash.cc b/chrome/browser/ui/views/frame/browser_frame_ash.cc
index 1eae5d8..cd39767 100644
--- a/chrome/browser/ui/views/frame/browser_frame_ash.cc
+++ b/chrome/browser/ui/views/frame/browser_frame_ash.cc
@@ -4,7 +4,8 @@
 
 #include "chrome/browser/ui/views/frame/browser_frame_ash.h"
 
-#include "ash/ash_switches.h"
+#include <memory>
+
 #include "ash/shell.h"
 #include "ash/wm/window_properties.h"
 #include "ash/wm/window_state.h"
@@ -52,14 +53,11 @@
 ///////////////////////////////////////////////////////////////////////////////
 // BrowserFrameAsh, public:
 
-// static
-const char BrowserFrameAsh::kWindowName[] = "BrowserFrameAsh";
-
 BrowserFrameAsh::BrowserFrameAsh(BrowserFrame* browser_frame,
                                  BrowserView* browser_view)
     : views::NativeWidgetAura(browser_frame),
       browser_view_(browser_view) {
-  GetNativeWindow()->SetName(kWindowName);
+  GetNativeWindow()->SetName("BrowserFrameAsh");
   Browser* browser = browser_view->browser();
   ash::wm::WindowState* window_state =
       ash::wm::GetWindowState(GetNativeWindow());
@@ -70,14 +68,15 @@
   // This way the requested bounds are honored.
   if (!browser->bounds_overridden() && !browser->is_session_restore())
     SetWindowAutoManaged();
-#if defined(OS_CHROMEOS)
+
   // For legacy reasons v1 apps (like Secure Shell) are allowed to consume keys
   // like brightness, volume, etc. Otherwise these keys are handled by the
   // Ash window manager.
   window_state->set_can_consume_system_keys(browser->is_app());
-#endif  // defined(OS_CHROMEOS)
 }
 
+BrowserFrameAsh::~BrowserFrameAsh() {}
+
 ///////////////////////////////////////////////////////////////////////////////
 // BrowserFrameAsh, views::NativeWidgetAura overrides:
 
@@ -132,13 +131,7 @@
 views::Widget::InitParams BrowserFrameAsh::GetWidgetParams() {
   views::Widget::InitParams params;
   params.native_widget = this;
-
   params.context = ash::Shell::GetPrimaryRootWindow();
-#if defined(OS_WIN)
-  // If this window is under ASH on Windows, we need it to be translucent.
-  params.opacity = views::Widget::InitParams::TRANSLUCENT_WINDOW;
-#endif
-
   return params;
 }
 
@@ -154,9 +147,6 @@
   return 0;
 }
 
-BrowserFrameAsh::~BrowserFrameAsh() {
-}
-
 ///////////////////////////////////////////////////////////////////////////////
 // BrowserFrameAsh, private:
 
diff --git a/chrome/browser/ui/views/frame/browser_frame_ash.h b/chrome/browser/ui/views/frame/browser_frame_ash.h
index 85a9c98..0989f98 100644
--- a/chrome/browser/ui/views/frame/browser_frame_ash.h
+++ b/chrome/browser/ui/views/frame/browser_frame_ash.h
@@ -5,8 +5,6 @@
 #ifndef CHROME_BROWSER_UI_VIEWS_FRAME_BROWSER_FRAME_ASH_H_
 #define CHROME_BROWSER_UI_VIEWS_FRAME_BROWSER_FRAME_ASH_H_
 
-#include <memory>
-
 #include "base/macros.h"
 #include "chrome/browser/ui/views/frame/native_browser_frame.h"
 #include "ui/views/widget/native_widget_aura.h"
@@ -14,22 +12,15 @@
 class BrowserFrame;
 class BrowserView;
 
-////////////////////////////////////////////////////////////////////////////////
-//  BrowserFrameAsh
-//
-//  BrowserFrameAsh is a NativeWidgetAura subclass that provides the window
-//  frame for the Chrome browser window.
-//
+// BrowserFrameAsh provides the frame for Chrome browser windows on Chrome OS.
 class BrowserFrameAsh : public views::NativeWidgetAura,
                         public NativeBrowserFrame {
  public:
-  static const char kWindowName[];
-
   BrowserFrameAsh(BrowserFrame* browser_frame, BrowserView* browser_view);
 
-  BrowserView* browser_view() const { return browser_view_; }
-
  protected:
+  ~BrowserFrameAsh() override;
+
   // Overridden from views::NativeWidgetAura:
   void OnWindowTargetVisibilityChanged(bool visible) override;
 
@@ -46,11 +37,7 @@
   bool HandleKeyboardEvent(
       const content::NativeWebKeyboardEvent& event) override;
 
-  ~BrowserFrameAsh() override;
-
  private:
-  class WindowPropertyWatcher;
-
   // Set the window into the auto managed mode.
   void SetWindowAutoManaged();
 
diff --git a/chrome/browser/ui/views/frame/browser_header_painter_ash.h b/chrome/browser/ui/views/frame/browser_header_painter_ash.h
index 96fedaf0..f5e28059 100644
--- a/chrome/browser/ui/views/frame/browser_header_painter_ash.h
+++ b/chrome/browser/ui/views/frame/browser_header_painter_ash.h
@@ -8,7 +8,6 @@
 #include <memory>
 
 #include "ash/frame/header_painter.h"
-#include "base/compiler_specific.h"  // override
 #include "base/macros.h"
 #include "ui/gfx/animation/animation_delegate.h"
 
diff --git a/chrome/browser/ui/views/frame/browser_non_client_frame_view_ash.cc b/chrome/browser/ui/views/frame/browser_non_client_frame_view_ash.cc
index 1a7e16a..455998a 100644
--- a/chrome/browser/ui/views/frame/browser_non_client_frame_view_ash.cc
+++ b/chrome/browser/ui/views/frame/browser_non_client_frame_view_ash.cc
@@ -11,10 +11,10 @@
 #include "ash/frame/default_header_painter.h"
 #include "ash/frame/frame_border_hit_test.h"
 #include "ash/frame/header_painter_util.h"
+#include "ash/public/cpp/app_types.h"
 #include "ash/shell.h"
 #include "ash/wm/tablet_mode/tablet_mode_controller.h"
 #include "ash/wm/window_util.h"
-#include "build/build_config.h"
 #include "chrome/browser/profiles/profiles_state.h"
 #include "chrome/browser/ui/ash/multi_user/multi_user_window_manager.h"
 #include "chrome/browser/ui/browser.h"
@@ -41,10 +41,6 @@
 #include "ui/views/widget/widget.h"
 #include "ui/views/widget/widget_delegate.h"
 
-#if defined(OS_CHROMEOS)
-#include "ash/public/cpp/app_types.h"
-#endif
-
 namespace {
 
 // Space between right edge of tabstrip and maximize button.
@@ -110,7 +106,6 @@
                          caption_button_container_);
   }
 
-#if defined(OS_CHROMEOS)
   if (browser_view()->browser()->is_app()) {
     frame()->GetNativeWindow()->SetProperty(
         aura::client::kAppType, static_cast<int>(ash::AppType::CHROME_APP));
@@ -118,7 +113,6 @@
     frame()->GetNativeWindow()->SetProperty(
         aura::client::kAppType, static_cast<int>(ash::AppType::BROWSER));
   }
-#endif
 }
 
 ///////////////////////////////////////////////////////////////////////////////
@@ -421,10 +415,6 @@
 
 void BrowserNonClientFrameViewAsh::LayoutProfileIndicatorIcon() {
   DCHECK(profile_indicator_icon());
-#if !defined(OS_CHROMEOS)
-  // ChromeOS shows avatar on V1 app.
-  DCHECK(browser_view()->IsTabStripVisible());
-#endif
 
   const gfx::ImageSkia incognito_icon = GetIncognitoAvatarIcon();
   const int avatar_bottom = GetTopInset(false) +
diff --git a/chrome/browser/ui/views/frame/browser_non_client_frame_view_ash.h b/chrome/browser/ui/views/frame/browser_non_client_frame_view_ash.h
index c88fae4..3baa86f 100644
--- a/chrome/browser/ui/views/frame/browser_non_client_frame_view_ash.h
+++ b/chrome/browser/ui/views/frame/browser_non_client_frame_view_ash.h
@@ -21,6 +21,7 @@
 class HeaderPainter;
 }
 
+// Provides the BrowserNonClientFrameView for Chrome OS.
 class BrowserNonClientFrameViewAsh : public BrowserNonClientFrameView,
                                      public ash::ShellObserver,
                                      public ash::TabletModeObserver,
diff --git a/chrome/browser/ui/views/passwords/manage_passwords_bubble_view.cc b/chrome/browser/ui/views/passwords/manage_passwords_bubble_view.cc
index b60fb3f0..9c44097 100644
--- a/chrome/browser/ui/views/passwords/manage_passwords_bubble_view.cc
+++ b/chrome/browser/ui/views/passwords/manage_passwords_bubble_view.cc
@@ -236,13 +236,26 @@
 // The items are made of '*'s.
 std::unique_ptr<views::Combobox> GeneratePasswordDropdownView(
     const autofill::PasswordForm& form) {
+  DCHECK(!form.other_possible_passwords.empty());
   std::vector<base::string16> passwords;
   for (const base::string16& possible_password :
        form.other_possible_passwords) {
     passwords.push_back(base::string16(possible_password.length(), '*'));
   }
-  return std::make_unique<views::Combobox>(
+  std::unique_ptr<views::Combobox> combobox = std::make_unique<views::Combobox>(
       std::make_unique<ui::SimpleComboboxModel>(passwords));
+  size_t index = std::distance(
+      form.other_possible_passwords.begin(),
+      find(form.other_possible_passwords.begin(),
+           form.other_possible_passwords.end(), form.password_value));
+  // Unlikely, but if we don't find the password in possible passwords,
+  // we will set the default to first element.
+  if (index == form.other_possible_passwords.size()) {
+    combobox->SetSelectedIndex(0);
+  } else {
+    combobox->SetSelectedIndex(index);
+  }
+  return combobox;
 }
 
 // Builds a credential row, adds the given elements to the layout.
@@ -584,6 +597,14 @@
   if (editing_ && accept_changes) {
     parent_->model()->OnUsernameEdited(
         static_cast<views::Textfield*>(username_field_)->text());
+    if (password_view_button_ &&
+        parent_->model()->pending_password().other_possible_passwords.size() >
+            1) {
+      parent_->model()->OnPasswordSelected(
+          parent_->model()->pending_password().other_possible_passwords.at(
+              static_cast<views::Combobox*>(password_field_)
+                  ->selected_index()));
+    }
   }
   editing_ = !editing_;
   edit_button_->SetEnabled(!editing_);
diff --git a/chrome/browser/ui/webui/memory_internals_ui.cc b/chrome/browser/ui/webui/memory_internals_ui.cc
index ec2df3e..48560e4 100644
--- a/chrome/browser/ui/webui/memory_internals_ui.cc
+++ b/chrome/browser/ui/webui/memory_internals_ui.cc
@@ -43,8 +43,9 @@
 std::string GetMessageString() {
 #if BUILDFLAG(USE_ALLOCATOR_SHIM)
   switch (profiling::ProfilingProcessHost::GetCurrentMode()) {
-    case profiling::ProfilingProcessHost::Mode::kBrowser:
-      return std::string("Memory logging is enabled for the browser only.");
+    case profiling::ProfilingProcessHost::Mode::kMinimal:
+      return std::string(
+          "Memory logging is enabled for the browser and GPU processes.");
 
     case profiling::ProfilingProcessHost::Mode::kAll:
       return std::string("Memory logging is enabled for all processes.");
@@ -54,8 +55,8 @@
       return std::string("Memory logging is not enabled. Start with --") +
              switches::kMemlog + "=" + switches::kMemlogModeAll +
              " to log all processes, or --" + switches::kMemlog + "=" +
-             switches::kMemlogModeBrowser +
-             " to log only the browser process. "
+             switches::kMemlogModeMinimal +
+             " to log only the browser and GPU processes. "
              "This is also configurable in chrome://flags";
   }
 #else
@@ -217,14 +218,25 @@
     base::WeakPtr<MemoryInternalsDOMHandler> dom_handler) {
   std::vector<base::Value> result;
 
-  if (profiling::ProfilingProcessHost::GetCurrentMode() ==
-      profiling::ProfilingProcessHost::Mode::kAll) {
+  if (profiling::ProfilingProcessHost::GetCurrentMode() !=
+      profiling::ProfilingProcessHost::Mode::kNone) {
     // Add child processes (this does not include renderers).
     for (content::BrowserChildProcessHostIterator iter; !iter.Done(); ++iter) {
       // Note that ChildProcessData.id is a child ID and not an OS PID.
       const content::ChildProcessData& data = iter.GetData();
-      result.push_back(MakeProcessInfo(base::GetProcId(data.handle),
-                                       GetChildDescription(data)));
+
+      bool show_process = true;
+      if (profiling::ProfilingProcessHost::GetCurrentMode() ==
+          profiling::ProfilingProcessHost::Mode::kMinimal) {
+        show_process =
+            data.process_type == content::ProcessType::PROCESS_TYPE_BROWSER ||
+            data.process_type == content::ProcessType::PROCESS_TYPE_GPU;
+      }
+
+      if (show_process) {
+        result.push_back(MakeProcessInfo(base::GetProcId(data.handle),
+                                         GetChildDescription(data)));
+      }
     }
   }
 
diff --git a/chrome/browser/ui/webui/print_preview/printer_backend_proxy.cc b/chrome/browser/ui/webui/print_preview/printer_backend_proxy.cc
index 822d241..0081dcb 100644
--- a/chrome/browser/ui/webui/print_preview/printer_backend_proxy.cc
+++ b/chrome/browser/ui/webui/print_preview/printer_backend_proxy.cc
@@ -39,7 +39,6 @@
 
   VLOG(1) << "Get printer capabilities start for " << device_name;
 
-  std::unique_ptr<base::DictionaryValue> printer_info;
   if (!print_backend->IsValidPrinter(device_name)) {
     LOG(WARNING) << "Invalid printer " << device_name;
     return nullptr;
diff --git a/chrome/browser/ui/window_sizer/window_sizer_ash.cc b/chrome/browser/ui/window_sizer/window_sizer_ash.cc
index 9ee0042..0df8ef7 100644
--- a/chrome/browser/ui/window_sizer/window_sizer_ash.cc
+++ b/chrome/browser/ui/window_sizer/window_sizer_ash.cc
@@ -17,7 +17,8 @@
 
 bool WindowSizer::GetBrowserBoundsAsh(gfx::Rect* bounds,
                                       ui::WindowShowState* show_state) const {
-  if (!ash_util::ShouldOpenAshOnStartup() || !browser_)
+  // TODO(crbug.com/764009): Mash support.
+  if (ash_util::IsRunningInMash() || !browser_)
     return false;
 
   bool determined = false;
diff --git a/chrome/common/chrome_switches.cc b/chrome/common/chrome_switches.cc
index 19344aaa..2d9ccdf 100644
--- a/chrome/common/chrome_switches.cc
+++ b/chrome/common/chrome_switches.cc
@@ -503,7 +503,7 @@
 // Enables the out-of-process memory logging.
 const char kMemlog[] = "memlog";
 const char kMemlogModeAll[] = "all";
-const char kMemlogModeBrowser[] = "browser";
+const char kMemlogModeMinimal[] = "minimal";
 
 // Allows setting a different destination ID for connection-monitoring GCM
 // messages. Useful when running against a non-prod management server.
diff --git a/chrome/common/chrome_switches.h b/chrome/common/chrome_switches.h
index a53b2b5..abcdeb0 100644
--- a/chrome/common/chrome_switches.h
+++ b/chrome/common/chrome_switches.h
@@ -156,7 +156,7 @@
 extern const char kMediaCacheSize[];
 extern const char kMemlog[];
 extern const char kMemlogModeAll[];
-extern const char kMemlogModeBrowser[];
+extern const char kMemlogModeMinimal[];
 extern const char kMonitoringDestinationID[];
 extern const char kNetLogCaptureMode[];
 extern const char kNoDefaultBrowserCheck[];
diff --git a/chrome/common/extensions/api/processes.idl b/chrome/common/extensions/api/processes.idl
index a1c479f9..964b94c4 100644
--- a/chrome/common/extensions/api/processes.idl
+++ b/chrome/common/extensions/api/processes.idl
@@ -53,7 +53,10 @@
     long naclDebugPort;
     // Array of TaskInfos representing the tasks running on this process.
     TaskInfo[] tasks;
-    // The most recent measurement of the process CPU usage, between 0 and 100.
+    // The most recent measurement of the process’s CPU usage, expressed as the
+    // percentage of a single CPU core used in total, by all of the process’s
+    // threads. This gives a value from zero to CpuInfo.numOfProcessors*100,
+    // which can exceed 100% in multi-threaded processes.
     // Only available when receiving the object as part of a callback from
     // onUpdated or onUpdatedWithMemory.
     double? cpu;
diff --git a/chrome/common/extensions/docs/server2/app.yaml b/chrome/common/extensions/docs/server2/app.yaml
index c61678d..4cc9f65 100644
--- a/chrome/common/extensions/docs/server2/app.yaml
+++ b/chrome/common/extensions/docs/server2/app.yaml
@@ -1,5 +1,5 @@
 application: chrome-apps-doc
-version: 3-52-0
+version: 3-53-0
 runtime: python27
 api_version: 1
 threadsafe: false
diff --git a/chrome/installer/linux/BUILD.gn b/chrome/installer/linux/BUILD.gn
index 0a5e502f..077e52d 100644
--- a/chrome/installer/linux/BUILD.gn
+++ b/chrome/installer/linux/BUILD.gn
@@ -343,7 +343,7 @@
   deb_target_name = "${target_name}_deb"
   action(deb_target_name) {
     visibility = [ ":*" ]
-    script = "flock_make_package.py"
+    script = "make_package.py"
 
     if (current_cpu == "x86") {
       deb_arch = "i386"
@@ -361,7 +361,6 @@
     ]
 
     args = [
-      rebase_path("$root_out_dir/linux_package.lock", root_build_dir),
       rebase_path("$root_out_dir/installer/debian/build.sh", root_build_dir),
       "-a",
       build_script_arch,
@@ -389,7 +388,7 @@
     rpm_target_name = "${target_name}_rpm"
     action(rpm_target_name) {
       visibility = [ ":*" ]
-      script = "flock_make_package.py"
+      script = "make_package.py"
 
       if (current_cpu == "x86") {
         rpm_arch = "i386"
@@ -407,7 +406,6 @@
       ]
 
       args = [
-        rebase_path("$root_out_dir/linux_package.lock", root_build_dir),
         rebase_path("$root_out_dir/installer/rpm/build.sh", root_build_dir),
         "-a",
         build_script_arch,
diff --git a/chrome/installer/linux/flock_make_package.py b/chrome/installer/linux/flock_make_package.py
deleted file mode 100644
index 839fc40..0000000
--- a/chrome/installer/linux/flock_make_package.py
+++ /dev/null
@@ -1,21 +0,0 @@
-# Copyright 2015 The Chromium Authors. All rights reserved.
-# Use of this source code is governed by a BSD-style license that can be
-# found in the LICENSE file.
-
-# Linux package generation is serialized because it creates large numbers of
-# temporary files that can overload the /tmp partition on the builders.
-# See https://codereview.chromium.org/243019
-#
-# This script does a flock to serialize, and then runs the given shell
-# script with the given parameters.
-#
-# Usage:
-#   flock_make_package.py <lockfile> <shell_script> [<args_to_script>*]
-
-import subprocess
-import sys
-
-if len(sys.argv) < 3:
-  print "Incorrect args."
-  sys.exit(1)
-sys.exit(subprocess.call(["flock", "--", sys.argv[1], "bash"] + sys.argv[2:]))
diff --git a/chrome/installer/linux/make_package.py b/chrome/installer/linux/make_package.py
new file mode 100644
index 0000000..24a259c0
--- /dev/null
+++ b/chrome/installer/linux/make_package.py
@@ -0,0 +1,14 @@
+# Copyright 2015 The Chromium Authors. All rights reserved.
+# Use of this source code is governed by a BSD-style license that can be
+# found in the LICENSE file.
+
+# Usage:
+#   make_package.py <shell_script> [<args_to_script>*]
+
+import subprocess
+import sys
+
+if len(sys.argv) < 2:
+  print "Incorrect args."
+  sys.exit(1)
+sys.exit(subprocess.call(["bash"] + sys.argv[2:]))
diff --git a/chrome/test/BUILD.gn b/chrome/test/BUILD.gn
index ffa0998..b88835b 100644
--- a/chrome/test/BUILD.gn
+++ b/chrome/test/BUILD.gn
@@ -3721,6 +3721,7 @@
 
       # The autofill popup is implemented in mostly native code on Android.
       "../browser/ui/autofill/autofill_popup_controller_unittest.cc",
+      "../browser/ui/blocked_content/scoped_visibility_tracker_unittest.cc",
       "../browser/ui/bookmarks/bookmark_context_menu_controller_unittest.cc",
       "../browser/ui/bookmarks/bookmark_unittest.cc",
       "../browser/ui/browser_close_unittest.cc",
diff --git a/chrome/test/chromedriver/chrome/devtools_http_client.cc b/chrome/test/chromedriver/chrome/devtools_http_client.cc
index b9c4708..333c57f 100644
--- a/chrome/test/chromedriver/chrome/devtools_http_client.cc
+++ b/chrome/test/chromedriver/chrome/devtools_http_client.cc
@@ -212,7 +212,6 @@
     if (status.IsError() && status.code() != kDisconnected)
       return status;
 
-    std::unique_ptr<base::Value> result;
     status = CloseWebView(*it);
     // Ignore disconnected error, because it may be closed already.
     if (status.IsError() && status.code() != kDisconnected)
diff --git a/chromecast/browser/cast_content_browser_client.cc b/chromecast/browser/cast_content_browser_client.cc
index 27e2fa71..ef3395aa 100644
--- a/chromecast/browser/cast_content_browser_client.cc
+++ b/chromecast/browser/cast_content_browser_client.cc
@@ -75,6 +75,10 @@
 #if defined(OS_ANDROID)
 #include "components/cdm/browser/cdm_message_filter_android.h"
 #include "components/crash/content/browser/crash_dump_observer_android.h"
+#if !BUILDFLAG(IS_CAST_USING_CMA_BACKEND)
+#include "components/cdm/browser/media_drm_storage_impl.h"
+#include "url/origin.h"
+#endif  // !BUILDFLAG(IS_CAST_USING_CMA_BACKEND)
 #else
 #include "chromecast/browser/memory_pressure_controller_impl.h"
 #endif  // defined(OS_ANDROID)
@@ -107,6 +111,25 @@
 }
 #endif  // BUILDFLAG(ENABLE_MOJO_MEDIA_IN_BROWSER_PROCESS)
 
+#if defined(OS_ANDROID) && !BUILDFLAG(IS_CAST_USING_CMA_BACKEND)
+void CreateMediaDrmStorage(content::RenderFrameHost* render_frame_host,
+                           ::media::mojom::MediaDrmStorageRequest request) {
+  DVLOG(1) << __func__;
+  PrefService* pref_service = CastBrowserProcess::GetInstance()->pref_service();
+  DCHECK(pref_service);
+
+  url::Origin origin = render_frame_host->GetLastCommittedOrigin();
+  if (origin.unique()) {
+    DVLOG(1) << __func__ << ": Unique origin.";
+    return;
+  }
+
+  // The object will be deleted on connection error, or when the frame navigates
+  // away.
+  new cdm::MediaDrmStorageImpl(render_frame_host, pref_service, origin,
+                               std::move(request));
+}
+#endif  // defined(OS_ANDROID) && !BUILDFLAG(IS_CAST_USING_CMA_BACKEND)
 }  // namespace
 
 CastContentBrowserClient::CastContentBrowserClient()
@@ -525,6 +548,15 @@
 #endif  // !defined(OS_ANDROID)
 }
 
+void CastContentBrowserClient::ExposeInterfacesToMediaService(
+    service_manager::BinderRegistry* registry,
+    content::RenderFrameHost* render_frame_host) {
+#if defined(OS_ANDROID) && !BUILDFLAG(IS_CAST_USING_CMA_BACKEND)
+  registry->AddInterface(
+      base::BindRepeating(&CreateMediaDrmStorage, render_frame_host));
+#endif
+}
+
 void CastContentBrowserClient::RegisterInProcessServices(
     StaticServiceMap* services) {
 #if BUILDFLAG(ENABLE_MOJO_MEDIA_IN_BROWSER_PROCESS)
diff --git a/chromecast/browser/cast_content_browser_client.h b/chromecast/browser/cast_content_browser_client.h
index a741455..52d652d 100644
--- a/chromecast/browser/cast_content_browser_client.h
+++ b/chromecast/browser/cast_content_browser_client.h
@@ -162,6 +162,9 @@
       service_manager::BinderRegistry* registry,
       content::AssociatedInterfaceRegistry* associated_registry,
       content::RenderProcessHost* render_process_host) override;
+  void ExposeInterfacesToMediaService(
+      service_manager::BinderRegistry* registry,
+      content::RenderFrameHost* render_frame_host) override;
   void RegisterInProcessServices(StaticServiceMap* services) override;
   std::unique_ptr<base::Value> GetServiceManifestOverlay(
       base::StringPiece service_name) override;
diff --git a/chromecast/browser/pref_service_helper.cc b/chromecast/browser/pref_service_helper.cc
index 70edc10..56d9de58 100644
--- a/chromecast/browser/pref_service_helper.cc
+++ b/chromecast/browser/pref_service_helper.cc
@@ -10,13 +10,19 @@
 #include "base/files/file_util.h"
 #include "base/logging.h"
 #include "base/path_service.h"
+#include "build/build_config.h"
 #include "chromecast/base/cast_paths.h"
 #include "chromecast/base/pref_names.h"
+#include "chromecast/chromecast_features.h"
 #include "components/prefs/json_pref_store.h"
 #include "components/prefs/pref_registry_simple.h"
 #include "components/prefs/pref_service_factory.h"
 #include "components/prefs/pref_store.h"
 
+#if defined(OS_ANDROID) && !BUILDFLAG(IS_CAST_USING_CMA_BACKEND)
+#include "components/cdm/browser/media_drm_storage_impl.h"
+#endif  // defined(OS_ANDROID) && !BUILDFLAG(IS_CAST_USING_CMA_BACKEND)
+
 namespace chromecast {
 namespace shell {
 
@@ -54,6 +60,10 @@
   registry->RegisterListPref(prefs::kActiveDCSExperiments);
   registry->RegisterDictionaryPref(prefs::kLatestDCSFeatures);
 
+#if defined(OS_ANDROID) && !BUILDFLAG(IS_CAST_USING_CMA_BACKEND)
+  cdm::MediaDrmStorageImpl::RegisterProfilePrefs(registry);
+#endif  // defined(OS_ANDROID) && !BUILDFLAG(IS_CAST_USING_CMA_BACKEND)
+
   RegisterPlatformPrefs(registry);
 
   PrefServiceFactory prefServiceFactory;
diff --git a/components/history/core/browser/top_sites_impl_unittest.cc b/components/history/core/browser/top_sites_impl_unittest.cc
index 4ecec6c..3ef72e53 100644
--- a/components/history/core/browser/top_sites_impl_unittest.cc
+++ b/components/history/core/browser/top_sites_impl_unittest.cc
@@ -326,7 +326,7 @@
 
 // Helper function for appending a URL to a vector of "most visited" URLs,
 // using the default values for everything but the URL.
-void AppendMostVisitedURL(std::vector<MostVisitedURL>* list, const GURL& url) {
+void AppendMostVisitedURL(const GURL& url, std::vector<MostVisitedURL>* list) {
   MostVisitedURL mv;
   mv.url = url;
   mv.redirects.push_back(url);
@@ -335,9 +335,9 @@
 
 // Helper function for appending a URL to a vector of "most visited" URLs,
 // using the default values for everything but the URL.
-void AppendForcedMostVisitedURL(std::vector<MostVisitedURL>* list,
-                                const GURL& url,
-                                double last_forced_time) {
+void AppendForcedMostVisitedURL(const GURL& url,
+                                double last_forced_time,
+                                std::vector<MostVisitedURL>* list) {
   MostVisitedURL mv;
   mv.url = url;
   mv.last_forced_time = base::Time::FromJsTime(last_forced_time);
@@ -347,9 +347,9 @@
 
 // Same as AppendMostVisitedURL except that it adds a redirect from the first
 // URL to the second.
-void AppendMostVisitedURLWithRedirect(std::vector<MostVisitedURL>* list,
-                                      const GURL& redirect_source,
-                                      const GURL& redirect_dest) {
+void AppendMostVisitedURLWithRedirect(const GURL& redirect_source,
+                                      const GURL& redirect_dest,
+                                      std::vector<MostVisitedURL>* list) {
   MostVisitedURL mv;
   mv.url = redirect_dest;
   mv.redirects.push_back(redirect_source);
@@ -379,8 +379,8 @@
   GURL dest("http://www.google.com/");
 
   std::vector<MostVisitedURL> most_visited;
-  AppendMostVisitedURLWithRedirect(&most_visited, source, dest);
-  AppendMostVisitedURL(&most_visited, news);
+  AppendMostVisitedURLWithRedirect(source, dest, &most_visited);
+  AppendMostVisitedURL(news, &most_visited);
   SetTopSites(most_visited);
 
   // Random URLs not in the database are returned unchanged.
@@ -473,15 +473,15 @@
   GURL gets_moved_1("http://getsmoved1/");
 
   std::vector<MostVisitedURL> old_list;
-  AppendMostVisitedURL(&old_list, stays_the_same);  // 0  (unchanged)
-  AppendMostVisitedURL(&old_list, gets_deleted_1);  // 1  (deleted)
-  AppendMostVisitedURL(&old_list, gets_moved_1);    // 2  (moved to 3)
+  AppendMostVisitedURL(stays_the_same, &old_list);  // 0  (unchanged)
+  AppendMostVisitedURL(gets_deleted_1, &old_list);  // 1  (deleted)
+  AppendMostVisitedURL(gets_moved_1, &old_list);    // 2  (moved to 3)
 
   std::vector<MostVisitedURL> new_list;
-  AppendMostVisitedURL(&new_list, stays_the_same);  // 0  (unchanged)
-  AppendMostVisitedURL(&new_list, gets_added_1);    // 1  (added)
-  AppendMostVisitedURL(&new_list, gets_added_2);    // 2  (added)
-  AppendMostVisitedURL(&new_list, gets_moved_1);    // 3  (moved from 2)
+  AppendMostVisitedURL(stays_the_same, &new_list);  // 0  (unchanged)
+  AppendMostVisitedURL(gets_added_1, &new_list);    // 1  (added)
+  AppendMostVisitedURL(gets_added_2, &new_list);    // 2  (added)
+  AppendMostVisitedURL(gets_moved_1, &new_list);    // 3  (moved from 2)
 
   history::TopSitesDelta delta;
   history::TopSitesImpl::DiffMostVisited(old_list, new_list, &delta);
@@ -517,26 +517,26 @@
   GURL gets_moved_1("http://getsmoved1/");
 
   std::vector<MostVisitedURL> old_list;
-  AppendForcedMostVisitedURL(&old_list, stays_the_same_1, 1000);
-  AppendForcedMostVisitedURL(&old_list, new_last_forced_time, 2000);
-  AppendForcedMostVisitedURL(&old_list, stays_the_same_2, 3000);
-  AppendForcedMostVisitedURL(&old_list, move_to_nonforced, 4000);
-  AppendForcedMostVisitedURL(&old_list, gets_deleted_1, 5000);
-  AppendMostVisitedURL(&old_list, move_to_forced);
-  AppendMostVisitedURL(&old_list, stays_the_same_3);
-  AppendMostVisitedURL(&old_list, gets_deleted_2);
-  AppendMostVisitedURL(&old_list, gets_moved_1);
+  AppendForcedMostVisitedURL(stays_the_same_1, 1000, &old_list);
+  AppendForcedMostVisitedURL(new_last_forced_time, 2000, &old_list);
+  AppendForcedMostVisitedURL(stays_the_same_2, 3000, &old_list);
+  AppendForcedMostVisitedURL(move_to_nonforced, 4000, &old_list);
+  AppendForcedMostVisitedURL(gets_deleted_1, 5000, &old_list);
+  AppendMostVisitedURL(move_to_forced, &old_list);
+  AppendMostVisitedURL(stays_the_same_3, &old_list);
+  AppendMostVisitedURL(gets_deleted_2, &old_list);
+  AppendMostVisitedURL(gets_moved_1, &old_list);
 
   std::vector<MostVisitedURL> new_list;
-  AppendForcedMostVisitedURL(&new_list, stays_the_same_1, 1000);
-  AppendForcedMostVisitedURL(&new_list, stays_the_same_2, 3000);
-  AppendForcedMostVisitedURL(&new_list, new_last_forced_time, 4000);
-  AppendForcedMostVisitedURL(&new_list, gets_added_1, 5000);
-  AppendForcedMostVisitedURL(&new_list, move_to_forced, 6000);
-  AppendMostVisitedURL(&new_list, move_to_nonforced);
-  AppendMostVisitedURL(&new_list, stays_the_same_3);
-  AppendMostVisitedURL(&new_list, gets_added_2);
-  AppendMostVisitedURL(&new_list, gets_moved_1);
+  AppendForcedMostVisitedURL(stays_the_same_1, 1000, &new_list);
+  AppendForcedMostVisitedURL(stays_the_same_2, 3000, &new_list);
+  AppendForcedMostVisitedURL(new_last_forced_time, 4000, &new_list);
+  AppendForcedMostVisitedURL(gets_added_1, 5000, &new_list);
+  AppendForcedMostVisitedURL(move_to_forced, 6000, &new_list);
+  AppendMostVisitedURL(move_to_nonforced, &new_list);
+  AppendMostVisitedURL(stays_the_same_3, &new_list);
+  AppendMostVisitedURL(gets_added_2, &new_list);
+  AppendMostVisitedURL(gets_moved_1, &new_list);
 
   history::TopSitesDelta delta;
   history::TopSitesImpl::DiffMostVisited(old_list, new_list, &delta);
@@ -571,7 +571,7 @@
   GURL invalid_url("application://favicon/http://google.com/");
 
   std::vector<MostVisitedURL> list;
-  AppendMostVisitedURL(&list, url2);
+  AppendMostVisitedURL(url2, &list);
 
   MostVisitedURL mv;
   mv.url = url1b;
@@ -614,7 +614,7 @@
 
   // Configure top sites with 'google.com'.
   std::vector<MostVisitedURL> list;
-  AppendMostVisitedURL(&list, url);
+  AppendMostVisitedURL(url, &list);
   SetTopSites(list);
 
   // Create a dummy thumbnail.
@@ -815,11 +815,11 @@
 
   // Add a number of forced URLs.
   std::vector<MostVisitedURL> list;
-  AppendForcedMostVisitedURL(&list, GURL("http://forced1"), 1000);
+  AppendForcedMostVisitedURL(GURL("http://forced1"), 1000, &list);
   list[0].title = base::ASCIIToUTF16("forced1");
-  AppendForcedMostVisitedURL(&list, GURL("http://forced2"), 2000);
-  AppendForcedMostVisitedURL(&list, GURL("http://forced3"), 3000);
-  AppendForcedMostVisitedURL(&list, GURL("http://forced4"), 4000);
+  AppendForcedMostVisitedURL(GURL("http://forced2"), 2000, &list);
+  AppendForcedMostVisitedURL(GURL("http://forced3"), 3000, &list);
+  AppendForcedMostVisitedURL(GURL("http://forced4"), 4000, &list);
   SetTopSites(list);
 
   // Add a thumbnail.
@@ -1426,42 +1426,42 @@
 TEST_F(TopSitesImplTest, SetForcedTopSites) {
   // Create forced elements in old URL list.
   MostVisitedURLList old_url_list;
-  AppendForcedMostVisitedURL(&old_url_list, GURL("http://oldforced/0"), 1000);
-  AppendForcedMostVisitedURL(&old_url_list, GURL("http://oldforced/1"), 4000);
-  AppendForcedMostVisitedURL(&old_url_list, GURL("http://oldforced/2"), 7000);
-  AppendForcedMostVisitedURL(&old_url_list, GURL("http://oldforced/3"), 10000);
-  AppendForcedMostVisitedURL(&old_url_list, GURL("http://oldforced/4"), 11000);
-  AppendForcedMostVisitedURL(&old_url_list, GURL("http://oldforced/5"), 12000);
-  AppendForcedMostVisitedURL(&old_url_list, GURL("http://oldforced/6"), 13000);
-  AppendForcedMostVisitedURL(&old_url_list, GURL("http://oldforced/7"), 18000);
-  AppendForcedMostVisitedURL(&old_url_list, GURL("http://oldforced/8"), 21000);
+  AppendForcedMostVisitedURL(GURL("http://oldforced/0"), 1000, &old_url_list);
+  AppendForcedMostVisitedURL(GURL("http://oldforced/1"), 4000, &old_url_list);
+  AppendForcedMostVisitedURL(GURL("http://oldforced/2"), 7000, &old_url_list);
+  AppendForcedMostVisitedURL(GURL("http://oldforced/3"), 10000, &old_url_list);
+  AppendForcedMostVisitedURL(GURL("http://oldforced/4"), 11000, &old_url_list);
+  AppendForcedMostVisitedURL(GURL("http://oldforced/5"), 12000, &old_url_list);
+  AppendForcedMostVisitedURL(GURL("http://oldforced/6"), 13000, &old_url_list);
+  AppendForcedMostVisitedURL(GURL("http://oldforced/7"), 18000, &old_url_list);
+  AppendForcedMostVisitedURL(GURL("http://oldforced/8"), 21000, &old_url_list);
   const size_t kNumOldForcedURLs = 9;
 
   // Create forced elements in new URL list.
   MostVisitedURLList new_url_list;
-  AppendForcedMostVisitedURL(&new_url_list, GURL("http://newforced/0"), 2000);
-  AppendForcedMostVisitedURL(&new_url_list, GURL("http://newforced/1"), 3000);
-  AppendForcedMostVisitedURL(&new_url_list, GURL("http://newforced/2"), 5000);
-  AppendForcedMostVisitedURL(&new_url_list, GURL("http://newforced/3"), 6000);
-  AppendForcedMostVisitedURL(&new_url_list, GURL("http://newforced/4"), 8000);
-  AppendForcedMostVisitedURL(&new_url_list, GURL("http://newforced/5"), 9000);
-  AppendForcedMostVisitedURL(&new_url_list, GURL("http://newforced/6"), 14000);
-  AppendForcedMostVisitedURL(&new_url_list, GURL("http://newforced/7"), 15000);
-  AppendForcedMostVisitedURL(&new_url_list, GURL("http://newforced/8"), 16000);
-  AppendForcedMostVisitedURL(&new_url_list, GURL("http://newforced/9"), 17000);
-  AppendForcedMostVisitedURL(&new_url_list, GURL("http://newforced/10"), 19000);
-  AppendForcedMostVisitedURL(&new_url_list, GURL("http://newforced/11"), 20000);
-  AppendForcedMostVisitedURL(&new_url_list, GURL("http://newforced/12"), 22000);
+  AppendForcedMostVisitedURL(GURL("http://newforced/0"), 2000, &new_url_list);
+  AppendForcedMostVisitedURL(GURL("http://newforced/1"), 3000, &new_url_list);
+  AppendForcedMostVisitedURL(GURL("http://newforced/2"), 5000, &new_url_list);
+  AppendForcedMostVisitedURL(GURL("http://newforced/3"), 6000, &new_url_list);
+  AppendForcedMostVisitedURL(GURL("http://newforced/4"), 8000, &new_url_list);
+  AppendForcedMostVisitedURL(GURL("http://newforced/5"), 9000, &new_url_list);
+  AppendForcedMostVisitedURL(GURL("http://newforced/6"), 14000, &new_url_list);
+  AppendForcedMostVisitedURL(GURL("http://newforced/7"), 15000, &new_url_list);
+  AppendForcedMostVisitedURL(GURL("http://newforced/8"), 16000, &new_url_list);
+  AppendForcedMostVisitedURL(GURL("http://newforced/9"), 17000, &new_url_list);
+  AppendForcedMostVisitedURL(GURL("http://newforced/10"), 19000, &new_url_list);
+  AppendForcedMostVisitedURL(GURL("http://newforced/11"), 20000, &new_url_list);
+  AppendForcedMostVisitedURL(GURL("http://newforced/12"), 22000, &new_url_list);
 
   // Setup a number non-forced URLs in both old and new list.
   const size_t kNumNonForcedURLs = 20;  // Maximum number of non-forced URLs.
   for (size_t i = 0; i < kNumNonForcedURLs; ++i) {
     std::ostringstream url;
     url << "http://oldnonforced/" << i;
-    AppendMostVisitedURL(&old_url_list, GURL(url.str()));
+    AppendMostVisitedURL(GURL(url.str()), &old_url_list);
     url.str("");
     url << "http://newnonforced/" << i;
-    AppendMostVisitedURL(&new_url_list, GURL(url.str()));
+    AppendMostVisitedURL(GURL(url.str()), &new_url_list);
   }
 
   // Set the initial list of URLs.
@@ -1547,25 +1547,25 @@
 TEST_F(TopSitesImplTest, SetForcedTopSitesWithCollisions) {
   // Setup an old URL list in order to generate some collisions.
   MostVisitedURLList old_url_list;
-  AppendForcedMostVisitedURL(&old_url_list, GURL("http://url/0"), 1000);
+  AppendForcedMostVisitedURL(GURL("http://url/0"), 1000, &old_url_list);
   // The following three will be evicted.
-  AppendForcedMostVisitedURL(&old_url_list, GURL("http://collision/0"), 4000);
-  AppendForcedMostVisitedURL(&old_url_list, GURL("http://collision/1"), 6000);
-  AppendForcedMostVisitedURL(&old_url_list, GURL("http://collision/2"), 7000);
+  AppendForcedMostVisitedURL(GURL("http://collision/0"), 4000, &old_url_list);
+  AppendForcedMostVisitedURL(GURL("http://collision/1"), 6000, &old_url_list);
+  AppendForcedMostVisitedURL(GURL("http://collision/2"), 7000, &old_url_list);
   // The following is evicted since all non-forced URLs are, therefore it
   // doesn't cause a collision.
-  AppendMostVisitedURL(&old_url_list, GURL("http://noncollision/0"));
+  AppendMostVisitedURL(GURL("http://noncollision/0"), &old_url_list);
   SetTopSites(old_url_list);
 
   // Setup a new URL list that will cause collisions.
   MostVisitedURLList new_url_list;
-  AppendForcedMostVisitedURL(&new_url_list, GURL("http://collision/1"), 2000);
-  AppendForcedMostVisitedURL(&new_url_list, GURL("http://url/2"), 3000);
-  AppendForcedMostVisitedURL(&new_url_list, GURL("http://collision/0"), 5000);
-  AppendForcedMostVisitedURL(&new_url_list, GURL("http://noncollision/0"),
-                             9000);
-  AppendMostVisitedURL(&new_url_list, GURL("http://collision/2"));
-  AppendMostVisitedURL(&new_url_list, GURL("http://url/3"));
+  AppendForcedMostVisitedURL(GURL("http://collision/1"), 2000, &new_url_list);
+  AppendForcedMostVisitedURL(GURL("http://url/2"), 3000, &new_url_list);
+  AppendForcedMostVisitedURL(GURL("http://collision/0"), 5000, &new_url_list);
+  AppendForcedMostVisitedURL(GURL("http://noncollision/0"), 9000,
+                             &new_url_list);
+  AppendMostVisitedURL(GURL("http://collision/2"), &new_url_list);
+  AppendMostVisitedURL(GURL("http://url/3"), &new_url_list);
   SetTopSites(new_url_list);
 
   // Query all URLs.
@@ -1594,9 +1594,9 @@
 TEST_F(TopSitesImplTest, SetTopSitesIdentical) {
   // Set the initial list of URLs.
   MostVisitedURLList url_list;
-  AppendForcedMostVisitedURL(&url_list, GURL("http://url/0"), 1000);
-  AppendMostVisitedURL(&url_list, GURL("http://url/1"));
-  AppendMostVisitedURL(&url_list, GURL("http://url/2"));
+  AppendForcedMostVisitedURL(GURL("http://url/0"), 1000, &url_list);
+  AppendMostVisitedURL(GURL("http://url/1"), &url_list);
+  AppendMostVisitedURL(GURL("http://url/2"), &url_list);
   SetTopSites(url_list);
 
   // Set the new list of URLs to be exactly the same.
@@ -1618,15 +1618,15 @@
 TEST_F(TopSitesImplTest, SetTopSitesWithAlreadyExistingForcedURLs) {
   // Set the initial list of URLs.
   MostVisitedURLList old_url_list;
-  AppendForcedMostVisitedURL(&old_url_list, GURL("http://url/0/redir"), 1000);
-  AppendForcedMostVisitedURL(&old_url_list, GURL("http://url/1"), 2000);
+  AppendForcedMostVisitedURL(GURL("http://url/0/redir"), 1000, &old_url_list);
+  AppendForcedMostVisitedURL(GURL("http://url/1"), 2000, &old_url_list);
   SetTopSites(old_url_list);
 
   // Setup a new URL list that will cause collisions.
   MostVisitedURLList new_url_list;
-  AppendMostVisitedURLWithRedirect(&new_url_list, GURL("http://url/0/redir"),
-                                   GURL("http://url/0"));
-  AppendMostVisitedURL(&new_url_list, GURL("http://url/1"));
+  AppendMostVisitedURLWithRedirect(GURL("http://url/0/redir"),
+                                   GURL("http://url/0"), &new_url_list);
+  AppendMostVisitedURL(GURL("http://url/1"), &new_url_list);
   SetTopSites(new_url_list);
 
   // Query all URLs.
@@ -1646,11 +1646,11 @@
 TEST_F(TopSitesImplTest, AddForcedURL) {
   // Set the initial list of URLs.
   MostVisitedURLList url_list;
-  AppendForcedMostVisitedURL(&url_list, GURL("http://forced/0"), 2000);
-  AppendForcedMostVisitedURL(&url_list, GURL("http://forced/1"), 4000);
-  AppendMostVisitedURL(&url_list, GURL("http://nonforced/0"));
-  AppendMostVisitedURL(&url_list, GURL("http://nonforced/1"));
-  AppendMostVisitedURL(&url_list, GURL("http://nonforced/2"));
+  AppendForcedMostVisitedURL(GURL("http://forced/0"), 2000, &url_list);
+  AppendForcedMostVisitedURL(GURL("http://forced/1"), 4000, &url_list);
+  AppendMostVisitedURL(GURL("http://nonforced/0"), &url_list);
+  AppendMostVisitedURL(GURL("http://nonforced/1"), &url_list);
+  AppendMostVisitedURL(GURL("http://nonforced/2"), &url_list);
   SetTopSites(url_list);
 
   // Add forced sites here and there to exercise a couple of cases.
diff --git a/components/nacl/loader/BUILD.gn b/components/nacl/loader/BUILD.gn
index eef2cb0..fe78475 100644
--- a/components/nacl/loader/BUILD.gn
+++ b/components/nacl/loader/BUILD.gn
@@ -134,6 +134,12 @@
 
     ldflags = [ "-pie" ]
 
+    if (is_chromeos) {
+      # NaCl is not working with compiler-rt in ChromeOS.
+      # Force libgcc as a workaround. See https://crbug.com/761103
+      ldflags += [ "-rtlib=libgcc" ]
+    }
+
     data_deps = [
       "//native_client/src/trusted/service_runtime/linux:bootstrap",
     ]
diff --git a/components/policy/resources/policy_templates.json b/components/policy/resources/policy_templates.json
index 80c4292..f71ec3c 100644
--- a/components/policy/resources/policy_templates.json
+++ b/components/policy/resources/policy_templates.json
@@ -8197,6 +8197,7 @@
         'dynamic_refresh': False,
         'per_profile': False,
       },
+      'future': True,
       'example_value': False,
       'id': 346,
       'caption': '''Enables force sign in for <ph name="PRODUCT_NAME">$1<ex>Google Chrome</ex></ph>''',
diff --git a/components/previews/core/BUILD.gn b/components/previews/core/BUILD.gn
index 6105235..84d89fe 100644
--- a/components/previews/core/BUILD.gn
+++ b/components/previews/core/BUILD.gn
@@ -4,6 +4,8 @@
 
 static_library("core") {
   sources = [
+    "previews_amp_converter.cc",
+    "previews_amp_converter.h",
     "previews_black_list.cc",
     "previews_black_list.h",
     "previews_black_list_item.cc",
@@ -27,6 +29,7 @@
     "//components/variations",
     "//net:net",
     "//sql",
+    "//third_party/re2",
     "//url:url",
   ]
 }
@@ -34,6 +37,7 @@
 source_set("unit_tests") {
   testonly = true
   sources = [
+    "previews_amp_converter_unittest.cc",
     "previews_black_list_item_unittest.cc",
     "previews_black_list_unittest.cc",
     "previews_experiments_unittest.cc",
diff --git a/components/previews/core/DEPS b/components/previews/core/DEPS
index 6193f48a..8eb4524 100644
--- a/components/previews/core/DEPS
+++ b/components/previews/core/DEPS
@@ -1,5 +1,6 @@
 include_rules = [
   "+components/variations",
   "+net",
-  "+sql"
+  "+sql",
+  "+third_party/re2"
 ]
diff --git a/components/previews/core/previews_amp_converter.cc b/components/previews/core/previews_amp_converter.cc
new file mode 100644
index 0000000..30b6f9c
--- /dev/null
+++ b/components/previews/core/previews_amp_converter.cc
@@ -0,0 +1,183 @@
+// Copyright 2017 The Chromium Authors. All rights reserved.
+// Use of this source code is governed by a BSD-style license that can be
+// found in the LICENSE file.
+
+#include "components/previews/core/previews_amp_converter.h"
+
+#include <utility>
+
+#include "base/feature_list.h"
+#include "base/json/json_reader.h"
+#include "base/memory/ptr_util.h"
+#include "base/metrics/field_trial.h"
+#include "base/metrics/field_trial_params.h"
+#include "base/strings/string_util.h"
+#include "base/values.h"
+#include "components/previews/core/previews_features.h"
+#include "components/variations/variations_associated_data.h"
+#include "third_party/re2/src/re2/re2.h"
+#include "url/url_constants.h"
+
+namespace previews {
+
+namespace {
+
+const char kAMPRedirectionConfig[] = "config";
+
+// Allowed URL schemes to match.
+enum MatchingScheme { HTTP, HTTPS, BOTH };
+
+}  // namespace
+
+struct AMPConverterEntry {
+  AMPConverterEntry(MatchingScheme matching_scheme,
+                    std::unique_ptr<re2::RE2> matching_path_pattern,
+                    const std::string& hostname_amp,
+                    const std::string& scheme_amp,
+                    const std::string& prefix,
+                    const std::string& suffix,
+                    const std::string& suffix_html)
+      : matching_scheme(matching_scheme),
+        matching_path_pattern(std::move(matching_path_pattern)),
+        hostname_amp(hostname_amp),
+        scheme_amp(scheme_amp),
+        prefix(prefix),
+        suffix(suffix),
+        suffix_html(suffix_html) {}
+
+  ~AMPConverterEntry() {}
+
+  // URL scheme to match.
+  const MatchingScheme matching_scheme;
+
+  // RE2 pattern the URL path should match.
+  const std::unique_ptr<re2::RE2> matching_path_pattern;
+
+  // New AMP hostname for the URL, if any.
+  const std::string hostname_amp;
+
+  // New scheme for the AMP URL, if any.
+  const std::string scheme_amp;
+
+  // String to be prefixed to the URL path, if any.
+  const std::string prefix;
+
+  // String to be suffixed to the URL path, before query string and named
+  // anchor, if any.
+  const std::string suffix;
+
+  // String to be suffixed to the URL path, before the .html extension, if
+  // any.
+  const std::string suffix_html;
+};
+
+PreviewsAMPConverter::PreviewsAMPConverter() {
+  std::string config_text = GetFieldTrialParamValueByFeature(
+      features::kAMPRedirection, kAMPRedirectionConfig);
+  if (config_text.empty())
+    return;
+
+  std::unique_ptr<base::Value> value = base::JSONReader::Read(config_text);
+  const base::ListValue* entries = nullptr;
+  if (!value || !value->GetAsList(&entries))
+    return;
+
+  re2::RE2::Options options(re2::RE2::DefaultOptions);
+  options.set_case_sensitive(true);
+
+  for (const auto& entry : *entries) {
+    const base::DictionaryValue* dict = nullptr;
+    if (!entry.GetAsDictionary(&dict))
+      continue;
+    std::string host, matching_scheme_str, matching_path_pattern_str, host_amp,
+        scheme_amp, prefix, suffix, suffix_html;
+    dict->GetString("host", &host);
+    dict->GetString("scheme", &matching_scheme_str);
+    dict->GetString("pattern", &matching_path_pattern_str);
+    dict->GetString("hostamp", &host_amp);
+    dict->GetString("schemeamp", &scheme_amp);
+    dict->GetString("prefix", &prefix);
+    dict->GetString("suffix", &suffix);
+    dict->GetString("suffixhtml", &suffix_html);
+    MatchingScheme matching_scheme =
+        matching_scheme_str == url::kHttpScheme
+            ? MatchingScheme::HTTP
+            : matching_scheme_str == url::kHttpsScheme ? MatchingScheme::HTTPS
+                                                       : MatchingScheme::BOTH;
+
+    // If matching scheme is HTTPS or BOTH, then AMP scheme should not be http,
+    // which will redirect https to http.
+    DCHECK(matching_scheme == MatchingScheme::HTTP ||
+           scheme_amp != url::kHttpScheme);
+
+    std::unique_ptr<re2::RE2> matching_path_pattern_re2(
+        base::MakeUnique<re2::RE2>(matching_path_pattern_str, options));
+    if (host.empty() || !matching_path_pattern_re2->ok() ||
+        (scheme_amp != "" && scheme_amp != url::kHttpScheme &&
+         scheme_amp != url::kHttpsScheme)) {
+      continue;
+    }
+    amp_converter_.insert(std::make_pair(
+        host, base::MakeUnique<AMPConverterEntry>(
+                  matching_scheme, std::move(matching_path_pattern_re2),
+                  host_amp, scheme_amp, prefix, suffix, suffix_html)));
+  }
+}
+
+PreviewsAMPConverter::~PreviewsAMPConverter() {}
+
+bool PreviewsAMPConverter::GetAMPURL(const GURL& url, GURL* new_amp_url) const {
+  DCHECK_CALLED_ON_VALID_THREAD(thread_checker_);
+
+  if (!url.is_valid() || !url.SchemeIsHTTPOrHTTPS()) {
+    return false;
+  }
+
+  const auto amp_converter_iter = amp_converter_.find(url.host());
+  if (amp_converter_iter == amp_converter_.end() ||
+      !re2::RE2::FullMatch(
+          url.path(), *amp_converter_iter->second->matching_path_pattern)) {
+    return false;
+  }
+  const auto& entry = *amp_converter_iter->second;
+
+  // Check for allowed URL schemes.
+  if (entry.matching_scheme != MatchingScheme::BOTH &&
+      (entry.matching_scheme == MatchingScheme::HTTP) !=
+          url.SchemeIs(url::kHttpScheme)) {
+    return false;
+  }
+
+  GURL amp_url(url);
+  GURL::Replacements url_replacements;
+  if (!entry.hostname_amp.empty())
+    url_replacements.SetHostStr(entry.hostname_amp);
+  if (!entry.scheme_amp.empty()) {
+    // Avoid https to http redirection.
+    if (url.scheme() == url::kHttpsScheme &&
+        entry.scheme_amp == url::kHttpScheme) {
+      return false;
+    }
+    url_replacements.SetSchemeStr(entry.scheme_amp);
+  }
+
+  std::string path;
+  if (!entry.prefix.empty() || !entry.suffix.empty() ||
+      !entry.suffix_html.empty()) {
+    DCHECK(entry.prefix.empty() || entry.prefix[0] == '/');
+    path = base::JoinString({entry.prefix, url.path(), entry.suffix}, "");
+    if (!entry.suffix_html.empty() &&
+        base::EndsWith(path, ".html", base::CompareCase::SENSITIVE)) {
+      // Insert suffix_html before the .html extension.
+      path.insert(path.length() - 5, entry.suffix_html);
+    }
+    url_replacements.SetPathStr(path);
+  }
+  amp_url = amp_url.ReplaceComponents(url_replacements);
+  if (!amp_url.is_valid())
+    return false;
+  new_amp_url->Swap(&amp_url);
+  return true;
+}
+
+}  // namespace previews
diff --git a/components/previews/core/previews_amp_converter.h b/components/previews/core/previews_amp_converter.h
new file mode 100644
index 0000000..e5e4a837
--- /dev/null
+++ b/components/previews/core/previews_amp_converter.h
@@ -0,0 +1,44 @@
+// Copyright 2017 The Chromium Authors. All rights reserved.
+// Use of this source code is governed by a BSD-style license that can be
+// found in the LICENSE file.
+
+#ifndef COMPONENTS_PREVIEWS_CORE_PREVIEWS_AMP_REDIRECTION_H_
+#define COMPONENTS_PREVIEWS_CORE_PREVIEWS_AMP_REDIRECTION_H_
+
+#include <map>
+#include <memory>
+#include <string>
+
+#include "base/macros.h"
+#include "base/threading/thread_checker.h"
+#include "url/gurl.h"
+
+namespace previews {
+
+// Contains the parameters for converting URLs for one domain.
+struct AMPConverterEntry;
+
+// Checks whether an URL is whitelisted for AMP redirection previews and
+// implements the scheme used to convert URL to its AMP version.
+class PreviewsAMPConverter {
+ public:
+  PreviewsAMPConverter();
+
+  virtual ~PreviewsAMPConverter();
+
+  // Returns true if |url| can be converted to its AMP version. |new_amp_url|
+  // will contain the AMP URL.
+  bool GetAMPURL(const GURL& url, GURL* new_amp_url) const;
+
+ private:
+  // Maps the hostname to its AMP conversion scheme.
+  std::map<std::string, std::unique_ptr<AMPConverterEntry>> amp_converter_;
+
+  THREAD_CHECKER(thread_checker_);
+
+  DISALLOW_COPY_AND_ASSIGN(PreviewsAMPConverter);
+};
+
+}  // namespace previews
+
+#endif  // COMPONENTS_PREVIEWS_CORE_PREVIEWS_AMP_REDIRECTION_H_
diff --git a/components/previews/core/previews_amp_converter_unittest.cc b/components/previews/core/previews_amp_converter_unittest.cc
new file mode 100644
index 0000000..2583dc6
--- /dev/null
+++ b/components/previews/core/previews_amp_converter_unittest.cc
@@ -0,0 +1,278 @@
+// Copyright 2017 The Chromium Authors. All rights reserved.
+// Use of this source code is governed by a BSD-style license that can be
+// found in the LICENSE file.
+
+#include "components/previews/core/previews_amp_converter.h"
+
+#include <memory>
+#include <string>
+
+#include "base/test/scoped_feature_list.h"
+#include "components/previews/core/previews_features.h"
+#include "testing/gtest/include/gtest/gtest.h"
+
+namespace previews {
+
+namespace {
+
+class PreviewsAMPConverterTest : public testing::Test {
+ public:
+  PreviewsAMPConverterTest() {}
+
+  void Initialize() { amp_converter_.reset(new PreviewsAMPConverter()); }
+
+  PreviewsAMPConverter* amp_converter() { return amp_converter_.get(); }
+
+  void CreateAMPRedirectionFieldTrialWithParams(
+      std::initializer_list<
+          typename std::map<std::string, std::string>::value_type> params) {
+    scoped_feature_list_.InitAndEnableFeatureWithParameters(
+        features::kAMPRedirection, params);
+  }
+
+ private:
+  base::test::ScopedFeatureList scoped_feature_list_;
+  std::unique_ptr<PreviewsAMPConverter> amp_converter_;
+};
+
+TEST_F(PreviewsAMPConverterTest, TestDisallowedByDefault) {
+  Initialize();
+
+  const char* urls[] = {"", "http://test.com", "https://test.com",
+                        "http://www.test.com", "http://test.com/index.html"};
+  GURL amp_url;
+  for (const char* url : urls) {
+    EXPECT_FALSE(amp_converter()->GetAMPURL(GURL(url), &amp_url)) << url;
+  }
+}
+
+TEST_F(PreviewsAMPConverterTest, TestEmptyConfig) {
+  CreateAMPRedirectionFieldTrialWithParams({{"config", ""}});
+  Initialize();
+
+  const char* urls[] = {"", "http://test.com", "https://test.com",
+                        "http://www.test.com", "http://test.com/index.html"};
+  GURL amp_url;
+  for (const char* url : urls) {
+    EXPECT_FALSE(amp_converter()->GetAMPURL(GURL(url), &amp_url)) << url;
+  }
+}
+
+TEST_F(PreviewsAMPConverterTest, TestMalformedConfig) {
+  CreateAMPRedirectionFieldTrialWithParams({{"config", "config = foo bar"}});
+  Initialize();
+
+  const char* urls[] = {"", "http://test.com", "https://test.com",
+                        "http://www.test.com", "http://test.com/index.html"};
+  GURL amp_url;
+  for (const char* url : urls) {
+    EXPECT_FALSE(amp_converter()->GetAMPURL(GURL(url), &amp_url)) << url;
+  }
+}
+
+TEST_F(PreviewsAMPConverterTest, TestFieldTrialEnabled) {
+  struct {
+    const char* url;
+    bool expected_result;
+    const char* expected_amp_url;
+  } tests[] = {
+      {"", false},
+      {"http://www.test.com", false},
+      {"http://test.com", true, "http://test.com/"},
+      {"http://test2.com", false},
+      {"https://test.com", true, "https://test.com/"},
+      {"http://test.com/index.html", true, "http://test.com/index.html"},
+
+      // Case sensitive tests.
+      {"http://Test.com", true, "http://test.com/"},
+      {"http://TEST.com/Index.html", true, "http://test.com/Index.html"},
+  };
+
+  CreateAMPRedirectionFieldTrialWithParams(
+      {{"config", "[{\"host\":\"test.com\", \"pattern\":\".*\"}]"}});
+  Initialize();
+
+  for (const auto& test : tests) {
+    GURL amp_url;
+    EXPECT_EQ(test.expected_result,
+              amp_converter()->GetAMPURL(GURL(test.url), &amp_url))
+        << test.url;
+    if (test.expected_amp_url)
+      EXPECT_EQ(test.expected_amp_url, amp_url.spec());
+  }
+}
+
+TEST_F(PreviewsAMPConverterTest, TestMultipleConversions) {
+  CreateAMPRedirectionFieldTrialWithParams(
+      {{"config",
+        "[{\"host\":\"test.com\", \"pattern\":\".*\", "
+        "\"hostamp\":\"amp.test.com\"},"
+        "{\"host\":\"testprefix.com\", \"pattern\":\".*\", "
+        "\"prefix\":\"/amp\"},"
+        "{\"host\":\"testsuffix.com\", \"pattern\":\".*\", "
+        "\"suffix\":\".amp\"},"
+        "{\"host\":\"testsuffixhtml.com\", \"pattern\":\".*\", "
+        "\"suffixhtml\":\".amp\"},"
+        "{\"host\":\"prefixandsuffix.com\", \"pattern\":\".*\", "
+        "\"prefix\":\"/pre\", \"suffix\":\".suf\"}]"}});
+  Initialize();
+
+  struct {
+    const char* url;
+    bool expected_result;
+    const char* expected_amp_url;
+  } tests[] = {
+      {"", false},
+      {"http://www.test.com", false},
+      {"http://test.com", true, "http://amp.test.com/"},
+      {"https://test.com", true, "https://amp.test.com/"},
+      {"http://test.com/index.html?id=foo#anchor", true,
+       "http://amp.test.com/index.html?id=foo#anchor"},
+      {"http://testprefix.com/index.html?id=foo#anchor", true,
+       "http://testprefix.com/amp/index.html?id=foo#anchor"},
+      {"http://testprefix.com", true, "http://testprefix.com/amp/"},
+      {"http://testsuffix.com/index.html?id=foo#anchor", true,
+       "http://testsuffix.com/index.html.amp?id=foo#anchor"},
+      {"http://testsuffixhtml.com/index.html?id=foo#anchor", true,
+       "http://testsuffixhtml.com/index.amp.html?id=foo#anchor"},
+      {"http://prefixandsuffix.com/index.html?id=foo#anchor", true,
+       "http://prefixandsuffix.com/pre/index.html."
+       "suf?id=foo#anchor"},
+  };
+
+  for (const auto& test : tests) {
+    GURL amp_url;
+    EXPECT_EQ(test.expected_result,
+              amp_converter()->GetAMPURL(GURL(test.url), &amp_url))
+        << test.url;
+    if (test.expected_amp_url)
+      EXPECT_EQ(test.expected_amp_url, amp_url.spec());
+  }
+}
+
+TEST_F(PreviewsAMPConverterTest, TestPathPatterns) {
+  CreateAMPRedirectionFieldTrialWithParams(
+      {{"config",
+        "[{\"host\":\"test1.com\", \"pattern\":\"/foo/bar/.+\"},"
+        "{\"host\":\"test2.com\", \"pattern\":\"/(foo|bar)/.*.html$\"},"
+        "{\"host\":\"test3.com\", "
+        "\"pattern\":\"/[0-9]{4}/[0-9]{2}/[0-9]{2}/.*.html$\"}]"}});
+  Initialize();
+
+  struct {
+    const char* url;
+    bool expected_result;
+    const char* expected_amp_url;
+  } tests[] = {
+      {"http://test1.com", false},
+      {"http://test1.com/foo/bar", false},
+      {"http://test1.com/foo/bar/", false},
+      {"http://test1.com/foo/bar/baz", true, "http://test1.com/foo/bar/baz"},
+      {"http://test2.com/foo/index.html", true,
+       "http://test2.com/foo/index.html"},
+      {"http://test2.com/bar/b.html", true, "http://test2.com/bar/b.html"},
+      {"http://test2.com/baz/b.html", false},
+      {"http://test3.com/2017/01/02/index.html", true,
+       "http://test3.com/2017/01/02/index.html"}};
+
+  for (const auto& test : tests) {
+    GURL amp_url;
+    EXPECT_EQ(test.expected_result,
+              amp_converter()->GetAMPURL(GURL(test.url), &amp_url))
+        << test.url;
+    if (test.expected_amp_url)
+      EXPECT_EQ(test.expected_amp_url, amp_url.spec());
+  }
+}
+
+TEST_F(PreviewsAMPConverterTest, TestURLScheme) {
+  CreateAMPRedirectionFieldTrialWithParams(
+      {{"config",
+        "[{\"host\":\"test_http.com\", \"scheme\":\"http\", "
+        "\"pattern\":\".*\"},"
+        "{\"host\":\"test_https.com\", \"scheme\":\"https\", "
+        "\"pattern\":\".*\"},"
+        "{\"host\":\"test_both.com\", \"pattern\":\".*\"},"
+        "{\"host\":\"test_amp_http.com\", \"scheme\":\"http\", "
+        "\"pattern\":\".*\", \"schemeamp\":\"http\"},"
+        "{\"host\":\"test_amp_https.com\", \"pattern\":\".*\", "
+        "\"schemeamp\":\"https\"},"
+        "{\"host\":\"test_amp_invalid.com\", "
+        "\"pattern\":\".*\", \"schemeamp\":\"invalid\"}]"}});
+  Initialize();
+
+  struct {
+    const char* url;
+    bool expected_result;
+    const char* expected_amp_url;
+  } tests[] = {
+      {"http://test_http.com", true, "http://test_http.com/"},
+      {"https://test_http.com", false},
+      {"http://test_https.com", false},
+      {"https://test_https.com", true, "https://test_https.com/"},
+      {"http://test_both.com", true, "http://test_both.com/"},
+      {"https://test_both.com", true, "https://test_both.com/"},
+      {"http://test_amp_http.com", true, "http://test_amp_http.com/"},
+      {"https://test_amp_http.com", false, /* Should not redirect to http */},
+      {"http://test_amp_https.com", true, "https://test_amp_https.com/"},
+      {"https://test_amp_https.com", true, "https://test_amp_https.com/"},
+      {"https://test_amp_invalid.com", false},
+      {"http://test_amp_invalid.com", false},
+  };
+
+  for (const auto& test : tests) {
+    GURL amp_url;
+    EXPECT_EQ(test.expected_result,
+              amp_converter()->GetAMPURL(GURL(test.url), &amp_url))
+        << test.url;
+    if (test.expected_amp_url)
+      EXPECT_EQ(test.expected_amp_url, amp_url.spec());
+  }
+}
+
+TEST_F(PreviewsAMPConverterTest, TestFullRegex) {
+  CreateAMPRedirectionFieldTrialWithParams(
+      {{"config",
+        "[{\"host\":\"www.test1.com\", \"scheme\":\"http\", "
+        "\"pattern\":\"^/201[67]/[0-9]{2}/[0-9]{2}/.*/index.html$\", "
+        "\"schemeamp\":\"https\", \"hostamp\":\"www.amp.test1.com\", "
+        "\"prefix\":\"/foo\"},"
+        "{\"host\":\"www.test2.com\", \"scheme\":\"http\", "
+        "\"pattern\":\"^/.*/201[67]/[0-9]{2}/[0-9]{2}/.*[.]html$\", "
+        "\"suffixhtml\":\".amp\"},"
+        "{\"host\":\"m.test3.com\", \"pattern\":\"^/foo/entry/bar_.*/$\", "
+        "\"suffix\":\"post\"}]"}});
+  Initialize();
+
+  struct {
+    const char* url;
+    bool expected_result;
+    const char* expected_amp_url;
+  } tests[] = {
+      {"http://www.test1.com", false},
+      {"http://www.test1.com/2017/09/05/foo-bar/index.html", true,
+       "https://www.amp.test1.com/foo/2017/09/05/foo-bar/index.html"},
+      {"http://www.test1.com/2016/01/12/baz-foo/index.html", true,
+       "https://www.amp.test1.com/foo/2016/01/12/baz-foo/index.html"},
+      {"http://www.test2.com", false},
+      {"http://www.test2.com/foo/2017/09/05/foo-bar/index.html", true,
+       "http://www.test2.com/foo/2017/09/05/foo-bar/index.amp.html"},
+      {"http://www.test2.com/bar/2016/04/23/foo-bar/index.html", true,
+       "http://www.test2.com/bar/2016/04/23/foo-bar/index.amp.html"},
+      {"http://m.test3.com/foo/entry/bar_baz/", true,
+       "http://m.test3.com/foo/entry/bar_baz/post"},
+  };
+
+  for (const auto& test : tests) {
+    GURL amp_url;
+    EXPECT_EQ(test.expected_result,
+              amp_converter()->GetAMPURL(GURL(test.url), &amp_url))
+        << test.url;
+    if (test.expected_amp_url)
+      EXPECT_EQ(test.expected_amp_url, amp_url.spec());
+  }
+}
+
+}  // namespace
+
+}  // namespace previews
diff --git a/components/update_client/BUILD.gn b/components/update_client/BUILD.gn
index 23ac41f..d33cc6c 100644
--- a/components/update_client/BUILD.gn
+++ b/components/update_client/BUILD.gn
@@ -9,6 +9,7 @@
     "action_runner.cc",
     "action_runner.h",
     "action_runner_win.cc",
+    "activity_data_service.h",
     "background_downloader_win.cc",
     "background_downloader_win.h",
     "component.cc",
diff --git a/components/update_client/activity_data_service.h b/components/update_client/activity_data_service.h
new file mode 100644
index 0000000..5d3744cb
--- /dev/null
+++ b/components/update_client/activity_data_service.h
@@ -0,0 +1,42 @@
+// Copyright 2017 The Chromium Authors. All rights reserved.
+// Use of this source code is governed by a BSD-style license that can be
+// found in the LICENSE file.
+
+#ifndef COMPONENTS_UPDATE_CLIENT_ACTIVITY_DATA_SERVICE_H_
+#define COMPONENTS_UPDATE_CLIENT_ACTIVITY_DATA_SERVICE_H_
+
+#include <memory>
+#include <string>
+
+#include "base/macros.h"
+
+namespace update_client {
+
+const int kDateFirstTime = -1;
+const int kDaysFirstTime = -1;
+const int kDateUnknown = -2;
+const int kDaysUnknown = -2;
+
+// This is an interface that injects certain update information (active, days
+// since ...) into the update engine of the update client.
+// GetDaysSinceLastActive and GetDaysSinceLastRollCall are used for backward
+// compatibility.
+class ActivityDataService {
+ public:
+  // Returns the current state of the active bit of the specified |id|.
+  virtual bool GetActiveBit(const std::string& id) const = 0;
+
+  // Clears the active bit of the specified |id|.
+  virtual void ClearActiveBit(const std::string& id) = 0;
+
+  // The following 2 functions return the number of days since last
+  // active/roll call.
+  virtual int GetDaysSinceLastActive(const std::string& id) const = 0;
+  virtual int GetDaysSinceLastRollCall(const std::string& id) const = 0;
+
+  virtual ~ActivityDataService() {}
+};
+
+}  // namespace update_client
+
+#endif  // COMPONENTS_UPDATE_CLIENT_ACTIVITY_DATA_SERVICE_H_
diff --git a/components/update_client/configurator.h b/components/update_client/configurator.h
index 44a2d04..99ebcbc1 100644
--- a/components/update_client/configurator.h
+++ b/components/update_client/configurator.h
@@ -24,6 +24,7 @@
 
 namespace update_client {
 
+class ActivityDataService;
 class OutOfProcessPatcher;
 
 // Controls the component updater behavior.
@@ -123,6 +124,16 @@
   // persistent storage.
   virtual PrefService* GetPrefService() const = 0;
 
+  // Returns an ActivityDataService that the update_client can use to access
+  // to update information (namely active bit, last active/rollcall days)
+  // normally stored in the user extension profile.
+  // Similar to PrefService, ActivityDataService must outlive the entire
+  // update_client, and be safe to access from the thread the update_client
+  // is constructed on.
+  // Returning null is safe and will disable any functionality that requires
+  // accessing to the information provided by ActivityDataService.
+  virtual ActivityDataService* GetActivityDataService() const = 0;
+
   // Returns true if the Chrome is installed for the current user only, or false
   // if Chrome is installed for all users on the machine. This function must be
   // called only from a blocking pool thread, as it may access the file system.
diff --git a/components/update_client/persisted_data.cc b/components/update_client/persisted_data.cc
index 4f2c34a..ea1ad1e 100644
--- a/components/update_client/persisted_data.cc
+++ b/components/update_client/persisted_data.cc
@@ -15,14 +15,16 @@
 #include "components/prefs/pref_registry_simple.h"
 #include "components/prefs/pref_service.h"
 #include "components/prefs/scoped_user_pref_update.h"
+#include "components/update_client/activity_data_service.h"
 
 const char kPersistedDataPreference[] = "updateclientdata";
-const int kDateLastRollCallUnknown = -2;
 
 namespace update_client {
 
-PersistedData::PersistedData(PrefService* pref_service)
-    : pref_service_(pref_service) {}
+PersistedData::PersistedData(PrefService* pref_service,
+                             ActivityDataService* activity_data_service)
+    : pref_service_(pref_service),
+      activity_data_service_(activity_data_service) {}
 
 PersistedData::~PersistedData() {
   DCHECK(thread_checker_.CalledOnValidThread());
@@ -66,7 +68,11 @@
 }
 
 int PersistedData::GetDateLastRollCall(const std::string& id) const {
-  return GetInt(id, "dlrc", kDateLastRollCallUnknown);
+  return GetInt(id, "dlrc", kDateUnknown);
+}
+
+int PersistedData::GetDateLastActive(const std::string& id) const {
+  return GetInt(id, "dla", kDateUnknown);
 }
 
 std::string PersistedData::GetPingFreshness(const std::string& id) const {
@@ -92,7 +98,7 @@
   if (!pref_service_ || datenum < 0)
     return;
   DictionaryPrefUpdate update(pref_service_, kPersistedDataPreference);
-  for (auto id : ids) {
+  for (const auto& id : ids) {
     // We assume ids do not contain '.' characters.
     DCHECK_EQ(std::string::npos, id.find('.'));
     update->SetInteger(base::StringPrintf("apps.%s.dlrc", id.c_str()), datenum);
@@ -101,6 +107,23 @@
   }
 }
 
+void PersistedData::SetDateLastActive(const std::vector<std::string>& ids,
+                                      int datenum) {
+  DCHECK(thread_checker_.CalledOnValidThread());
+  if (!pref_service_ || datenum < 0)
+    return;
+  DictionaryPrefUpdate update(pref_service_, kPersistedDataPreference);
+  for (const auto& id : ids) {
+    if (GetActiveBit(id)) {
+      // We assume ids do not contain '.' characters.
+      DCHECK_EQ(std::string::npos, id.find('.'));
+      update->SetInteger(base::StringPrintf("apps.%s.dla", id.c_str()),
+                         datenum);
+      activity_data_service_->ClearActiveBit(id);
+    }
+  }
+}
+
 void PersistedData::SetString(const std::string& id,
                               const std::string& key,
                               const std::string& value) {
@@ -127,6 +150,24 @@
   SetString(id, "cohorthint", cohort_hint);
 }
 
+bool PersistedData::GetActiveBit(const std::string& id) const {
+  return activity_data_service_ && activity_data_service_->GetActiveBit(id);
+}
+
+int PersistedData::GetDaysSinceLastRollCall(const std::string& id) const {
+  DCHECK(thread_checker_.CalledOnValidThread());
+  return activity_data_service_
+             ? activity_data_service_->GetDaysSinceLastRollCall(id)
+             : kDaysUnknown;
+}
+
+int PersistedData::GetDaysSinceLastActive(const std::string& id) const {
+  DCHECK(thread_checker_.CalledOnValidThread());
+  return activity_data_service_
+             ? activity_data_service_->GetDaysSinceLastActive(id)
+             : kDaysUnknown;
+}
+
 void PersistedData::RegisterPrefs(PrefRegistrySimple* registry) {
   registry->RegisterDictionaryPref(kPersistedDataPreference);
 }
diff --git a/components/update_client/persisted_data.h b/components/update_client/persisted_data.h
index 06d4d0d2..d35bd150 100644
--- a/components/update_client/persisted_data.h
+++ b/components/update_client/persisted_data.h
@@ -17,6 +17,8 @@
 
 namespace update_client {
 
+class ActivityDataService;
+
 // A PersistedData is a wrapper layer around a PrefService, designed to maintain
 // update data that outlives the browser process and isn't exposed outside of
 // update_client.
@@ -26,10 +28,13 @@
 // initialized on.
 class PersistedData {
  public:
-  // Constructs a provider that uses the specified |pref_service|.
+  // Constructs a provider using the specified |pref_service| and
+  // |activity_data_service|.
   // The associated preferences are assumed to already be registered.
-  // The |pref_service| must outlive the entire update_client.
-  explicit PersistedData(PrefService* pref_service);
+  // The |pref_service| and |activity_data_service| must outlive the entire
+  // update_client.
+  PersistedData(PrefService* pref_service,
+                ActivityDataService* activity_data_service);
 
   ~PersistedData();
 
@@ -38,6 +43,13 @@
   // -2 indicates that there is no recorded date number for the |id|.
   int GetDateLastRollCall(const std::string& id) const;
 
+  // Returns the DateLastActive (the server-localized calendar date number the
+  // |id| was last active by this client on) for the specified |id|.
+  // -1 indicates that there is no recorded date for the |id| (i.e. this is the
+  // first time the |id| is active).
+  // -2 indicates that the |id| has an unknown value of last active date.
+  int GetDateLastActive(const std::string& id) const;
+
   // Returns the PingFreshness (a random token that is written into the profile
   // data whenever the DateLastRollCall it is modified) for the specified |id|.
   // "" indicates that there is no recorded freshness value for the |id|.
@@ -49,6 +61,15 @@
   // has been fully initialized are ignored. Also sets the PingFreshness.
   void SetDateLastRollCall(const std::vector<std::string>& ids, int datenum);
 
+  // Records the DateLastActive for the specified |ids|. |datenum| must be a
+  // non-negative integer: calls with a negative |datenum| are simply ignored.
+  // Calls to SetDateLastActive that occur prior to the persisted data store
+  // has been fully initialized or the active bit of the |ids| are not set
+  // are ignored.
+  // This function also clears the active bits of the specified |ids| if they
+  // are set.
+  void SetDateLastActive(const std::vector<std::string>& ids, int datenum);
+
   // This is called only via update_client's RegisterUpdateClientPreferences.
   static void RegisterPrefs(PrefRegistrySimple* registry);
 
@@ -66,6 +87,18 @@
   void SetCohortHint(const std::string& id, const std::string& cohort_hint);
   void SetCohortName(const std::string& id, const std::string& cohort_name);
 
+  // Returns true if the active bit of the specified |id| is set.
+  bool GetActiveBit(const std::string& id) const;
+
+  // The following two functions returns the number of days since the last
+  // time the client checked for update/was active.
+  // -1 indicates that this is the first time the client reports
+  // an update check/active for the specified |id|.
+  // -2 indicates that the client has no information about the
+  // update check/last active of the specified |id|.
+  int GetDaysSinceLastRollCall(const std::string& id) const;
+  int GetDaysSinceLastActive(const std::string& id) const;
+
  private:
   int GetInt(const std::string& id, const std::string& key, int fallback) const;
   std::string GetString(const std::string& id, const std::string& key) const;
@@ -75,6 +108,7 @@
 
   base::ThreadChecker thread_checker_;
   PrefService* pref_service_;
+  ActivityDataService* activity_data_service_;
 
   DISALLOW_COPY_AND_ASSIGN(PersistedData);
 };
diff --git a/components/update_client/persisted_data_unittest.cc b/components/update_client/persisted_data_unittest.cc
index cc5f875..7f7ae6e 100644
--- a/components/update_client/persisted_data_unittest.cc
+++ b/components/update_client/persisted_data_unittest.cc
@@ -2,32 +2,50 @@
 // Use of this source code is governed by a BSD-style license that can be
 // found in the LICENSE file.
 
+#include <map>
 #include <memory>
 #include <string>
 #include <vector>
 
 #include "components/prefs/testing_pref_service.h"
+#include "components/update_client/activity_data_service.h"
 #include "components/update_client/persisted_data.h"
 #include "testing/gtest/include/gtest/gtest.h"
 
 namespace update_client {
 
 TEST(PersistedDataTest, Simple) {
-  std::unique_ptr<TestingPrefServiceSimple> pref(
-      new TestingPrefServiceSimple());
+  auto pref = std::make_unique<TestingPrefServiceSimple>();
   PersistedData::RegisterPrefs(pref->registry());
-  std::unique_ptr<PersistedData> metadata(new PersistedData(pref.get()));
+  auto metadata = std::make_unique<PersistedData>(pref.get(), nullptr);
   EXPECT_EQ(-2, metadata->GetDateLastRollCall("someappid"));
+  EXPECT_EQ(-2, metadata->GetDateLastActive("someappid"));
+  EXPECT_EQ(-2, metadata->GetDaysSinceLastRollCall("someappid"));
+  EXPECT_EQ(-2, metadata->GetDaysSinceLastActive("someappid"));
   std::vector<std::string> items;
   items.push_back("someappid");
   metadata->SetDateLastRollCall(items, 3383);
+  metadata->SetDateLastActive(items, 3383);
   EXPECT_EQ(3383, metadata->GetDateLastRollCall("someappid"));
+  EXPECT_EQ(-2, metadata->GetDateLastActive("someappid"));
+  EXPECT_EQ(-2, metadata->GetDaysSinceLastRollCall("someappid"));
+  EXPECT_EQ(-2, metadata->GetDaysSinceLastActive("someappid"));
   EXPECT_EQ(-2, metadata->GetDateLastRollCall("someotherappid"));
+  EXPECT_EQ(-2, metadata->GetDateLastActive("someotherappid"));
+  EXPECT_EQ(-2, metadata->GetDaysSinceLastRollCall("someotherappid"));
+  EXPECT_EQ(-2, metadata->GetDaysSinceLastActive("someotherappid"));
   const std::string pf1 = metadata->GetPingFreshness("someappid");
   EXPECT_FALSE(pf1.empty());
   metadata->SetDateLastRollCall(items, 3386);
+  metadata->SetDateLastActive(items, 3386);
   EXPECT_EQ(3386, metadata->GetDateLastRollCall("someappid"));
+  EXPECT_EQ(-2, metadata->GetDateLastActive("someappid"));
+  EXPECT_EQ(-2, metadata->GetDaysSinceLastRollCall("someappid"));
+  EXPECT_EQ(-2, metadata->GetDaysSinceLastActive("someappid"));
   EXPECT_EQ(-2, metadata->GetDateLastRollCall("someotherappid"));
+  EXPECT_EQ(-2, metadata->GetDateLastActive("someotherappid"));
+  EXPECT_EQ(-2, metadata->GetDaysSinceLastRollCall("someotherappid"));
+  EXPECT_EQ(-2, metadata->GetDaysSinceLastActive("someotherappid"));
   const std::string pf2 = metadata->GetPingFreshness("someappid");
   EXPECT_FALSE(pf2.empty());
   // The following has a 1 / 2^128 chance of being flaky.
@@ -35,27 +53,35 @@
 }
 
 TEST(PersistedDataTest, SharedPref) {
-  std::unique_ptr<TestingPrefServiceSimple> pref(
-      new TestingPrefServiceSimple());
+  auto pref = std::make_unique<TestingPrefServiceSimple>();
   PersistedData::RegisterPrefs(pref->registry());
-  std::unique_ptr<PersistedData> metadata(new PersistedData(pref.get()));
+  auto metadata = std::make_unique<PersistedData>(pref.get(), nullptr);
   EXPECT_EQ(-2, metadata->GetDateLastRollCall("someappid"));
+  EXPECT_EQ(-2, metadata->GetDateLastActive("someappid"));
+  EXPECT_EQ(-2, metadata->GetDaysSinceLastRollCall("someappid"));
+  EXPECT_EQ(-2, metadata->GetDaysSinceLastActive("someappid"));
   std::vector<std::string> items;
   items.push_back("someappid");
   metadata->SetDateLastRollCall(items, 3383);
+  metadata->SetDateLastActive(items, 3383);
 
   // Now, create a new PersistedData reading from the same path, verify
   // that it loads the value.
-  metadata.reset(new PersistedData(pref.get()));
+  metadata = std::make_unique<PersistedData>(pref.get(), nullptr);
   EXPECT_EQ(3383, metadata->GetDateLastRollCall("someappid"));
+  EXPECT_EQ(-2, metadata->GetDateLastActive("someappid"));
+  EXPECT_EQ(-2, metadata->GetDaysSinceLastRollCall("someappid"));
+  EXPECT_EQ(-2, metadata->GetDaysSinceLastActive("someappid"));
   EXPECT_EQ(-2, metadata->GetDateLastRollCall("someotherappid"));
+  EXPECT_EQ(-2, metadata->GetDateLastActive("someotherappid"));
+  EXPECT_EQ(-2, metadata->GetDaysSinceLastRollCall("someotherappid"));
+  EXPECT_EQ(-2, metadata->GetDaysSinceLastActive("someotherappid"));
 }
 
 TEST(PersistedDataTest, SimpleCohort) {
-  std::unique_ptr<TestingPrefServiceSimple> pref(
-      new TestingPrefServiceSimple());
+  auto pref = std::make_unique<TestingPrefServiceSimple>();
   PersistedData::RegisterPrefs(pref->registry());
-  std::unique_ptr<PersistedData> metadata(new PersistedData(pref.get()));
+  auto metadata = std::make_unique<PersistedData>(pref.get(), nullptr);
   EXPECT_EQ("", metadata->GetCohort("someappid"));
   EXPECT_EQ("", metadata->GetCohort("someotherappid"));
   EXPECT_EQ("", metadata->GetCohortHint("someappid"));
@@ -88,4 +114,137 @@
   EXPECT_EQ("ocn2", metadata->GetCohortName("someotherappid"));
 }
 
+TEST(PersistedDataTest, ActivityData) {
+  class TestActivityDataService : public ActivityDataService {
+   public:
+    bool GetActiveBit(const std::string& id) const override {
+      auto it = active_.find(id);
+      return it != active_.end() ? it->second : false;
+    }
+
+    int GetDaysSinceLastActive(const std::string& id) const override {
+      auto it = days_last_active_.find(id);
+      return it != days_last_active_.end() ? it->second : -1;
+    }
+
+    int GetDaysSinceLastRollCall(const std::string& id) const override {
+      auto it = days_last_roll_call_.find(id);
+      return it != days_last_roll_call_.end() ? it->second : -1;
+    }
+
+    void ClearActiveBit(const std::string& id) override { active_[id] = false; }
+
+    void SetDaysSinceLastActive(const std::string& id, int numdays) {
+      days_last_active_[id] = numdays;
+    }
+
+    void SetDaysSinceLastRollCall(const std::string& id, int numdays) {
+      days_last_roll_call_[id] = numdays;
+    }
+
+    void SetActiveBit(const std::string& id) { active_[id] = true; }
+
+   private:
+    std::map<std::string, bool> active_;
+    std::map<std::string, int> days_last_active_;
+    std::map<std::string, int> days_last_roll_call_;
+  };
+
+  auto pref = std::make_unique<TestingPrefServiceSimple>();
+  auto activity_service = std::make_unique<TestActivityDataService>();
+  PersistedData::RegisterPrefs(pref->registry());
+  auto metadata =
+      std::make_unique<PersistedData>(pref.get(), activity_service.get());
+
+  std::vector<std::string> items({"id1", "id2", "id3"});
+
+  for (const auto& item : items) {
+    EXPECT_EQ(-2, metadata->GetDateLastActive(item));
+    EXPECT_EQ(-2, metadata->GetDateLastRollCall(item));
+    EXPECT_EQ(-1, metadata->GetDaysSinceLastActive(item));
+    EXPECT_EQ(-1, metadata->GetDaysSinceLastRollCall(item));
+    EXPECT_EQ(false, metadata->GetActiveBit(item));
+  }
+
+  metadata->SetDateLastActive(items, 1234);
+  metadata->SetDateLastRollCall(items, 1234);
+  for (const auto& item : items) {
+    EXPECT_EQ(false, metadata->GetActiveBit(item));
+    EXPECT_EQ(-2, metadata->GetDateLastActive(item));
+    EXPECT_EQ(1234, metadata->GetDateLastRollCall(item));
+    EXPECT_EQ(-1, metadata->GetDaysSinceLastActive(item));
+    EXPECT_EQ(-1, metadata->GetDaysSinceLastRollCall(item));
+  }
+
+  activity_service->SetActiveBit("id1");
+  activity_service->SetDaysSinceLastActive("id1", 3);
+  activity_service->SetDaysSinceLastRollCall("id1", 2);
+  activity_service->SetDaysSinceLastRollCall("id2", 3);
+  activity_service->SetDaysSinceLastRollCall("id3", 4);
+  EXPECT_EQ(true, metadata->GetActiveBit("id1"));
+  EXPECT_EQ(false, metadata->GetActiveBit("id2"));
+  EXPECT_EQ(false, metadata->GetActiveBit("id2"));
+  EXPECT_EQ(3, metadata->GetDaysSinceLastActive("id1"));
+  EXPECT_EQ(-1, metadata->GetDaysSinceLastActive("id2"));
+  EXPECT_EQ(-1, metadata->GetDaysSinceLastActive("id3"));
+  EXPECT_EQ(2, metadata->GetDaysSinceLastRollCall("id1"));
+  EXPECT_EQ(3, metadata->GetDaysSinceLastRollCall("id2"));
+  EXPECT_EQ(4, metadata->GetDaysSinceLastRollCall("id3"));
+
+  metadata->SetDateLastActive(items, 3384);
+  metadata->SetDateLastRollCall(items, 3383);
+  EXPECT_EQ(false, metadata->GetActiveBit("id1"));
+  EXPECT_EQ(false, metadata->GetActiveBit("id2"));
+  EXPECT_EQ(false, metadata->GetActiveBit("id3"));
+  EXPECT_EQ(3, metadata->GetDaysSinceLastActive("id1"));
+  EXPECT_EQ(-1, metadata->GetDaysSinceLastActive("id2"));
+  EXPECT_EQ(-1, metadata->GetDaysSinceLastActive("id3"));
+  EXPECT_EQ(2, metadata->GetDaysSinceLastRollCall("id1"));
+  EXPECT_EQ(3, metadata->GetDaysSinceLastRollCall("id2"));
+  EXPECT_EQ(4, metadata->GetDaysSinceLastRollCall("id3"));
+  EXPECT_EQ(3384, metadata->GetDateLastActive("id1"));
+  EXPECT_EQ(-2, metadata->GetDateLastActive("id2"));
+  EXPECT_EQ(-2, metadata->GetDateLastActive("id3"));
+  EXPECT_EQ(3383, metadata->GetDateLastRollCall("id1"));
+  EXPECT_EQ(3383, metadata->GetDateLastRollCall("id2"));
+  EXPECT_EQ(3383, metadata->GetDateLastRollCall("id3"));
+
+  metadata->SetDateLastActive(items, 5000);
+  metadata->SetDateLastRollCall(items, 3390);
+  EXPECT_EQ(false, metadata->GetActiveBit("id1"));
+  EXPECT_EQ(false, metadata->GetActiveBit("id2"));
+  EXPECT_EQ(false, metadata->GetActiveBit("id3"));
+  EXPECT_EQ(3, metadata->GetDaysSinceLastActive("id1"));
+  EXPECT_EQ(-1, metadata->GetDaysSinceLastActive("id2"));
+  EXPECT_EQ(-1, metadata->GetDaysSinceLastActive("id3"));
+  EXPECT_EQ(2, metadata->GetDaysSinceLastRollCall("id1"));
+  EXPECT_EQ(3, metadata->GetDaysSinceLastRollCall("id2"));
+  EXPECT_EQ(4, metadata->GetDaysSinceLastRollCall("id3"));
+  EXPECT_EQ(3384, metadata->GetDateLastActive("id1"));
+  EXPECT_EQ(-2, metadata->GetDateLastActive("id2"));
+  EXPECT_EQ(-2, metadata->GetDateLastActive("id3"));
+  EXPECT_EQ(3390, metadata->GetDateLastRollCall("id1"));
+  EXPECT_EQ(3390, metadata->GetDateLastRollCall("id2"));
+  EXPECT_EQ(3390, metadata->GetDateLastRollCall("id3"));
+
+  activity_service->SetActiveBit("id2");
+  metadata->SetDateLastActive(items, 5678);
+  metadata->SetDateLastRollCall(items, 6789);
+  EXPECT_EQ(false, metadata->GetActiveBit("id1"));
+  EXPECT_EQ(false, metadata->GetActiveBit("id2"));
+  EXPECT_EQ(false, metadata->GetActiveBit("id3"));
+  EXPECT_EQ(3, metadata->GetDaysSinceLastActive("id1"));
+  EXPECT_EQ(-1, metadata->GetDaysSinceLastActive("id2"));
+  EXPECT_EQ(-1, metadata->GetDaysSinceLastActive("id3"));
+  EXPECT_EQ(2, metadata->GetDaysSinceLastRollCall("id1"));
+  EXPECT_EQ(3, metadata->GetDaysSinceLastRollCall("id2"));
+  EXPECT_EQ(4, metadata->GetDaysSinceLastRollCall("id3"));
+  EXPECT_EQ(3384, metadata->GetDateLastActive("id1"));
+  EXPECT_EQ(5678, metadata->GetDateLastActive("id2"));
+  EXPECT_EQ(-2, metadata->GetDateLastActive("id3"));
+  EXPECT_EQ(6789, metadata->GetDateLastRollCall("id1"));
+  EXPECT_EQ(6789, metadata->GetDateLastRollCall("id2"));
+  EXPECT_EQ(6789, metadata->GetDateLastRollCall("id3"));
+}
+
 }  // namespace update_client
diff --git a/components/update_client/test_configurator.cc b/components/update_client/test_configurator.cc
index a61c093..4dd09d0 100644
--- a/components/update_client/test_configurator.cc
+++ b/components/update_client/test_configurator.cc
@@ -9,6 +9,7 @@
 #include "base/threading/thread_task_runner_handle.h"
 #include "base/version.h"
 #include "components/prefs/pref_service.h"
+#include "components/update_client/activity_data_service.h"
 #include "components/update_client/out_of_process_patcher.h"
 #include "net/url_request/url_request_test_util.h"
 #include "url/gurl.h"
@@ -164,6 +165,10 @@
   return nullptr;
 }
 
+ActivityDataService* TestConfigurator::GetActivityDataService() const {
+  return nullptr;
+}
+
 bool TestConfigurator::IsPerUserInstall() const {
   return true;
 }
diff --git a/components/update_client/test_configurator.h b/components/update_client/test_configurator.h
index 01a9674..83686f44 100644
--- a/components/update_client/test_configurator.h
+++ b/components/update_client/test_configurator.h
@@ -25,6 +25,8 @@
 
 namespace update_client {
 
+class ActivityDataService;
+
 #define POST_INTERCEPT_SCHEME "https"
 #define POST_INTERCEPT_HOSTNAME "localhost2"
 #define POST_INTERCEPT_PATH "/update2"
@@ -80,6 +82,7 @@
   bool EnabledBackgroundDownloader() const override;
   bool EnabledCupSigning() const override;
   PrefService* GetPrefService() const override;
+  ActivityDataService* GetActivityDataService() const override;
   bool IsPerUserInstall() const override;
   std::vector<uint8_t> GetRunActionKeyHash() const override;
 
diff --git a/components/update_client/update_checker_unittest.cc b/components/update_client/update_checker_unittest.cc
index 70c667fc..439321bf 100644
--- a/components/update_client/update_checker_unittest.cc
+++ b/components/update_client/update_checker_unittest.cc
@@ -101,7 +101,7 @@
   config_ = base::MakeRefCounted<TestConfigurator>();
   pref_ = base::MakeUnique<TestingPrefServiceSimple>();
   PersistedData::RegisterPrefs(pref_->registry());
-  metadata_ = base::MakeUnique<PersistedData>(pref_.get());
+  metadata_ = base::MakeUnique<PersistedData>(pref_.get(), nullptr);
   interceptor_factory_ =
       base::MakeUnique<InterceptorFactory>(base::ThreadTaskRunnerHandle::Get());
   post_interceptor_ = interceptor_factory_->CreateInterceptor();
diff --git a/components/update_client/update_client_unittest.cc b/components/update_client/update_client_unittest.cc
index 05b872f..549280c 100644
--- a/components/update_client/update_client_unittest.cc
+++ b/components/update_client/update_client_unittest.cc
@@ -187,7 +187,7 @@
 
 UpdateClientTest::UpdateClientTest() {
   PersistedData::RegisterPrefs(pref_->registry());
-  metadata_ = base::MakeUnique<PersistedData>(pref_.get());
+  metadata_ = base::MakeUnique<PersistedData>(pref_.get(), nullptr);
 }
 
 UpdateClientTest::~UpdateClientTest() {
diff --git a/components/update_client/update_engine.cc b/components/update_client/update_engine.cc
index cf22810..664e74e 100644
--- a/components/update_client/update_engine.cc
+++ b/components/update_client/update_engine.cc
@@ -4,6 +4,7 @@
 
 #include "components/update_client/update_engine.h"
 
+#include <memory>
 #include <utility>
 
 #include "base/bind.h"
@@ -57,7 +58,9 @@
       update_checker_factory_(update_checker_factory),
       crx_downloader_factory_(crx_downloader_factory),
       ping_manager_(ping_manager),
-      metadata_(new PersistedData(config->GetPrefService())),
+      metadata_(
+          std::make_unique<PersistedData>(config->GetPrefService(),
+                                          config->GetActivityDataService())),
       notify_observers_callback_(notify_observers_callback) {}
 
 UpdateEngine::~UpdateEngine() {
diff --git a/components/viz/service/display/gl_renderer_unittest.cc b/components/viz/service/display/gl_renderer_unittest.cc
index a2851af..429a08d 100644
--- a/components/viz/service/display/gl_renderer_unittest.cc
+++ b/components/viz/service/display/gl_renderer_unittest.cc
@@ -1919,12 +1919,6 @@
                      bool lost_resource,
                      cc::BlockingTaskRunner* main_thread_task_runner) {}
 
-static void CollectResources(std::vector<ReturnedResource>* array,
-                             const std::vector<ReturnedResource>& returned,
-                             cc::BlockingTaskRunner* main_thread_task_runner) {
-  array->insert(array->end(), returned.begin(), returned.end());
-}
-
 TEST_F(GLRendererTest, DontOverlayWithCopyRequests) {
   cc::FakeOutputSurfaceClient output_surface_client;
   std::unique_ptr<cc::FakeOutputSurface> output_surface(
@@ -1933,42 +1927,15 @@
 
   std::unique_ptr<SharedBitmapManager> shared_bitmap_manager(
       new cc::TestSharedBitmapManager());
-  auto parent_resource_provider =
+  std::unique_ptr<cc::DisplayResourceProvider> resource_provider =
       cc::FakeResourceProvider::Create<cc::DisplayResourceProvider>(
           output_surface->context_provider(), shared_bitmap_manager.get());
   std::unique_ptr<cc::TextureMailboxDeleter> mailbox_deleter(
       new cc::TextureMailboxDeleter(base::ThreadTaskRunnerHandle::Get()));
 
-  auto child_context_provider = cc::TestContextProvider::Create();
-  ASSERT_TRUE(child_context_provider->BindToCurrentThread());
-  auto child_resource_provider =
-      cc::FakeResourceProvider::Create<cc::LayerTreeResourceProvider>(
-          child_context_provider.get(), shared_bitmap_manager.get());
-
-  TextureMailbox mailbox(gpu::Mailbox::Generate(), gpu::SyncToken(),
-                         GL_TEXTURE_2D, gfx::Size(256, 256), true, false);
-  auto release_callback =
-      cc::SingleReleaseCallbackImpl::Create(base::Bind(&MailboxReleased));
-  ResourceId resource_id =
-      child_resource_provider->CreateResourceFromTextureMailbox(
-          mailbox, std::move(release_callback));
-
-  std::vector<ReturnedResource> returned_to_child;
-  int child_id = parent_resource_provider->CreateChild(
-      base::Bind(&CollectResources, &returned_to_child));
-
-  // Transfer resource to the parent.
-  cc::ResourceProvider::ResourceIdArray resource_ids_to_transfer;
-  resource_ids_to_transfer.push_back(resource_id);
-  std::vector<TransferableResource> list;
-  child_resource_provider->PrepareSendToParent(resource_ids_to_transfer, &list);
-  parent_resource_provider->ReceiveFromChild(child_id, list);
-  ResourceId parent_resource_id = list[0].id;
-
   RendererSettings settings;
   FakeRendererGL renderer(&settings, output_surface.get(),
-                          parent_resource_provider.get(),
-                          mailbox_deleter.get());
+                          resource_provider.get(), mailbox_deleter.get());
   renderer.Initialize();
   renderer.SetVisible(true);
 
@@ -1987,6 +1954,13 @@
   root_pass->has_transparent_background = false;
   root_pass->copy_requests.push_back(CopyOutputRequest::CreateStubForTesting());
 
+  TextureMailbox mailbox =
+      TextureMailbox(gpu::Mailbox::Generate(), gpu::SyncToken(), GL_TEXTURE_2D,
+                     gfx::Size(256, 256), true, false);
+  std::unique_ptr<cc::SingleReleaseCallbackImpl> release_callback =
+      cc::SingleReleaseCallbackImpl::Create(base::Bind(&MailboxReleased));
+  ResourceId resource_id = resource_provider->CreateResourceFromTextureMailbox(
+      mailbox, std::move(release_callback));
   bool needs_blending = false;
   bool premultiplied_alpha = false;
   bool flipped = false;
@@ -1997,7 +1971,7 @@
       root_pass->CreateAndAppendDrawQuad<cc::TextureDrawQuad>();
   overlay_quad->SetNew(
       root_pass->CreateAndAppendSharedQuadState(), gfx::Rect(viewport_size),
-      gfx::Rect(viewport_size), needs_blending, parent_resource_id,
+      gfx::Rect(viewport_size), needs_blending, resource_id,
       premultiplied_alpha, gfx::PointF(0, 0), gfx::PointF(1, 1),
       SK_ColorTRANSPARENT, vertex_opacity, flipped, nearest_neighbor, false);
 
@@ -2022,7 +1996,7 @@
   overlay_quad = root_pass->CreateAndAppendDrawQuad<cc::TextureDrawQuad>();
   overlay_quad->SetNew(
       root_pass->CreateAndAppendSharedQuadState(), gfx::Rect(viewport_size),
-      gfx::Rect(viewport_size), needs_blending, parent_resource_id,
+      gfx::Rect(viewport_size), needs_blending, resource_id,
       premultiplied_alpha, gfx::PointF(0, 0), gfx::PointF(1, 1),
       SK_ColorTRANSPARENT, vertex_opacity, flipped, nearest_neighbor, false);
   EXPECT_CALL(*validator, AllowCALayerOverlays())
@@ -2044,7 +2018,7 @@
   overlay_quad = root_pass->CreateAndAppendDrawQuad<cc::TextureDrawQuad>();
   overlay_quad->SetNew(
       root_pass->CreateAndAppendSharedQuadState(), gfx::Rect(viewport_size),
-      gfx::Rect(viewport_size), needs_blending, parent_resource_id,
+      gfx::Rect(viewport_size), needs_blending, resource_id,
       premultiplied_alpha, gfx::PointF(0, 0), gfx::PointF(1, 1),
       SK_ColorTRANSPARENT, vertex_opacity, flipped, nearest_neighbor, false);
   EXPECT_CALL(*validator, AllowCALayerOverlays())
@@ -2120,44 +2094,15 @@
 
   std::unique_ptr<SharedBitmapManager> shared_bitmap_manager(
       new cc::TestSharedBitmapManager());
-  auto parent_resource_provider =
+  std::unique_ptr<cc::DisplayResourceProvider> resource_provider =
       cc::FakeResourceProvider::Create<cc::DisplayResourceProvider>(
           output_surface->context_provider(), shared_bitmap_manager.get());
   std::unique_ptr<cc::TextureMailboxDeleter> mailbox_deleter(
       new cc::TextureMailboxDeleter(base::ThreadTaskRunnerHandle::Get()));
 
-  auto child_context_provider = cc::TestContextProvider::Create();
-  ASSERT_TRUE(child_context_provider->BindToCurrentThread());
-  auto child_resource_provider =
-      cc::FakeResourceProvider::Create<cc::LayerTreeResourceProvider>(
-          child_context_provider.get(), shared_bitmap_manager.get());
-
-  gpu::SyncToken sync_token(gpu::CommandBufferNamespace::GPU_IO, 0,
-                            gpu::CommandBufferId::FromUnsafeValue(0x123), 29);
-  TextureMailbox mailbox(gpu::Mailbox::Generate(), sync_token, GL_TEXTURE_2D,
-                         gfx::Size(256, 256), true, false);
-  auto release_callback =
-      cc::SingleReleaseCallbackImpl::Create(base::Bind(&MailboxReleased));
-  ResourceId resource_id =
-      child_resource_provider->CreateResourceFromTextureMailbox(
-          mailbox, std::move(release_callback));
-
-  std::vector<ReturnedResource> returned_to_child;
-  int child_id = parent_resource_provider->CreateChild(
-      base::Bind(&CollectResources, &returned_to_child));
-
-  // Transfer resource to the parent.
-  cc::ResourceProvider::ResourceIdArray resource_ids_to_transfer;
-  resource_ids_to_transfer.push_back(resource_id);
-  std::vector<TransferableResource> list;
-  child_resource_provider->PrepareSendToParent(resource_ids_to_transfer, &list);
-  parent_resource_provider->ReceiveFromChild(child_id, list);
-  ResourceId parent_resource_id = list[0].id;
-
   RendererSettings settings;
   FakeRendererGL renderer(&settings, output_surface.get(),
-                          parent_resource_provider.get(),
-                          mailbox_deleter.get());
+                          resource_provider.get(), mailbox_deleter.get());
   renderer.Initialize();
   renderer.SetVisible(true);
 
@@ -2172,6 +2117,15 @@
                     gfx::Transform(), cc::FilterOperations());
   root_pass->has_transparent_background = false;
 
+  gpu::SyncToken sync_token(gpu::CommandBufferNamespace::GPU_IO, 0,
+                            gpu::CommandBufferId::FromUnsafeValue(0x123), 29);
+  TextureMailbox mailbox =
+      TextureMailbox(gpu::Mailbox::Generate(), sync_token, GL_TEXTURE_2D,
+                     gfx::Size(256, 256), true, false);
+  std::unique_ptr<cc::SingleReleaseCallbackImpl> release_callback =
+      cc::SingleReleaseCallbackImpl::Create(base::Bind(&MailboxReleased));
+  ResourceId resource_id = resource_provider->CreateResourceFromTextureMailbox(
+      mailbox, std::move(release_callback));
   bool needs_blending = false;
   bool premultiplied_alpha = false;
   bool flipped = false;
@@ -2187,20 +2141,14 @@
                        gfx::Rect(viewport_size), gfx::Rect(viewport_size),
                        false, false, 1, SkBlendMode::kSrcOver, 0);
   overlay_quad->SetNew(shared_state, gfx::Rect(viewport_size),
-                       gfx::Rect(viewport_size), needs_blending,
-                       parent_resource_id, premultiplied_alpha, uv_top_left,
-                       uv_bottom_right, SK_ColorTRANSPARENT, vertex_opacity,
-                       flipped, nearest_neighbor, false);
-
-  // The verified flush flag will be set by
-  // cc::LayerTreeResourceProvider::PrepareSendToParent. Before checking if the
-  // gpu::SyncToken matches, set this flag first.
-  sync_token.SetVerifyFlush();
+                       gfx::Rect(viewport_size), needs_blending, resource_id,
+                       premultiplied_alpha, uv_top_left, uv_bottom_right,
+                       SK_ColorTRANSPARENT, vertex_opacity, flipped,
+                       nearest_neighbor, false);
 
   // Verify that overlay_quad actually gets turned into an overlay, and even
   // though it's not drawn, that its sync point is waited on.
   EXPECT_CALL(*context, waitSyncToken(MatchesSyncToken(sync_token))).Times(1);
-
   EXPECT_CALL(
       overlay_scheduler,
       Schedule(1, gfx::OVERLAY_TRANSFORM_NONE, _, gfx::Rect(viewport_size),
@@ -2354,40 +2302,14 @@
       cc::FakeOutputSurface::Create3d(std::move(provider)));
   output_surface->BindToClient(&output_surface_client);
 
-  auto parent_resource_provider =
+  std::unique_ptr<cc::DisplayResourceProvider> resource_provider =
       cc::FakeResourceProvider::Create<cc::DisplayResourceProvider>(
           output_surface->context_provider(), nullptr);
 
-  auto child_context_provider = cc::TestContextProvider::Create();
-  ASSERT_TRUE(child_context_provider->BindToCurrentThread());
-  auto child_resource_provider =
-      cc::FakeResourceProvider::Create<cc::LayerTreeResourceProvider>(
-          child_context_provider.get(), nullptr);
-
-  TextureMailbox mailbox(gpu::Mailbox::Generate(), gpu::SyncToken(),
-                         GL_TEXTURE_2D, gfx::Size(256, 256), true, false);
-  auto release_callback =
-      cc::SingleReleaseCallbackImpl::Create(base::Bind(&MailboxReleased));
-  ResourceId resource_id =
-      child_resource_provider->CreateResourceFromTextureMailbox(
-          mailbox, std::move(release_callback));
-
-  std::vector<ReturnedResource> returned_to_child;
-  int child_id = parent_resource_provider->CreateChild(
-      base::Bind(&CollectResources, &returned_to_child));
-
-  // Transfer resource to the parent.
-  cc::ResourceProvider::ResourceIdArray resource_ids_to_transfer;
-  resource_ids_to_transfer.push_back(resource_id);
-  std::vector<TransferableResource> list;
-  child_resource_provider->PrepareSendToParent(resource_ids_to_transfer, &list);
-  parent_resource_provider->ReceiveFromChild(child_id, list);
-  ResourceId parent_resource_id = list[0].id;
-
   RendererSettings settings;
   settings.partial_swap_enabled = true;
   FakeRendererGL renderer(&settings, output_surface.get(),
-                          parent_resource_provider.get());
+                          resource_provider.get());
   renderer.Initialize();
   renderer.SetVisible(true);
   TestOverlayProcessor* processor =
@@ -2399,6 +2321,14 @@
 
   gfx::Size viewport_size(100, 100);
 
+  TextureMailbox mailbox =
+      TextureMailbox(gpu::Mailbox::Generate(), gpu::SyncToken(), GL_TEXTURE_2D,
+                     gfx::Size(256, 256), true, false);
+  std::unique_ptr<cc::SingleReleaseCallbackImpl> release_callback =
+      cc::SingleReleaseCallbackImpl::Create(base::Bind(&MailboxReleased));
+  ResourceId resource_id = resource_provider->CreateResourceFromTextureMailbox(
+      mailbox, std::move(release_callback));
+
   for (int i = 0; i < 65; i++) {
     int root_pass_id = 1;
     cc::RenderPass* root_pass = AddRenderPass(
@@ -2415,8 +2345,8 @@
       cc::YUVVideoDrawQuad* quad =
           root_pass->CreateAndAppendDrawQuad<cc::YUVVideoDrawQuad>();
       quad->SetNew(shared_state, rect, rect, needs_blending, tex_coord_rect,
-                   tex_coord_rect, rect.size(), rect.size(), parent_resource_id,
-                   parent_resource_id, parent_resource_id, parent_resource_id,
+                   tex_coord_rect, rect.size(), rect.size(), resource_id,
+                   resource_id, resource_id, resource_id,
                    cc::YUVVideoDrawQuad::REC_601, gfx::ColorSpace(), 0, 1.0, 8);
     }
 
diff --git a/content/browser/frame_host/frame_tree_node.cc b/content/browser/frame_host/frame_tree_node.cc
index e98deb8d2..adca53ed 100644
--- a/content/browser/frame_host/frame_tree_node.cc
+++ b/content/browser/frame_host/frame_tree_node.cc
@@ -96,11 +96,17 @@
   // FrameTreeNode::Observer
   void OnFrameTreeNodeDestroyed(FrameTreeNode* node) override {
     if (observing_original_opener_) {
+      // The "original owner" is special. It's used for attribution, and clients
+      // walk down the original owner chain. Therefore, if a link in the chain
+      // is being destroyed, reconnect the observation to the parent of the link
+      // being destroyed.
       CHECK_EQ(owner_->original_opener(), node);
-      owner_->SetOriginalOpener(nullptr);
+      owner_->SetOriginalOpener(node->original_opener());
+      // |this| is deleted at this point.
     } else {
       CHECK_EQ(owner_->opener(), node);
       owner_->SetOpener(nullptr);
+      // |this| is deleted at this point.
     }
   }
 
@@ -140,9 +146,7 @@
       frame_tree_node_id_(next_frame_tree_node_id_++),
       parent_(parent),
       opener_(nullptr),
-      opener_observer_(nullptr),
       original_opener_(nullptr),
-      original_opener_observer_(nullptr),
       has_committed_real_load_(false),
       is_collapsed_(false),
       replication_state_(
@@ -256,20 +260,23 @@
   opener_ = opener;
 
   if (opener_) {
-    if (!opener_observer_)
-      opener_observer_ = base::MakeUnique<OpenerDestroyedObserver>(this, false);
+    opener_observer_ = base::MakeUnique<OpenerDestroyedObserver>(this, false);
     opener_->AddObserver(opener_observer_.get());
   }
 }
 
 void FrameTreeNode::SetOriginalOpener(FrameTreeNode* opener) {
-  DCHECK(!original_opener_ || !opener);
+  // The original opener tracks main frames only.
   DCHECK(opener == nullptr || !opener->parent());
 
+  if (original_opener_) {
+    original_opener_->RemoveObserver(original_opener_observer_.get());
+    original_opener_observer_.reset();
+  }
+
   original_opener_ = opener;
 
   if (original_opener_) {
-    DCHECK(!original_opener_observer_);
     original_opener_observer_ =
         base::MakeUnique<OpenerDestroyedObserver>(this, true);
     original_opener_->AddObserver(original_opener_observer_.get());
diff --git a/content/browser/frame_host/render_frame_host_impl_browsertest.cc b/content/browser/frame_host/render_frame_host_impl_browsertest.cc
index 39a57e38..2b67ceb 100644
--- a/content/browser/frame_host/render_frame_host_impl_browsertest.cc
+++ b/content/browser/frame_host/render_frame_host_impl_browsertest.cc
@@ -5,6 +5,7 @@
 #include "content/browser/frame_host/render_frame_host_impl.h"
 
 #include "base/macros.h"
+#include "content/browser/frame_host/navigation_handle_impl.h"
 #include "content/browser/web_contents/web_contents_impl.h"
 #include "content/common/frame_messages.h"
 #include "content/public/browser/javascript_dialog_manager.h"
@@ -542,6 +543,67 @@
   CHECK_EQ(2, post_counter);
 }
 
+namespace {
+
+class NavigationHandleGrabber : public WebContentsObserver {
+ public:
+  explicit NavigationHandleGrabber(WebContents* web_contents)
+      : WebContentsObserver(web_contents) {}
+
+  void ReadyToCommitNavigation(NavigationHandle* navigation_handle) override {
+    if (navigation_handle->GetURL().path() != "/title2.html")
+      return;
+    static_cast<NavigationHandleImpl*>(navigation_handle)
+        ->set_complete_callback_for_testing(
+            base::Bind(&NavigationHandleGrabber::SendingNavigationCommitted,
+                       base::Unretained(this), navigation_handle));
+  }
+
+  void SendingNavigationCommitted(
+      NavigationHandle* navigation_handle,
+      NavigationThrottle::ThrottleCheckResult result) {
+    if (navigation_handle->GetURL().path() != "/title2.html")
+      return;
+    ExecuteScriptAsync(web_contents(), "document.open();");
+  }
+
+  void DidFinishNavigation(NavigationHandle* navigation_handle) override {
+    if (navigation_handle->GetURL().path() != "/title2.html")
+      return;
+    if (navigation_handle->HasCommitted())
+      committed_title2_ = true;
+    run_loop_.QuitClosure().Run();
+  }
+
+  void WaitForTitle2() { run_loop_.Run(); }
+
+  bool committed_title2() { return committed_title2_; }
+
+ private:
+  bool committed_title2_ = false;
+  base::RunLoop run_loop_;
+};
+}  // namespace
+
+// Verifies that if a frame aborts a navigation right after it starts, it is
+// cancelled.
+IN_PROC_BROWSER_TEST_F(RenderFrameHostImplBrowserTest, FastNavigationAbort) {
+  GURL url(embedded_test_server()->GetURL("/title1.html"));
+  NavigateToURL(shell(), url);
+
+  // Now make a navigation.
+  NavigationHandleGrabber observer(shell()->web_contents());
+  const base::string16 title = base::ASCIIToUTF16("done");
+  EXPECT_TRUE(ExecuteScript(shell()->web_contents(),
+                            "window.location.href='/title2.html'"));
+  observer.WaitForTitle2();
+  // Flush IPCs to make sure the renderer didn't tell us to navigate. Need to
+  // make two round trips.
+  EXPECT_TRUE(ExecuteScript(shell()->web_contents(), ""));
+  EXPECT_TRUE(ExecuteScript(shell()->web_contents(), ""));
+  EXPECT_FALSE(observer.committed_title2());
+}
+
 IN_PROC_BROWSER_TEST_F(RenderFrameHostImplBrowserTest,
                        TerminationDisablersClearedOnRendererCrash) {
   EXPECT_TRUE(NavigateToURL(
diff --git a/content/browser/web_contents/web_contents_impl_browsertest.cc b/content/browser/web_contents/web_contents_impl_browsertest.cc
index 8ddf2f77..d89c4668 100644
--- a/content/browser/web_contents/web_contents_impl_browsertest.cc
+++ b/content/browser/web_contents/web_contents_impl_browsertest.cc
@@ -950,6 +950,31 @@
   }
 }
 
+// Test that HasOriginalOpener() tracks provenance through closed WebContentses.
+IN_PROC_BROWSER_TEST_F(WebContentsImplBrowserTest,
+                       HasOriginalOpenerTracksThroughClosedWebContents) {
+  const GURL blank_url = GURL("about:blank");
+
+  Shell* shell1 = shell();
+  EXPECT_TRUE(NavigateToURL(shell1, blank_url));
+
+  Shell* shell2 = OpenPopup(shell1, blank_url, "window2");
+  Shell* shell3 = OpenPopup(shell2, blank_url, "window3");
+
+  EXPECT_EQ(shell2->web_contents(),
+            WebContents::FromRenderFrameHost(
+                shell3->web_contents()->GetOriginalOpener()));
+  EXPECT_EQ(shell1->web_contents(),
+            WebContents::FromRenderFrameHost(
+                shell2->web_contents()->GetOriginalOpener()));
+
+  shell2->Close();
+
+  EXPECT_EQ(shell1->web_contents(),
+            WebContents::FromRenderFrameHost(
+                shell3->web_contents()->GetOriginalOpener()));
+}
+
 // TODO(clamy): Make the test work on Windows and on Mac. On Mac and Windows,
 // there seem to be an issue with the ShellJavascriptDialogManager.
 // Flaky on all platforms: https://crbug.com/655628
diff --git a/content/public/browser/web_contents.h b/content/public/browser/web_contents.h
index dcc8954..57f5b07b 100644
--- a/content/public/browser/web_contents.h
+++ b/content/public/browser/web_contents.h
@@ -696,7 +696,9 @@
   // Returns true if this WebContents was opened by another WebContents, even
   // if the opener was suppressed. In contrast to HasOpener/GetOpener, the
   // original opener doesn't reflect window.opener which can be suppressed or
-  // updated.
+  // updated. This traces all the way back, so if the original owner was closed,
+  // but _it_ had an original owner, this will return the original owner's
+  // original owner, etc.
   virtual bool HasOriginalOpener() const = 0;
 
   // Returns the original opener if HasOriginalOpener() is true, or nullptr
diff --git a/content/renderer/gpu/render_widget_compositor.cc b/content/renderer/gpu/render_widget_compositor.cc
index 89d0576..9a176ac3 100644
--- a/content/renderer/gpu/render_widget_compositor.cc
+++ b/content/renderer/gpu/render_widget_compositor.cc
@@ -531,13 +531,15 @@
   }
 
   // On desktop, if there's over 4GB of memory on the machine, increase the
-  // working set size to 256MB for both gpu and software.
+  // image decode budget to 256MB for both gpu and software.
   const int kImageDecodeMemoryThresholdMB = 4 * 1024;
   if (base::SysInfo::AmountOfPhysicalMemoryMB() >=
       kImageDecodeMemoryThresholdMB) {
+    settings.decoded_image_cache_budget_bytes = 256 * 1024 * 1024;
     settings.decoded_image_working_set_budget_bytes = 256 * 1024 * 1024;
   } else {
-    // This is the default, but recorded here as well.
+    // These are the defaults, but recorded here as well.
+    settings.decoded_image_cache_budget_bytes = 128 * 1024 * 1024;
     settings.decoded_image_working_set_budget_bytes = 128 * 1024 * 1024;
   }
 #endif  // defined(OS_ANDROID)
@@ -552,6 +554,11 @@
         !using_synchronous_compositor) {
       settings.preferred_tile_format = viz::RGBA_4444;
     }
+
+    // When running on a low end device, we limit cached bytes to 512KB.
+    // This allows pages which are light on images to stay in cache, but
+    // prevents most long-term caching.
+    settings.decoded_image_cache_budget_bytes = 512 * 1024;
   }
 
   if (cmd.HasSwitch(switches::kEnableLowResTiling))
diff --git a/content/renderer/render_frame_impl.cc b/content/renderer/render_frame_impl.cc
index 3f55fcf..3794e1d 100644
--- a/content/renderer/render_frame_impl.cc
+++ b/content/renderer/render_frame_impl.cc
@@ -4157,6 +4157,7 @@
 }
 
 void RenderFrameImpl::AbortClientNavigation() {
+  browser_side_navigation_pending_ = false;
   Send(new FrameHostMsg_AbortNavigation(routing_id_));
 }
 
@@ -5225,6 +5226,15 @@
     const CommonNavigationParams& common_params,
     const RequestNavigationParams& request_params) {
   CHECK(IsBrowserSideNavigationEnabled());
+  // If this was a renderer-initiated navigation (nav_entry_id == 0) from this
+  // frame, but it was aborted, then ignore it.
+  if (!browser_side_navigation_pending_ &&
+      !browser_side_navigation_pending_url_.is_empty() &&
+      browser_side_navigation_pending_url_ == request_params.original_url &&
+      request_params.nav_entry_id == 0) {
+    browser_side_navigation_pending_url_ = GURL();
+    return;
+  }
 
   // This will override the url requested by the WebURLLoader, as well as
   // provide it with the response to the request.
@@ -5259,6 +5269,7 @@
                                       : nullptr);
 
   browser_side_navigation_pending_ = false;
+  browser_side_navigation_pending_url_ = GURL();
 
   NavigateInternal(common_params, StartNavigationParams(), request_params,
                    std::move(stream_override));
@@ -5305,6 +5316,7 @@
     // that the load stopped.
     Send(new FrameHostMsg_DidStopLoading(routing_id_));
     browser_side_navigation_pending_ = false;
+    browser_side_navigation_pending_url_ = GURL();
     return;
   }
 
@@ -5322,6 +5334,7 @@
       Send(new FrameHostMsg_DidStopLoading(routing_id_));
     }
     browser_side_navigation_pending_ = false;
+    browser_side_navigation_pending_url_ = GURL();
     return;
   }
 
@@ -5357,6 +5370,7 @@
   }
 
   browser_side_navigation_pending_ = false;
+  browser_side_navigation_pending_url_ = GURL();
 }
 
 void RenderFrameImpl::OnReportContentSecurityPolicyViolation(
@@ -6404,6 +6418,7 @@
 void RenderFrameImpl::BeginNavigation(const NavigationPolicyInfo& info) {
   CHECK(IsBrowserSideNavigationEnabled());
   browser_side_navigation_pending_ = true;
+  browser_side_navigation_pending_url_ = info.url_request.Url();
 
   blink::WebURLRequest& request = info.url_request;
 
diff --git a/content/renderer/render_frame_impl.h b/content/renderer/render_frame_impl.h
index 6c0e347b..2c9f02a 100644
--- a/content/renderer/render_frame_impl.h
+++ b/content/renderer/render_frame_impl.h
@@ -1447,6 +1447,7 @@
   bool name_changed_before_first_commit_ = false;
 
   bool browser_side_navigation_pending_ = false;
+  GURL browser_side_navigation_pending_url_;
 
   // A bitwise OR of bindings types that have been enabled for this RenderFrame.
   // See BindingsPolicy for details.
diff --git a/docs/memory/README.md b/docs/memory/README.md
index ad99948..1c23bed 100644
--- a/docs/memory/README.md
+++ b/docs/memory/README.md
@@ -75,8 +75,8 @@
 ## Key knowledge areas and contacts
 | Knowledge Area | Contact points |
 |----------------|----------------|
-| Chrome on Android | mariahkomenko, dskiba, ssid |
-| Browser Process | mariahkomenko, dskiba, ssid |
+| Chrome on Android | mariakhomenko, dskiba, ssid |
+| Browser Process | mariakhomenko, dskiba, ssid |
 | GPU/cc | ericrk |
 | Memory metrics | erikchen, primano, ajwong, wez |
 | Native Heap Profiling | primiano, dskiba, ajwong |
diff --git a/extensions/browser/api/lock_screen_data/lock_screen_item_storage.cc b/extensions/browser/api/lock_screen_data/lock_screen_item_storage.cc
index 1d94a1e..c5c77ef 100644
--- a/extensions/browser/api/lock_screen_data/lock_screen_item_storage.cc
+++ b/extensions/browser/api/lock_screen_data/lock_screen_item_storage.cc
@@ -84,10 +84,6 @@
                                        extension_id, callback);
 }
 
-void ReleaseValueStoreCache(std::unique_ptr<LocalValueStoreCache> cache) {
-  // Nothing to do. Used only to defer |cache| destruction to the FILE thread.
-}
-
 }  // namespace
 
 // static
@@ -131,9 +127,7 @@
 LockScreenItemStorage::~LockScreenItemStorage() {
   data_item_cache_.clear();
 
-  task_runner_->PostTask(
-      FROM_HERE, base::Bind(&ReleaseValueStoreCache,
-                            base::Passed(std::move(value_store_cache_))));
+  task_runner_->DeleteSoon(FROM_HERE, value_store_cache_.release());
 
   DCHECK_EQ(g_data_item_storage, this);
   g_data_item_storage = nullptr;
diff --git a/extensions/renderer/messaging_bindings.cc b/extensions/renderer/messaging_bindings.cc
index 07582eda8..9947579 100644
--- a/extensions/renderer/messaging_bindings.cc
+++ b/extensions/renderer/messaging_bindings.cc
@@ -374,10 +374,6 @@
       .first->second.get();
 }
 
-base::WeakPtr<MessagingBindings> MessagingBindings::GetWeakPtr() {
-  return weak_ptr_factory_.GetWeakPtr();
-}
-
 void MessagingBindings::PostMessage(
     const v8::FunctionCallbackInfo<v8::Value>& args) {
   // Arguments are (int32_t port_id, string message).
diff --git a/extensions/renderer/messaging_bindings.h b/extensions/renderer/messaging_bindings.h
index e770c15..9e46331 100644
--- a/extensions/renderer/messaging_bindings.h
+++ b/extensions/renderer/messaging_bindings.h
@@ -72,8 +72,6 @@
 
   const base::UnguessableToken& context_id() const { return context_id_; }
 
-  base::WeakPtr<MessagingBindings> GetWeakPtr();
-
  private:
   using PortMap = std::map<int, std::unique_ptr<ExtensionPort>>;
 
diff --git a/extensions/shell/installer/linux/BUILD.gn b/extensions/shell/installer/linux/BUILD.gn
index b95071f2..c66bef0 100644
--- a/extensions/shell/installer/linux/BUILD.gn
+++ b/extensions/shell/installer/linux/BUILD.gn
@@ -176,7 +176,7 @@
   deb_target_name = "${target_name}_deb"
   action(deb_target_name) {
     visibility = [ ":*" ]
-    script = "//chrome/installer/linux/flock_make_package.py"
+    script = "//chrome/installer/linux/make_package.py"
     deb_arch = "amd64"
 
     inputs = packaging_files_binaries
@@ -185,7 +185,6 @@
     ]
 
     args = [
-      rebase_path("$root_out_dir/linux_package.lock", root_build_dir),
       rebase_path("$root_out_dir/app_shell_installer/debian/build.sh",
                   root_build_dir),
       "-a",
diff --git a/gpu/command_buffer/service/service_discardable_manager.cc b/gpu/command_buffer/service/service_discardable_manager.cc
index c8a8b43..18810e6 100644
--- a/gpu/command_buffer/service/service_discardable_manager.cc
+++ b/gpu/command_buffer/service/service_discardable_manager.cc
@@ -5,45 +5,11 @@
 #include "gpu/command_buffer/service/service_discardable_manager.h"
 
 #include "base/memory/singleton.h"
-#include "base/sys_info.h"
-#include "build/build_config.h"
 #include "gpu/command_buffer/service/texture_manager.h"
 
 namespace gpu {
-namespace {
-size_t CacheSizeLimit() {
-// Cache size values are designed to roughly correspond to existing image cache
-// sizes for 2-3 renderers. These will be updated as more types of data are
-// moved to this cache.
-#if defined(OS_ANDROID)
-  const size_t kLowEndCacheSizeBytes = 512 * 1024;
-  const size_t kNormalCacheSizeBytes = 128 * 1024 * 1024;
-#else
-  const size_t kNormalCacheSizeBytes = 384 * 1024 * 1024;
-  const size_t kLargeCacheSizeBytes = 512 * 1024 * 1024;
-  // Device ram threshold at which we move from a normal cache to a large cache.
-  // While this is a GPU memory cache, we can't read GPU memory reliably, so we
-  // use system ram as a proxy.
-  const int kLargeCacheSizeMemoryThresholdMB = 4 * 1024;
-#endif  // defined(OS_ANDROID)
 
-#if defined(OS_ANDROID)
-  if (base::SysInfo::IsLowEndDevice()) {
-    return kLowEndCacheSizeBytes;
-  } else {
-    return kNormalCacheSizeBytes;
-  }
-#else
-  if (base::SysInfo::AmountOfPhysicalMemoryMB() <
-      kLargeCacheSizeMemoryThresholdMB) {
-    return kNormalCacheSizeBytes;
-  } else {
-    return kLargeCacheSizeBytes;
-  }
-#endif
-}
-
-}  // namespace
+const size_t ServiceDiscardableManager::kMaxSize;
 
 ServiceDiscardableManager::GpuDiscardableEntry::GpuDiscardableEntry(
     ServiceDiscardableHandle handle,
@@ -57,9 +23,7 @@
     default;
 
 ServiceDiscardableManager::ServiceDiscardableManager()
-    : entries_(EntryCache::NO_AUTO_EVICT),
-      cache_size_limit_(CacheSizeLimit()) {}
-
+    : entries_(EntryCache::NO_AUTO_EVICT) {}
 ServiceDiscardableManager::~ServiceDiscardableManager() {
 #if DCHECK_IS_ON()
   for (const auto& entry : entries_) {
@@ -168,7 +132,7 @@
 
 void ServiceDiscardableManager::EnforceLimits() {
   for (auto it = entries_.rbegin(); it != entries_.rend();) {
-    if (total_size_ <= cache_size_limit_) {
+    if (total_size_ <= kMaxSize) {
       return;
     }
     if (!it->second.handle.Delete()) {
diff --git a/gpu/command_buffer/service/service_discardable_manager.h b/gpu/command_buffer/service/service_discardable_manager.h
index b9bf82b..d8fe6f4 100644
--- a/gpu/command_buffer/service/service_discardable_manager.h
+++ b/gpu/command_buffer/service/service_discardable_manager.h
@@ -64,9 +64,9 @@
       uint32_t texture_id,
       gles2::TextureManager* texture_manager) const;
 
-  void SetCacheSizeLimitForTesting(size_t cache_size_limit) {
-    cache_size_limit_ = cache_size_limit;
-  }
+  // TODO(ericrk): Arbitrary limit, refine this once we actually use this class
+  // in production. crbug.com/706456
+  static const size_t kMaxSize = 256 * 1024 * 1024;
 
  private:
   void EnforceLimits();
@@ -106,9 +106,6 @@
   // GpuDiscardableEntry::size for each entry.
   size_t total_size_ = 0;
 
-  // The limit above which the cache will start evicting resources.
-  size_t cache_size_limit_ = 0;
-
   DISALLOW_COPY_AND_ASSIGN(ServiceDiscardableManager);
 };
 
diff --git a/gpu/command_buffer/service/service_discardable_manager_unittest.cc b/gpu/command_buffer/service/service_discardable_manager_unittest.cc
index 11f37be..3213139 100644
--- a/gpu/command_buffer/service/service_discardable_manager_unittest.cc
+++ b/gpu/command_buffer/service/service_discardable_manager_unittest.cc
@@ -200,12 +200,9 @@
 
 TEST_F(ServiceDiscardableManagerTest, Limits) {
   // Size textures so that four fit in the discardable manager.
-  const size_t cache_size_limit = 4 * 1024 * 1024;
-  const size_t texture_size = cache_size_limit / 4;
+  const size_t texture_size = ServiceDiscardableManager::kMaxSize / 4;
   const size_t large_texture_size = 3 * texture_size;
 
-  discardable_manager_.SetCacheSizeLimitForTesting(cache_size_limit);
-
   // Create 4 textures, this should fill up the discardable cache.
   for (int i = 1; i < 5; ++i) {
     texture_manager_->CreateTexture(i, i);
diff --git a/ios/chrome/app/main_controller.mm b/ios/chrome/app/main_controller.mm
index 402bf2f..7b1974f 100644
--- a/ios/chrome/app/main_controller.mm
+++ b/ios/chrome/app/main_controller.mm
@@ -355,8 +355,6 @@
 - (void)activateBVCAndMakeCurrentBVCPrimary;
 // Sets |currentBVC| as the root view controller for the window.
 - (void)displayCurrentBVC;
-// Shows the Sync settings UI.
-- (void)showSyncSettings;
 // Invokes the sign in flow with the specified authentication operation and
 // invokes |callback| when finished.
 - (void)showSigninWithOperation:(AuthenticationOperation)operation
@@ -368,8 +366,6 @@
 // successfully and the profile wasn't swapped before invoking.
 - (ShowSigninCommandCompletionCallback)successfulSigninCompletion:
     (ProceduralBlock)callback;
-// Shows the Sync encryption passphrase (part of Settings).
-- (void)showSyncEncryptionPassphrase;
 // Shows the tab switcher UI.
 - (void)showTabSwitcher;
 // Starts a voice search on the current BVC.
@@ -1458,6 +1454,55 @@
   }
 }
 
+#pragma mark - ApplicationSettingsCommands
+
+- (void)showAccountsSettings {
+  if ([self currentBrowserState]->IsOffTheRecord()) {
+    NOTREACHED();
+    return;
+  }
+  if (_settingsNavigationController) {
+    [_settingsNavigationController showAccountsSettings];
+    return;
+  }
+  _settingsNavigationController = [SettingsNavigationController
+      newAccountsController:self.currentBrowserState
+                   delegate:self];
+  [[self topPresentedViewController]
+      presentViewController:_settingsNavigationController
+                   animated:YES
+                 completion:nil];
+}
+
+- (void)showSyncSettings {
+  if (_settingsNavigationController) {
+    [_settingsNavigationController showSyncSettings];
+    return;
+  }
+  _settingsNavigationController =
+      [SettingsNavigationController newSyncController:_mainBrowserState
+                               allowSwitchSyncAccount:YES
+                                             delegate:self];
+  [[self topPresentedViewController]
+      presentViewController:_settingsNavigationController
+                   animated:YES
+                 completion:nil];
+}
+
+- (void)showSyncPassphraseSettings {
+  if (_settingsNavigationController) {
+    [_settingsNavigationController showSyncPassphraseSettings];
+    return;
+  }
+  _settingsNavigationController = [SettingsNavigationController
+      newSyncEncryptionPassphraseController:_mainBrowserState
+                                   delegate:self];
+  [[self topPresentedViewController]
+      presentViewController:_settingsNavigationController
+                   animated:YES
+                 completion:nil];
+}
+
 #pragma mark - chromeExecuteCommand
 
 - (IBAction)chromeExecuteCommand:(id)sender {
@@ -1478,12 +1523,6 @@
       }
       break;
     }
-    case IDC_SHOW_SYNC_SETTINGS:
-      [self showSyncSettings];
-      break;
-    case IDC_SHOW_SYNC_PASSPHRASE_SETTINGS:
-      [self showSyncEncryptionPassphrase];
-      break;
     case IDC_SHOW_MAIL_COMPOSER:
       [self.currentBVC chromeExecuteCommand:sender];
       break;
@@ -1930,49 +1969,6 @@
                  completion:nil];
 }
 
-- (void)showAccountsSettings {
-  if ([self currentBrowserState]->IsOffTheRecord()) {
-    NOTREACHED();
-    return;
-  }
-  if (_settingsNavigationController) {
-    [_settingsNavigationController showAccountsSettings];
-    return;
-  }
-  _settingsNavigationController = [SettingsNavigationController
-      newAccountsController:self.currentBrowserState
-                   delegate:self];
-  [[self topPresentedViewController]
-      presentViewController:_settingsNavigationController
-                   animated:YES
-                 completion:nil];
-}
-
-- (void)showSyncSettings {
-  if (_settingsNavigationController)
-    return;
-  _settingsNavigationController =
-      [SettingsNavigationController newSyncController:_mainBrowserState
-                               allowSwitchSyncAccount:YES
-                                             delegate:self];
-  [[self topPresentedViewController]
-      presentViewController:_settingsNavigationController
-                   animated:YES
-                 completion:nil];
-}
-
-- (void)showSyncEncryptionPassphrase {
-  if (_settingsNavigationController)
-    return;
-  _settingsNavigationController = [SettingsNavigationController
-      newSyncEncryptionPassphraseController:_mainBrowserState
-                                   delegate:self];
-  [[self topPresentedViewController]
-      presentViewController:_settingsNavigationController
-                   animated:YES
-                 completion:nil];
-}
-
 - (void)showSigninWithOperation:(AuthenticationOperation)operation
                        identity:(ChromeIdentity*)identity
                     accessPoint:(signin_metrics::AccessPoint)accessPoint
diff --git a/ios/chrome/browser/component_updater/ios_component_updater_configurator.cc b/ios/chrome/browser/component_updater/ios_component_updater_configurator.cc
index 484fe768..f1e6447 100644
--- a/ios/chrome/browser/component_updater/ios_component_updater_configurator.cc
+++ b/ios/chrome/browser/component_updater/ios_component_updater_configurator.cc
@@ -11,6 +11,7 @@
 
 #include "base/version.h"
 #include "components/component_updater/configurator_impl.h"
+#include "components/update_client/activity_data_service.h"
 #include "components/update_client/out_of_process_patcher.h"
 #include "components/update_client/update_query_params.h"
 #include "ios/chrome/browser/application_context.h"
@@ -49,6 +50,7 @@
   bool EnabledBackgroundDownloader() const override;
   bool EnabledCupSigning() const override;
   PrefService* GetPrefService() const override;
+  update_client::ActivityDataService* GetActivityDataService() const override;
   bool IsPerUserInstall() const override;
   std::vector<uint8_t> GetRunActionKeyHash() const override;
 
@@ -156,6 +158,11 @@
   return GetApplicationContext()->GetLocalState();
 }
 
+update_client::ActivityDataService* IOSConfigurator::GetActivityDataService()
+    const {
+  return nullptr;
+}
+
 bool IOSConfigurator::IsPerUserInstall() const {
   return true;
 }
diff --git a/ios/chrome/browser/tabs/tab_unittest.mm b/ios/chrome/browser/tabs/tab_unittest.mm
index 8bad150..480bb01 100644
--- a/ios/chrome/browser/tabs/tab_unittest.mm
+++ b/ios/chrome/browser/tabs/tab_unittest.mm
@@ -151,8 +151,7 @@
 class TabTest : public BlockCleanupTest {
  public:
   TabTest()
-      : thread_bundle_(web::TestWebThreadBundle::REAL_FILE_THREAD),
-        scoped_browser_state_manager_(
+      : scoped_browser_state_manager_(
             base::MakeUnique<TestChromeBrowserStateManager>(base::FilePath())),
         web_state_impl_(nullptr) {}
 
diff --git a/ios/chrome/browser/ui/browser_view_controller.mm b/ios/chrome/browser/ui/browser_view_controller.mm
index b905327d6..df93d269 100644
--- a/ios/chrome/browser/ui/browser_view_controller.mm
+++ b/ios/chrome/browser/ui/browser_view_controller.mm
@@ -1582,7 +1582,7 @@
   [[UpgradeCenter sharedInstance] addInfoBarToManager:infoBarManager
                                              forTabId:[tab tabId]];
   if (!ReSignInInfoBarDelegate::Create(_browserState, tab)) {
-    DisplaySyncErrors(_browserState, tab);
+    DisplaySyncErrors(_browserState, tab, self.dispatcher);
   }
 
   // The rest of this function initiates the new tab animation, which is
diff --git a/ios/chrome/browser/ui/commands/application_commands.h b/ios/chrome/browser/ui/commands/application_commands.h
index e465000..be2473b 100644
--- a/ios/chrome/browser/ui/commands/application_commands.h
+++ b/ios/chrome/browser/ui/commands/application_commands.h
@@ -18,6 +18,12 @@
 // Shows the accounts settings.
 - (void)showAccountsSettings;
 
+// Shows the sync settings UI.
+- (void)showSyncSettings;
+
+// Shows the sync encryption passphrase UI.
+- (void)showSyncPassphraseSettings;
+
 @end
 
 // Protocol for commands that will generally be handled by the application,
diff --git a/ios/chrome/browser/ui/commands/ios_command_ids.h b/ios/chrome/browser/ui/commands/ios_command_ids.h
index ced3795..23ec0a9 100644
--- a/ios/chrome/browser/ui/commands/ios_command_ids.h
+++ b/ios/chrome/browser/ui/commands/ios_command_ids.h
@@ -15,10 +15,8 @@
 // clang-format off
 #define IDC_SHOW_SIGNIN_IOS                            40905
 #define IDC_SHOW_ADD_ACCOUNT                           40910
-#define IDC_SHOW_SYNC_SETTINGS                         40914
 #define IDC_CLEAR_BROWSING_DATA_IOS                    40924
 #define IDC_SHOW_MAIL_COMPOSER                         40926
-#define IDC_SHOW_SYNC_PASSPHRASE_SETTINGS              40952
 // clang-format on
 
 #endif  // IOS_CHROME_BROWSER_UI_COMMANDS_IOS_COMMAND_IDS_H_
diff --git a/ios/chrome/browser/ui/first_run/first_run_chrome_signin_view_controller.mm b/ios/chrome/browser/ui/first_run/first_run_chrome_signin_view_controller.mm
index 52b6bc5..afc0f44 100644
--- a/ios/chrome/browser/ui/first_run/first_run_chrome_signin_view_controller.mm
+++ b/ios/chrome/browser/ui/first_run/first_run_chrome_signin_view_controller.mm
@@ -99,7 +99,8 @@
 
 - (void)finishFirstRunAndDismiss {
   DCHECK(self.presentingViewController);
-  FinishFirstRun(self.browserState, [_tabModel currentTab], _firstRunConfig);
+  FinishFirstRun(self.browserState, [_tabModel currentTab], _firstRunConfig,
+                 self.dispatcher);
   [self.presentingViewController dismissViewControllerAnimated:YES
                                                     completion:^{
                                                       FirstRunDismissed();
diff --git a/ios/chrome/browser/ui/first_run/first_run_util.h b/ios/chrome/browser/ui/first_run/first_run_util.h
index a1f9239e..68ef0203 100644
--- a/ios/chrome/browser/ui/first_run/first_run_util.h
+++ b/ios/chrome/browser/ui/first_run/first_run_util.h
@@ -7,6 +7,7 @@
 
 #import <UIKit/UIKit.h>
 
+@protocol ApplicationSettingsCommands;
 @class FirstRunConfiguration;
 @class Tab;
 
@@ -45,7 +46,8 @@
 // Methods for writing sentinel and recording metrics and posting notifications
 void FinishFirstRun(ios::ChromeBrowserState* browserState,
                     Tab* tab,
-                    FirstRunConfiguration* config);
+                    FirstRunConfiguration* config,
+                    id<ApplicationSettingsCommands> dispatcher);
 
 // Records Product tour timing metrics using histogram.
 void RecordProductTourTimingMetrics(NSString* timer_name,
diff --git a/ios/chrome/browser/ui/first_run/first_run_util.mm b/ios/chrome/browser/ui/first_run/first_run_util.mm
index 79f2d2af..8632104b 100644
--- a/ios/chrome/browser/ui/first_run/first_run_util.mm
+++ b/ios/chrome/browser/ui/first_run/first_run_util.mm
@@ -159,7 +159,8 @@
 
 void FinishFirstRun(ios::ChromeBrowserState* browserState,
                     Tab* tab,
-                    FirstRunConfiguration* config) {
+                    FirstRunConfiguration* config,
+                    id<ApplicationSettingsCommands> dispatcher) {
   [[NSNotificationCenter defaultCenter]
       postNotificationName:kChromeFirstRunUIWillFinishNotification
                     object:nil];
@@ -167,7 +168,7 @@
                                         config.hasSSOAccount);
 
   // Display the sync errors infobar.
-  DisplaySyncErrors(browserState, tab);
+  DisplaySyncErrors(browserState, tab, dispatcher);
 }
 
 void RecordProductTourTimingMetrics(NSString* timer_name,
diff --git a/ios/chrome/browser/ui/ntp/recent_tabs/recent_tabs_table_view_controller.mm b/ios/chrome/browser/ui/ntp/recent_tabs/recent_tabs_table_view_controller.mm
index f0100900..7f71f7d 100644
--- a/ios/chrome/browser/ui/ntp/recent_tabs/recent_tabs_table_view_controller.mm
+++ b/ios/chrome/browser/ui/ntp/recent_tabs/recent_tabs_table_view_controller.mm
@@ -803,7 +803,8 @@
     }
     case CELL_OTHER_DEVICES_SIGNED_IN_SYNC_OFF:
       subview = [[SignedInSyncOffView alloc] initWithFrame:CGRectZero
-                                              browserState:_browserState];
+                                              browserState:_browserState
+                                                dispatcher:self.dispatcher];
       [cell setSelectionStyle:UITableViewCellSelectionStyleNone];
       break;
     case CELL_OTHER_DEVICES_SIGNED_IN_SYNC_ON_NO_SESSIONS:
diff --git a/ios/chrome/browser/ui/ntp/recent_tabs/views/signed_in_sync_off_view.h b/ios/chrome/browser/ui/ntp/recent_tabs/views/signed_in_sync_off_view.h
index 3fd01146..dd3cd6e 100644
--- a/ios/chrome/browser/ui/ntp/recent_tabs/views/signed_in_sync_off_view.h
+++ b/ios/chrome/browser/ui/ntp/recent_tabs/views/signed_in_sync_off_view.h
@@ -7,6 +7,8 @@
 
 #import <UIKit/UIKit.h>
 
+@protocol ApplicationSettingsCommands;
+
 namespace ios {
 class ChromeBrowserState;
 }
@@ -16,7 +18,12 @@
 
 // Designated initializer.
 - (instancetype)initWithFrame:(CGRect)aRect
-                 browserState:(ios::ChromeBrowserState*)browserState;
+                 browserState:(ios::ChromeBrowserState*)browserState
+                   dispatcher:(id<ApplicationSettingsCommands>)dispatcher
+    NS_DESIGNATED_INITIALIZER;
+
+- (instancetype)initWithFrame:(CGRect)frame NS_UNAVAILABLE;
+- (instancetype)initWithCoder:(NSCoder*)aDecoder NS_UNAVAILABLE;
 
 // Returns the desired height when included in a UITableViewCell.
 + (CGFloat)desiredHeightInUITableViewCell;
diff --git a/ios/chrome/browser/ui/ntp/recent_tabs/views/signed_in_sync_off_view.mm b/ios/chrome/browser/ui/ntp/recent_tabs/views/signed_in_sync_off_view.mm
index 2379f16..446ec4c 100644
--- a/ios/chrome/browser/ui/ntp/recent_tabs/views/signed_in_sync_off_view.mm
+++ b/ios/chrome/browser/ui/ntp/recent_tabs/views/signed_in_sync_off_view.mm
@@ -6,6 +6,8 @@
 
 #include "base/logging.h"
 #import "ios/chrome/browser/ui/commands/UIKit+ChromeExecuteCommand.h"
+#import "ios/chrome/browser/ui/commands/application_commands.h"
+#import "ios/chrome/browser/ui/commands/show_signin_command.h"
 #import "ios/chrome/browser/ui/fancy_ui/primary_action_button.h"
 #import "ios/chrome/browser/ui/ntp/recent_tabs/views/views_utils.h"
 #include "ios/chrome/browser/ui/rtl_geometry.h"
@@ -26,15 +28,23 @@
 
 }  // anonymous namespace
 
+@interface SignedInSyncOffView ()
+// Dispatcher for sending commands.
+@property(nonatomic, weak) id<ApplicationSettingsCommands> dispatcher;
+@end
+
 @implementation SignedInSyncOffView {
   ios::ChromeBrowserState* _browserState;  // Weak.
 }
+@synthesize dispatcher = _dispatcher;
 
 - (instancetype)initWithFrame:(CGRect)aRect
-                 browserState:(ios::ChromeBrowserState*)browserState {
+                 browserState:(ios::ChromeBrowserState*)browserState
+                   dispatcher:(id<ApplicationSettingsCommands>)dispatcher {
   self = [super initWithFrame:CGRectZero];
   if (self) {
     _browserState = browserState;
+    _dispatcher = dispatcher;
     // Create and add sign in label.
     UILabel* enableSyncLabel = recent_tabs::CreateMultilineLabel(
         l10n_util::GetNSString(IDS_IOS_OPEN_TABS_SYNC_IS_OFF_MOBILE));
@@ -74,7 +84,19 @@
 }
 
 - (void)showSyncSettings {
-  [self chromeExecuteCommand:GetSyncCommandForBrowserState(_browserState)];
+  SyncSetupService::SyncServiceState syncState =
+      GetSyncStateForBrowserState(_browserState);
+  if (ShouldShowSyncSignin(syncState)) {
+    [self chromeExecuteCommand:
+              [[ShowSigninCommand alloc]
+                  initWithOperation:AUTHENTICATION_OPERATION_REAUTHENTICATE
+                        accessPoint:signin_metrics::AccessPoint::
+                                        ACCESS_POINT_UNKNOWN]];
+  } else if (ShouldShowSyncSettings(syncState)) {
+    [self.dispatcher showSyncSettings];
+  } else if (ShouldShowSyncPassphraseSettings(syncState)) {
+    [self.dispatcher showSyncPassphraseSettings];
+  }
 }
 
 @end
diff --git a/ios/chrome/browser/ui/settings/settings_navigation_controller.mm b/ios/chrome/browser/ui/settings/settings_navigation_controller.mm
index 4b292f5..6533afa 100644
--- a/ios/chrome/browser/ui/settings/settings_navigation_controller.mm
+++ b/ios/chrome/browser/ui/settings/settings_navigation_controller.mm
@@ -481,23 +481,6 @@
       CHECK_EQ(commandBrowserState, [self mainBrowserState]);
       break;
     }
-    case IDC_SHOW_SYNC_SETTINGS: {
-      SyncSettingsCollectionViewController* controller =
-          [[SyncSettingsCollectionViewController alloc]
-                initWithBrowserState:mainBrowserState_
-              allowSwitchSyncAccount:YES];
-      controller.dispatcher = [delegate_ dispatcherForSettings];
-      [self pushViewController:controller animated:YES];
-      return;
-    }
-    case IDC_SHOW_SYNC_PASSPHRASE_SETTINGS: {
-      SyncEncryptionPassphraseCollectionViewController* controller =
-          [[SyncEncryptionPassphraseCollectionViewController alloc]
-              initWithBrowserState:mainBrowserState_];
-      controller.dispatcher = [delegate_ dispatcherForSettings];
-      [self pushViewController:controller animated:YES];
-      return;
-    }
     default:
       NOTREACHED()
           << "Unexpected command " << [sender tag]
@@ -534,6 +517,23 @@
   [self pushViewController:controller animated:YES];
 }
 
+- (void)showSyncSettings {
+  SyncSettingsCollectionViewController* controller =
+      [[SyncSettingsCollectionViewController alloc]
+            initWithBrowserState:mainBrowserState_
+          allowSwitchSyncAccount:YES];
+  controller.dispatcher = [delegate_ dispatcherForSettings];
+  [self pushViewController:controller animated:YES];
+}
+
+- (void)showSyncPassphraseSettings {
+  SyncEncryptionPassphraseCollectionViewController* controller =
+      [[SyncEncryptionPassphraseCollectionViewController alloc]
+          initWithBrowserState:mainBrowserState_];
+  controller.dispatcher = [delegate_ dispatcherForSettings];
+  [self pushViewController:controller animated:YES];
+}
+
 #pragma mark - Profile
 
 - (ios::ChromeBrowserState*)mainBrowserState {
diff --git a/ios/chrome/browser/ui/settings/sync_settings_collection_view_controller.mm b/ios/chrome/browser/ui/settings/sync_settings_collection_view_controller.mm
index f1c9cf0..9d30a351 100644
--- a/ios/chrome/browser/ui/settings/sync_settings_collection_view_controller.mm
+++ b/ios/chrome/browser/ui/settings/sync_settings_collection_view_controller.mm
@@ -37,6 +37,7 @@
 #import "ios/chrome/browser/ui/commands/UIKit+ChromeExecuteCommand.h"
 #import "ios/chrome/browser/ui/commands/application_commands.h"
 #import "ios/chrome/browser/ui/commands/open_url_command.h"
+#import "ios/chrome/browser/ui/commands/show_signin_command.h"
 #import "ios/chrome/browser/ui/settings/cells/sync_switch_item.h"
 #import "ios/chrome/browser/ui/settings/cells/text_and_error_item.h"
 #import "ios/chrome/browser/ui/settings/settings_navigation_controller.h"
@@ -590,8 +591,19 @@
     return;
   }
 
-  GenericChromeCommand* command = GetSyncCommandForBrowserState(_browserState);
-  [self chromeExecuteCommand:command];
+  SyncSetupService::SyncServiceState syncState =
+      GetSyncStateForBrowserState(_browserState);
+  if (ShouldShowSyncSignin(syncState)) {
+    [self chromeExecuteCommand:
+              [[ShowSigninCommand alloc]
+                  initWithOperation:AUTHENTICATION_OPERATION_REAUTHENTICATE
+                        accessPoint:signin_metrics::AccessPoint::
+                                        ACCESS_POINT_UNKNOWN]];
+  } else if (ShouldShowSyncSettings(syncState)) {
+    [self.dispatcher showSyncSettings];
+  } else if (ShouldShowSyncPassphraseSettings(syncState)) {
+    [self.dispatcher showSyncPassphraseSettings];
+  }
 }
 
 - (void)startSwitchAccountForIdentity:(ChromeIdentity*)identity
diff --git a/ios/chrome/browser/ui/sync/sync_error_infobar_delegate.h b/ios/chrome/browser/ui/sync/sync_error_infobar_delegate.h
index 17bb46f0..495a98a 100644
--- a/ios/chrome/browser/ui/sync/sync_error_infobar_delegate.h
+++ b/ios/chrome/browser/ui/sync/sync_error_infobar_delegate.h
@@ -15,6 +15,7 @@
 #include "ios/chrome/browser/sync/sync_setup_service.h"
 #include "ui/gfx/image/image.h"
 
+@protocol ApplicationSettingsCommands;
 @class GenericChromeCommand;
 
 namespace gfx {
@@ -33,12 +34,14 @@
 class SyncErrorInfoBarDelegate : public ConfirmInfoBarDelegate,
                                  public syncer::SyncServiceObserver {
  public:
-  explicit SyncErrorInfoBarDelegate(ios::ChromeBrowserState* browser_state);
+  SyncErrorInfoBarDelegate(ios::ChromeBrowserState* browser_state,
+                           id<ApplicationSettingsCommands> dispatcher);
   ~SyncErrorInfoBarDelegate() override;
 
   // Creates a sync error infobar and adds it to |infobar_manager|.
   static bool Create(infobars::InfoBarManager* infobar_manager,
-                     ios::ChromeBrowserState* browser_state);
+                     ios::ChromeBrowserState* browser_state,
+                     id<ApplicationSettingsCommands> dispatcher);
 
   // InfoBarDelegate implementation.
   InfoBarIdentifier GetIdentifier() const override;
@@ -60,6 +63,7 @@
   base::string16 message_;
   base::string16 button_text_;
   base::scoped_nsobject<GenericChromeCommand> command_;
+  id<ApplicationSettingsCommands> dispatcher_;
 
   DISALLOW_COPY_AND_ASSIGN(SyncErrorInfoBarDelegate);
 };
diff --git a/ios/chrome/browser/ui/sync/sync_error_infobar_delegate.mm b/ios/chrome/browser/ui/sync/sync_error_infobar_delegate.mm
index 9bbe83d..31923b38 100644
--- a/ios/chrome/browser/ui/sync/sync_error_infobar_delegate.mm
+++ b/ios/chrome/browser/ui/sync/sync_error_infobar_delegate.mm
@@ -21,7 +21,9 @@
 #include "ios/chrome/browser/sync/sync_setup_service.h"
 #include "ios/chrome/browser/sync/sync_setup_service_factory.h"
 #import "ios/chrome/browser/ui/commands/UIKit+ChromeExecuteCommand.h"
+#import "ios/chrome/browser/ui/commands/application_commands.h"
 #import "ios/chrome/browser/ui/commands/generic_chrome_command.h"
+#import "ios/chrome/browser/ui/commands/show_signin_command.h"
 #import "ios/chrome/browser/ui/sync/sync_util.h"
 #include "ui/base/l10n/l10n_util.h"
 
@@ -30,18 +32,21 @@
 #endif
 
 // static
-bool SyncErrorInfoBarDelegate::Create(infobars::InfoBarManager* infobar_manager,
-                                      ios::ChromeBrowserState* browser_state) {
+bool SyncErrorInfoBarDelegate::Create(
+    infobars::InfoBarManager* infobar_manager,
+    ios::ChromeBrowserState* browser_state,
+    id<ApplicationSettingsCommands> dispatcher) {
   DCHECK(infobar_manager);
   std::unique_ptr<ConfirmInfoBarDelegate> delegate(
-      new SyncErrorInfoBarDelegate(browser_state));
+      new SyncErrorInfoBarDelegate(browser_state, dispatcher));
   return !!infobar_manager->AddInfoBar(
       infobar_manager->CreateConfirmInfoBar(std::move(delegate)));
 }
 
 SyncErrorInfoBarDelegate::SyncErrorInfoBarDelegate(
-    ios::ChromeBrowserState* browser_state)
-    : browser_state_(browser_state) {
+    ios::ChromeBrowserState* browser_state,
+    id<ApplicationSettingsCommands> dispatcher)
+    : browser_state_(browser_state), dispatcher_(dispatcher) {
   DCHECK(!browser_state->IsOffTheRecord());
   icon_ = gfx::Image([UIImage imageNamed:@"infobar_warning"]);
   SyncSetupService* sync_setup_service =
@@ -54,7 +59,6 @@
       GetSyncErrorMessageForBrowserState(browser_state_));
   button_text_ = base::SysNSStringToUTF16(
       GetSyncErrorButtonTitleForBrowserState(browser_state_));
-  command_.reset(GetSyncCommandForBrowserState(browser_state_));
 
   // Register for sync status changes.
   syncer::SyncService* sync_service =
@@ -92,10 +96,20 @@
 }
 
 bool SyncErrorInfoBarDelegate::Accept() {
-  DCHECK(command_);
-  UIWindow* main_window = [[UIApplication sharedApplication] keyWindow];
-  DCHECK(main_window);
-  [main_window chromeExecuteCommand:command_];
+  if (ShouldShowSyncSignin(error_state_)) {
+    UIWindow* main_window = [[UIApplication sharedApplication] keyWindow];
+    DCHECK(main_window);
+    [main_window
+        chromeExecuteCommand:
+            [[ShowSigninCommand alloc]
+                initWithOperation:AUTHENTICATION_OPERATION_REAUTHENTICATE
+                      accessPoint:signin_metrics::AccessPoint::
+                                      ACCESS_POINT_UNKNOWN]];
+  } else if (ShouldShowSyncSettings(error_state_)) {
+    [dispatcher_ showSyncSettings];
+  } else if (ShouldShowSyncPassphraseSettings(error_state_)) {
+    [dispatcher_ showSyncPassphraseSettings];
+  }
   return false;
 }
 
@@ -117,7 +131,7 @@
     infobars::InfoBarManager* infobar_manager = infobar->owner();
     if (infobar_manager) {
       std::unique_ptr<ConfirmInfoBarDelegate> new_infobar_delegate(
-          new SyncErrorInfoBarDelegate(browser_state_));
+          new SyncErrorInfoBarDelegate(browser_state_, dispatcher_));
       infobar_manager->ReplaceInfoBar(infobar,
                                       infobar_manager->CreateConfirmInfoBar(
                                           std::move(new_infobar_delegate)));
diff --git a/ios/chrome/browser/ui/sync/sync_util.h b/ios/chrome/browser/ui/sync/sync_util.h
index 3a79aad9..5c140cb 100644
--- a/ios/chrome/browser/ui/sync/sync_util.h
+++ b/ios/chrome/browser/ui/sync/sync_util.h
@@ -10,6 +10,7 @@
 #include "google_apis/gaia/google_service_auth_error.h"
 #include "ios/chrome/browser/sync/sync_setup_service.h"
 
+@protocol ApplicationSettingsCommands;
 @class GenericChromeCommand;
 @class Tab;
 
@@ -33,13 +34,26 @@
 NSString* GetSyncErrorButtonTitleForBrowserState(
     ios::ChromeBrowserState* browserState);
 
-// Gets the command associated with the sync state of |browserState|.
-GenericChromeCommand* GetSyncCommandForBrowserState(
+// Gets the sync state of |browserState|.
+SyncSetupService::SyncServiceState GetSyncStateForBrowserState(
     ios::ChromeBrowserState* browserState);
 
+// Returns true if sync signin should be displayed based on |syncState|.
+bool ShouldShowSyncSignin(SyncSetupService::SyncServiceState syncState);
+
+// Returns true if sync passphrase settings should be displayed based on
+// |syncState|.
+bool ShouldShowSyncPassphraseSettings(
+    SyncSetupService::SyncServiceState syncState);
+
+// Returns true if sync settings should be displayed based on |syncState|.
+bool ShouldShowSyncSettings(SyncSetupService::SyncServiceState syncState);
+
 // Check for sync errors, and display any that ought to be shown to the user.
 // Returns true if an infobar was brought up.
-bool DisplaySyncErrors(ios::ChromeBrowserState* browser_state, Tab* tab);
+bool DisplaySyncErrors(ios::ChromeBrowserState* browser_state,
+                       Tab* tab,
+                       id<ApplicationSettingsCommands> dispatcher);
 
 // Returns true if |errorState| corresponds to a transient sync error.
 bool IsTransientSyncError(SyncSetupService::SyncServiceState errorState);
diff --git a/ios/chrome/browser/ui/sync/sync_util.mm b/ios/chrome/browser/ui/sync/sync_util.mm
index 551ebf1..115dd18 100644
--- a/ios/chrome/browser/ui/sync/sync_util.mm
+++ b/ios/chrome/browser/ui/sync/sync_util.mm
@@ -102,30 +102,38 @@
   }
 }
 
-GenericChromeCommand* GetSyncCommandForBrowserState(
+SyncSetupService::SyncServiceState GetSyncStateForBrowserState(
     ios::ChromeBrowserState* browserState) {
   SyncSetupService* syncSetupService =
       SyncSetupServiceFactory::GetForBrowserState(browserState);
   DCHECK(syncSetupService);
-  SyncSetupService::SyncServiceState syncState =
-      syncSetupService->GetSyncServiceState();
+  return syncSetupService->GetSyncServiceState();
+}
+
+bool ShouldShowSyncSignin(SyncSetupService::SyncServiceState syncState) {
+  return syncState == SyncSetupService::kSyncServiceSignInNeedsUpdate;
+}
+
+bool ShouldShowSyncPassphraseSettings(
+    SyncSetupService::SyncServiceState syncState) {
+  return syncState == SyncSetupService::kSyncServiceNeedsPassphrase;
+}
+
+bool ShouldShowSyncSettings(SyncSetupService::SyncServiceState syncState) {
   switch (syncState) {
-    case SyncSetupService::kSyncServiceSignInNeedsUpdate:
-      return [[ShowSigninCommand alloc]
-          initWithOperation:AUTHENTICATION_OPERATION_REAUTHENTICATE
-                accessPoint:signin_metrics::AccessPoint::ACCESS_POINT_UNKNOWN];
-    case SyncSetupService::kSyncServiceNeedsPassphrase:
-      return [[GenericChromeCommand alloc]
-          initWithTag:IDC_SHOW_SYNC_PASSPHRASE_SETTINGS];
     case SyncSetupService::kSyncServiceCouldNotConnect:
     case SyncSetupService::kSyncServiceServiceUnavailable:
     case SyncSetupService::kSyncServiceUnrecoverableError:
     case SyncSetupService::kNoSyncServiceError:
-      return [[GenericChromeCommand alloc] initWithTag:IDC_SHOW_SYNC_SETTINGS];
+      return true;
+    default:
+      return false;
   }
 }
 
-bool DisplaySyncErrors(ios::ChromeBrowserState* browser_state, Tab* tab) {
+bool DisplaySyncErrors(ios::ChromeBrowserState* browser_state,
+                       Tab* tab,
+                       id<ApplicationSettingsCommands> dispatcher) {
   // Avoid displaying sync errors on incognito tabs.
   if (browser_state->IsOffTheRecord())
     return false;
@@ -164,7 +172,8 @@
   infobars::InfoBarManager* infoBarManager =
       InfoBarManagerImpl::FromWebState(tab.webState);
   DCHECK(infoBarManager);
-  return SyncErrorInfoBarDelegate::Create(infoBarManager, browser_state);
+  return SyncErrorInfoBarDelegate::Create(infoBarManager, browser_state,
+                                          dispatcher);
 }
 
 bool IsTransientSyncError(SyncSetupService::SyncServiceState errorState) {
diff --git a/ios/chrome/browser/ui/tab_switcher/tab_switcher_panel_overlay_view.h b/ios/chrome/browser/ui/tab_switcher/tab_switcher_panel_overlay_view.h
index 3178310..8231eb4 100644
--- a/ios/chrome/browser/ui/tab_switcher/tab_switcher_panel_overlay_view.h
+++ b/ios/chrome/browser/ui/tab_switcher/tab_switcher_panel_overlay_view.h
@@ -7,6 +7,7 @@
 
 #import <UIKit/UIKit.h>
 
+@protocol ApplicationCommands;
 @protocol BrowserCommands;
 
 namespace ios {
@@ -31,11 +32,13 @@
 @interface TabSwitcherPanelOverlayView : UIView
 
 @property(nonatomic, assign) TabSwitcherPanelOverlayType overlayType;
-@property(nonatomic, readonly, weak) id<BrowserCommands> dispatcher;
+@property(nonatomic, readonly, weak) id<ApplicationCommands, BrowserCommands>
+    dispatcher;
 
 - (instancetype)initWithFrame:(CGRect)frame
                  browserState:(ios::ChromeBrowserState*)browserState
-                   dispatcher:(id<BrowserCommands>)dispatcher;
+                   dispatcher:
+                       (id<ApplicationCommands, BrowserCommands>)dispatcher;
 @end
 
 #endif  // IOS_CHROME_BROWSER_UI_TAB_SWITCHER_TAB_SWITCHER_PANEL_OVERLAY_VIEW_H_
diff --git a/ios/chrome/browser/ui/tab_switcher/tab_switcher_panel_overlay_view.mm b/ios/chrome/browser/ui/tab_switcher/tab_switcher_panel_overlay_view.mm
index 8afe95d6b..6de39de 100644
--- a/ios/chrome/browser/ui/tab_switcher/tab_switcher_panel_overlay_view.mm
+++ b/ios/chrome/browser/ui/tab_switcher/tab_switcher_panel_overlay_view.mm
@@ -15,6 +15,7 @@
 #import "ios/chrome/browser/ui/authentication/signin_promo_view_mediator.h"
 #import "ios/chrome/browser/ui/colors/MDCPalette+CrAdditions.h"
 #import "ios/chrome/browser/ui/commands/UIKit+ChromeExecuteCommand.h"
+#import "ios/chrome/browser/ui/commands/application_commands.h"
 #import "ios/chrome/browser/ui/commands/browser_commands.h"
 #import "ios/chrome/browser/ui/commands/open_new_tab_command.h"
 #import "ios/chrome/browser/ui/commands/show_signin_command.h"
@@ -92,7 +93,8 @@
 
 - (instancetype)initWithFrame:(CGRect)frame
                  browserState:(ios::ChromeBrowserState*)browserState
-                   dispatcher:(id<BrowserCommands>)dispatcher {
+                   dispatcher:
+                       (id<ApplicationCommands, BrowserCommands>)dispatcher {
   self = [super initWithFrame:frame];
   if (self) {
     _browserState = browserState;
@@ -448,7 +450,19 @@
 }
 
 - (void)showSyncSettings {
-  [self chromeExecuteCommand:GetSyncCommandForBrowserState(_browserState)];
+  SyncSetupService::SyncServiceState syncState =
+      GetSyncStateForBrowserState(_browserState);
+  if (ShouldShowSyncSignin(syncState)) {
+    [self chromeExecuteCommand:
+              [[ShowSigninCommand alloc]
+                  initWithOperation:AUTHENTICATION_OPERATION_REAUTHENTICATE
+                        accessPoint:signin_metrics::AccessPoint::
+                                        ACCESS_POINT_UNKNOWN]];
+  } else if (ShouldShowSyncSettings(syncState)) {
+    [self.dispatcher showSyncSettings];
+  } else if (ShouldShowSyncPassphraseSettings(syncState)) {
+    [self.dispatcher showSyncPassphraseSettings];
+  }
 }
 
 - (void)sendNewTabCommand:(id)sender {
diff --git a/ios/clean/chrome/browser/ui/adaptor/application_commands_adaptor.mm b/ios/clean/chrome/browser/ui/adaptor/application_commands_adaptor.mm
index 85e4420..515b398 100644
--- a/ios/clean/chrome/browser/ui/adaptor/application_commands_adaptor.mm
+++ b/ios/clean/chrome/browser/ui/adaptor/application_commands_adaptor.mm
@@ -66,12 +66,22 @@
   [self showAlert:@"showReportAnIssue"];
 }
 
+- (void)openURL:(OpenUrlCommand*)command {
+  [self showAlert:@"openURL"];
+}
+
+#pragma mark - ApplicationSettingsCommands
+
 - (void)showAccountsSettings {
   [self showAlert:@"showAccountsSettings"];
 }
 
-- (void)openURL:(OpenUrlCommand*)command {
-  [self showAlert:@"openURL"];
+- (void)showSyncSettings {
+  [self showAlert:@"showSyncSettings"];
+}
+
+- (void)showSyncPassphraseSettings {
+  [self showAlert:@"showSyncPassphraseSettings"];
 }
 
 #pragma mark - Private
diff --git a/ios/tools/coverage/coverage.py b/ios/tools/coverage/coverage.py
index 7863087..dff5c716 100755
--- a/ios/tools/coverage/coverage.py
+++ b/ios/tools/coverage/coverage.py
@@ -458,6 +458,10 @@
                                'based on CPUs availability. Please refer to '
                                '\'ninja -h\' for more details.')
 
+  arg_parser.add_argument('-r', '--reuse-profdata', type=str,
+                          help='Skip building test target and running tests '
+                               'and re-use the specified profile data file.')
+
   arg_parser.add_argument('target', nargs='+',
                           help='The name of the test target to run.')
 
@@ -513,7 +517,10 @@
   if args.filter:
     _AssertFilterPathsExist(args.filter)
 
-  profdata_path = _CreateCoverageProfileDataForTarget(target, jobs)
+  profdata_path = args.reuse_profdata
+  if not profdata_path:
+    profdata_path = _CreateCoverageProfileDataForTarget(target, jobs)
+
   _DisplayLineCoverageReport(target, profdata_path,
                              args.filter or DEFAULT_FILTER_PATHS)
 
diff --git a/ios/web/app/web_main_loop.h b/ios/web/app/web_main_loop.h
index 74218ed..ca18981 100644
--- a/ios/web/app/web_main_loop.h
+++ b/ios/web/app/web_main_loop.h
@@ -86,7 +86,6 @@
 
   // Members initialized in |RunMainMessageLoopParts()| ------------------------
   std::unique_ptr<WebThreadImpl> db_thread_;
-  std::unique_ptr<WebThreadImpl> file_thread_;
   std::unique_ptr<WebThreadImpl> io_thread_;
 
   // Members initialized in |WebThreadsStarted()| --------------------------
diff --git a/ios/web/app/web_main_loop.mm b/ios/web/app/web_main_loop.mm
index b13a6ad..779fcbf1 100644
--- a/ios/web/app/web_main_loop.mm
+++ b/ios/web/app/web_main_loop.mm
@@ -151,11 +151,6 @@
         thread_to_start = &db_thread_;
         options.timer_slack = base::TIMER_SLACK_MAXIMUM;
         break;
-      case WebThread::FILE:
-        thread_to_start = &file_thread_;
-        options = io_message_loop_options;
-        options.timer_slack = base::TIMER_SLACK_MAXIMUM;
-        break;
       case WebThread::IO:
         thread_to_start = &io_thread_;
         options = io_message_loop_options;
@@ -230,9 +225,6 @@
       case WebThread::DB:
         db_thread_.reset();
         break;
-      case WebThread::FILE:
-        file_thread_.reset();
-        break;
       case WebThread::IO:
         io_thread_.reset();
         break;
@@ -244,13 +236,12 @@
     }
   }
 
-  // Close the blocking I/O pool after the other threads. Other threads such
-  // as the I/O thread may need to schedule work like closing files or flushing
-  // data during shutdown, so the blocking pool needs to be available. There
-  // may also be slow operations pending that will block shutdown, so closing
-  // it here (which will block until required operations are complete) gives
-  // more head start for those operations to finish.
-  WebThreadImpl::ShutdownThreadPool();
+  // Shutdown TaskScheduler after the other threads. Other threads such as the
+  // I/O thread may need to schedule work like closing files or flushing data
+  // during shutdown, so TaskScheduler needs to be available. There may also be
+  // slow operations pending that will block shutdown, so closing it here (which
+  // will block until required operations are complete) gives more head start
+  // for those operations to finish.
   base::TaskScheduler::GetInstance()->Shutdown();
 
   URLDataManagerIOS::DeleteDataSources();
diff --git a/ios/web/public/test/test_web_thread_bundle.h b/ios/web/public/test/test_web_thread_bundle.h
index 5325ecca..1785dd7 100644
--- a/ios/web/public/test/test_web_thread_bundle.h
+++ b/ios/web/public/test/test_web_thread_bundle.h
@@ -6,11 +6,11 @@
 #define IOS_WEB_PUBLIC_TEST_TEST_WEB_THREAD_BUNDLE_H_
 
 // TestWebThreadBundle is a convenience class for creating a set of
-// TestWebThreads, a blocking pool, and a task scheduler in unit tests. For
-// most tests, it is sufficient to just instantiate the TestWebThreadBundle as a
-// member variable. It is a good idea to put the TestWebThreadBundle as the
-// first member variable in test classes, so it is destroyed last, and the test
-// threads always exist from the perspective of other classes.
+// TestWebThreads and a task scheduler in unit tests. For most tests, it is
+// sufficient to just instantiate the TestWebThreadBundle as a member variable.
+// It is a good idea to put the TestWebThreadBundle as the first member variable
+// in test classes, so it is destroyed last, and the test threads always exist
+// from the perspective of other classes.
 //
 // By default, all of the created TestWebThreads will be backed by a single
 // shared MessageLoop. If a test truly needs separate threads, it can do so by
@@ -20,8 +20,8 @@
 // To synchronously run tasks posted to TestWebThreads that use the shared
 // MessageLoop, call RunLoop::Run/RunUntilIdle() on the thread where the
 // TestWebThreadBundle lives. The destructor of TestWebThreadBundle runs
-// remaining TestWebThreads tasks, remaining blocking pool tasks, and remaining
-// BLOCK_SHUTDOWN task scheduler tasks.
+// remaining TestWebThreads tasks and remaining BLOCK_SHUTDOWN task scheduler
+// tasks.
 //
 // Some tests using the IO thread expect a MessageLoopForIO. Passing
 // IO_MAINLOOP will use a MessageLoopForIO for the main MessageLoop.
@@ -50,8 +50,7 @@
     DEFAULT = 0,
     IO_MAINLOOP = 1 << 0,
     REAL_DB_THREAD = 1 << 1,
-    REAL_FILE_THREAD = 1 << 2,
-    REAL_IO_THREAD = 1 << 3,
+    REAL_IO_THREAD = 1 << 2,
   };
 
   TestWebThreadBundle();
@@ -65,7 +64,6 @@
   std::unique_ptr<base::test::ScopedTaskEnvironment> scoped_task_environment_;
   std::unique_ptr<TestWebThread> ui_thread_;
   std::unique_ptr<TestWebThread> db_thread_;
-  std::unique_ptr<TestWebThread> file_thread_;
   std::unique_ptr<TestWebThread> io_thread_;
 
   DISALLOW_COPY_AND_ASSIGN(TestWebThreadBundle);
diff --git a/ios/web/public/web_thread.h b/ios/web/public/web_thread.h
index c9df60d..a60b1ba2 100644
--- a/ios/web/public/web_thread.h
+++ b/ios/web/public/web_thread.h
@@ -19,7 +19,6 @@
 
 namespace base {
 class MessageLoop;
-class SequencedWorkerPool;
 }
 
 namespace tracked_objects {
@@ -69,12 +68,8 @@
     // This is the thread that interacts with the database.
     DB,
 
-    // This is the thread that interacts with the file system.
-    FILE,
-
     // This is the thread that processes non-blocking IO, i.e. IPC and network.
-    // Blocking IO should happen on other threads like DB, FILE,
-    // FILE_USER_BLOCKING and CACHE depending on the usage.
+    // Blocking IO should happen in TaskScheduler.
     IO,
 
     // NOTE: do not add new threads here that are only used by a small number of
@@ -132,42 +127,6 @@
     return GetTaskRunnerForThread(identifier)->DeleteSoon(from_here, object);
   }
 
-  // Simplified wrappers for posting to the blocking thread pool. Use this
-  // for doing things like blocking I/O.
-  //
-  // The first variant will run the task in the pool with no sequencing
-  // semantics, so may get run in parallel with other posted tasks. The second
-  // variant will all post a task with no sequencing semantics, and will post a
-  // reply task to the origin TaskRunner upon completion.  The third variant
-  // provides sequencing between tasks with the same sequence token name.
-  //
-  // These tasks are guaranteed to run before shutdown.
-  //
-  // If you need to provide different shutdown semantics (like you have
-  // something slow and noncritical that doesn't need to block shutdown),
-  // or you want to manually provide a sequence token (which saves a map
-  // lookup and is guaranteed unique without you having to come up with a
-  // unique string), you can access the sequenced worker pool directly via
-  // GetBlockingPool().
-  //
-  // If you need to PostTaskAndReplyWithResult, use
-  // base::PostTaskAndReplyWithResult() with GetBlockingPool() as the task
-  // runner.
-  static bool PostBlockingPoolTask(const tracked_objects::Location& from_here,
-                                   base::OnceClosure task);
-  static bool PostBlockingPoolTaskAndReply(
-      const tracked_objects::Location& from_here,
-      base::OnceClosure task,
-      base::OnceClosure reply);
-  static bool PostBlockingPoolSequencedTask(
-      const std::string& sequence_token_name,
-      const tracked_objects::Location& from_here,
-      base::OnceClosure task);
-
-  // Returns the thread pool used for blocking file I/O. Use this object to
-  // perform random blocking operations such as file writes.
-  static base::SequencedWorkerPool* GetBlockingPool() WARN_UNUSED_RESULT;
-
   // Callable on any thread.  Returns whether the given well-known thread is
   // initialized.
   static bool IsThreadInitialized(ID identifier) WARN_UNUSED_RESULT;
@@ -206,11 +165,11 @@
   // Use these templates in conjunction with RefCountedThreadSafe or
   // std::unique_ptr when you want to ensure that an object is deleted on a
   // specific thread. This is needed when an object can hop between threads
-  // (i.e. IO -> FILE -> IO), and thread switching delays can mean that the
-  // final IO tasks executes before the FILE task's stack unwinds.
-  // This would lead to the object destructing on the FILE thread, which often
-  // is not what you want (i.e. to unregister from NotificationService, to
-  // notify other objects on the creating thread etc).
+  // (i.e. IO -> UI -> IO), and thread switching delays can mean that the final
+  // IO tasks executes before the UI task's stack unwinds. This would lead to
+  // the object destructing on the UI thread, which often is not what you want
+  // (i.e. to unregister from NotificationService, to notify other objects on
+  // the creating thread etc).
   template <ID thread>
   struct DeleteOnThread {
     template <typename T>
@@ -247,7 +206,6 @@
   // std::unique_ptr<Foo, web::WebThread::DeleteOnIOThread> ptr;
   struct DeleteOnUIThread : public DeleteOnThread<UI> {};
   struct DeleteOnIOThread : public DeleteOnThread<IO> {};
-  struct DeleteOnFileThread : public DeleteOnThread<FILE> {};
   struct DeleteOnDBThread : public DeleteOnThread<DB> {};
 
  private:
diff --git a/ios/web/test/BUILD.gn b/ios/web/test/BUILD.gn
index 584377f7..fa8bc67f 100644
--- a/ios/web/test/BUILD.gn
+++ b/ios/web/test/BUILD.gn
@@ -60,6 +60,7 @@
     "//ios/web/public/test/fakes",
     "//ios/web/public/test/http_server",
     "//ios/web/test/fakes",
+    "//net",
     "//testing/gtest",
     "//third_party/ocmock",
     "//ui/base",
diff --git a/ios/web/test/test_web_thread_bundle.cc b/ios/web/test/test_web_thread_bundle.cc
index d5e4b3b2..0a36aa9 100644
--- a/ios/web/test/test_web_thread_bundle.cc
+++ b/ios/web/test/test_web_thread_bundle.cc
@@ -10,6 +10,7 @@
 #include "base/test/scoped_task_environment.h"
 #include "ios/web/public/test/test_web_thread.h"
 #include "ios/web/web_thread_impl.h"
+#include "net/disk_cache/simple/simple_backend_impl.h"
 
 namespace web {
 
@@ -22,11 +23,11 @@
 }
 
 TestWebThreadBundle::~TestWebThreadBundle() {
-  // To avoid memory leaks, ensure that any tasks posted to the blocking pool
-  // via PostTaskAndReply are able to reply back to the originating thread, by
-  // flushing the blocking pool while the browser threads still exist.
+  // To avoid memory leaks, ensure that any tasks posted to the cache pool via
+  // PostTaskAndReply are able to reply back to the originating thread, by
+  // flushing the cache pool while the browser threads still exist.
   base::RunLoop().RunUntilIdle();
-  WebThreadImpl::FlushThreadPoolHelperForTesting();
+  disk_cache::SimpleBackendImpl::FlushWorkerPoolForTesting();
 
   // To ensure a clean teardown, each thread's message loop must be flushed
   // just before the thread is destroyed. But destroying a fake thread does not
@@ -35,14 +36,12 @@
   base::RunLoop().RunUntilIdle();
   io_thread_.reset();
   base::RunLoop().RunUntilIdle();
-  file_thread_.reset();
-  base::RunLoop().RunUntilIdle();
   db_thread_.reset();
   base::RunLoop().RunUntilIdle();
-  // This is the point at which the thread pool is normally shut down. So flush
+  // This is the point at which the cache pool is normally shut down. So flush
   // it again in case any shutdown tasks have been posted to the pool from the
   // threads above.
-  WebThreadImpl::FlushThreadPoolHelperForTesting();
+  disk_cache::SimpleBackendImpl::FlushWorkerPoolForTesting();
   base::RunLoop().RunUntilIdle();
   ui_thread_.reset();
   base::RunLoop().RunUntilIdle();
@@ -68,14 +67,6 @@
         new TestWebThread(WebThread::DB, base::MessageLoop::current()));
   }
 
-  if (options & TestWebThreadBundle::REAL_FILE_THREAD) {
-    file_thread_.reset(new TestWebThread(WebThread::FILE));
-    file_thread_->Start();
-  } else {
-    file_thread_.reset(
-        new TestWebThread(WebThread::FILE, base::MessageLoop::current()));
-  }
-
   if (options & TestWebThreadBundle::REAL_IO_THREAD) {
     io_thread_.reset(new TestWebThread(WebThread::IO));
     io_thread_->StartIOThread();
diff --git a/ios/web/web_thread_impl.cc b/ios/web/web_thread_impl.cc
index 9afe46d7..59a0d58 100644
--- a/ios/web/web_thread_impl.cc
+++ b/ios/web/web_thread_impl.cc
@@ -15,10 +15,8 @@
 #include "base/message_loop/message_loop.h"
 #include "base/run_loop.h"
 #include "base/single_thread_task_runner.h"
-#include "base/threading/sequenced_worker_pool.h"
 #include "base/threading/thread_restrictions.h"
 #include "ios/web/public/web_thread_delegate.h"
-#include "net/disk_cache/simple/simple_backend_impl.h"
 #include "net/url_request/url_fetcher.h"
 
 namespace web {
@@ -29,7 +27,6 @@
 const char* const g_web_thread_names[WebThread::ID_COUNT] = {
     "Web_UIThread",                // UI
     "Web_DBThread",                // DB
-    "Web_FileThread",              // FILE
     "Web_IOThread",                // IO
 };
 
@@ -87,11 +84,7 @@
     LAZY_INSTANCE_INITIALIZER;
 
 struct WebThreadGlobals {
-  WebThreadGlobals()
-      : blocking_pool(
-            new base::SequencedWorkerPool(3,
-                                          "WebBlocking",
-                                          base::TaskPriority::USER_VISIBLE)) {
+  WebThreadGlobals() {
     memset(threads, 0, WebThread::ID_COUNT * sizeof(threads[0]));
     memset(thread_delegates, 0,
            WebThread::ID_COUNT * sizeof(thread_delegates[0]));
@@ -110,8 +103,6 @@
   // Only atomic operations are used on this array. The delegates are not owned
   // by this array, rather by whoever calls WebThread::SetDelegate.
   WebThreadDelegate* thread_delegates[WebThread::ID_COUNT];
-
-  const scoped_refptr<base::SequencedWorkerPool> blocking_pool;
 };
 
 base::LazyInstance<WebThreadGlobals>::Leaky g_globals =
@@ -130,26 +121,6 @@
   Initialize();
 }
 
-// static
-void WebThreadImpl::ShutdownThreadPool() {
-  // The goal is to make it impossible to 'infinite loop' during shutdown,
-  // but to reasonably expect that all BLOCKING_SHUTDOWN tasks queued during
-  // shutdown get run. There's nothing particularly scientific about the
-  // number chosen.
-  const int kMaxNewShutdownBlockingTasks = 1000;
-  WebThreadGlobals& globals = g_globals.Get();
-  globals.blocking_pool->Shutdown(kMaxNewShutdownBlockingTasks);
-}
-
-// static
-void WebThreadImpl::FlushThreadPoolHelperForTesting() {
-  // We don't want to create a pool if none exists.
-  if (g_globals == nullptr)
-    return;
-  g_globals.Get().blocking_pool->FlushForTesting();
-  disk_cache::SimpleBackendImpl::FlushWorkerPoolForTesting();
-}
-
 void WebThreadImpl::Init() {
   WebThreadGlobals& globals = g_globals.Get();
 
@@ -184,12 +155,6 @@
   CHECK_GT(line_number, 0);
 }
 
-NOINLINE void WebThreadImpl::FileThreadRun(base::RunLoop* run_loop) {
-  volatile int line_number = __LINE__;
-  Thread::Run(run_loop);
-  CHECK_GT(line_number, 0);
-}
-
 NOINLINE void WebThreadImpl::IOThreadRun(base::RunLoop* run_loop) {
   volatile int line_number = __LINE__;
   Thread::Run(run_loop);
@@ -206,8 +171,6 @@
       return UIThreadRun(run_loop);
     case WebThread::DB:
       return DBThreadRun(run_loop);
-    case WebThread::FILE:
-      return FileThreadRun(run_loop);
     case WebThread::IO:
       return IOThreadRun(run_loop);
     case WebThread::ID_COUNT:
@@ -311,36 +274,6 @@
 }
 
 // static
-bool WebThread::PostBlockingPoolTask(const tracked_objects::Location& from_here,
-                                     base::OnceClosure task) {
-  return g_globals.Get().blocking_pool->PostWorkerTask(from_here,
-                                                       std::move(task));
-}
-
-// static
-bool WebThread::PostBlockingPoolTaskAndReply(
-    const tracked_objects::Location& from_here,
-    base::OnceClosure task,
-    base::OnceClosure reply) {
-  return g_globals.Get().blocking_pool->PostTaskAndReply(
-      from_here, std::move(task), std::move(reply));
-}
-
-// static
-bool WebThread::PostBlockingPoolSequencedTask(
-    const std::string& sequence_token_name,
-    const tracked_objects::Location& from_here,
-    base::OnceClosure task) {
-  return g_globals.Get().blocking_pool->PostNamedSequencedWorkerTask(
-      sequence_token_name, from_here, std::move(task));
-}
-
-// static
-base::SequencedWorkerPool* WebThread::GetBlockingPool() {
-  return g_globals.Get().blocking_pool.get();
-}
-
-// static
 bool WebThread::IsThreadInitialized(ID identifier) {
   if (g_globals == nullptr)
     return false;
diff --git a/ios/web/web_thread_impl.h b/ios/web/web_thread_impl.h
index c2e388b..30d3ff8 100644
--- a/ios/web/web_thread_impl.h
+++ b/ios/web/web_thread_impl.h
@@ -25,8 +25,6 @@
   WebThreadImpl(WebThread::ID identifier, base::MessageLoop* message_loop);
   ~WebThreadImpl() override;
 
-  static void ShutdownThreadPool();
-
  protected:
   void Init() override;
   void Run(base::RunLoop* run_loop) override;
@@ -42,9 +40,6 @@
   // the thread id from the callstack alone in crash dumps.
   void UIThreadRun(base::RunLoop* run_loop);
   void DBThreadRun(base::RunLoop* run_loop);
-  void FileThreadRun(base::RunLoop* run_loop);
-  void FileUserBlockingThreadRun(base::RunLoop* run_loop);
-  void CacheThreadRun(base::RunLoop* run_loop);
   void IOThreadRun(base::RunLoop* run_loop);
 
   static bool PostTaskHelper(WebThread::ID identifier,
@@ -64,7 +59,6 @@
   friend class TestWebThreadBundle;
   friend class TestWebThreadBundleImpl;
   friend class WebTestSuiteListener;
-  static void FlushThreadPoolHelperForTesting();
 
   // The identifier of this thread.  Only one thread can exist with a given
   // identifier at a given time.
diff --git a/media/base/moving_average.cc b/media/base/moving_average.cc
index 985c86e0..e06f744c 100644
--- a/media/base/moving_average.cc
+++ b/media/base/moving_average.cc
@@ -17,8 +17,6 @@
   // exceeds |depth_|.
   base::TimeDelta& oldest = samples_[count_++ % depth_];
   total_ += sample - oldest;
-  square_sum_us_ += sample.InMicroseconds() * sample.InMicroseconds() -
-                    oldest.InMicroseconds() * oldest.InMicroseconds();
   oldest = sample;
   if (sample > max_)
     max_ = sample;
@@ -35,21 +33,25 @@
 
 base::TimeDelta MovingAverage::Deviation() const {
   DCHECK_GT(count_, 0u);
+  const base::TimeDelta average = Average();
+  const uint64_t size = std::min(static_cast<uint64_t>(depth_), count_);
 
-  const double size = std::min(static_cast<uint64_t>(depth_), count_);
-  const double average_us = total_.InMicroseconds() / size;
-  double sqr_deviation_us = square_sum_us_ / size - average_us * average_us;
-  if (sqr_deviation_us < 0)
-    sqr_deviation_us = 0;
+  // Perform the calculation in floating point since squaring the delta can
+  // exceed the bounds of a uint64_t value given two int64_t inputs.
+  double deviation_secs = 0;
+  for (uint64_t i = 0; i < size; ++i) {
+    const double x = (samples_[i] - average).InSecondsF();
+    deviation_secs += x * x;
+  }
 
-  return base::TimeDelta::FromMicroseconds(sqrt(sqr_deviation_us));
+  deviation_secs /= size;
+  return base::TimeDelta::FromSecondsD(std::sqrt(deviation_secs));
 }
 
 void MovingAverage::Reset() {
   count_ = 0;
   total_ = base::TimeDelta();
   max_ = kNoTimestamp;
-  square_sum_us_ = 0;
   std::fill(samples_.begin(), samples_.end(), base::TimeDelta());
 }
 
diff --git a/media/base/moving_average.h b/media/base/moving_average.h
index 70babf8..d8b86e9d 100644
--- a/media/base/moving_average.h
+++ b/media/base/moving_average.h
@@ -31,7 +31,7 @@
   // Returns the current average of all held samples.
   base::TimeDelta Average() const;
 
-  // Returns the standard deviation of all held samples.
+  // Returns the population standard deviation of all held samples.
   base::TimeDelta Deviation() const;
 
   // Resets the state of the class to its initial post-construction state.
@@ -50,7 +50,6 @@
   uint64_t count_ = 0;
 
   base::TimeDelta total_;
-  uint64_t square_sum_us_ = 0;
 
   // Maximum value ever seen.
   base::TimeDelta max_ = kNoTimestamp;
diff --git a/media/formats/webm/webm_parser.cc b/media/formats/webm/webm_parser.cc
index 1fc60f53..8ee800cc 100644
--- a/media/formats/webm/webm_parser.cc
+++ b/media/formats/webm/webm_parser.cc
@@ -985,17 +985,17 @@
 }
 
 bool WebMListParser::IsSiblingOrAncestor(int id_a, int id_b) const {
-  DCHECK((id_a == kWebMIdSegment) || (id_a == kWebMIdCluster));
-
   if (id_a == kWebMIdCluster) {
     // kWebMIdCluster siblings.
     for (size_t i = 0; i < arraysize(kSegmentIds); i++) {
       if (kSegmentIds[i].id_ == id_b)
         return true;
     }
+  } else if (id_a != kWebMIdSegment) {
+    return false;
   }
 
-  // kWebMIdSegment siblings.
+  // kWebMIdSegment sibling or ancestor, respectively; kWebMIdCluster ancestors.
   return ((id_b == kWebMIdSegment) || (id_b == kWebMIdEBMLHeader));
 }
 
diff --git a/media/formats/webm/webm_parser.h b/media/formats/webm/webm_parser.h
index 863da04..90a853b 100644
--- a/media/formats/webm/webm_parser.h
+++ b/media/formats/webm/webm_parser.h
@@ -130,6 +130,10 @@
   bool OnListEnd();
 
   // Checks to see if |id_b| is a sibling or ancestor of |id_a|.
+  // This method is used to determine whether or not a new element |id_b| is a
+  // valid continuation or valid terminator of an unknown-sized list element
+  // |id_a|.  This parser doesn't allow other element types than kWebMIdCluster
+  // or kWebMIdSegment to have unknown size.
   bool IsSiblingOrAncestor(int id_a, int id_b) const;
 
   State state_;
diff --git a/mojo/android/javatests/src/org/chromium/mojo/bindings/BindingsHelperTest.java b/mojo/android/javatests/src/org/chromium/mojo/bindings/BindingsHelperTest.java
index 38bd348..35543bc 100644
--- a/mojo/android/javatests/src/org/chromium/mojo/bindings/BindingsHelperTest.java
+++ b/mojo/android/javatests/src/org/chromium/mojo/bindings/BindingsHelperTest.java
@@ -6,18 +6,23 @@
 
 import android.support.test.filters.SmallTest;
 
-import junit.framework.TestCase;
+import org.junit.Assert;
+import org.junit.Test;
+import org.junit.runner.RunWith;
+
+import org.chromium.base.test.BaseJUnit4ClassRunner;
 
 import java.nio.charset.Charset;
 
 /**
  * Testing {@link BindingsHelper}.
  */
-public class BindingsHelperTest extends TestCase {
-
+@RunWith(BaseJUnit4ClassRunner.class)
+public class BindingsHelperTest {
     /**
      * Testing {@link BindingsHelper#utf8StringSizeInBytes(String)}.
      */
+    @Test
     @SmallTest
     public void testUTF8StringLength() {
         String[] stringsToTest = {
@@ -30,26 +35,27 @@
             "你午饭想吃什么\0éléphant",
         };
         for (String s : stringsToTest) {
-            assertEquals(s.getBytes(Charset.forName("utf8")).length,
+            Assert.assertEquals(s.getBytes(Charset.forName("utf8")).length,
                     BindingsHelper.utf8StringSizeInBytes(s));
         }
-        assertEquals(1, BindingsHelper.utf8StringSizeInBytes("\0"));
+        Assert.assertEquals(1, BindingsHelper.utf8StringSizeInBytes("\0"));
         String s = new StringBuilder().appendCodePoint(0x0).appendCodePoint(0x80)
                 .appendCodePoint(0x800).appendCodePoint(0x10000).toString();
-        assertEquals(10, BindingsHelper.utf8StringSizeInBytes(s));
-        assertEquals(10, s.getBytes(Charset.forName("utf8")).length);
+        Assert.assertEquals(10, BindingsHelper.utf8StringSizeInBytes(s));
+        Assert.assertEquals(10, s.getBytes(Charset.forName("utf8")).length);
     }
 
     /**
      * Testing {@link BindingsHelper#align(int)}.
      */
+    @Test
     @SmallTest
     public void testAlign() {
         for (int i = 0; i < 3 * BindingsHelper.ALIGNMENT; ++i) {
             int j = BindingsHelper.align(i);
-            assertTrue(j >= i);
-            assertTrue(j % BindingsHelper.ALIGNMENT == 0);
-            assertTrue(j - i < BindingsHelper.ALIGNMENT);
+            Assert.assertTrue(j >= i);
+            Assert.assertTrue(j % BindingsHelper.ALIGNMENT == 0);
+            Assert.assertTrue(j - i < BindingsHelper.ALIGNMENT);
         }
     }
 }
diff --git a/mojo/android/javatests/src/org/chromium/mojo/bindings/BindingsTest.java b/mojo/android/javatests/src/org/chromium/mojo/bindings/BindingsTest.java
index d280c77..6a383ac 100644
--- a/mojo/android/javatests/src/org/chromium/mojo/bindings/BindingsTest.java
+++ b/mojo/android/javatests/src/org/chromium/mojo/bindings/BindingsTest.java
@@ -6,8 +6,11 @@
 
 import android.support.test.filters.SmallTest;
 
-import junit.framework.TestCase;
+import org.junit.Assert;
+import org.junit.Test;
+import org.junit.runner.RunWith;
 
+import org.chromium.base.test.BaseJUnit4ClassRunner;
 import org.chromium.mojo.HandleMock;
 import org.chromium.mojo.bindings.test.mojom.imported.Color;
 import org.chromium.mojo.bindings.test.mojom.imported.Point;
@@ -34,8 +37,8 @@
 /**
  * Testing generated classes and associated features.
  */
-public class BindingsTest extends TestCase {
-
+@RunWith(BaseJUnit4ClassRunner.class)
+public class BindingsTest {
     /**
      * Create a new typical Bar instance.
      */
@@ -95,26 +98,27 @@
 
     private static <T> void checkConstantField(
             Field field, Class<T> expectedClass, T value) throws IllegalAccessException {
-        assertEquals(expectedClass, field.getType());
-        assertEquals(Modifier.FINAL, field.getModifiers() & Modifier.FINAL);
-        assertEquals(Modifier.STATIC, field.getModifiers() & Modifier.STATIC);
-        assertEquals(value, field.get(null));
+        Assert.assertEquals(expectedClass, field.getType());
+        Assert.assertEquals(Modifier.FINAL, field.getModifiers() & Modifier.FINAL);
+        Assert.assertEquals(Modifier.STATIC, field.getModifiers() & Modifier.STATIC);
+        Assert.assertEquals(value, field.get(null));
     }
 
     private static <T> void checkField(Field field, Class<T> expectedClass,
             Object object, T value) throws IllegalArgumentException, IllegalAccessException {
-        assertEquals(expectedClass, field.getType());
-        assertEquals(0, field.getModifiers() & Modifier.FINAL);
-        assertEquals(0, field.getModifiers() & Modifier.STATIC);
-        assertEquals(value, field.get(object));
+        Assert.assertEquals(expectedClass, field.getType());
+        Assert.assertEquals(0, field.getModifiers() & Modifier.FINAL);
+        Assert.assertEquals(0, field.getModifiers() & Modifier.STATIC);
+        Assert.assertEquals(value, field.get(object));
     }
 
     /**
      * Testing constants are correctly generated.
      */
+    @Test
     @SmallTest
-    public void testConstants() throws NoSuchFieldException, SecurityException,
-            IllegalAccessException {
+    public void testConstants()
+            throws NoSuchFieldException, SecurityException, IllegalAccessException {
         checkConstantField(SampleServiceConstants.class.getField("TWELVE"), byte.class, (byte) 12);
         checkConstantField(InterfaceConstants.class.getField("LONG"), long.class, 4405L);
     }
@@ -122,9 +126,9 @@
     /**
      * Testing enums are correctly generated.
      */
+    @Test
     @SmallTest
-    public void testEnums() throws NoSuchFieldException, SecurityException,
-            IllegalAccessException {
+    public void testEnums() throws NoSuchFieldException, SecurityException, IllegalAccessException {
         checkConstantField(Color.class.getField("RED"), int.class, 0);
         checkConstantField(Color.class.getField("BLACK"), int.class, 1);
 
@@ -141,9 +145,10 @@
      * @throws IllegalAccessException
      * @throws IllegalArgumentException
      */
+    @Test
     @SmallTest
     public void testStructDefaults() throws NoSuchFieldException, SecurityException,
-            IllegalArgumentException, IllegalAccessException {
+                                            IllegalArgumentException, IllegalAccessException {
         // Check default values.
         DefaultsTest test = new DefaultsTest();
 
@@ -171,7 +176,7 @@
         checkField(DefaultsTest.class.getField("a20"), int.class, test, Bar.Type.BOTH);
         checkField(DefaultsTest.class.getField("a21"), Point.class, test, null);
 
-        assertNotNull(test.a22);
+        Assert.assertNotNull(test.a22);
         checkField(DefaultsTest.class.getField("a22"), Thing.class, test, test.a22);
         checkField(DefaultsTest.class.getField("a23"), long.class, test, -1L);
         checkField(DefaultsTest.class.getField("a24"), long.class, test, 0x123456789L);
@@ -183,9 +188,10 @@
      *
      * @throws IllegalAccessException
      */
+    @Test
     @SmallTest
-    public void testFooGeneration() throws NoSuchFieldException, SecurityException,
-            IllegalAccessException {
+    public void testFooGeneration()
+            throws NoSuchFieldException, SecurityException, IllegalAccessException {
         // Checking Foo constants.
         checkConstantField(Foo.class.getField("FOOBY"), String.class, "Fooby");
 
@@ -193,32 +199,34 @@
         Foo foo = new Foo();
         checkField(Foo.class.getField("name"), String.class, foo, Foo.FOOBY);
 
-        assertNotNull(foo.source);
-        assertFalse(foo.source.isValid());
+        Assert.assertNotNull(foo.source);
+        Assert.assertFalse(foo.source.isValid());
         checkField(Foo.class.getField("source"), MessagePipeHandle.class, foo, foo.source);
     }
 
     /**
      * Testing serialization of the Foo class.
      */
+    @Test
     @SmallTest
     public void testFooSerialization() {
         // Checking serialization and deserialization of a Foo object.
         Foo typicalFoo = createFoo();
         Message serializedFoo = typicalFoo.serialize(null);
         Foo deserializedFoo = Foo.deserialize(serializedFoo);
-        assertEquals(typicalFoo, deserializedFoo);
+        Assert.assertEquals(typicalFoo, deserializedFoo);
     }
 
     /**
      * Testing serialization of the EmptyStruct class.
      */
+    @Test
     @SmallTest
     public void testEmptyStructSerialization() {
         // Checking serialization and deserialization of a EmptyStruct object.
         Message serializedStruct = new EmptyStruct().serialize(null);
         EmptyStruct emptyStruct = EmptyStruct.deserialize(serializedStruct);
-        assertNotNull(emptyStruct);
+        Assert.assertNotNull(emptyStruct);
     }
 
     // In testing maps we want to make sure that the key used when inserting an
@@ -226,16 +234,17 @@
     // has default implementations of equals and hashCode that use reference
     // equality and hashing, respectively, and that's not what we want for our
     // mojom values.
+    @Test
     @SmallTest
     public void testHashMapStructKey() {
         Map<Rect, Integer> map = new HashMap<>();
         map.put(createRect(1, 2, 3, 4), 123);
 
         Rect key = createRect(1, 2, 3, 4);
-        assertNotNull(map.get(key));
-        assertEquals(123, map.get(key).intValue());
+        Assert.assertNotNull(map.get(key));
+        Assert.assertEquals(123, map.get(key).intValue());
 
         map.remove(key);
-        assertTrue(map.isEmpty());
+        Assert.assertTrue(map.isEmpty());
     }
 }
diff --git a/mojo/android/javatests/src/org/chromium/mojo/bindings/CallbacksTest.java b/mojo/android/javatests/src/org/chromium/mojo/bindings/CallbacksTest.java
index 497be65..2e91ee0 100644
--- a/mojo/android/javatests/src/org/chromium/mojo/bindings/CallbacksTest.java
+++ b/mojo/android/javatests/src/org/chromium/mojo/bindings/CallbacksTest.java
@@ -6,8 +6,11 @@
 
 import android.support.test.filters.SmallTest;
 
-import junit.framework.TestCase;
+import org.junit.Assert;
+import org.junit.Test;
+import org.junit.runner.RunWith;
 
+import org.chromium.base.test.BaseJUnit4ClassRunner;
 import org.chromium.mojo.bindings.Callbacks.Callback1;
 import org.chromium.mojo.bindings.Callbacks.Callback7;
 
@@ -18,11 +21,12 @@
 /**
  * Testing generated callbacks
  */
-public class CallbacksTest extends TestCase {
-
+@RunWith(BaseJUnit4ClassRunner.class)
+public class CallbacksTest {
     /**
      * Testing {@link Callback1}.
      */
+    @Test
     @SmallTest
     public void testCallback1() {
         final List<Integer> parameters = new ArrayList<Integer>();
@@ -32,12 +36,13 @@
                 parameters.add(i1);
             }
         }.call(1);
-        assertEquals(Arrays.asList(1), parameters);
+        Assert.assertEquals(Arrays.asList(1), parameters);
     }
 
     /**
      * Testing {@link Callback7}.
      */
+    @Test
     @SmallTest
     public void testCallback7() {
         final List<Integer> parameters = new ArrayList<Integer>();
@@ -54,6 +59,6 @@
                 parameters.add(i7);
             }
         }.call(1, 2, 3, 4, 5, 6, 7);
-        assertEquals(Arrays.asList(1, 2, 3, 4, 5, 6, 7), parameters);
+        Assert.assertEquals(Arrays.asList(1, 2, 3, 4, 5, 6, 7), parameters);
     }
 }
diff --git a/mojo/android/javatests/src/org/chromium/mojo/bindings/MessageHeaderTest.java b/mojo/android/javatests/src/org/chromium/mojo/bindings/MessageHeaderTest.java
index b2e6ac8..3d53f60 100644
--- a/mojo/android/javatests/src/org/chromium/mojo/bindings/MessageHeaderTest.java
+++ b/mojo/android/javatests/src/org/chromium/mojo/bindings/MessageHeaderTest.java
@@ -6,18 +6,22 @@
 
 import android.support.test.filters.SmallTest;
 
-import junit.framework.TestCase;
+import org.junit.Assert;
+import org.junit.Test;
+import org.junit.runner.RunWith;
 
+import org.chromium.base.test.BaseJUnit4ClassRunner;
 import org.chromium.mojo.bindings.test.mojom.imported.Point;
 
 /**
  * Testing internal classes of interfaces.
  */
-public class MessageHeaderTest extends TestCase {
-
+@RunWith(BaseJUnit4ClassRunner.class)
+public class MessageHeaderTest {
     /**
      * Testing that headers are identical after being serialized/deserialized.
      */
+    @Test
     @SmallTest
     public void testSimpleMessageHeader() {
         final int xValue = 1;
@@ -29,19 +33,20 @@
         ServiceMessage message = p.serializeWithHeader(null, new MessageHeader(type));
 
         MessageHeader header = message.getHeader();
-        assertTrue(header.validateHeader(type, 0));
-        assertEquals(type, header.getType());
-        assertEquals(0, header.getFlags());
+        Assert.assertTrue(header.validateHeader(type, 0));
+        Assert.assertEquals(type, header.getType());
+        Assert.assertEquals(0, header.getFlags());
 
         Point p2 = Point.deserialize(message.getPayload());
-        assertNotNull(p2);
-        assertEquals(p.x, p2.x);
-        assertEquals(p.y, p2.y);
+        Assert.assertNotNull(p2);
+        Assert.assertEquals(p.x, p2.x);
+        Assert.assertEquals(p.y, p2.y);
     }
 
     /**
      * Testing that headers are identical after being serialized/deserialized.
      */
+    @Test
     @SmallTest
     public void testMessageWithRequestIdHeader() {
         final int xValue = 1;
@@ -56,14 +61,14 @@
         message.setRequestId(requestId);
 
         MessageHeader header = message.getHeader();
-        assertTrue(header.validateHeader(type, MessageHeader.MESSAGE_EXPECTS_RESPONSE_FLAG));
-        assertEquals(type, header.getType());
-        assertEquals(MessageHeader.MESSAGE_EXPECTS_RESPONSE_FLAG, header.getFlags());
-        assertEquals(requestId, header.getRequestId());
+        Assert.assertTrue(header.validateHeader(type, MessageHeader.MESSAGE_EXPECTS_RESPONSE_FLAG));
+        Assert.assertEquals(type, header.getType());
+        Assert.assertEquals(MessageHeader.MESSAGE_EXPECTS_RESPONSE_FLAG, header.getFlags());
+        Assert.assertEquals(requestId, header.getRequestId());
 
         Point p2 = Point.deserialize(message.getPayload());
-        assertNotNull(p2);
-        assertEquals(p.x, p2.x);
-        assertEquals(p.y, p2.y);
+        Assert.assertNotNull(p2);
+        Assert.assertEquals(p.x, p2.x);
+        Assert.assertEquals(p.y, p2.y);
     }
 }
diff --git a/mojo/android/javatests/src/org/chromium/mojo/bindings/SerializationTest.java b/mojo/android/javatests/src/org/chromium/mojo/bindings/SerializationTest.java
index 2c17e3a..5ee6743b 100644
--- a/mojo/android/javatests/src/org/chromium/mojo/bindings/SerializationTest.java
+++ b/mojo/android/javatests/src/org/chromium/mojo/bindings/SerializationTest.java
@@ -6,8 +6,11 @@
 
 import android.support.test.filters.SmallTest;
 
-import junit.framework.TestCase;
+import org.junit.Assert;
+import org.junit.Test;
+import org.junit.runner.RunWith;
 
+import org.chromium.base.test.BaseJUnit4ClassRunner;
 import org.chromium.mojo.HandleMock;
 import org.chromium.mojo.bindings.test.mojom.mojo.Struct1;
 import org.chromium.mojo.bindings.test.mojom.mojo.Struct2;
@@ -23,12 +26,12 @@
  * Tests for the serialization logic of the generated structs, using structs defined in
  * mojo/public/interfaces/bindings/tests/serialization_test_structs.mojom .
  */
-public class SerializationTest extends TestCase {
-
+@RunWith(BaseJUnit4ClassRunner.class)
+public class SerializationTest {
     private static void assertThrowsSerializationException(Struct struct) {
         try {
             struct.serialize(null);
-            fail("Serialization of invalid struct should have thrown an exception.");
+            Assert.fail("Serialization of invalid struct should have thrown an exception.");
         } catch (SerializationException ex) {
             // Expected.
         }
@@ -38,10 +41,11 @@
      * Verifies that serializing a struct with an invalid handle of a non-nullable type throws an
      * exception.
      */
+    @Test
     @SmallTest
     public void testHandle() {
         Struct2 struct = new Struct2();
-        assertFalse(struct.hdl.isValid());
+        Assert.assertFalse(struct.hdl.isValid());
         assertThrowsSerializationException(struct);
 
         // Make the struct valid and verify that it serializes without an exception.
@@ -52,10 +56,11 @@
     /**
      * Verifies that serializing a struct with a null struct pointer throws an exception.
      */
+    @Test
     @SmallTest
     public void testStructPointer() {
         Struct3 struct = new Struct3();
-        assertNull(struct.struct1);
+        Assert.assertNull(struct.struct1);
         assertThrowsSerializationException(struct);
 
         // Make the struct valid and verify that it serializes without an exception.
@@ -67,10 +72,11 @@
      * Verifies that serializing a struct with an array of structs throws an exception when the
      * struct is invalid.
      */
+    @Test
     @SmallTest
     public void testStructArray() {
         Struct4 struct = new Struct4();
-        assertNull(struct.data);
+        Assert.assertNull(struct.data);
         assertThrowsSerializationException(struct);
 
         // Create the (1-element) array but have the element null.
@@ -86,10 +92,11 @@
      * Verifies that serializing a struct with a fixed-size array of incorrect length throws an
      * exception.
      */
+    @Test
     @SmallTest
     public void testFixedSizeArray() {
         Struct5 struct = new Struct5();
-        assertNull(struct.pair);
+        Assert.assertNull(struct.pair);
         assertThrowsSerializationException(struct);
 
         // Create the (1-element) array, 2-element array is required.
@@ -107,10 +114,11 @@
     /**
      * Verifies that serializing a struct with a null string throws an exception.
      */
+    @Test
     @SmallTest
     public void testString() {
         Struct6 struct = new Struct6();
-        assertNull(struct.str);
+        Assert.assertNull(struct.str);
         assertThrowsSerializationException(struct);
 
         // Make the struct valid and verify that it serializes without an exception.
@@ -122,18 +130,20 @@
      * Verifies that a struct with an invalid nullable handle, null nullable struct pointer and null
      * nullable string serializes without an exception.
      */
+    @Test
     @SmallTest
     public void testNullableFields() {
         StructOfNullables struct = new StructOfNullables();
-        assertFalse(struct.hdl.isValid());
-        assertNull(struct.struct1);
-        assertNull(struct.str);
+        Assert.assertFalse(struct.hdl.isValid());
+        Assert.assertNull(struct.struct1);
+        Assert.assertNull(struct.str);
         struct.serialize(null);
     }
 
     /**
      * Verifies that a struct can be serialized to and deserialized from a ByteBuffer.
      */
+    @Test
     @SmallTest
     public void testByteBufferSerialization() {
         Struct1 input = new Struct1();
@@ -143,21 +153,22 @@
 
         byte[] expected_raw_bytes = {16, 0, 0, 0, 0, 0, 0, 0, 0x7F, 0, 0, 0, 0, 0, 0, 0};
         ByteBuffer expected_buf = ByteBuffer.wrap(expected_raw_bytes);
-        assertEquals(expected_buf, buf);
+        Assert.assertEquals(expected_buf, buf);
 
         Struct1 output = Struct1.deserialize(buf);
-        assertEquals(0x7F, output.i);
+        Assert.assertEquals(0x7F, output.i);
     }
 
     /**
      * Verifies that a struct with handles cannot be serialized to a ByteBuffer.
      */
+    @Test
     @SmallTest
     public void testByteBufferSerializationWithHandles() {
         StructOfNullables struct = new StructOfNullables();
-        assertFalse(struct.hdl.isValid());
-        assertNull(struct.struct1);
-        assertNull(struct.str);
+        Assert.assertFalse(struct.hdl.isValid());
+        Assert.assertNull(struct.struct1);
+        Assert.assertNull(struct.str);
 
         // It is okay to serialize invalid handles.
         struct.serialize();
@@ -166,7 +177,7 @@
 
         try {
             struct.serialize();
-            fail("Serializing a struct with handles to a ByteBuffer should have thrown an "
+            Assert.fail("Serializing a struct with handles to a ByteBuffer should have thrown an "
                     + "exception.");
         } catch (UnsupportedOperationException ex) {
             // Expected.
diff --git a/net/socket/socket.cc b/net/socket/socket.cc
index 4e9cf3f..987cc9a 100644
--- a/net/socket/socket.cc
+++ b/net/socket/socket.cc
@@ -9,7 +9,7 @@
 namespace net {
 
 const base::Feature Socket::kReadIfReadyExperiment{
-    "SocketReadIfReady", base::FEATURE_DISABLED_BY_DEFAULT};
+    "SocketReadIfReady", base::FEATURE_ENABLED_BY_DEFAULT};
 
 int Socket::ReadIfReady(IOBuffer* buf,
                         int buf_len,
diff --git a/net/socket/socket_bio_adapter_unittest.cc b/net/socket/socket_bio_adapter_unittest.cc
index bedf28da6..9fe18cb 100644
--- a/net/socket/socket_bio_adapter_unittest.cc
+++ b/net/socket/socket_bio_adapter_unittest.cc
@@ -41,10 +41,12 @@
                              public SocketBIOAdapter::Delegate {
  protected:
   void SetUp() override {
-    if (GetParam() != READ_IF_READY_DISABLED)
-      scoped_feature_list_.InitAndEnableFeature(Socket::kReadIfReadyExperiment);
-    if (GetParam() == READ_IF_READY_ENABLED_SUPPORTED)
+    if (GetParam() == READ_IF_READY_DISABLED) {
+      scoped_feature_list_.InitAndDisableFeature(
+          Socket::kReadIfReadyExperiment);
+    } else if (GetParam() == READ_IF_READY_ENABLED_SUPPORTED) {
       factory_.set_enable_read_if_ready(true);
+    }
   }
 
   std::unique_ptr<StreamSocket> MakeTestSocket(SocketDataProvider* data) {
diff --git a/net/socket/ssl_client_socket_unittest.cc b/net/socket/ssl_client_socket_unittest.cc
index d33a4d6..112959e 100644
--- a/net/socket/ssl_client_socket_unittest.cc
+++ b/net/socket/ssl_client_socket_unittest.cc
@@ -1008,8 +1008,10 @@
       : SSLClientSocketTest(), read_if_ready_enabled_(GetParam()) {}
 
   void SetUp() override {
-    if (read_if_ready_enabled())
-      scoped_feature_list_.InitAndEnableFeature(Socket::kReadIfReadyExperiment);
+    if (!read_if_ready_enabled()) {
+      scoped_feature_list_.InitAndDisableFeature(
+          Socket::kReadIfReadyExperiment);
+    }
   }
 
   // Convienient wrapper to call Read()/ReadIfReady() depending on whether
diff --git a/net/spdy/chromium/spdy_session_unittest.cc b/net/spdy/chromium/spdy_session_unittest.cc
index e94de4c..9729d805 100644
--- a/net/spdy/chromium/spdy_session_unittest.cc
+++ b/net/spdy/chromium/spdy_session_unittest.cc
@@ -5543,10 +5543,12 @@
       public testing::WithParamInterface<ReadIfReadySupport> {
  public:
   void SetUp() override {
-    if (GetParam() != READ_IF_READY_DISABLED)
-      scoped_feature_list_.InitAndEnableFeature(Socket::kReadIfReadyExperiment);
-    if (GetParam() == READ_IF_READY_ENABLED_SUPPORTED)
+    if (GetParam() == READ_IF_READY_DISABLED) {
+      scoped_feature_list_.InitAndDisableFeature(
+          Socket::kReadIfReadyExperiment);
+    } else if (GetParam() == READ_IF_READY_ENABLED_SUPPORTED) {
       session_deps_.socket_factory->set_enable_read_if_ready(true);
+    }
     SpdySessionTest::SetUp();
   }
 
diff --git a/pdf/document_loader.cc b/pdf/document_loader.cc
index b9728eeb..8fbe12fc 100644
--- a/pdf/document_loader.cc
+++ b/pdf/document_loader.cc
@@ -381,7 +381,6 @@
 
 void DocumentLoader::DidOpen(int32_t result) {
   if (result != PP_OK) {
-    NOTREACHED();
     client_->OnDocumentFailed();
     return;
   }
diff --git a/testing/variations/fieldtrial_testing_config.json b/testing/variations/fieldtrial_testing_config.json
index 9620a8f..039f764 100644
--- a/testing/variations/fieldtrial_testing_config.json
+++ b/testing/variations/fieldtrial_testing_config.json
@@ -1206,7 +1206,7 @@
                 {
                     "name": "Enabled",
                     "params": {
-                        "engagement_threshold_for_flash": "32"
+                        "engagement_threshold_for_flash": "64"
                     },
                     "enable_features": [
                         "PreferHtmlOverPlugins"
diff --git a/third_party/WebKit/LayoutTests/FlagExpectations/enable-blink-features=LayoutNG b/third_party/WebKit/LayoutTests/FlagExpectations/enable-blink-features=LayoutNG
index a1c03f3..d4150e8e 100644
--- a/third_party/WebKit/LayoutTests/FlagExpectations/enable-blink-features=LayoutNG
+++ b/third_party/WebKit/LayoutTests/FlagExpectations/enable-blink-features=LayoutNG
@@ -11,6 +11,10 @@
 crbug.com/714962 editing/pasteboard/19644-2.html [ Failure ]
 crbug.com/714962 editing/text-iterator/findString-restarts-at-last-position.html [ Failure ]
 
+# TODO(editing-dev): Investigate why a BR is left in the editable container when
+# LayoutNG is enabled, but not when disabled.
+crbug.com/707656 editing/deleting/in-visibly-empty-root.html [ Failure ]
+
 # New failures are appended below by the script.
 crbug.com/591099 accessibility/accessibility-hit-test-crash.html [ Failure Pass ]
 crbug.com/591099 accessibility/accessibility-node-memory-management.html [ Failure Pass ]
diff --git a/third_party/WebKit/LayoutTests/TestExpectations b/third_party/WebKit/LayoutTests/TestExpectations
index e39574f6..8497bdcd 100644
--- a/third_party/WebKit/LayoutTests/TestExpectations
+++ b/third_party/WebKit/LayoutTests/TestExpectations
@@ -3169,7 +3169,6 @@
 crbug.com/755405 [ Android ] external/wpt/cssom/cssom-cssText-serialize.html [ Failure ]
 crbug.com/755405 [ Android ] external/wpt/cssom/medialist-interfaces-004.html [ Failure ]
 crbug.com/755405 [ Android ] external/wpt/cssom-view/cssom-view-window-screen-interface.html [ Failure ]
-crbug.com/755405 [ Android ] external/wpt/cssom-view/ttwf-scrollintoview.html [ Failure ]
 crbug.com/755405 [ Android ] external/wpt/cssom-view/cssom-view/media-query-list-interface.xht [ Failure ]
 crbug.com/755405 [ Android ] external/wpt/custom-elements/HTMLElement-constructor.html [ Failure ]
 crbug.com/755405 [ Android ] external/wpt/custom-elements/parser/parser-constructs-custom-element-in-document-write.html [ Failure ]
@@ -3674,3 +3673,4 @@
 # Sheriff failures 2017-09-11
 crbug.com/763809 [ Win7 Debug ] fast/multicol/nested-very-tall-inside-short-crash.html [ Pass Failure Timeout ]
 crbug.com/763810 [ Win7 Debug ] virtual/threaded/transitions/transition-end-event-nested.html [ Pass Failure ]
+crbug.com/763975 [ Linux Debug ] webaudio/internals/cycle-connection-gc.html [ Pass Failure ]
\ No newline at end of file
diff --git a/third_party/WebKit/LayoutTests/VirtualTestSuites b/third_party/WebKit/LayoutTests/VirtualTestSuites
index f8299d4a..ee8a64e 100644
--- a/third_party/WebKit/LayoutTests/VirtualTestSuites
+++ b/third_party/WebKit/LayoutTests/VirtualTestSuites
@@ -2,7 +2,8 @@
   {
     "prefix": "color_space",
     "base": "fast/canvas/color-space",
-    "args": ["--enable-blink-features=ColorCanvasExtensions"]
+    "args": ["--enable-blink-features=ColorCanvasExtensions",
+             "--force-color-profile=srgb"]
   },
   {
     "prefix": "gpu",
diff --git a/third_party/WebKit/LayoutTests/editing/selection/offset-from-point-expected.txt b/third_party/WebKit/LayoutTests/editing/selection/offset-from-point-expected.txt
index 315aab4..a53ede52 100644
--- a/third_party/WebKit/LayoutTests/editing/selection/offset-from-point-expected.txt
+++ b/third_party/WebKit/LayoutTests/editing/selection/offset-from-point-expected.txt
@@ -1,7 +1,11 @@
 12 345 6789
+
 12 345 6789
+
 12 345 6789
+
 12 345 6789
+
 LTR
 0=-1 (-1)
 1=11 (12)
diff --git a/third_party/WebKit/LayoutTests/external/WPT_BASE_MANIFEST.json b/third_party/WebKit/LayoutTests/external/WPT_BASE_MANIFEST.json
index 9f504d9..133e38c5 100644
--- a/third_party/WebKit/LayoutTests/external/WPT_BASE_MANIFEST.json
+++ b/third_party/WebKit/LayoutTests/external/WPT_BASE_MANIFEST.json
@@ -97414,6 +97414,11 @@
      {}
     ]
    ],
+   "cssom-view/scrollintoview-expected.txt": [
+    [
+     {}
+    ]
+   ],
    "cssom-view/support/1x1-green.png": [
     [
      {}
@@ -140870,15 +140875,15 @@
      {}
     ]
    ],
-   "cssom-view/ttwf-js-cssomview-getclientrects-length.html": [
+   "cssom-view/scrollintoview.html": [
     [
-     "/cssom-view/ttwf-js-cssomview-getclientrects-length.html",
+     "/cssom-view/scrollintoview.html",
      {}
     ]
    ],
-   "cssom-view/ttwf-scrollintoview.html": [
+   "cssom-view/ttwf-js-cssomview-getclientrects-length.html": [
     [
-     "/cssom-view/ttwf-scrollintoview.html",
+     "/cssom-view/ttwf-js-cssomview-getclientrects-length.html",
      {}
     ]
    ],
@@ -247661,6 +247666,14 @@
    "e3bc7ab9a646c1275e5dab9394df97d72ef8a42e",
    "testharness"
   ],
+  "cssom-view/scrollintoview-expected.txt": [
+   "abe5aed0abbce1de3b0fdfb436f3784d71349f47",
+   "support"
+  ],
+  "cssom-view/scrollintoview.html": [
+   "6ff3bd8afc87c9f678115e18d3ff8b5331f81c00",
+   "testharness"
+  ],
   "cssom-view/support/1x1-green.png": [
    "51e7b6974a09eda6cb31337717c5eaeb9c44b443",
    "support"
@@ -247841,10 +247854,6 @@
    "7f3440e65abbe692e3c28f1f1d04671054ecc815",
    "testharness"
   ],
-  "cssom-view/ttwf-scrollintoview.html": [
-   "55d874f53db3c8ed03fff063584eecbcda10d2ce",
-   "testharness"
-  ],
   "cssom-view/window-screen-height-immutable.html": [
    "3193a200624217a260e17660006e9ce31a52814c",
    "testharness"
@@ -290926,7 +290935,7 @@
    "testharness"
   ],
   "service-workers/service-worker/link-element-register-security-error.https-expected.txt": [
-   "00fdefa383b6af7b40390df922a7a9e0baea168b",
+   "4d32a8b5a3a95d0a26c9ba315bfa37572cadeebc",
    "support"
   ],
   "service-workers/service-worker/link-element-register-security-error.https.html": [
diff --git a/third_party/WebKit/LayoutTests/external/wpt/cssom-view/scrollintoview-expected.txt b/third_party/WebKit/LayoutTests/external/wpt/cssom-view/scrollintoview-expected.txt
new file mode 100644
index 0000000..b1a475b
--- /dev/null
+++ b/third_party/WebKit/LayoutTests/external/wpt/cssom-view/scrollintoview-expected.txt
@@ -0,0 +1,43 @@
+This is a testharness.js-based test.
+PASS scrollIntoView() starting at left,top
+PASS scrollIntoView() starting at left,bottom
+PASS scrollIntoView() starting at right,top
+PASS scrollIntoView() starting at right,bottom
+PASS scrollIntoView(true) starting at left,top
+PASS scrollIntoView(true) starting at left,bottom
+PASS scrollIntoView(true) starting at right,top
+PASS scrollIntoView(true) starting at right,bottom
+PASS scrollIntoView(false) starting at left,top
+PASS scrollIntoView(false) starting at left,bottom
+PASS scrollIntoView(false) starting at right,top
+PASS scrollIntoView(false) starting at right,bottom
+PASS scrollIntoView(undefined) starting at left,top
+PASS scrollIntoView(undefined) starting at left,bottom
+PASS scrollIntoView(undefined) starting at right,top
+PASS scrollIntoView(undefined) starting at right,bottom
+FAIL scrollIntoView(null) starting at left,top assert_approx_equals: scrollX expected 3400 +/- 0.5 but got 3700
+FAIL scrollIntoView(null) starting at left,bottom assert_approx_equals: scrollX expected 3400 +/- 0.5 but got 3700
+FAIL scrollIntoView(null) starting at right,top assert_approx_equals: scrollX expected 4000 +/- 0.5 but got 3700
+FAIL scrollIntoView(null) starting at right,bottom assert_approx_equals: scrollX expected 4000 +/- 0.5 but got 3700
+FAIL scrollIntoView({}) starting at left,top assert_approx_equals: scrollX expected 3400 +/- 0.5 but got 3700
+FAIL scrollIntoView({}) starting at left,bottom assert_approx_equals: scrollX expected 3400 +/- 0.5 but got 3700
+FAIL scrollIntoView({}) starting at right,top assert_approx_equals: scrollX expected 4000 +/- 0.5 but got 3700
+FAIL scrollIntoView({}) starting at right,bottom assert_approx_equals: scrollX expected 4000 +/- 0.5 but got 3700
+PASS scrollIntoView({block: "center", inline: "center"}) starting at left,top
+PASS scrollIntoView({block: "center", inline: "center"}) starting at left,bottom
+PASS scrollIntoView({block: "center", inline: "center"}) starting at right,top
+PASS scrollIntoView({block: "center", inline: "center"}) starting at right,bottom
+PASS scrollIntoView({block: "start", inline: "start"}) starting at left,top
+PASS scrollIntoView({block: "start", inline: "start"}) starting at left,bottom
+PASS scrollIntoView({block: "start", inline: "start"}) starting at right,top
+PASS scrollIntoView({block: "start", inline: "start"}) starting at right,bottom
+PASS scrollIntoView({block: "end", inline: "end"}) starting at left,top
+PASS scrollIntoView({block: "end", inline: "end"}) starting at left,bottom
+PASS scrollIntoView({block: "end", inline: "end"}) starting at right,top
+PASS scrollIntoView({block: "end", inline: "end"}) starting at right,bottom
+PASS scrollIntoView({block: "nearest", inline: "nearest"}) starting at left,top
+PASS scrollIntoView({block: "nearest", inline: "nearest"}) starting at left,bottom
+PASS scrollIntoView({block: "nearest", inline: "nearest"}) starting at right,top
+PASS scrollIntoView({block: "nearest", inline: "nearest"}) starting at right,bottom
+Harness: the test ran to completion.
+
diff --git a/third_party/WebKit/LayoutTests/external/wpt/cssom-view/scrollintoview.html b/third_party/WebKit/LayoutTests/external/wpt/cssom-view/scrollintoview.html
new file mode 100644
index 0000000..c69025b
--- /dev/null
+++ b/third_party/WebKit/LayoutTests/external/wpt/cssom-view/scrollintoview.html
@@ -0,0 +1,112 @@
+<!DOCTYPE html>
+<title>CSSOM View - scrollIntoView</title>
+<meta charset="utf-8">
+<link rel="author" title="Chris Wu" href="mailto:pwx.frontend@gmail.com">
+<link rel="help" href="https://drafts.csswg.org/cssom-view/#dom-element-scrollintoview">
+<link rel="help" href="https://heycam.github.io/webidl/#es-operations">
+<link rel="help" href="https://heycam.github.io/webidl/#es-overloads">
+<meta name="flags" content="dom">
+<script src="/resources/testharness.js"></script>
+<script src="/resources/testharnessreport.js"></script>
+<style>
+body.running { margin: 0; padding: 4000px; overflow: hidden }
+body.running #testDiv {
+  width: 200px;
+  height: 200px;
+  background-color: lightgreen;
+}
+</style>
+<body class=running>
+<div id=testDiv></div>
+<div id="log"></div>
+<script>
+var testDiv = document.getElementById('testDiv');
+
+var expectedXLeft = 4000;
+var expectedXRight = 4000 - window.innerWidth + testDiv.clientWidth;
+var expectedXCenter = 4000 - (window.innerWidth / 2) + (testDiv.clientWidth / 2);
+
+var expectedYTop = 4000;
+var expectedYBottom = 4000 - window.innerHeight + testDiv.clientHeight;
+var expectedYCenter = 4000 - (window.innerHeight / 2) + (testDiv.clientHeight / 2);
+
+[
+  ["omitted argument", "nearest", expectedYTop],
+  [true, "nearest", expectedYTop],
+  [false, "nearest", expectedYBottom],
+  [undefined, "nearest", expectedYTop],
+  [null, "nearest", expectedYTop],
+  [{}, "nearest", expectedYTop],
+  [{block: "center", inline: "center"}, expectedXCenter, expectedYCenter],
+  [{block: "start", inline: "start"}, expectedXLeft, expectedYTop],
+  [{block: "end", inline: "end"}, expectedXRight, expectedYBottom],
+  [{block: "nearest", inline: "nearest"}, "nearest", "nearest"],
+].forEach(([input, expectedX, expectedY]) => {
+  test(() => {
+    window.scrollTo(0, 0);
+    testScrollIntoView(input);
+    var x = (expectedX === "nearest") ? expectedXRight : expectedX;
+    var y = (expectedY === "nearest") ? expectedYBottom : expectedY;
+    assert_approx_equals(window.scrollX, x, 0.5, 'scrollX');
+    assert_approx_equals(window.scrollY, y, 0.5, 'scrollY');
+  }, `scrollIntoView(${format_input(input)}) starting at left,top`);
+
+  test(() => {
+    window.scrollTo(0, 12000);
+    testScrollIntoView(input);
+    var x = (expectedX === "nearest") ? expectedXRight : expectedX;
+    var y = (expectedY === "nearest") ? expectedYTop : expectedY;
+    assert_approx_equals(window.scrollX, x, 0.5, 'scrollX');
+    assert_approx_equals(window.scrollY, y, 0.5, 'scrollY');
+  }, `scrollIntoView(${format_input(input)}) starting at left,bottom`);
+
+  test(() => {
+    window.scrollTo(12000, 0);
+    testScrollIntoView(input);
+    var x = (expectedX === "nearest") ? expectedXLeft : expectedX;
+    var y = (expectedY === "nearest") ? expectedYBottom : expectedY;
+    assert_approx_equals(window.scrollX, x, 0.5, 'scrollX');
+    assert_approx_equals(window.scrollY, y, 0.5, 'scrollY');
+  }, `scrollIntoView(${format_input(input)}) starting at right,top`);
+
+  test(() => {
+    window.scrollTo(12000, 12000);
+    testScrollIntoView(input);
+    var x = (expectedX === "nearest") ? expectedXLeft : expectedX;
+    var y = (expectedY === "nearest") ? expectedYTop : expectedY;
+    assert_approx_equals(window.scrollX, x, 0.5, 'scrollX');
+    assert_approx_equals(window.scrollY, y, 0.5, 'scrollY');
+  }, `scrollIntoView(${format_input(input)}) starting at right,bottom`);
+});
+
+function testScrollIntoView(input) {
+  if (input === "omitted argument") {
+    testDiv.scrollIntoView();
+  } else {
+    testDiv.scrollIntoView(input);
+  }
+}
+
+// This formats dict as a string suitable as test name.
+// format_value() is provided by testharness.js,
+// which also preserves sign for -0.
+function format_dict(dict) {
+  const props = [];
+  for (let prop in dict) {
+    props.push(`${prop}: ${format_value(dict[prop])}`);
+  }
+  return `{${props.join(', ')}}`;
+}
+
+function format_input(input) {
+  if (input === "omitted argument") {
+    return "";
+  } else if (input === null || typeof input !== "object") {
+    return format_value(input);
+  }
+  return format_dict(input);
+}
+
+document.body.classList.remove('running');
+window.scrollTo(0, 0);
+</script>
diff --git a/third_party/WebKit/LayoutTests/external/wpt/cssom-view/ttwf-scrollintoview.html b/third_party/WebKit/LayoutTests/external/wpt/cssom-view/ttwf-scrollintoview.html
deleted file mode 100644
index 1ccb9c5..0000000
--- a/third_party/WebKit/LayoutTests/external/wpt/cssom-view/ttwf-scrollintoview.html
+++ /dev/null
@@ -1,32 +0,0 @@
-<!DOCTYPE html>
-<html>
-<head>
-    <title>CSSOM View - 6 - scrollIntoView tests</title>
-    <meta charset="utf-8">
-    <link rel="author" title="Chris Wu" href="mailto:pwx.frontend@gmail.com">
-    <link rel="help" href="http://www.w3.org/TR/cssom-view/#dom-element-scrollintoview">
-    <meta name="flags" content="dom">
-    <script src="/resources/testharness.js"></script>
-    <script src="/resources/testharnessreport.js"></script>
-    <style type="text/css">
-        #phitem{height: 2000px;}
-        #viewitem{width:300px;height:200px;margin:0 auto;background-color: lightgreen;}
-    </style>
-</head>
-<body>
-    <div id="myDiv">
-        <div id="phitem"></div>
-        <div id="viewitem"></div>
-    </div>
-    <div id="log"></div>
-    <script>
-        var asytest = async_test('check scrollIntoView');
-        asytest.step(function(){
-            var viewitem = document.getElementById('viewitem');
-            viewitem.scrollIntoView();
-            assert_true(window.pageYOffset + window.innerHeight > viewitem.offsetTop, "The element isn't in the viewport")
-        })
-        asytest.done()
-    </script>
-</body>
-</html>
diff --git a/third_party/WebKit/LayoutTests/fast/css-generated-content/hover-inline-expected.txt b/third_party/WebKit/LayoutTests/fast/css-generated-content/hover-inline-expected.txt
index e082e2dc..f46f03a2 100644
--- a/third_party/WebKit/LayoutTests/fast/css-generated-content/hover-inline-expected.txt
+++ b/third_party/WebKit/LayoutTests/fast/css-generated-content/hover-inline-expected.txt
@@ -1,2 +1,3 @@
 Hovering the generated text should hover the span:
+
 PASS
diff --git a/third_party/WebKit/LayoutTests/fast/dom/shadow/anchor-content-projected-expected.txt b/third_party/WebKit/LayoutTests/fast/dom/shadow/anchor-content-projected-expected.txt
index f088280..4058bedd 100644
--- a/third_party/WebKit/LayoutTests/fast/dom/shadow/anchor-content-projected-expected.txt
+++ b/third_party/WebKit/LayoutTests/fast/dom/shadow/anchor-content-projected-expected.txt
@@ -1,5 +1,8 @@
 Links should be clickable even when their content is projected into them.
+
 On success, you will see a series of "PASS" messages, followed by "TEST COMPLETE".
+
+
 Cursor Info: type=Hand hotSpot=0,0
 PASS window.location.hash is "#link-clicked"
 PASS successfullyParsed is true
diff --git a/third_party/WebKit/LayoutTests/fast/events/dispatch-mouse-events-to-window-always-expected.txt b/third_party/WebKit/LayoutTests/fast/events/dispatch-mouse-events-to-window-always-expected.txt
index 3e20e30..44034bf1 100644
--- a/third_party/WebKit/LayoutTests/fast/events/dispatch-mouse-events-to-window-always-expected.txt
+++ b/third_party/WebKit/LayoutTests/fast/events/dispatch-mouse-events-to-window-always-expected.txt
@@ -1,5 +1,8 @@
 Test that wheel and mouse events are dispatched to document and window even if they do not hit any element in the page.
+
 On success, you will see a series of "PASS" messages, followed by "TEST COMPLETE".
+
+
 outside body, inside element
 eventType: mousedown
 PASS objectsToString(actualReceivers) is "HTMLDivElement,HTMLBodyElement,HTMLDocument,Window"
diff --git a/third_party/WebKit/LayoutTests/fast/media/HTMLMediaElement-construction-in-detached-document-expected.txt b/third_party/WebKit/LayoutTests/fast/media/HTMLMediaElement-construction-in-detached-document-expected.txt
new file mode 100644
index 0000000..c820deb
--- /dev/null
+++ b/third_party/WebKit/LayoutTests/fast/media/HTMLMediaElement-construction-in-detached-document-expected.txt
@@ -0,0 +1 @@
+PASS if creating an audio element in a detached Document doesn't crash.
diff --git a/third_party/WebKit/LayoutTests/fast/media/HTMLMediaElement-construction-in-detached-document.html b/third_party/WebKit/LayoutTests/fast/media/HTMLMediaElement-construction-in-detached-document.html
new file mode 100644
index 0000000..20b4b1c6
--- /dev/null
+++ b/third_party/WebKit/LayoutTests/fast/media/HTMLMediaElement-construction-in-detached-document.html
@@ -0,0 +1,12 @@
+<body>
+PASS if creating an audio element in a detached Document doesn't crash.
+<iframe id="i"></iframe>
+<script>
+if (window.testRunner)
+  testRunner.dumpAsText();
+
+var child_document = i.contentDocument;
+i.remove();
+var audio = child_document.createElement("audio");
+</script>
+</body>
diff --git a/third_party/WebKit/LayoutTests/fast/text/ellipsis-in-relative-inline-2-expected.html b/third_party/WebKit/LayoutTests/fast/text/ellipsis-in-relative-inline-2-expected.html
new file mode 100644
index 0000000..bc6f063
--- /dev/null
+++ b/third_party/WebKit/LayoutTests/fast/text/ellipsis-in-relative-inline-2-expected.html
@@ -0,0 +1,37 @@
+<style>
+.wrapper {
+  width: 200px;
+}
+.row  {
+  white-space: nowrap;
+  overflow: hidden;
+  text-overflow: ellipsis;
+}
+.icon {
+  color: white;
+}
+.rtl {
+    direction: rtl;
+}
+</style>
+<p>crbug.com/762978: There should be an ellipsis in both lines below.</p>
+<div class="wrapper">
+  <div class="row">
+    <span class="icon">
+      T
+    </span>
+    <span class="label">
+      This text should truncate with ellipsis
+    </span>
+  </div>
+</div>
+<div class="wrapper">
+  <div class="row rtl">
+    <span class="label">
+      This text should truncate with ellipsis
+    </span>
+    <span class="icon">
+      T
+    </span>
+  </div>
+</div>
diff --git a/third_party/WebKit/LayoutTests/fast/text/ellipsis-in-relative-inline-2.html b/third_party/WebKit/LayoutTests/fast/text/ellipsis-in-relative-inline-2.html
new file mode 100644
index 0000000..c98b519e
--- /dev/null
+++ b/third_party/WebKit/LayoutTests/fast/text/ellipsis-in-relative-inline-2.html
@@ -0,0 +1,41 @@
+<style>
+.icon {
+  position: relative;
+  top: 1px;
+}
+.wrapper {
+  width: 200px;
+}
+.row  {
+  white-space: nowrap;
+  overflow: hidden;
+  text-overflow: ellipsis;
+}
+.icon {
+  color: white;
+}
+.rtl {
+    direction: rtl;
+}
+</style>
+<p>crbug.com/762978: There should be an ellipsis in both lines below.</p>
+<div class="wrapper">
+  <div class="row">
+    <span class="icon">
+      T
+    </span>
+    <span class="label">
+      This text should truncate with ellipsis
+    </span>
+  </div>
+</div>
+<div class="wrapper">
+  <div class="row rtl">
+    <span class="label">
+      This text should truncate with ellipsis
+    </span>
+    <span class="icon">
+      T
+    </span>
+  </div>
+</div>
diff --git a/third_party/WebKit/LayoutTests/fast/text/sub-pixel/text-scaling-ltr-expected.txt b/third_party/WebKit/LayoutTests/fast/text/sub-pixel/text-scaling-ltr-expected.txt
index f252848..a24a55a 100644
--- a/third_party/WebKit/LayoutTests/fast/text/sub-pixel/text-scaling-ltr-expected.txt
+++ b/third_party/WebKit/LayoutTests/fast/text/sub-pixel/text-scaling-ltr-expected.txt
@@ -5,3 +5,4 @@
 Font Size Scaling (LTR, Latin)
 Size of the text should scale smoothly. Reported width should be within 0.02x of that of the highlighted reference row.
 
+
diff --git a/third_party/WebKit/LayoutTests/fast/text/sub-pixel/text-scaling-rtl-expected.txt b/third_party/WebKit/LayoutTests/fast/text/sub-pixel/text-scaling-rtl-expected.txt
index 906d1ed..616e423 100644
--- a/third_party/WebKit/LayoutTests/fast/text/sub-pixel/text-scaling-rtl-expected.txt
+++ b/third_party/WebKit/LayoutTests/fast/text/sub-pixel/text-scaling-rtl-expected.txt
@@ -5,3 +5,4 @@
 Font Size Scaling (RTL, Arabic)
 Size of the text should scale smoothly. Reported width should be within 0.02px of that of the highlighted reference row.
 
+
diff --git a/third_party/WebKit/LayoutTests/fast/text/sub-pixel/text-scaling-vertical-expected.txt b/third_party/WebKit/LayoutTests/fast/text/sub-pixel/text-scaling-vertical-expected.txt
index f3dc2272..908d157 100644
--- a/third_party/WebKit/LayoutTests/fast/text/sub-pixel/text-scaling-vertical-expected.txt
+++ b/third_party/WebKit/LayoutTests/fast/text/sub-pixel/text-scaling-vertical-expected.txt
@@ -5,3 +5,4 @@
 Font Size Scaling (vertical-rl, Latin)
 Size of the text should scale smoothly. Reported height (logical width) should be within 0.02px of that of the highlighted reference row.
 
+
diff --git a/third_party/WebKit/LayoutTests/fast/text/sub-pixel/text-scaling-webfont-expected.txt b/third_party/WebKit/LayoutTests/fast/text/sub-pixel/text-scaling-webfont-expected.txt
index 24a8cf4..ee9e37c5 100644
--- a/third_party/WebKit/LayoutTests/fast/text/sub-pixel/text-scaling-webfont-expected.txt
+++ b/third_party/WebKit/LayoutTests/fast/text/sub-pixel/text-scaling-webfont-expected.txt
@@ -5,3 +5,4 @@
 Font Size Scaling (WebFont, Latin)
 Size of the text should scale smoothly. Reported width should be within 0.02px of that of the highlighted reference row.
 
+
diff --git a/third_party/WebKit/LayoutTests/html/sections/nav-element-expected.txt b/third_party/WebKit/LayoutTests/html/sections/nav-element-expected.txt
index 4cab53ae..acd6c4fa 100644
--- a/third_party/WebKit/LayoutTests/html/sections/nav-element-expected.txt
+++ b/third_party/WebKit/LayoutTests/html/sections/nav-element-expected.txt
@@ -4,11 +4,13 @@
 
 Test that p does not close nav. This paragraph should have a double green border.
 
+
 Test that nav can nest inside itself. This paragraph should have a double green border.
 
 Test of residual style. This text should be bold.
 This should be bold too.
 
+
 Test of FormatBlock behavior. This text should have a green border.
 
 DOM for the above (so this test can dump as text)
diff --git a/third_party/WebKit/LayoutTests/http/tests/canvas/philip/tests/security.drawImage.canvas-expected.txt b/third_party/WebKit/LayoutTests/http/tests/canvas/philip/tests/security.drawImage.canvas-expected.txt
index cfc9846..13d97762 100644
--- a/third_party/WebKit/LayoutTests/http/tests/canvas/philip/tests/security.drawImage.canvas-expected.txt
+++ b/third_party/WebKit/LayoutTests/http/tests/canvas/philip/tests/security.drawImage.canvas-expected.txt
@@ -1,7 +1,10 @@
 < [index] >
+
 security.drawImage.canvas
 drawImage of unclean canvas makes the canvas origin-unclean
+
 References: security.drawImage.canvas
 Actual output:
+
 Passed
 
diff --git a/third_party/WebKit/LayoutTests/http/tests/canvas/philip/tests/security.drawImage.image-expected.txt b/third_party/WebKit/LayoutTests/http/tests/canvas/philip/tests/security.drawImage.image-expected.txt
index 6e248c5..d5dc00d 100644
--- a/third_party/WebKit/LayoutTests/http/tests/canvas/philip/tests/security.drawImage.image-expected.txt
+++ b/third_party/WebKit/LayoutTests/http/tests/canvas/philip/tests/security.drawImage.image-expected.txt
@@ -1,7 +1,10 @@
 < [index] >
+
 security.drawImage.image
 drawImage of different-origin image makes the canvas origin-unclean
+
 References: security.drawImage.image security.toDataURL security.getImageData
 Actual output:
+
 Passed
 
diff --git a/third_party/WebKit/LayoutTests/http/tests/canvas/philip/tests/security.pattern.canvas.fillStyle-expected.txt b/third_party/WebKit/LayoutTests/http/tests/canvas/philip/tests/security.pattern.canvas.fillStyle-expected.txt
index 2d07c611..61df12d7 100644
--- a/third_party/WebKit/LayoutTests/http/tests/canvas/philip/tests/security.pattern.canvas.fillStyle-expected.txt
+++ b/third_party/WebKit/LayoutTests/http/tests/canvas/philip/tests/security.pattern.canvas.fillStyle-expected.txt
@@ -1,7 +1,10 @@
 < [index] >
+
 security.pattern.canvas.fillStyle
 Setting fillStyle to a pattern of an unclean canvas makes the canvas origin-unclean
+
 References: security.fillStyle.canvas Bugzilla
 Actual output:
+
 Passed
 
diff --git a/third_party/WebKit/LayoutTests/http/tests/canvas/philip/tests/security.pattern.canvas.strokeStyle-expected.txt b/third_party/WebKit/LayoutTests/http/tests/canvas/philip/tests/security.pattern.canvas.strokeStyle-expected.txt
index 07e4453..b07b953 100644
--- a/third_party/WebKit/LayoutTests/http/tests/canvas/philip/tests/security.pattern.canvas.strokeStyle-expected.txt
+++ b/third_party/WebKit/LayoutTests/http/tests/canvas/philip/tests/security.pattern.canvas.strokeStyle-expected.txt
@@ -1,7 +1,10 @@
 < [index] >
+
 security.pattern.canvas.strokeStyle
 Setting strokeStyle to a pattern of an unclean canvas makes the canvas origin-unclean
+
 References: security.strokeStyle.canvas Bugzilla
 Actual output:
+
 Passed
 
diff --git a/third_party/WebKit/LayoutTests/http/tests/canvas/philip/tests/security.pattern.canvas.timing-expected.txt b/third_party/WebKit/LayoutTests/http/tests/canvas/philip/tests/security.pattern.canvas.timing-expected.txt
index 3767600..95a43eb 100644
--- a/third_party/WebKit/LayoutTests/http/tests/canvas/philip/tests/security.pattern.canvas.timing-expected.txt
+++ b/third_party/WebKit/LayoutTests/http/tests/canvas/philip/tests/security.pattern.canvas.timing-expected.txt
@@ -1,8 +1,12 @@
 < [index] >
+
 security.pattern.canvas.timing
 Pattern safety depends on whether the source was origin-clean, not on whether it still is clean
+
 References: security.start security.fillStyle.canvas
 Disagrees with spec on "is" vs "was"
+
 Actual output:
+
 Passed
 
diff --git a/third_party/WebKit/LayoutTests/http/tests/canvas/philip/tests/security.pattern.create-expected.txt b/third_party/WebKit/LayoutTests/http/tests/canvas/philip/tests/security.pattern.create-expected.txt
index 7cdf389..9c2070e 100644
--- a/third_party/WebKit/LayoutTests/http/tests/canvas/philip/tests/security.pattern.create-expected.txt
+++ b/third_party/WebKit/LayoutTests/http/tests/canvas/philip/tests/security.pattern.create-expected.txt
@@ -1,7 +1,10 @@
 < [index] >
+
 security.pattern.create
 Creating an unclean pattern does not make the canvas origin-unclean
+
 References: security.start
 Actual output:
+
 Passed
 
diff --git a/third_party/WebKit/LayoutTests/http/tests/canvas/philip/tests/security.pattern.cross-expected.txt b/third_party/WebKit/LayoutTests/http/tests/canvas/philip/tests/security.pattern.cross-expected.txt
index b3dbcae06..ab097ac 100644
--- a/third_party/WebKit/LayoutTests/http/tests/canvas/philip/tests/security.pattern.cross-expected.txt
+++ b/third_party/WebKit/LayoutTests/http/tests/canvas/philip/tests/security.pattern.cross-expected.txt
@@ -1,7 +1,10 @@
 < [index] >
+
 security.pattern.cross
 Using an unclean pattern makes the target canvas origin-unclean, not the pattern canvas
+
 References: security.start
 Actual output:
+
 Passed
 
diff --git a/third_party/WebKit/LayoutTests/http/tests/canvas/philip/tests/security.pattern.image.fillStyle-expected.txt b/third_party/WebKit/LayoutTests/http/tests/canvas/philip/tests/security.pattern.image.fillStyle-expected.txt
index 04cdf33..2f1e835 100644
--- a/third_party/WebKit/LayoutTests/http/tests/canvas/philip/tests/security.pattern.image.fillStyle-expected.txt
+++ b/third_party/WebKit/LayoutTests/http/tests/canvas/philip/tests/security.pattern.image.fillStyle-expected.txt
@@ -1,7 +1,10 @@
 < [index] >
+
 security.pattern.image.fillStyle
 Setting fillStyle to a pattern of a different-origin image makes the canvas origin-unclean
+
 References: security.fillStyle.image
 Actual output:
+
 Passed
 
diff --git a/third_party/WebKit/LayoutTests/http/tests/canvas/philip/tests/security.pattern.image.strokeStyle-expected.txt b/third_party/WebKit/LayoutTests/http/tests/canvas/philip/tests/security.pattern.image.strokeStyle-expected.txt
index 509eafd..debab8f 100644
--- a/third_party/WebKit/LayoutTests/http/tests/canvas/philip/tests/security.pattern.image.strokeStyle-expected.txt
+++ b/third_party/WebKit/LayoutTests/http/tests/canvas/philip/tests/security.pattern.image.strokeStyle-expected.txt
@@ -1,7 +1,10 @@
 < [index] >
+
 security.pattern.image.strokeStyle
 Setting strokeStyle to a pattern of a different-origin image makes the canvas origin-unclean
+
 References: security.strokeStyle.image
 Actual output:
+
 Passed
 
diff --git a/third_party/WebKit/LayoutTests/http/tests/canvas/philip/tests/security.reset-expected.txt b/third_party/WebKit/LayoutTests/http/tests/canvas/philip/tests/security.reset-expected.txt
index 7d163c1..8adf16b 100644
--- a/third_party/WebKit/LayoutTests/http/tests/canvas/philip/tests/security.reset-expected.txt
+++ b/third_party/WebKit/LayoutTests/http/tests/canvas/philip/tests/security.reset-expected.txt
@@ -1,7 +1,10 @@
 < [index] >
+
 security.reset
 Resetting the canvas state does not reset the origin-clean flag
+
 References: initial.reset
 Actual output:
+
 Failed assertion: should throw exception: canvas.toDataURL()
 
diff --git a/third_party/WebKit/LayoutTests/platform/android/fast/inline-block/overflow-clip-expected.png b/third_party/WebKit/LayoutTests/platform/android/fast/inline-block/overflow-clip-expected.png
new file mode 100644
index 0000000..46d9243
--- /dev/null
+++ b/third_party/WebKit/LayoutTests/platform/android/fast/inline-block/overflow-clip-expected.png
Binary files differ
diff --git a/third_party/WebKit/LayoutTests/platform/linux/css1/basic/comments-expected.png b/third_party/WebKit/LayoutTests/platform/linux/css1/basic/comments-expected.png
index 23e7fa2..a90477f 100644
--- a/third_party/WebKit/LayoutTests/platform/linux/css1/basic/comments-expected.png
+++ b/third_party/WebKit/LayoutTests/platform/linux/css1/basic/comments-expected.png
Binary files differ
diff --git a/third_party/WebKit/LayoutTests/platform/linux/css1/basic/comments-expected.txt b/third_party/WebKit/LayoutTests/platform/linux/css1/basic/comments-expected.txt
index 1a9619c..37d2e51 100644
--- a/third_party/WebKit/LayoutTests/platform/linux/css1/basic/comments-expected.txt
+++ b/third_party/WebKit/LayoutTests/platform/linux/css1/basic/comments-expected.txt
@@ -7,33 +7,33 @@
         LayoutText {#text} at (0,0) size 355x19
           text run at (0,0) width 355: "The style declarations which apply to the text below are:"
       LayoutBlockFlow {PRE} at (0,36) size 769x240
-        LayoutText {#text} at (0,0) size 334x240
-          text run at (0,0) width 230: "/* This is a CSS1 comment. */"
-          text run at (230,0) width 0: " "
-          text run at (0,16) width 334: ".one {color: green;} /* Another comment */"
-          text run at (334,16) width 0: " "
-          text run at (0,32) width 287: "/* The following should not be used:"
-          text run at (287,32) width 0: " "
-          text run at (0,48) width 167: ".two {color: red;} */"
-          text run at (167,48) width 0: " "
-          text run at (0,64) width 318: ".three {color: green; /* color: red; */}"
-          text run at (318,64) width 0: " "
-          text run at (0,80) width 22: "/**"
-          text run at (22,80) width 0: " "
-          text run at (0,96) width 175: ".four {color: red;} */"
-          text run at (175,96) width 0: " "
+        LayoutText {#text} at (0,0) size 336x240
+          text run at (0,0) width 232: "/* This is a CSS1 comment. */"
+          text run at (232,0) width 0: " "
+          text run at (0,16) width 336: ".one {color: green;} /* Another comment */"
+          text run at (336,16) width 0: " "
+          text run at (0,32) width 288: "/* The following should not be used:"
+          text run at (288,32) width 0: " "
+          text run at (0,48) width 168: ".two {color: red;} */"
+          text run at (168,48) width 0: " "
+          text run at (0,64) width 320: ".three {color: green; /* color: red; */}"
+          text run at (320,64) width 0: " "
+          text run at (0,80) width 24: "/**"
+          text run at (24,80) width 0: " "
+          text run at (0,96) width 176: ".four {color: red;} */"
+          text run at (176,96) width 0: " "
           text run at (0,112) width 168: ".five {color: green;}"
           text run at (168,112) width 0: " "
-          text run at (0,128) width 30: "/**/"
-          text run at (30,128) width 0: " "
+          text run at (0,128) width 32: "/**/"
+          text run at (32,128) width 0: " "
           text run at (0,144) width 160: ".six {color: green;}"
           text run at (160,144) width 0: " "
-          text run at (0,160) width 79: "/*********/"
-          text run at (79,160) width 0: " "
+          text run at (0,160) width 88: "/*********/"
+          text run at (88,160) width 0: " "
           text run at (0,176) width 176: ".seven {color: green;}"
           text run at (176,176) width 0: " "
-          text run at (0,192) width 125: "/* a comment **/"
-          text run at (125,192) width 0: " "
+          text run at (0,192) width 128: "/* a comment **/"
+          text run at (128,192) width 0: " "
           text run at (0,208) width 176: ".eight {color: green;}"
           text run at (176,208) width 0: " "
           text run at (0,224) width 0: " "
diff --git a/third_party/WebKit/LayoutTests/platform/linux/css1/basic/containment-expected.png b/third_party/WebKit/LayoutTests/platform/linux/css1/basic/containment-expected.png
index 94d55899..3175599 100644
--- a/third_party/WebKit/LayoutTests/platform/linux/css1/basic/containment-expected.png
+++ b/third_party/WebKit/LayoutTests/platform/linux/css1/basic/containment-expected.png
Binary files differ
diff --git a/third_party/WebKit/LayoutTests/platform/linux/css1/basic/contextual_selectors-expected.png b/third_party/WebKit/LayoutTests/platform/linux/css1/basic/contextual_selectors-expected.png
index 6112d6d..97690e2 100644
--- a/third_party/WebKit/LayoutTests/platform/linux/css1/basic/contextual_selectors-expected.png
+++ b/third_party/WebKit/LayoutTests/platform/linux/css1/basic/contextual_selectors-expected.png
Binary files differ
diff --git a/third_party/WebKit/LayoutTests/platform/linux/css1/basic/grouping-expected.png b/third_party/WebKit/LayoutTests/platform/linux/css1/basic/grouping-expected.png
index 6fa52bc5..13d7815 100644
--- a/third_party/WebKit/LayoutTests/platform/linux/css1/basic/grouping-expected.png
+++ b/third_party/WebKit/LayoutTests/platform/linux/css1/basic/grouping-expected.png
Binary files differ
diff --git a/third_party/WebKit/LayoutTests/platform/linux/css1/basic/id_as_selector-expected.png b/third_party/WebKit/LayoutTests/platform/linux/css1/basic/id_as_selector-expected.png
index 9a547898..967b12a 100644
--- a/third_party/WebKit/LayoutTests/platform/linux/css1/basic/id_as_selector-expected.png
+++ b/third_party/WebKit/LayoutTests/platform/linux/css1/basic/id_as_selector-expected.png
Binary files differ
diff --git a/third_party/WebKit/LayoutTests/platform/linux/css1/basic/inheritance-expected.png b/third_party/WebKit/LayoutTests/platform/linux/css1/basic/inheritance-expected.png
index 8afc076b..36fce52 100644
--- a/third_party/WebKit/LayoutTests/platform/linux/css1/basic/inheritance-expected.png
+++ b/third_party/WebKit/LayoutTests/platform/linux/css1/basic/inheritance-expected.png
Binary files differ
diff --git a/third_party/WebKit/LayoutTests/platform/linux/css1/box_properties/border-expected.png b/third_party/WebKit/LayoutTests/platform/linux/css1/box_properties/border-expected.png
index 662f8b08..72a9bb5 100644
--- a/third_party/WebKit/LayoutTests/platform/linux/css1/box_properties/border-expected.png
+++ b/third_party/WebKit/LayoutTests/platform/linux/css1/box_properties/border-expected.png
Binary files differ
diff --git a/third_party/WebKit/LayoutTests/platform/linux/css1/box_properties/border_bottom-expected.png b/third_party/WebKit/LayoutTests/platform/linux/css1/box_properties/border_bottom-expected.png
index fd606fa..d27a587 100644
--- a/third_party/WebKit/LayoutTests/platform/linux/css1/box_properties/border_bottom-expected.png
+++ b/third_party/WebKit/LayoutTests/platform/linux/css1/box_properties/border_bottom-expected.png
Binary files differ
diff --git a/third_party/WebKit/LayoutTests/platform/linux/css1/box_properties/border_bottom_inline-expected.png b/third_party/WebKit/LayoutTests/platform/linux/css1/box_properties/border_bottom_inline-expected.png
index 135de6e..3bc2598 100644
--- a/third_party/WebKit/LayoutTests/platform/linux/css1/box_properties/border_bottom_inline-expected.png
+++ b/third_party/WebKit/LayoutTests/platform/linux/css1/box_properties/border_bottom_inline-expected.png
Binary files differ
diff --git a/third_party/WebKit/LayoutTests/platform/linux/css1/box_properties/border_bottom_width-expected.png b/third_party/WebKit/LayoutTests/platform/linux/css1/box_properties/border_bottom_width-expected.png
index 3682aeb6..26248fd0 100644
--- a/third_party/WebKit/LayoutTests/platform/linux/css1/box_properties/border_bottom_width-expected.png
+++ b/third_party/WebKit/LayoutTests/platform/linux/css1/box_properties/border_bottom_width-expected.png
Binary files differ
diff --git a/third_party/WebKit/LayoutTests/platform/linux/css1/box_properties/border_bottom_width_inline-expected.png b/third_party/WebKit/LayoutTests/platform/linux/css1/box_properties/border_bottom_width_inline-expected.png
index 3ad65031..4e61d83e 100644
--- a/third_party/WebKit/LayoutTests/platform/linux/css1/box_properties/border_bottom_width_inline-expected.png
+++ b/third_party/WebKit/LayoutTests/platform/linux/css1/box_properties/border_bottom_width_inline-expected.png
Binary files differ
diff --git a/third_party/WebKit/LayoutTests/platform/linux/css1/box_properties/border_color-expected.png b/third_party/WebKit/LayoutTests/platform/linux/css1/box_properties/border_color-expected.png
index 34585c46..bdfef32a1 100644
--- a/third_party/WebKit/LayoutTests/platform/linux/css1/box_properties/border_color-expected.png
+++ b/third_party/WebKit/LayoutTests/platform/linux/css1/box_properties/border_color-expected.png
Binary files differ
diff --git a/third_party/WebKit/LayoutTests/platform/linux/css1/box_properties/border_color_inline-expected.png b/third_party/WebKit/LayoutTests/platform/linux/css1/box_properties/border_color_inline-expected.png
index 939bdfc7..c1275a3 100644
--- a/third_party/WebKit/LayoutTests/platform/linux/css1/box_properties/border_color_inline-expected.png
+++ b/third_party/WebKit/LayoutTests/platform/linux/css1/box_properties/border_color_inline-expected.png
Binary files differ
diff --git a/third_party/WebKit/LayoutTests/platform/linux/css1/box_properties/border_inline-expected.png b/third_party/WebKit/LayoutTests/platform/linux/css1/box_properties/border_inline-expected.png
index cd8a856..69627cc 100644
--- a/third_party/WebKit/LayoutTests/platform/linux/css1/box_properties/border_inline-expected.png
+++ b/third_party/WebKit/LayoutTests/platform/linux/css1/box_properties/border_inline-expected.png
Binary files differ
diff --git a/third_party/WebKit/LayoutTests/platform/linux/css1/box_properties/border_left-expected.png b/third_party/WebKit/LayoutTests/platform/linux/css1/box_properties/border_left-expected.png
index 801d4af..eca0a7f 100644
--- a/third_party/WebKit/LayoutTests/platform/linux/css1/box_properties/border_left-expected.png
+++ b/third_party/WebKit/LayoutTests/platform/linux/css1/box_properties/border_left-expected.png
Binary files differ
diff --git a/third_party/WebKit/LayoutTests/platform/linux/css1/box_properties/border_left_inline-expected.png b/third_party/WebKit/LayoutTests/platform/linux/css1/box_properties/border_left_inline-expected.png
index be4f28885..a229c84 100644
--- a/third_party/WebKit/LayoutTests/platform/linux/css1/box_properties/border_left_inline-expected.png
+++ b/third_party/WebKit/LayoutTests/platform/linux/css1/box_properties/border_left_inline-expected.png
Binary files differ
diff --git a/third_party/WebKit/LayoutTests/platform/linux/css1/box_properties/border_left_width-expected.png b/third_party/WebKit/LayoutTests/platform/linux/css1/box_properties/border_left_width-expected.png
index e891fbb..0b1197a 100644
--- a/third_party/WebKit/LayoutTests/platform/linux/css1/box_properties/border_left_width-expected.png
+++ b/third_party/WebKit/LayoutTests/platform/linux/css1/box_properties/border_left_width-expected.png
Binary files differ
diff --git a/third_party/WebKit/LayoutTests/platform/linux/css1/box_properties/border_left_width_inline-expected.png b/third_party/WebKit/LayoutTests/platform/linux/css1/box_properties/border_left_width_inline-expected.png
index 5b355e1..29c5264c 100644
--- a/third_party/WebKit/LayoutTests/platform/linux/css1/box_properties/border_left_width_inline-expected.png
+++ b/third_party/WebKit/LayoutTests/platform/linux/css1/box_properties/border_left_width_inline-expected.png
Binary files differ
diff --git a/third_party/WebKit/LayoutTests/platform/linux/css1/box_properties/border_right-expected.png b/third_party/WebKit/LayoutTests/platform/linux/css1/box_properties/border_right-expected.png
index 411890a..ba4205aa 100644
--- a/third_party/WebKit/LayoutTests/platform/linux/css1/box_properties/border_right-expected.png
+++ b/third_party/WebKit/LayoutTests/platform/linux/css1/box_properties/border_right-expected.png
Binary files differ
diff --git a/third_party/WebKit/LayoutTests/platform/linux/css1/box_properties/border_right_inline-expected.png b/third_party/WebKit/LayoutTests/platform/linux/css1/box_properties/border_right_inline-expected.png
index 0adb5f86..ce1af30d6 100644
--- a/third_party/WebKit/LayoutTests/platform/linux/css1/box_properties/border_right_inline-expected.png
+++ b/third_party/WebKit/LayoutTests/platform/linux/css1/box_properties/border_right_inline-expected.png
Binary files differ
diff --git a/third_party/WebKit/LayoutTests/platform/linux/css1/box_properties/border_right_width-expected.png b/third_party/WebKit/LayoutTests/platform/linux/css1/box_properties/border_right_width-expected.png
index 556a3db..18fc7139 100644
--- a/third_party/WebKit/LayoutTests/platform/linux/css1/box_properties/border_right_width-expected.png
+++ b/third_party/WebKit/LayoutTests/platform/linux/css1/box_properties/border_right_width-expected.png
Binary files differ
diff --git a/third_party/WebKit/LayoutTests/platform/linux/css1/box_properties/border_right_width_inline-expected.png b/third_party/WebKit/LayoutTests/platform/linux/css1/box_properties/border_right_width_inline-expected.png
index 3b983872..5a74601ad 100644
--- a/third_party/WebKit/LayoutTests/platform/linux/css1/box_properties/border_right_width_inline-expected.png
+++ b/third_party/WebKit/LayoutTests/platform/linux/css1/box_properties/border_right_width_inline-expected.png
Binary files differ
diff --git a/third_party/WebKit/LayoutTests/platform/linux/css1/box_properties/border_style-expected.png b/third_party/WebKit/LayoutTests/platform/linux/css1/box_properties/border_style-expected.png
index 5af001f..c58b397 100644
--- a/third_party/WebKit/LayoutTests/platform/linux/css1/box_properties/border_style-expected.png
+++ b/third_party/WebKit/LayoutTests/platform/linux/css1/box_properties/border_style-expected.png
Binary files differ
diff --git a/third_party/WebKit/LayoutTests/platform/linux/css1/box_properties/border_style_inline-expected.png b/third_party/WebKit/LayoutTests/platform/linux/css1/box_properties/border_style_inline-expected.png
index a6816bd0..a9daed61 100644
--- a/third_party/WebKit/LayoutTests/platform/linux/css1/box_properties/border_style_inline-expected.png
+++ b/third_party/WebKit/LayoutTests/platform/linux/css1/box_properties/border_style_inline-expected.png
Binary files differ
diff --git a/third_party/WebKit/LayoutTests/platform/linux/css1/box_properties/border_top-expected.png b/third_party/WebKit/LayoutTests/platform/linux/css1/box_properties/border_top-expected.png
index 6f92c67..f06c5ff 100644
--- a/third_party/WebKit/LayoutTests/platform/linux/css1/box_properties/border_top-expected.png
+++ b/third_party/WebKit/LayoutTests/platform/linux/css1/box_properties/border_top-expected.png
Binary files differ
diff --git a/third_party/WebKit/LayoutTests/platform/linux/css1/box_properties/border_top_inline-expected.png b/third_party/WebKit/LayoutTests/platform/linux/css1/box_properties/border_top_inline-expected.png
index 49cfc71..2324fb74 100644
--- a/third_party/WebKit/LayoutTests/platform/linux/css1/box_properties/border_top_inline-expected.png
+++ b/third_party/WebKit/LayoutTests/platform/linux/css1/box_properties/border_top_inline-expected.png
Binary files differ
diff --git a/third_party/WebKit/LayoutTests/platform/linux/css1/box_properties/border_top_width-expected.png b/third_party/WebKit/LayoutTests/platform/linux/css1/box_properties/border_top_width-expected.png
index 8a3c921..b263abe4 100644
--- a/third_party/WebKit/LayoutTests/platform/linux/css1/box_properties/border_top_width-expected.png
+++ b/third_party/WebKit/LayoutTests/platform/linux/css1/box_properties/border_top_width-expected.png
Binary files differ
diff --git a/third_party/WebKit/LayoutTests/platform/linux/css1/box_properties/border_top_width_inline-expected.png b/third_party/WebKit/LayoutTests/platform/linux/css1/box_properties/border_top_width_inline-expected.png
index 58f925f5..6e896ab 100644
--- a/third_party/WebKit/LayoutTests/platform/linux/css1/box_properties/border_top_width_inline-expected.png
+++ b/third_party/WebKit/LayoutTests/platform/linux/css1/box_properties/border_top_width_inline-expected.png
Binary files differ
diff --git a/third_party/WebKit/LayoutTests/platform/linux/css1/box_properties/border_width-expected.png b/third_party/WebKit/LayoutTests/platform/linux/css1/box_properties/border_width-expected.png
index 39084ba..05713d6 100644
--- a/third_party/WebKit/LayoutTests/platform/linux/css1/box_properties/border_width-expected.png
+++ b/third_party/WebKit/LayoutTests/platform/linux/css1/box_properties/border_width-expected.png
Binary files differ
diff --git a/third_party/WebKit/LayoutTests/platform/linux/css1/box_properties/border_width_inline-expected.png b/third_party/WebKit/LayoutTests/platform/linux/css1/box_properties/border_width_inline-expected.png
index 12761ab..f040266 100644
--- a/third_party/WebKit/LayoutTests/platform/linux/css1/box_properties/border_width_inline-expected.png
+++ b/third_party/WebKit/LayoutTests/platform/linux/css1/box_properties/border_width_inline-expected.png
Binary files differ
diff --git a/third_party/WebKit/LayoutTests/platform/linux/css1/box_properties/clear-expected.png b/third_party/WebKit/LayoutTests/platform/linux/css1/box_properties/clear-expected.png
index 4e76195..2fa89e0 100644
--- a/third_party/WebKit/LayoutTests/platform/linux/css1/box_properties/clear-expected.png
+++ b/third_party/WebKit/LayoutTests/platform/linux/css1/box_properties/clear-expected.png
Binary files differ
diff --git a/third_party/WebKit/LayoutTests/platform/linux/css1/box_properties/clear_float-expected.png b/third_party/WebKit/LayoutTests/platform/linux/css1/box_properties/clear_float-expected.png
index 17ed55a..9a2e9e2 100644
--- a/third_party/WebKit/LayoutTests/platform/linux/css1/box_properties/clear_float-expected.png
+++ b/third_party/WebKit/LayoutTests/platform/linux/css1/box_properties/clear_float-expected.png
Binary files differ
diff --git a/third_party/WebKit/LayoutTests/platform/linux/css1/box_properties/float-expected.png b/third_party/WebKit/LayoutTests/platform/linux/css1/box_properties/float-expected.png
index f0fc73e..145777c 100644
--- a/third_party/WebKit/LayoutTests/platform/linux/css1/box_properties/float-expected.png
+++ b/third_party/WebKit/LayoutTests/platform/linux/css1/box_properties/float-expected.png
Binary files differ
diff --git a/third_party/WebKit/LayoutTests/platform/linux/css1/box_properties/float_elements_in_series-expected.png b/third_party/WebKit/LayoutTests/platform/linux/css1/box_properties/float_elements_in_series-expected.png
index df19646..f0c1277 100644
--- a/third_party/WebKit/LayoutTests/platform/linux/css1/box_properties/float_elements_in_series-expected.png
+++ b/third_party/WebKit/LayoutTests/platform/linux/css1/box_properties/float_elements_in_series-expected.png
Binary files differ
diff --git a/third_party/WebKit/LayoutTests/platform/linux/css1/box_properties/float_margin-expected.png b/third_party/WebKit/LayoutTests/platform/linux/css1/box_properties/float_margin-expected.png
index 79c41cb5..74ce629 100644
--- a/third_party/WebKit/LayoutTests/platform/linux/css1/box_properties/float_margin-expected.png
+++ b/third_party/WebKit/LayoutTests/platform/linux/css1/box_properties/float_margin-expected.png
Binary files differ
diff --git a/third_party/WebKit/LayoutTests/platform/linux/css1/box_properties/height-expected.png b/third_party/WebKit/LayoutTests/platform/linux/css1/box_properties/height-expected.png
index 27f585d..5e1929e 100644
--- a/third_party/WebKit/LayoutTests/platform/linux/css1/box_properties/height-expected.png
+++ b/third_party/WebKit/LayoutTests/platform/linux/css1/box_properties/height-expected.png
Binary files differ
diff --git a/third_party/WebKit/LayoutTests/platform/linux/css1/box_properties/margin-expected.png b/third_party/WebKit/LayoutTests/platform/linux/css1/box_properties/margin-expected.png
index 37e79e0..cd498f5 100644
--- a/third_party/WebKit/LayoutTests/platform/linux/css1/box_properties/margin-expected.png
+++ b/third_party/WebKit/LayoutTests/platform/linux/css1/box_properties/margin-expected.png
Binary files differ
diff --git a/third_party/WebKit/LayoutTests/platform/linux/css1/box_properties/margin_bottom-expected.png b/third_party/WebKit/LayoutTests/platform/linux/css1/box_properties/margin_bottom-expected.png
index 6b1b5df..143704ee 100644
--- a/third_party/WebKit/LayoutTests/platform/linux/css1/box_properties/margin_bottom-expected.png
+++ b/third_party/WebKit/LayoutTests/platform/linux/css1/box_properties/margin_bottom-expected.png
Binary files differ
diff --git a/third_party/WebKit/LayoutTests/platform/linux/css1/box_properties/margin_bottom_inline-expected.png b/third_party/WebKit/LayoutTests/platform/linux/css1/box_properties/margin_bottom_inline-expected.png
index 37865481..9442667 100644
--- a/third_party/WebKit/LayoutTests/platform/linux/css1/box_properties/margin_bottom_inline-expected.png
+++ b/third_party/WebKit/LayoutTests/platform/linux/css1/box_properties/margin_bottom_inline-expected.png
Binary files differ
diff --git a/third_party/WebKit/LayoutTests/platform/linux/css1/box_properties/margin_inline-expected.png b/third_party/WebKit/LayoutTests/platform/linux/css1/box_properties/margin_inline-expected.png
index 84a91b5..8859390 100644
--- a/third_party/WebKit/LayoutTests/platform/linux/css1/box_properties/margin_inline-expected.png
+++ b/third_party/WebKit/LayoutTests/platform/linux/css1/box_properties/margin_inline-expected.png
Binary files differ
diff --git a/third_party/WebKit/LayoutTests/platform/linux/css1/box_properties/margin_left-expected.png b/third_party/WebKit/LayoutTests/platform/linux/css1/box_properties/margin_left-expected.png
index e6c414e..a154bf04 100644
--- a/third_party/WebKit/LayoutTests/platform/linux/css1/box_properties/margin_left-expected.png
+++ b/third_party/WebKit/LayoutTests/platform/linux/css1/box_properties/margin_left-expected.png
Binary files differ
diff --git a/third_party/WebKit/LayoutTests/platform/linux/css1/box_properties/margin_left_inline-expected.png b/third_party/WebKit/LayoutTests/platform/linux/css1/box_properties/margin_left_inline-expected.png
index fcdca9b..b075e90 100644
--- a/third_party/WebKit/LayoutTests/platform/linux/css1/box_properties/margin_left_inline-expected.png
+++ b/third_party/WebKit/LayoutTests/platform/linux/css1/box_properties/margin_left_inline-expected.png
Binary files differ
diff --git a/third_party/WebKit/LayoutTests/platform/linux/css1/box_properties/margin_right-expected.png b/third_party/WebKit/LayoutTests/platform/linux/css1/box_properties/margin_right-expected.png
index 2127a2e..8d65f88f 100644
--- a/third_party/WebKit/LayoutTests/platform/linux/css1/box_properties/margin_right-expected.png
+++ b/third_party/WebKit/LayoutTests/platform/linux/css1/box_properties/margin_right-expected.png
Binary files differ
diff --git a/third_party/WebKit/LayoutTests/platform/linux/css1/box_properties/margin_right_inline-expected.png b/third_party/WebKit/LayoutTests/platform/linux/css1/box_properties/margin_right_inline-expected.png
index 169fe1f..df781c4c 100644
--- a/third_party/WebKit/LayoutTests/platform/linux/css1/box_properties/margin_right_inline-expected.png
+++ b/third_party/WebKit/LayoutTests/platform/linux/css1/box_properties/margin_right_inline-expected.png
Binary files differ
diff --git a/third_party/WebKit/LayoutTests/platform/linux/css1/box_properties/margin_top-expected.png b/third_party/WebKit/LayoutTests/platform/linux/css1/box_properties/margin_top-expected.png
index bd492b89..9025be9 100644
--- a/third_party/WebKit/LayoutTests/platform/linux/css1/box_properties/margin_top-expected.png
+++ b/third_party/WebKit/LayoutTests/platform/linux/css1/box_properties/margin_top-expected.png
Binary files differ
diff --git a/third_party/WebKit/LayoutTests/platform/linux/css1/box_properties/margin_top_inline-expected.png b/third_party/WebKit/LayoutTests/platform/linux/css1/box_properties/margin_top_inline-expected.png
index 605907e..20c60324 100644
--- a/third_party/WebKit/LayoutTests/platform/linux/css1/box_properties/margin_top_inline-expected.png
+++ b/third_party/WebKit/LayoutTests/platform/linux/css1/box_properties/margin_top_inline-expected.png
Binary files differ
diff --git a/third_party/WebKit/LayoutTests/platform/linux/css1/box_properties/padding-expected.png b/third_party/WebKit/LayoutTests/platform/linux/css1/box_properties/padding-expected.png
index dda5abb..503ad58 100644
--- a/third_party/WebKit/LayoutTests/platform/linux/css1/box_properties/padding-expected.png
+++ b/third_party/WebKit/LayoutTests/platform/linux/css1/box_properties/padding-expected.png
Binary files differ
diff --git a/third_party/WebKit/LayoutTests/platform/linux/css1/box_properties/padding_bottom-expected.png b/third_party/WebKit/LayoutTests/platform/linux/css1/box_properties/padding_bottom-expected.png
index d2c47b3..f31c5e3 100644
--- a/third_party/WebKit/LayoutTests/platform/linux/css1/box_properties/padding_bottom-expected.png
+++ b/third_party/WebKit/LayoutTests/platform/linux/css1/box_properties/padding_bottom-expected.png
Binary files differ
diff --git a/third_party/WebKit/LayoutTests/platform/linux/css1/box_properties/padding_bottom_inline-expected.png b/third_party/WebKit/LayoutTests/platform/linux/css1/box_properties/padding_bottom_inline-expected.png
index ec7400f3..01823bf 100644
--- a/third_party/WebKit/LayoutTests/platform/linux/css1/box_properties/padding_bottom_inline-expected.png
+++ b/third_party/WebKit/LayoutTests/platform/linux/css1/box_properties/padding_bottom_inline-expected.png
Binary files differ
diff --git a/third_party/WebKit/LayoutTests/platform/linux/css1/box_properties/padding_inline-expected.png b/third_party/WebKit/LayoutTests/platform/linux/css1/box_properties/padding_inline-expected.png
index c9a0e64..4d33f7d 100644
--- a/third_party/WebKit/LayoutTests/platform/linux/css1/box_properties/padding_inline-expected.png
+++ b/third_party/WebKit/LayoutTests/platform/linux/css1/box_properties/padding_inline-expected.png
Binary files differ
diff --git a/third_party/WebKit/LayoutTests/platform/linux/css1/box_properties/padding_left-expected.png b/third_party/WebKit/LayoutTests/platform/linux/css1/box_properties/padding_left-expected.png
index d9c5350..d913fcf 100644
--- a/third_party/WebKit/LayoutTests/platform/linux/css1/box_properties/padding_left-expected.png
+++ b/third_party/WebKit/LayoutTests/platform/linux/css1/box_properties/padding_left-expected.png
Binary files differ
diff --git a/third_party/WebKit/LayoutTests/platform/linux/css1/box_properties/padding_left_inline-expected.png b/third_party/WebKit/LayoutTests/platform/linux/css1/box_properties/padding_left_inline-expected.png
index bd17bc7..e30e4e8 100644
--- a/third_party/WebKit/LayoutTests/platform/linux/css1/box_properties/padding_left_inline-expected.png
+++ b/third_party/WebKit/LayoutTests/platform/linux/css1/box_properties/padding_left_inline-expected.png
Binary files differ
diff --git a/third_party/WebKit/LayoutTests/platform/linux/css1/box_properties/padding_right-expected.png b/third_party/WebKit/LayoutTests/platform/linux/css1/box_properties/padding_right-expected.png
index dd7922b..9772efb3 100644
--- a/third_party/WebKit/LayoutTests/platform/linux/css1/box_properties/padding_right-expected.png
+++ b/third_party/WebKit/LayoutTests/platform/linux/css1/box_properties/padding_right-expected.png
Binary files differ
diff --git a/third_party/WebKit/LayoutTests/platform/linux/css1/box_properties/padding_right_inline-expected.png b/third_party/WebKit/LayoutTests/platform/linux/css1/box_properties/padding_right_inline-expected.png
index 64b1ebc..687ebfc 100644
--- a/third_party/WebKit/LayoutTests/platform/linux/css1/box_properties/padding_right_inline-expected.png
+++ b/third_party/WebKit/LayoutTests/platform/linux/css1/box_properties/padding_right_inline-expected.png
Binary files differ
diff --git a/third_party/WebKit/LayoutTests/platform/linux/css1/box_properties/padding_top-expected.png b/third_party/WebKit/LayoutTests/platform/linux/css1/box_properties/padding_top-expected.png
index 5dc6318..8a16987 100644
--- a/third_party/WebKit/LayoutTests/platform/linux/css1/box_properties/padding_top-expected.png
+++ b/third_party/WebKit/LayoutTests/platform/linux/css1/box_properties/padding_top-expected.png
Binary files differ
diff --git a/third_party/WebKit/LayoutTests/platform/linux/css1/box_properties/padding_top_inline-expected.png b/third_party/WebKit/LayoutTests/platform/linux/css1/box_properties/padding_top_inline-expected.png
index 958a292..7eaa7c7 100644
--- a/third_party/WebKit/LayoutTests/platform/linux/css1/box_properties/padding_top_inline-expected.png
+++ b/third_party/WebKit/LayoutTests/platform/linux/css1/box_properties/padding_top_inline-expected.png
Binary files differ
diff --git a/third_party/WebKit/LayoutTests/platform/linux/css1/box_properties/width-expected.png b/third_party/WebKit/LayoutTests/platform/linux/css1/box_properties/width-expected.png
index 093a8b9e..0cf4ab3 100644
--- a/third_party/WebKit/LayoutTests/platform/linux/css1/box_properties/width-expected.png
+++ b/third_party/WebKit/LayoutTests/platform/linux/css1/box_properties/width-expected.png
Binary files differ
diff --git a/third_party/WebKit/LayoutTests/platform/linux/css1/cascade/cascade_order-expected.png b/third_party/WebKit/LayoutTests/platform/linux/css1/cascade/cascade_order-expected.png
index dd5fab3..37baba9d 100644
--- a/third_party/WebKit/LayoutTests/platform/linux/css1/cascade/cascade_order-expected.png
+++ b/third_party/WebKit/LayoutTests/platform/linux/css1/cascade/cascade_order-expected.png
Binary files differ
diff --git a/third_party/WebKit/LayoutTests/platform/linux/css1/cascade/important-expected.png b/third_party/WebKit/LayoutTests/platform/linux/css1/cascade/important-expected.png
index 0c58c74..ddbf65eb 100644
--- a/third_party/WebKit/LayoutTests/platform/linux/css1/cascade/important-expected.png
+++ b/third_party/WebKit/LayoutTests/platform/linux/css1/cascade/important-expected.png
Binary files differ
diff --git a/third_party/WebKit/LayoutTests/platform/linux/css1/classification/display-expected.png b/third_party/WebKit/LayoutTests/platform/linux/css1/classification/display-expected.png
index be2308b..0735a99d 100644
--- a/third_party/WebKit/LayoutTests/platform/linux/css1/classification/display-expected.png
+++ b/third_party/WebKit/LayoutTests/platform/linux/css1/classification/display-expected.png
Binary files differ
diff --git a/third_party/WebKit/LayoutTests/platform/linux/css1/classification/list_style-expected.png b/third_party/WebKit/LayoutTests/platform/linux/css1/classification/list_style-expected.png
index 8af6f55..50397b4 100644
--- a/third_party/WebKit/LayoutTests/platform/linux/css1/classification/list_style-expected.png
+++ b/third_party/WebKit/LayoutTests/platform/linux/css1/classification/list_style-expected.png
Binary files differ
diff --git a/third_party/WebKit/LayoutTests/platform/linux/css1/classification/list_style_image-expected.png b/third_party/WebKit/LayoutTests/platform/linux/css1/classification/list_style_image-expected.png
index a64cb3185..fe5d4fd 100644
--- a/third_party/WebKit/LayoutTests/platform/linux/css1/classification/list_style_image-expected.png
+++ b/third_party/WebKit/LayoutTests/platform/linux/css1/classification/list_style_image-expected.png
Binary files differ
diff --git a/third_party/WebKit/LayoutTests/platform/linux/css1/classification/list_style_position-expected.png b/third_party/WebKit/LayoutTests/platform/linux/css1/classification/list_style_position-expected.png
index cf3bd14..44839a39 100644
--- a/third_party/WebKit/LayoutTests/platform/linux/css1/classification/list_style_position-expected.png
+++ b/third_party/WebKit/LayoutTests/platform/linux/css1/classification/list_style_position-expected.png
Binary files differ
diff --git a/third_party/WebKit/LayoutTests/platform/linux/css1/classification/list_style_type-expected.png b/third_party/WebKit/LayoutTests/platform/linux/css1/classification/list_style_type-expected.png
index 0b2ec471..2443af0 100644
--- a/third_party/WebKit/LayoutTests/platform/linux/css1/classification/list_style_type-expected.png
+++ b/third_party/WebKit/LayoutTests/platform/linux/css1/classification/list_style_type-expected.png
Binary files differ
diff --git a/third_party/WebKit/LayoutTests/platform/linux/css1/classification/white_space-expected.png b/third_party/WebKit/LayoutTests/platform/linux/css1/classification/white_space-expected.png
index cee3d70..b365602 100644
--- a/third_party/WebKit/LayoutTests/platform/linux/css1/classification/white_space-expected.png
+++ b/third_party/WebKit/LayoutTests/platform/linux/css1/classification/white_space-expected.png
Binary files differ
diff --git a/third_party/WebKit/LayoutTests/platform/linux/css1/color_and_background/background-expected.png b/third_party/WebKit/LayoutTests/platform/linux/css1/color_and_background/background-expected.png
index 6c1a350b..089897e 100644
--- a/third_party/WebKit/LayoutTests/platform/linux/css1/color_and_background/background-expected.png
+++ b/third_party/WebKit/LayoutTests/platform/linux/css1/color_and_background/background-expected.png
Binary files differ
diff --git a/third_party/WebKit/LayoutTests/platform/linux/css1/color_and_background/background_attachment-expected.png b/third_party/WebKit/LayoutTests/platform/linux/css1/color_and_background/background_attachment-expected.png
index 74f6c50..b660bb6 100644
--- a/third_party/WebKit/LayoutTests/platform/linux/css1/color_and_background/background_attachment-expected.png
+++ b/third_party/WebKit/LayoutTests/platform/linux/css1/color_and_background/background_attachment-expected.png
Binary files differ
diff --git a/third_party/WebKit/LayoutTests/platform/linux/css1/color_and_background/background_color-expected.png b/third_party/WebKit/LayoutTests/platform/linux/css1/color_and_background/background_color-expected.png
index 6782702..9637cf72 100644
--- a/third_party/WebKit/LayoutTests/platform/linux/css1/color_and_background/background_color-expected.png
+++ b/third_party/WebKit/LayoutTests/platform/linux/css1/color_and_background/background_color-expected.png
Binary files differ
diff --git a/third_party/WebKit/LayoutTests/platform/linux/css1/color_and_background/background_image-expected.png b/third_party/WebKit/LayoutTests/platform/linux/css1/color_and_background/background_image-expected.png
index 46b0989..2f8cdc8 100644
--- a/third_party/WebKit/LayoutTests/platform/linux/css1/color_and_background/background_image-expected.png
+++ b/third_party/WebKit/LayoutTests/platform/linux/css1/color_and_background/background_image-expected.png
Binary files differ
diff --git a/third_party/WebKit/LayoutTests/platform/linux/css1/color_and_background/background_position-expected.png b/third_party/WebKit/LayoutTests/platform/linux/css1/color_and_background/background_position-expected.png
index e884f3d..df4cca7 100644
--- a/third_party/WebKit/LayoutTests/platform/linux/css1/color_and_background/background_position-expected.png
+++ b/third_party/WebKit/LayoutTests/platform/linux/css1/color_and_background/background_position-expected.png
Binary files differ
diff --git a/third_party/WebKit/LayoutTests/platform/linux/css1/color_and_background/background_repeat-expected.png b/third_party/WebKit/LayoutTests/platform/linux/css1/color_and_background/background_repeat-expected.png
index af1364cb3..6925281 100644
--- a/third_party/WebKit/LayoutTests/platform/linux/css1/color_and_background/background_repeat-expected.png
+++ b/third_party/WebKit/LayoutTests/platform/linux/css1/color_and_background/background_repeat-expected.png
Binary files differ
diff --git a/third_party/WebKit/LayoutTests/platform/linux/css1/color_and_background/color-expected.png b/third_party/WebKit/LayoutTests/platform/linux/css1/color_and_background/color-expected.png
index 53cba51..5dbe7d03 100644
--- a/third_party/WebKit/LayoutTests/platform/linux/css1/color_and_background/color-expected.png
+++ b/third_party/WebKit/LayoutTests/platform/linux/css1/color_and_background/color-expected.png
Binary files differ
diff --git a/third_party/WebKit/LayoutTests/platform/linux/css1/conformance/forward_compatible_parsing-expected.png b/third_party/WebKit/LayoutTests/platform/linux/css1/conformance/forward_compatible_parsing-expected.png
index 9f2d41e..5eebe27 100644
--- a/third_party/WebKit/LayoutTests/platform/linux/css1/conformance/forward_compatible_parsing-expected.png
+++ b/third_party/WebKit/LayoutTests/platform/linux/css1/conformance/forward_compatible_parsing-expected.png
Binary files differ
diff --git a/third_party/WebKit/LayoutTests/platform/linux/css1/conformance/forward_compatible_parsing-expected.txt b/third_party/WebKit/LayoutTests/platform/linux/css1/conformance/forward_compatible_parsing-expected.txt
index 66ce4051..4972027 100644
--- a/third_party/WebKit/LayoutTests/platform/linux/css1/conformance/forward_compatible_parsing-expected.txt
+++ b/third_party/WebKit/LayoutTests/platform/linux/css1/conformance/forward_compatible_parsing-expected.txt
@@ -92,12 +92,12 @@
           text run at (0,656) width 0: " "
           text run at (0,672) width 360: "P.twentya {rotation-code: \"}\"; color: blue;} "
           text run at (360,672) width 0: " "
-          text run at (0,688) width 390: "P.twentyb {rotation-code: \"\\\"}\\\"\"; color: green;}"
-          text run at (390,688) width 0: " "
+          text run at (0,688) width 392: "P.twentyb {rotation-code: \"\\\"}\\\"\"; color: green;}"
+          text run at (392,688) width 0: " "
           text run at (0,704) width 400: "P.twentyonea {rotation-code: '}'; color: purple;} "
           text run at (400,704) width 0: " "
-          text run at (0,720) width 414: "P.twentyoneb {rotation-code: '\\'}\\''; color: green;}"
-          text run at (414,720) width 0: " "
+          text run at (0,720) width 416: "P.twentyoneb {rotation-code: '\\'}\\''; color: green;}"
+          text run at (416,720) width 0: " "
           text run at (0,736) width 104: "P.twentytwo {"
           text run at (104,736) width 0: " "
           text run at (0,752) width 376: " type-display: @threedee {rotation-code: '}';};"
diff --git a/third_party/WebKit/LayoutTests/platform/linux/css1/font_properties/font-expected.png b/third_party/WebKit/LayoutTests/platform/linux/css1/font_properties/font-expected.png
index 6448fda9..2fedb21 100644
--- a/third_party/WebKit/LayoutTests/platform/linux/css1/font_properties/font-expected.png
+++ b/third_party/WebKit/LayoutTests/platform/linux/css1/font_properties/font-expected.png
Binary files differ
diff --git a/third_party/WebKit/LayoutTests/platform/linux/css1/font_properties/font_family-expected.png b/third_party/WebKit/LayoutTests/platform/linux/css1/font_properties/font_family-expected.png
index 440a9ee..9c2375bd 100644
--- a/third_party/WebKit/LayoutTests/platform/linux/css1/font_properties/font_family-expected.png
+++ b/third_party/WebKit/LayoutTests/platform/linux/css1/font_properties/font_family-expected.png
Binary files differ
diff --git a/third_party/WebKit/LayoutTests/platform/linux/css1/font_properties/font_size-expected.png b/third_party/WebKit/LayoutTests/platform/linux/css1/font_properties/font_size-expected.png
index 66b91c9..77bb07f 100644
--- a/third_party/WebKit/LayoutTests/platform/linux/css1/font_properties/font_size-expected.png
+++ b/third_party/WebKit/LayoutTests/platform/linux/css1/font_properties/font_size-expected.png
Binary files differ
diff --git a/third_party/WebKit/LayoutTests/platform/linux/css1/font_properties/font_style-expected.png b/third_party/WebKit/LayoutTests/platform/linux/css1/font_properties/font_style-expected.png
index a1daaf4..33e7506 100644
--- a/third_party/WebKit/LayoutTests/platform/linux/css1/font_properties/font_style-expected.png
+++ b/third_party/WebKit/LayoutTests/platform/linux/css1/font_properties/font_style-expected.png
Binary files differ
diff --git a/third_party/WebKit/LayoutTests/platform/linux/css1/font_properties/font_variant-expected.png b/third_party/WebKit/LayoutTests/platform/linux/css1/font_properties/font_variant-expected.png
index feb15da7..c45818c4 100644
--- a/third_party/WebKit/LayoutTests/platform/linux/css1/font_properties/font_variant-expected.png
+++ b/third_party/WebKit/LayoutTests/platform/linux/css1/font_properties/font_variant-expected.png
Binary files differ
diff --git a/third_party/WebKit/LayoutTests/platform/linux/css1/font_properties/font_weight-expected.png b/third_party/WebKit/LayoutTests/platform/linux/css1/font_properties/font_weight-expected.png
index 5dee9b5e..227a2b5 100644
--- a/third_party/WebKit/LayoutTests/platform/linux/css1/font_properties/font_weight-expected.png
+++ b/third_party/WebKit/LayoutTests/platform/linux/css1/font_properties/font_weight-expected.png
Binary files differ
diff --git a/third_party/WebKit/LayoutTests/platform/linux/css1/formatting_model/canvas-expected.png b/third_party/WebKit/LayoutTests/platform/linux/css1/formatting_model/canvas-expected.png
index f787874..a02bac0 100644
--- a/third_party/WebKit/LayoutTests/platform/linux/css1/formatting_model/canvas-expected.png
+++ b/third_party/WebKit/LayoutTests/platform/linux/css1/formatting_model/canvas-expected.png
Binary files differ
diff --git a/third_party/WebKit/LayoutTests/platform/linux/css1/formatting_model/floating_elements-expected.png b/third_party/WebKit/LayoutTests/platform/linux/css1/formatting_model/floating_elements-expected.png
index ca1bef1..a7eeb697 100644
--- a/third_party/WebKit/LayoutTests/platform/linux/css1/formatting_model/floating_elements-expected.png
+++ b/third_party/WebKit/LayoutTests/platform/linux/css1/formatting_model/floating_elements-expected.png
Binary files differ
diff --git a/third_party/WebKit/LayoutTests/platform/linux/css1/formatting_model/height_of_lines-expected.png b/third_party/WebKit/LayoutTests/platform/linux/css1/formatting_model/height_of_lines-expected.png
index 89f146c..320b7fcd 100644
--- a/third_party/WebKit/LayoutTests/platform/linux/css1/formatting_model/height_of_lines-expected.png
+++ b/third_party/WebKit/LayoutTests/platform/linux/css1/formatting_model/height_of_lines-expected.png
Binary files differ
diff --git a/third_party/WebKit/LayoutTests/platform/linux/css1/formatting_model/inline_elements-expected.png b/third_party/WebKit/LayoutTests/platform/linux/css1/formatting_model/inline_elements-expected.png
index b4f0984b..9ee24fb7 100644
--- a/third_party/WebKit/LayoutTests/platform/linux/css1/formatting_model/inline_elements-expected.png
+++ b/third_party/WebKit/LayoutTests/platform/linux/css1/formatting_model/inline_elements-expected.png
Binary files differ
diff --git a/third_party/WebKit/LayoutTests/platform/linux/css1/formatting_model/replaced_elements-expected.png b/third_party/WebKit/LayoutTests/platform/linux/css1/formatting_model/replaced_elements-expected.png
index 4a07bd70..c2dfaa2 100644
--- a/third_party/WebKit/LayoutTests/platform/linux/css1/formatting_model/replaced_elements-expected.png
+++ b/third_party/WebKit/LayoutTests/platform/linux/css1/formatting_model/replaced_elements-expected.png
Binary files differ
diff --git a/third_party/WebKit/LayoutTests/platform/linux/css1/formatting_model/vertical_formatting-expected.png b/third_party/WebKit/LayoutTests/platform/linux/css1/formatting_model/vertical_formatting-expected.png
index 3157dee5..7a7b891 100644
--- a/third_party/WebKit/LayoutTests/platform/linux/css1/formatting_model/vertical_formatting-expected.png
+++ b/third_party/WebKit/LayoutTests/platform/linux/css1/formatting_model/vertical_formatting-expected.png
Binary files differ
diff --git a/third_party/WebKit/LayoutTests/platform/linux/css1/pseudo/anchor-expected.png b/third_party/WebKit/LayoutTests/platform/linux/css1/pseudo/anchor-expected.png
index fc66848f..b4e611b 100644
--- a/third_party/WebKit/LayoutTests/platform/linux/css1/pseudo/anchor-expected.png
+++ b/third_party/WebKit/LayoutTests/platform/linux/css1/pseudo/anchor-expected.png
Binary files differ
diff --git a/third_party/WebKit/LayoutTests/platform/linux/css1/pseudo/firstletter-expected.png b/third_party/WebKit/LayoutTests/platform/linux/css1/pseudo/firstletter-expected.png
index 9efadaaf..508325c6 100644
--- a/third_party/WebKit/LayoutTests/platform/linux/css1/pseudo/firstletter-expected.png
+++ b/third_party/WebKit/LayoutTests/platform/linux/css1/pseudo/firstletter-expected.png
Binary files differ
diff --git a/third_party/WebKit/LayoutTests/platform/linux/css1/pseudo/firstline-expected.png b/third_party/WebKit/LayoutTests/platform/linux/css1/pseudo/firstline-expected.png
index cbb0334..8fb0e49 100644
--- a/third_party/WebKit/LayoutTests/platform/linux/css1/pseudo/firstline-expected.png
+++ b/third_party/WebKit/LayoutTests/platform/linux/css1/pseudo/firstline-expected.png
Binary files differ
diff --git a/third_party/WebKit/LayoutTests/platform/linux/css1/pseudo/multiple_pseudo_elements-expected.png b/third_party/WebKit/LayoutTests/platform/linux/css1/pseudo/multiple_pseudo_elements-expected.png
index 8bcc5127..2113b53 100644
--- a/third_party/WebKit/LayoutTests/platform/linux/css1/pseudo/multiple_pseudo_elements-expected.png
+++ b/third_party/WebKit/LayoutTests/platform/linux/css1/pseudo/multiple_pseudo_elements-expected.png
Binary files differ
diff --git a/third_party/WebKit/LayoutTests/platform/linux/css1/pseudo/pseudo_elements_in_selectors-expected.png b/third_party/WebKit/LayoutTests/platform/linux/css1/pseudo/pseudo_elements_in_selectors-expected.png
index 8eb7716a..33e24d83 100644
--- a/third_party/WebKit/LayoutTests/platform/linux/css1/pseudo/pseudo_elements_in_selectors-expected.png
+++ b/third_party/WebKit/LayoutTests/platform/linux/css1/pseudo/pseudo_elements_in_selectors-expected.png
Binary files differ
diff --git a/third_party/WebKit/LayoutTests/platform/linux/css1/text_properties/letter_spacing-expected.png b/third_party/WebKit/LayoutTests/platform/linux/css1/text_properties/letter_spacing-expected.png
index 576b99d..3656028 100644
--- a/third_party/WebKit/LayoutTests/platform/linux/css1/text_properties/letter_spacing-expected.png
+++ b/third_party/WebKit/LayoutTests/platform/linux/css1/text_properties/letter_spacing-expected.png
Binary files differ
diff --git a/third_party/WebKit/LayoutTests/platform/linux/css1/text_properties/line_height-expected.png b/third_party/WebKit/LayoutTests/platform/linux/css1/text_properties/line_height-expected.png
index 4539f37..7fa6c3d3 100644
--- a/third_party/WebKit/LayoutTests/platform/linux/css1/text_properties/line_height-expected.png
+++ b/third_party/WebKit/LayoutTests/platform/linux/css1/text_properties/line_height-expected.png
Binary files differ
diff --git a/third_party/WebKit/LayoutTests/platform/linux/css1/text_properties/text_align-expected.png b/third_party/WebKit/LayoutTests/platform/linux/css1/text_properties/text_align-expected.png
index 435c1c4..f3c86e42 100644
--- a/third_party/WebKit/LayoutTests/platform/linux/css1/text_properties/text_align-expected.png
+++ b/third_party/WebKit/LayoutTests/platform/linux/css1/text_properties/text_align-expected.png
Binary files differ
diff --git a/third_party/WebKit/LayoutTests/platform/linux/css1/text_properties/text_decoration-expected.png b/third_party/WebKit/LayoutTests/platform/linux/css1/text_properties/text_decoration-expected.png
index 7fd474f..cf6624d 100644
--- a/third_party/WebKit/LayoutTests/platform/linux/css1/text_properties/text_decoration-expected.png
+++ b/third_party/WebKit/LayoutTests/platform/linux/css1/text_properties/text_decoration-expected.png
Binary files differ
diff --git a/third_party/WebKit/LayoutTests/platform/linux/css1/text_properties/text_indent-expected.png b/third_party/WebKit/LayoutTests/platform/linux/css1/text_properties/text_indent-expected.png
index af717e6..bac5342 100644
--- a/third_party/WebKit/LayoutTests/platform/linux/css1/text_properties/text_indent-expected.png
+++ b/third_party/WebKit/LayoutTests/platform/linux/css1/text_properties/text_indent-expected.png
Binary files differ
diff --git a/third_party/WebKit/LayoutTests/platform/linux/css1/text_properties/text_transform-expected.png b/third_party/WebKit/LayoutTests/platform/linux/css1/text_properties/text_transform-expected.png
index fb73520..4074ca7e 100644
--- a/third_party/WebKit/LayoutTests/platform/linux/css1/text_properties/text_transform-expected.png
+++ b/third_party/WebKit/LayoutTests/platform/linux/css1/text_properties/text_transform-expected.png
Binary files differ
diff --git a/third_party/WebKit/LayoutTests/platform/linux/css1/text_properties/vertical_align-expected.png b/third_party/WebKit/LayoutTests/platform/linux/css1/text_properties/vertical_align-expected.png
index 8e08d880..8b69dd9 100644
--- a/third_party/WebKit/LayoutTests/platform/linux/css1/text_properties/vertical_align-expected.png
+++ b/third_party/WebKit/LayoutTests/platform/linux/css1/text_properties/vertical_align-expected.png
Binary files differ
diff --git a/third_party/WebKit/LayoutTests/platform/linux/css1/text_properties/word_spacing-expected.png b/third_party/WebKit/LayoutTests/platform/linux/css1/text_properties/word_spacing-expected.png
index 140efd6..badd717a 100644
--- a/third_party/WebKit/LayoutTests/platform/linux/css1/text_properties/word_spacing-expected.png
+++ b/third_party/WebKit/LayoutTests/platform/linux/css1/text_properties/word_spacing-expected.png
Binary files differ
diff --git a/third_party/WebKit/LayoutTests/platform/linux/css1/units/color_units-expected.png b/third_party/WebKit/LayoutTests/platform/linux/css1/units/color_units-expected.png
index e768313..f4bae11 100644
--- a/third_party/WebKit/LayoutTests/platform/linux/css1/units/color_units-expected.png
+++ b/third_party/WebKit/LayoutTests/platform/linux/css1/units/color_units-expected.png
Binary files differ
diff --git a/third_party/WebKit/LayoutTests/platform/linux/css1/units/length_units-expected.png b/third_party/WebKit/LayoutTests/platform/linux/css1/units/length_units-expected.png
index 92bab55..88cfcd4 100644
--- a/third_party/WebKit/LayoutTests/platform/linux/css1/units/length_units-expected.png
+++ b/third_party/WebKit/LayoutTests/platform/linux/css1/units/length_units-expected.png
Binary files differ
diff --git a/third_party/WebKit/LayoutTests/platform/linux/css1/units/percentage_units-expected.png b/third_party/WebKit/LayoutTests/platform/linux/css1/units/percentage_units-expected.png
index c77e636..05f2895 100644
--- a/third_party/WebKit/LayoutTests/platform/linux/css1/units/percentage_units-expected.png
+++ b/third_party/WebKit/LayoutTests/platform/linux/css1/units/percentage_units-expected.png
Binary files differ
diff --git a/third_party/WebKit/LayoutTests/platform/linux/css1/units/urls-expected.png b/third_party/WebKit/LayoutTests/platform/linux/css1/units/urls-expected.png
index 988b7d5e..6c22c11 100644
--- a/third_party/WebKit/LayoutTests/platform/linux/css1/units/urls-expected.png
+++ b/third_party/WebKit/LayoutTests/platform/linux/css1/units/urls-expected.png
Binary files differ
diff --git a/third_party/WebKit/LayoutTests/platform/linux/css2.1/20110323/c543-txt-decor-000-expected.png b/third_party/WebKit/LayoutTests/platform/linux/css2.1/20110323/c543-txt-decor-000-expected.png
index ed0462e..f150be7 100644
--- a/third_party/WebKit/LayoutTests/platform/linux/css2.1/20110323/c543-txt-decor-000-expected.png
+++ b/third_party/WebKit/LayoutTests/platform/linux/css2.1/20110323/c543-txt-decor-000-expected.png
Binary files differ
diff --git a/third_party/WebKit/LayoutTests/platform/linux/css2.1/t0402-c71-fwd-parsing-02-f-expected.png b/third_party/WebKit/LayoutTests/platform/linux/css2.1/t0402-c71-fwd-parsing-02-f-expected.png
index dfcf4458..2a13c38a 100644
--- a/third_party/WebKit/LayoutTests/platform/linux/css2.1/t0402-c71-fwd-parsing-02-f-expected.png
+++ b/third_party/WebKit/LayoutTests/platform/linux/css2.1/t0402-c71-fwd-parsing-02-f-expected.png
Binary files differ
diff --git a/third_party/WebKit/LayoutTests/platform/linux/css2.1/t0602-c13-inh-underlin-00-e-expected.png b/third_party/WebKit/LayoutTests/platform/linux/css2.1/t0602-c13-inh-underlin-00-e-expected.png
index 1e66283..a0e543f 100644
--- a/third_party/WebKit/LayoutTests/platform/linux/css2.1/t0602-c13-inh-underlin-00-e-expected.png
+++ b/third_party/WebKit/LayoutTests/platform/linux/css2.1/t0602-c13-inh-underlin-00-e-expected.png
Binary files differ
diff --git a/third_party/WebKit/LayoutTests/platform/linux/css2.1/t0805-c5522-brdr-02-e-expected.png b/third_party/WebKit/LayoutTests/platform/linux/css2.1/t0805-c5522-brdr-02-e-expected.png
index cd6ddc13..27fc7cce 100644
--- a/third_party/WebKit/LayoutTests/platform/linux/css2.1/t0805-c5522-brdr-02-e-expected.png
+++ b/third_party/WebKit/LayoutTests/platform/linux/css2.1/t0805-c5522-brdr-02-e-expected.png
Binary files differ
diff --git a/third_party/WebKit/LayoutTests/platform/linux/css2.1/t1202-counter-01-b-expected.png b/third_party/WebKit/LayoutTests/platform/linux/css2.1/t1202-counter-01-b-expected.png
index 4cc246d..7094737 100644
--- a/third_party/WebKit/LayoutTests/platform/linux/css2.1/t1202-counter-01-b-expected.png
+++ b/third_party/WebKit/LayoutTests/platform/linux/css2.1/t1202-counter-01-b-expected.png
Binary files differ
diff --git a/third_party/WebKit/LayoutTests/platform/linux/css2.1/t1202-counter-02-b-expected.png b/third_party/WebKit/LayoutTests/platform/linux/css2.1/t1202-counter-02-b-expected.png
index 3d3cba7..dd15f42 100644
--- a/third_party/WebKit/LayoutTests/platform/linux/css2.1/t1202-counter-02-b-expected.png
+++ b/third_party/WebKit/LayoutTests/platform/linux/css2.1/t1202-counter-02-b-expected.png
Binary files differ
diff --git a/third_party/WebKit/LayoutTests/platform/linux/css2.1/t1202-counter-03-b-expected.png b/third_party/WebKit/LayoutTests/platform/linux/css2.1/t1202-counter-03-b-expected.png
index 38fc36e8..2e4bc8f 100644
--- a/third_party/WebKit/LayoutTests/platform/linux/css2.1/t1202-counter-03-b-expected.png
+++ b/third_party/WebKit/LayoutTests/platform/linux/css2.1/t1202-counter-03-b-expected.png
Binary files differ
diff --git a/third_party/WebKit/LayoutTests/platform/linux/css2.1/t1202-counter-04-b-expected.png b/third_party/WebKit/LayoutTests/platform/linux/css2.1/t1202-counter-04-b-expected.png
index 75068b3..1c77c82c6 100644
--- a/third_party/WebKit/LayoutTests/platform/linux/css2.1/t1202-counter-04-b-expected.png
+++ b/third_party/WebKit/LayoutTests/platform/linux/css2.1/t1202-counter-04-b-expected.png
Binary files differ
diff --git a/third_party/WebKit/LayoutTests/platform/linux/css2.1/t1202-counters-01-b-expected.png b/third_party/WebKit/LayoutTests/platform/linux/css2.1/t1202-counters-01-b-expected.png
index 088004f8..b4200b31 100644
--- a/third_party/WebKit/LayoutTests/platform/linux/css2.1/t1202-counters-01-b-expected.png
+++ b/third_party/WebKit/LayoutTests/platform/linux/css2.1/t1202-counters-01-b-expected.png
Binary files differ
diff --git a/third_party/WebKit/LayoutTests/platform/linux/css2.1/t1202-counters-02-b-expected.png b/third_party/WebKit/LayoutTests/platform/linux/css2.1/t1202-counters-02-b-expected.png
index 0a98c56..19449ed 100644
--- a/third_party/WebKit/LayoutTests/platform/linux/css2.1/t1202-counters-02-b-expected.png
+++ b/third_party/WebKit/LayoutTests/platform/linux/css2.1/t1202-counters-02-b-expected.png
Binary files differ
diff --git a/third_party/WebKit/LayoutTests/platform/linux/css2.1/t1202-counters-03-b-expected.png b/third_party/WebKit/LayoutTests/platform/linux/css2.1/t1202-counters-03-b-expected.png
index 1a13690..68ffd64 100644
--- a/third_party/WebKit/LayoutTests/platform/linux/css2.1/t1202-counters-03-b-expected.png
+++ b/third_party/WebKit/LayoutTests/platform/linux/css2.1/t1202-counters-03-b-expected.png
Binary files differ
diff --git a/third_party/WebKit/LayoutTests/platform/linux/css2.1/t1202-counters-04-b-expected.png b/third_party/WebKit/LayoutTests/platform/linux/css2.1/t1202-counters-04-b-expected.png
index 60321b6..0393f771 100644
--- a/third_party/WebKit/LayoutTests/platform/linux/css2.1/t1202-counters-04-b-expected.png
+++ b/third_party/WebKit/LayoutTests/platform/linux/css2.1/t1202-counters-04-b-expected.png
Binary files differ
diff --git a/third_party/WebKit/LayoutTests/platform/linux/css2.1/t1504-c523-font-style-00-b-expected.png b/third_party/WebKit/LayoutTests/platform/linux/css2.1/t1504-c523-font-style-00-b-expected.png
index 74989a2f..8db0f0c 100644
--- a/third_party/WebKit/LayoutTests/platform/linux/css2.1/t1504-c523-font-style-00-b-expected.png
+++ b/third_party/WebKit/LayoutTests/platform/linux/css2.1/t1504-c523-font-style-00-b-expected.png
Binary files differ
diff --git a/third_party/WebKit/LayoutTests/platform/linux/css2.1/t1601-c547-indent-01-d-expected.png b/third_party/WebKit/LayoutTests/platform/linux/css2.1/t1601-c547-indent-01-d-expected.png
index 580a2c2..70c2a4e 100644
--- a/third_party/WebKit/LayoutTests/platform/linux/css2.1/t1601-c547-indent-01-d-expected.png
+++ b/third_party/WebKit/LayoutTests/platform/linux/css2.1/t1601-c547-indent-01-d-expected.png
Binary files differ
diff --git a/third_party/WebKit/LayoutTests/platform/linux/css3/css3-modsel-35-expected.png b/third_party/WebKit/LayoutTests/platform/linux/css3/css3-modsel-35-expected.png
index 999aaa2..e6e546f 100644
--- a/third_party/WebKit/LayoutTests/platform/linux/css3/css3-modsel-35-expected.png
+++ b/third_party/WebKit/LayoutTests/platform/linux/css3/css3-modsel-35-expected.png
Binary files differ
diff --git a/third_party/WebKit/LayoutTests/platform/linux/css3/css3-modsel-37-expected.png b/third_party/WebKit/LayoutTests/platform/linux/css3/css3-modsel-37-expected.png
index f33e5b59a..c3146f5 100644
--- a/third_party/WebKit/LayoutTests/platform/linux/css3/css3-modsel-37-expected.png
+++ b/third_party/WebKit/LayoutTests/platform/linux/css3/css3-modsel-37-expected.png
Binary files differ
diff --git a/third_party/WebKit/LayoutTests/platform/linux/css3/flexbox/button-expected.png b/third_party/WebKit/LayoutTests/platform/linux/css3/flexbox/button-expected.png
index 31cc325..d9309e2 100644
--- a/third_party/WebKit/LayoutTests/platform/linux/css3/flexbox/button-expected.png
+++ b/third_party/WebKit/LayoutTests/platform/linux/css3/flexbox/button-expected.png
Binary files differ
diff --git a/third_party/WebKit/LayoutTests/platform/linux/css3/selectors3/html/css3-modsel-14c-expected.png b/third_party/WebKit/LayoutTests/platform/linux/css3/selectors3/html/css3-modsel-14c-expected.png
index ba39e590..a4d2327 100644
--- a/third_party/WebKit/LayoutTests/platform/linux/css3/selectors3/html/css3-modsel-14c-expected.png
+++ b/third_party/WebKit/LayoutTests/platform/linux/css3/selectors3/html/css3-modsel-14c-expected.png
Binary files differ
diff --git a/third_party/WebKit/LayoutTests/platform/linux/css3/selectors3/html/css3-modsel-14e-expected.png b/third_party/WebKit/LayoutTests/platform/linux/css3/selectors3/html/css3-modsel-14e-expected.png
index ba39e590..a4d2327 100644
--- a/third_party/WebKit/LayoutTests/platform/linux/css3/selectors3/html/css3-modsel-14e-expected.png
+++ b/third_party/WebKit/LayoutTests/platform/linux/css3/selectors3/html/css3-modsel-14e-expected.png
Binary files differ
diff --git a/third_party/WebKit/LayoutTests/platform/linux/css3/selectors3/html/css3-modsel-18-expected.png b/third_party/WebKit/LayoutTests/platform/linux/css3/selectors3/html/css3-modsel-18-expected.png
index f6bb9e3..51a817f 100644
--- a/third_party/WebKit/LayoutTests/platform/linux/css3/selectors3/html/css3-modsel-18-expected.png
+++ b/third_party/WebKit/LayoutTests/platform/linux/css3/selectors3/html/css3-modsel-18-expected.png
Binary files differ
diff --git a/third_party/WebKit/LayoutTests/platform/linux/css3/selectors3/html/css3-modsel-2-expected.png b/third_party/WebKit/LayoutTests/platform/linux/css3/selectors3/html/css3-modsel-2-expected.png
index 9f2ff492..2582b9b 100644
--- a/third_party/WebKit/LayoutTests/platform/linux/css3/selectors3/html/css3-modsel-2-expected.png
+++ b/third_party/WebKit/LayoutTests/platform/linux/css3/selectors3/html/css3-modsel-2-expected.png
Binary files differ
diff --git a/third_party/WebKit/LayoutTests/platform/linux/css3/selectors3/html/css3-modsel-30-expected.png b/third_party/WebKit/LayoutTests/platform/linux/css3/selectors3/html/css3-modsel-30-expected.png
index 21df23c..8b65416 100644
--- a/third_party/WebKit/LayoutTests/platform/linux/css3/selectors3/html/css3-modsel-30-expected.png
+++ b/third_party/WebKit/LayoutTests/platform/linux/css3/selectors3/html/css3-modsel-30-expected.png
Binary files differ
diff --git a/third_party/WebKit/LayoutTests/platform/linux/css3/selectors3/html/css3-modsel-31-expected.png b/third_party/WebKit/LayoutTests/platform/linux/css3/selectors3/html/css3-modsel-31-expected.png
index 7e7f3600..e350151 100644
--- a/third_party/WebKit/LayoutTests/platform/linux/css3/selectors3/html/css3-modsel-31-expected.png
+++ b/third_party/WebKit/LayoutTests/platform/linux/css3/selectors3/html/css3-modsel-31-expected.png
Binary files differ
diff --git a/third_party/WebKit/LayoutTests/platform/linux/css3/selectors3/html/css3-modsel-34-expected.png b/third_party/WebKit/LayoutTests/platform/linux/css3/selectors3/html/css3-modsel-34-expected.png
index a3383b82..241ad98 100644
--- a/third_party/WebKit/LayoutTests/platform/linux/css3/selectors3/html/css3-modsel-34-expected.png
+++ b/third_party/WebKit/LayoutTests/platform/linux/css3/selectors3/html/css3-modsel-34-expected.png
Binary files differ
diff --git a/third_party/WebKit/LayoutTests/platform/linux/css3/selectors3/html/css3-modsel-35-expected.png b/third_party/WebKit/LayoutTests/platform/linux/css3/selectors3/html/css3-modsel-35-expected.png
index 999aaa2..e6e546f 100644
--- a/third_party/WebKit/LayoutTests/platform/linux/css3/selectors3/html/css3-modsel-35-expected.png
+++ b/third_party/WebKit/LayoutTests/platform/linux/css3/selectors3/html/css3-modsel-35-expected.png
Binary files differ
diff --git a/third_party/WebKit/LayoutTests/platform/linux/css3/selectors3/html/css3-modsel-37-expected.png b/third_party/WebKit/LayoutTests/platform/linux/css3/selectors3/html/css3-modsel-37-expected.png
index f33e5b59a..c3146f5 100644
--- a/third_party/WebKit/LayoutTests/platform/linux/css3/selectors3/html/css3-modsel-37-expected.png
+++ b/third_party/WebKit/LayoutTests/platform/linux/css3/selectors3/html/css3-modsel-37-expected.png
Binary files differ
diff --git a/third_party/WebKit/LayoutTests/platform/linux/css3/selectors3/html/css3-modsel-45-expected.png b/third_party/WebKit/LayoutTests/platform/linux/css3/selectors3/html/css3-modsel-45-expected.png
index 144a795b..b3f7eea 100644
--- a/third_party/WebKit/LayoutTests/platform/linux/css3/selectors3/html/css3-modsel-45-expected.png
+++ b/third_party/WebKit/LayoutTests/platform/linux/css3/selectors3/html/css3-modsel-45-expected.png
Binary files differ
diff --git a/third_party/WebKit/LayoutTests/platform/linux/css3/selectors3/html/css3-modsel-45b-expected.png b/third_party/WebKit/LayoutTests/platform/linux/css3/selectors3/html/css3-modsel-45b-expected.png
index 7e2ffce..66d12b43 100644
--- a/third_party/WebKit/LayoutTests/platform/linux/css3/selectors3/html/css3-modsel-45b-expected.png
+++ b/third_party/WebKit/LayoutTests/platform/linux/css3/selectors3/html/css3-modsel-45b-expected.png
Binary files differ
diff --git a/third_party/WebKit/LayoutTests/platform/linux/css3/selectors3/html/css3-modsel-46-expected.png b/third_party/WebKit/LayoutTests/platform/linux/css3/selectors3/html/css3-modsel-46-expected.png
index cab3a5f1a..b0c0e21a 100644
--- a/third_party/WebKit/LayoutTests/platform/linux/css3/selectors3/html/css3-modsel-46-expected.png
+++ b/third_party/WebKit/LayoutTests/platform/linux/css3/selectors3/html/css3-modsel-46-expected.png
Binary files differ
diff --git a/third_party/WebKit/LayoutTests/platform/linux/css3/selectors3/html/css3-modsel-46b-expected.png b/third_party/WebKit/LayoutTests/platform/linux/css3/selectors3/html/css3-modsel-46b-expected.png
index cab3a5f1a..b0c0e21a 100644
--- a/third_party/WebKit/LayoutTests/platform/linux/css3/selectors3/html/css3-modsel-46b-expected.png
+++ b/third_party/WebKit/LayoutTests/platform/linux/css3/selectors3/html/css3-modsel-46b-expected.png
Binary files differ
diff --git a/third_party/WebKit/LayoutTests/platform/linux/css3/selectors3/html/css3-modsel-6-expected.png b/third_party/WebKit/LayoutTests/platform/linux/css3/selectors3/html/css3-modsel-6-expected.png
index 54f602b..6c2849f 100644
--- a/third_party/WebKit/LayoutTests/platform/linux/css3/selectors3/html/css3-modsel-6-expected.png
+++ b/third_party/WebKit/LayoutTests/platform/linux/css3/selectors3/html/css3-modsel-6-expected.png
Binary files differ
diff --git a/third_party/WebKit/LayoutTests/platform/linux/css3/selectors3/html/css3-modsel-7-expected.png b/third_party/WebKit/LayoutTests/platform/linux/css3/selectors3/html/css3-modsel-7-expected.png
index 9a75fbc..680bf73 100644
--- a/third_party/WebKit/LayoutTests/platform/linux/css3/selectors3/html/css3-modsel-7-expected.png
+++ b/third_party/WebKit/LayoutTests/platform/linux/css3/selectors3/html/css3-modsel-7-expected.png
Binary files differ
diff --git a/third_party/WebKit/LayoutTests/platform/linux/css3/selectors3/html/css3-modsel-75-expected.png b/third_party/WebKit/LayoutTests/platform/linux/css3/selectors3/html/css3-modsel-75-expected.png
index 3b9cdff..2f9bc2d 100644
--- a/third_party/WebKit/LayoutTests/platform/linux/css3/selectors3/html/css3-modsel-75-expected.png
+++ b/third_party/WebKit/LayoutTests/platform/linux/css3/selectors3/html/css3-modsel-75-expected.png
Binary files differ
diff --git a/third_party/WebKit/LayoutTests/platform/linux/css3/selectors3/html/css3-modsel-75b-expected.png b/third_party/WebKit/LayoutTests/platform/linux/css3/selectors3/html/css3-modsel-75b-expected.png
index 3b9cdff..2f9bc2d 100644
--- a/third_party/WebKit/LayoutTests/platform/linux/css3/selectors3/html/css3-modsel-75b-expected.png
+++ b/third_party/WebKit/LayoutTests/platform/linux/css3/selectors3/html/css3-modsel-75b-expected.png
Binary files differ
diff --git a/third_party/WebKit/LayoutTests/platform/linux/css3/selectors3/html/css3-modsel-76-expected.png b/third_party/WebKit/LayoutTests/platform/linux/css3/selectors3/html/css3-modsel-76-expected.png
index 6961ee9..a508c321 100644
--- a/third_party/WebKit/LayoutTests/platform/linux/css3/selectors3/html/css3-modsel-76-expected.png
+++ b/third_party/WebKit/LayoutTests/platform/linux/css3/selectors3/html/css3-modsel-76-expected.png
Binary files differ
diff --git a/third_party/WebKit/LayoutTests/platform/linux/css3/selectors3/html/css3-modsel-76b-expected.png b/third_party/WebKit/LayoutTests/platform/linux/css3/selectors3/html/css3-modsel-76b-expected.png
index 6961ee9..a508c321 100644
--- a/third_party/WebKit/LayoutTests/platform/linux/css3/selectors3/html/css3-modsel-76b-expected.png
+++ b/third_party/WebKit/LayoutTests/platform/linux/css3/selectors3/html/css3-modsel-76b-expected.png
Binary files differ
diff --git a/third_party/WebKit/LayoutTests/platform/linux/css3/selectors3/html/css3-modsel-79-expected.png b/third_party/WebKit/LayoutTests/platform/linux/css3/selectors3/html/css3-modsel-79-expected.png
index c672df7..7bcf94b7 100644
--- a/third_party/WebKit/LayoutTests/platform/linux/css3/selectors3/html/css3-modsel-79-expected.png
+++ b/third_party/WebKit/LayoutTests/platform/linux/css3/selectors3/html/css3-modsel-79-expected.png
Binary files differ
diff --git a/third_party/WebKit/LayoutTests/platform/linux/css3/selectors3/html/css3-modsel-8-expected.png b/third_party/WebKit/LayoutTests/platform/linux/css3/selectors3/html/css3-modsel-8-expected.png
index 00de5f4..4f2c3c8 100644
--- a/third_party/WebKit/LayoutTests/platform/linux/css3/selectors3/html/css3-modsel-8-expected.png
+++ b/third_party/WebKit/LayoutTests/platform/linux/css3/selectors3/html/css3-modsel-8-expected.png
Binary files differ
diff --git a/third_party/WebKit/LayoutTests/platform/linux/css3/selectors3/html/css3-modsel-80-expected.png b/third_party/WebKit/LayoutTests/platform/linux/css3/selectors3/html/css3-modsel-80-expected.png
index f845909..378470e 100644
--- a/third_party/WebKit/LayoutTests/platform/linux/css3/selectors3/html/css3-modsel-80-expected.png
+++ b/third_party/WebKit/LayoutTests/platform/linux/css3/selectors3/html/css3-modsel-80-expected.png
Binary files differ
diff --git a/third_party/WebKit/LayoutTests/platform/linux/css3/selectors3/html/css3-modsel-82-expected.png b/third_party/WebKit/LayoutTests/platform/linux/css3/selectors3/html/css3-modsel-82-expected.png
index aa5c739f..9956da9 100644
--- a/third_party/WebKit/LayoutTests/platform/linux/css3/selectors3/html/css3-modsel-82-expected.png
+++ b/third_party/WebKit/LayoutTests/platform/linux/css3/selectors3/html/css3-modsel-82-expected.png
Binary files differ
diff --git a/third_party/WebKit/LayoutTests/platform/linux/css3/selectors3/html/css3-modsel-82b-expected.png b/third_party/WebKit/LayoutTests/platform/linux/css3/selectors3/html/css3-modsel-82b-expected.png
index aa5c739f..9956da9 100644
--- a/third_party/WebKit/LayoutTests/platform/linux/css3/selectors3/html/css3-modsel-82b-expected.png
+++ b/third_party/WebKit/LayoutTests/platform/linux/css3/selectors3/html/css3-modsel-82b-expected.png
Binary files differ
diff --git a/third_party/WebKit/LayoutTests/platform/linux/css3/selectors3/xhtml/css3-modsel-113-expected.png b/third_party/WebKit/LayoutTests/platform/linux/css3/selectors3/xhtml/css3-modsel-113-expected.png
index d0e58d6..1fa1558e 100644
--- a/third_party/WebKit/LayoutTests/platform/linux/css3/selectors3/xhtml/css3-modsel-113-expected.png
+++ b/third_party/WebKit/LayoutTests/platform/linux/css3/selectors3/xhtml/css3-modsel-113-expected.png
Binary files differ
diff --git a/third_party/WebKit/LayoutTests/platform/linux/css3/selectors3/xhtml/css3-modsel-113b-expected.png b/third_party/WebKit/LayoutTests/platform/linux/css3/selectors3/xhtml/css3-modsel-113b-expected.png
index d0e58d6..1fa1558e 100644
--- a/third_party/WebKit/LayoutTests/platform/linux/css3/selectors3/xhtml/css3-modsel-113b-expected.png
+++ b/third_party/WebKit/LayoutTests/platform/linux/css3/selectors3/xhtml/css3-modsel-113b-expected.png
Binary files differ
diff --git a/third_party/WebKit/LayoutTests/platform/linux/css3/selectors3/xhtml/css3-modsel-114-expected.png b/third_party/WebKit/LayoutTests/platform/linux/css3/selectors3/xhtml/css3-modsel-114-expected.png
index 7b9237ba..44f9648 100644
--- a/third_party/WebKit/LayoutTests/platform/linux/css3/selectors3/xhtml/css3-modsel-114-expected.png
+++ b/third_party/WebKit/LayoutTests/platform/linux/css3/selectors3/xhtml/css3-modsel-114-expected.png
Binary files differ
diff --git a/third_party/WebKit/LayoutTests/platform/linux/css3/selectors3/xhtml/css3-modsel-114b-expected.png b/third_party/WebKit/LayoutTests/platform/linux/css3/selectors3/xhtml/css3-modsel-114b-expected.png
index 7b9237ba..44f9648 100644
--- a/third_party/WebKit/LayoutTests/platform/linux/css3/selectors3/xhtml/css3-modsel-114b-expected.png
+++ b/third_party/WebKit/LayoutTests/platform/linux/css3/selectors3/xhtml/css3-modsel-114b-expected.png
Binary files differ
diff --git a/third_party/WebKit/LayoutTests/platform/linux/css3/selectors3/xhtml/css3-modsel-119-expected.png b/third_party/WebKit/LayoutTests/platform/linux/css3/selectors3/xhtml/css3-modsel-119-expected.png
index ca9e3ea..a62ce8fb 100644
--- a/third_party/WebKit/LayoutTests/platform/linux/css3/selectors3/xhtml/css3-modsel-119-expected.png
+++ b/third_party/WebKit/LayoutTests/platform/linux/css3/selectors3/xhtml/css3-modsel-119-expected.png
Binary files differ
diff --git a/third_party/WebKit/LayoutTests/platform/linux/css3/selectors3/xhtml/css3-modsel-121-expected.png b/third_party/WebKit/LayoutTests/platform/linux/css3/selectors3/xhtml/css3-modsel-121-expected.png
index ca7ff00..b51ef20 100644
--- a/third_party/WebKit/LayoutTests/platform/linux/css3/selectors3/xhtml/css3-modsel-121-expected.png
+++ b/third_party/WebKit/LayoutTests/platform/linux/css3/selectors3/xhtml/css3-modsel-121-expected.png
Binary files differ
diff --git a/third_party/WebKit/LayoutTests/platform/linux/css3/selectors3/xhtml/css3-modsel-122-expected.png b/third_party/WebKit/LayoutTests/platform/linux/css3/selectors3/xhtml/css3-modsel-122-expected.png
index 44ae2ad..cef2f2e 100644
--- a/third_party/WebKit/LayoutTests/platform/linux/css3/selectors3/xhtml/css3-modsel-122-expected.png
+++ b/third_party/WebKit/LayoutTests/platform/linux/css3/selectors3/xhtml/css3-modsel-122-expected.png
Binary files differ
diff --git a/third_party/WebKit/LayoutTests/platform/linux/css3/selectors3/xhtml/css3-modsel-123-expected.png b/third_party/WebKit/LayoutTests/platform/linux/css3/selectors3/xhtml/css3-modsel-123-expected.png
index 40217832..0e3df23 100644
--- a/third_party/WebKit/LayoutTests/platform/linux/css3/selectors3/xhtml/css3-modsel-123-expected.png
+++ b/third_party/WebKit/LayoutTests/platform/linux/css3/selectors3/xhtml/css3-modsel-123-expected.png
Binary files differ
diff --git a/third_party/WebKit/LayoutTests/platform/linux/css3/selectors3/xhtml/css3-modsel-139-expected.png b/third_party/WebKit/LayoutTests/platform/linux/css3/selectors3/xhtml/css3-modsel-139-expected.png
index 690e282..92390d5 100644
--- a/third_party/WebKit/LayoutTests/platform/linux/css3/selectors3/xhtml/css3-modsel-139-expected.png
+++ b/third_party/WebKit/LayoutTests/platform/linux/css3/selectors3/xhtml/css3-modsel-139-expected.png
Binary files differ
diff --git a/third_party/WebKit/LayoutTests/platform/linux/css3/selectors3/xhtml/css3-modsel-139b-expected.png b/third_party/WebKit/LayoutTests/platform/linux/css3/selectors3/xhtml/css3-modsel-139b-expected.png
index 690e282..92390d5 100644
--- a/third_party/WebKit/LayoutTests/platform/linux/css3/selectors3/xhtml/css3-modsel-139b-expected.png
+++ b/third_party/WebKit/LayoutTests/platform/linux/css3/selectors3/xhtml/css3-modsel-139b-expected.png
Binary files differ
diff --git a/third_party/WebKit/LayoutTests/platform/linux/css3/selectors3/xhtml/css3-modsel-140-expected.png b/third_party/WebKit/LayoutTests/platform/linux/css3/selectors3/xhtml/css3-modsel-140-expected.png
index f9f78ac..98699fc 100644
--- a/third_party/WebKit/LayoutTests/platform/linux/css3/selectors3/xhtml/css3-modsel-140-expected.png
+++ b/third_party/WebKit/LayoutTests/platform/linux/css3/selectors3/xhtml/css3-modsel-140-expected.png
Binary files differ
diff --git a/third_party/WebKit/LayoutTests/platform/linux/css3/selectors3/xhtml/css3-modsel-140b-expected.png b/third_party/WebKit/LayoutTests/platform/linux/css3/selectors3/xhtml/css3-modsel-140b-expected.png
index f9f78ac..98699fc 100644
--- a/third_party/WebKit/LayoutTests/platform/linux/css3/selectors3/xhtml/css3-modsel-140b-expected.png
+++ b/third_party/WebKit/LayoutTests/platform/linux/css3/selectors3/xhtml/css3-modsel-140b-expected.png
Binary files differ
diff --git a/third_party/WebKit/LayoutTests/platform/linux/css3/selectors3/xhtml/css3-modsel-14c-expected.png b/third_party/WebKit/LayoutTests/platform/linux/css3/selectors3/xhtml/css3-modsel-14c-expected.png
index ba39e590..a4d2327 100644
--- a/third_party/WebKit/LayoutTests/platform/linux/css3/selectors3/xhtml/css3-modsel-14c-expected.png
+++ b/third_party/WebKit/LayoutTests/platform/linux/css3/selectors3/xhtml/css3-modsel-14c-expected.png
Binary files differ
diff --git a/third_party/WebKit/LayoutTests/platform/linux/css3/selectors3/xhtml/css3-modsel-14e-expected.png b/third_party/WebKit/LayoutTests/platform/linux/css3/selectors3/xhtml/css3-modsel-14e-expected.png
index ba39e590..a4d2327 100644
--- a/third_party/WebKit/LayoutTests/platform/linux/css3/selectors3/xhtml/css3-modsel-14e-expected.png
+++ b/third_party/WebKit/LayoutTests/platform/linux/css3/selectors3/xhtml/css3-modsel-14e-expected.png
Binary files differ
diff --git a/third_party/WebKit/LayoutTests/platform/linux/css3/selectors3/xhtml/css3-modsel-18-expected.png b/third_party/WebKit/LayoutTests/platform/linux/css3/selectors3/xhtml/css3-modsel-18-expected.png
index f6bb9e3..51a817f 100644
--- a/third_party/WebKit/LayoutTests/platform/linux/css3/selectors3/xhtml/css3-modsel-18-expected.png
+++ b/third_party/WebKit/LayoutTests/platform/linux/css3/selectors3/xhtml/css3-modsel-18-expected.png
Binary files differ
diff --git a/third_party/WebKit/LayoutTests/platform/linux/css3/selectors3/xhtml/css3-modsel-2-expected.png b/third_party/WebKit/LayoutTests/platform/linux/css3/selectors3/xhtml/css3-modsel-2-expected.png
index 9f2ff492..2582b9b 100644
--- a/third_party/WebKit/LayoutTests/platform/linux/css3/selectors3/xhtml/css3-modsel-2-expected.png
+++ b/third_party/WebKit/LayoutTests/platform/linux/css3/selectors3/xhtml/css3-modsel-2-expected.png
Binary files differ
diff --git a/third_party/WebKit/LayoutTests/platform/linux/css3/selectors3/xhtml/css3-modsel-30-expected.png b/third_party/WebKit/LayoutTests/platform/linux/css3/selectors3/xhtml/css3-modsel-30-expected.png
index 21df23c..8b65416 100644
--- a/third_party/WebKit/LayoutTests/platform/linux/css3/selectors3/xhtml/css3-modsel-30-expected.png
+++ b/third_party/WebKit/LayoutTests/platform/linux/css3/selectors3/xhtml/css3-modsel-30-expected.png
Binary files differ
diff --git a/third_party/WebKit/LayoutTests/platform/linux/css3/selectors3/xhtml/css3-modsel-31-expected.png b/third_party/WebKit/LayoutTests/platform/linux/css3/selectors3/xhtml/css3-modsel-31-expected.png
index 7e7f3600..e350151 100644
--- a/third_party/WebKit/LayoutTests/platform/linux/css3/selectors3/xhtml/css3-modsel-31-expected.png
+++ b/third_party/WebKit/LayoutTests/platform/linux/css3/selectors3/xhtml/css3-modsel-31-expected.png
Binary files differ
diff --git a/third_party/WebKit/LayoutTests/platform/linux/css3/selectors3/xhtml/css3-modsel-34-expected.png b/third_party/WebKit/LayoutTests/platform/linux/css3/selectors3/xhtml/css3-modsel-34-expected.png
index a3383b82..241ad98 100644
--- a/third_party/WebKit/LayoutTests/platform/linux/css3/selectors3/xhtml/css3-modsel-34-expected.png
+++ b/third_party/WebKit/LayoutTests/platform/linux/css3/selectors3/xhtml/css3-modsel-34-expected.png
Binary files differ
diff --git a/third_party/WebKit/LayoutTests/platform/linux/css3/selectors3/xhtml/css3-modsel-35-expected.png b/third_party/WebKit/LayoutTests/platform/linux/css3/selectors3/xhtml/css3-modsel-35-expected.png
index 999aaa2..e6e546f 100644
--- a/third_party/WebKit/LayoutTests/platform/linux/css3/selectors3/xhtml/css3-modsel-35-expected.png
+++ b/third_party/WebKit/LayoutTests/platform/linux/css3/selectors3/xhtml/css3-modsel-35-expected.png
Binary files differ
diff --git a/third_party/WebKit/LayoutTests/platform/linux/css3/selectors3/xhtml/css3-modsel-37-expected.png b/third_party/WebKit/LayoutTests/platform/linux/css3/selectors3/xhtml/css3-modsel-37-expected.png
index f33e5b59a..c3146f5 100644
--- a/third_party/WebKit/LayoutTests/platform/linux/css3/selectors3/xhtml/css3-modsel-37-expected.png
+++ b/third_party/WebKit/LayoutTests/platform/linux/css3/selectors3/xhtml/css3-modsel-37-expected.png
Binary files differ
diff --git a/third_party/WebKit/LayoutTests/platform/linux/css3/selectors3/xhtml/css3-modsel-45-expected.png b/third_party/WebKit/LayoutTests/platform/linux/css3/selectors3/xhtml/css3-modsel-45-expected.png
index 144a795b..b3f7eea 100644
--- a/third_party/WebKit/LayoutTests/platform/linux/css3/selectors3/xhtml/css3-modsel-45-expected.png
+++ b/third_party/WebKit/LayoutTests/platform/linux/css3/selectors3/xhtml/css3-modsel-45-expected.png
Binary files differ
diff --git a/third_party/WebKit/LayoutTests/platform/linux/css3/selectors3/xhtml/css3-modsel-45b-expected.png b/third_party/WebKit/LayoutTests/platform/linux/css3/selectors3/xhtml/css3-modsel-45b-expected.png
index 7e2ffce..66d12b43 100644
--- a/third_party/WebKit/LayoutTests/platform/linux/css3/selectors3/xhtml/css3-modsel-45b-expected.png
+++ b/third_party/WebKit/LayoutTests/platform/linux/css3/selectors3/xhtml/css3-modsel-45b-expected.png
Binary files differ
diff --git a/third_party/WebKit/LayoutTests/platform/linux/css3/selectors3/xhtml/css3-modsel-46-expected.png b/third_party/WebKit/LayoutTests/platform/linux/css3/selectors3/xhtml/css3-modsel-46-expected.png
index cab3a5f1a..b0c0e21a 100644
--- a/third_party/WebKit/LayoutTests/platform/linux/css3/selectors3/xhtml/css3-modsel-46-expected.png
+++ b/third_party/WebKit/LayoutTests/platform/linux/css3/selectors3/xhtml/css3-modsel-46-expected.png
Binary files differ
diff --git a/third_party/WebKit/LayoutTests/platform/linux/css3/selectors3/xhtml/css3-modsel-46b-expected.png b/third_party/WebKit/LayoutTests/platform/linux/css3/selectors3/xhtml/css3-modsel-46b-expected.png
index cab3a5f1a..b0c0e21a 100644
--- a/third_party/WebKit/LayoutTests/platform/linux/css3/selectors3/xhtml/css3-modsel-46b-expected.png
+++ b/third_party/WebKit/LayoutTests/platform/linux/css3/selectors3/xhtml/css3-modsel-46b-expected.png
Binary files differ
diff --git a/third_party/WebKit/LayoutTests/platform/linux/css3/selectors3/xhtml/css3-modsel-47-expected.png b/third_party/WebKit/LayoutTests/platform/linux/css3/selectors3/xhtml/css3-modsel-47-expected.png
index ff325447..0352885b 100644
--- a/third_party/WebKit/LayoutTests/platform/linux/css3/selectors3/xhtml/css3-modsel-47-expected.png
+++ b/third_party/WebKit/LayoutTests/platform/linux/css3/selectors3/xhtml/css3-modsel-47-expected.png
Binary files differ
diff --git a/third_party/WebKit/LayoutTests/platform/linux/css3/selectors3/xhtml/css3-modsel-48-expected.png b/third_party/WebKit/LayoutTests/platform/linux/css3/selectors3/xhtml/css3-modsel-48-expected.png
index 44ae2ad..cef2f2e 100644
--- a/third_party/WebKit/LayoutTests/platform/linux/css3/selectors3/xhtml/css3-modsel-48-expected.png
+++ b/third_party/WebKit/LayoutTests/platform/linux/css3/selectors3/xhtml/css3-modsel-48-expected.png
Binary files differ
diff --git a/third_party/WebKit/LayoutTests/platform/linux/css3/selectors3/xhtml/css3-modsel-49-expected.png b/third_party/WebKit/LayoutTests/platform/linux/css3/selectors3/xhtml/css3-modsel-49-expected.png
index 44ae2ad..cef2f2e 100644
--- a/third_party/WebKit/LayoutTests/platform/linux/css3/selectors3/xhtml/css3-modsel-49-expected.png
+++ b/third_party/WebKit/LayoutTests/platform/linux/css3/selectors3/xhtml/css3-modsel-49-expected.png
Binary files differ
diff --git a/third_party/WebKit/LayoutTests/platform/linux/css3/selectors3/xhtml/css3-modsel-6-expected.png b/third_party/WebKit/LayoutTests/platform/linux/css3/selectors3/xhtml/css3-modsel-6-expected.png
index 54f602b..6c2849f 100644
--- a/third_party/WebKit/LayoutTests/platform/linux/css3/selectors3/xhtml/css3-modsel-6-expected.png
+++ b/third_party/WebKit/LayoutTests/platform/linux/css3/selectors3/xhtml/css3-modsel-6-expected.png
Binary files differ
diff --git a/third_party/WebKit/LayoutTests/platform/linux/css3/selectors3/xhtml/css3-modsel-7-expected.png b/third_party/WebKit/LayoutTests/platform/linux/css3/selectors3/xhtml/css3-modsel-7-expected.png
index 9a75fbc..680bf73 100644
--- a/third_party/WebKit/LayoutTests/platform/linux/css3/selectors3/xhtml/css3-modsel-7-expected.png
+++ b/third_party/WebKit/LayoutTests/platform/linux/css3/selectors3/xhtml/css3-modsel-7-expected.png
Binary files differ
diff --git a/third_party/WebKit/LayoutTests/platform/linux/css3/selectors3/xhtml/css3-modsel-75-expected.png b/third_party/WebKit/LayoutTests/platform/linux/css3/selectors3/xhtml/css3-modsel-75-expected.png
index 3b9cdff..2f9bc2d 100644
--- a/third_party/WebKit/LayoutTests/platform/linux/css3/selectors3/xhtml/css3-modsel-75-expected.png
+++ b/third_party/WebKit/LayoutTests/platform/linux/css3/selectors3/xhtml/css3-modsel-75-expected.png
Binary files differ
diff --git a/third_party/WebKit/LayoutTests/platform/linux/css3/selectors3/xhtml/css3-modsel-75b-expected.png b/third_party/WebKit/LayoutTests/platform/linux/css3/selectors3/xhtml/css3-modsel-75b-expected.png
index 3b9cdff..2f9bc2d 100644
--- a/third_party/WebKit/LayoutTests/platform/linux/css3/selectors3/xhtml/css3-modsel-75b-expected.png
+++ b/third_party/WebKit/LayoutTests/platform/linux/css3/selectors3/xhtml/css3-modsel-75b-expected.png
Binary files differ
diff --git a/third_party/WebKit/LayoutTests/platform/linux/css3/selectors3/xhtml/css3-modsel-76-expected.png b/third_party/WebKit/LayoutTests/platform/linux/css3/selectors3/xhtml/css3-modsel-76-expected.png
index 6961ee9..a508c321 100644
--- a/third_party/WebKit/LayoutTests/platform/linux/css3/selectors3/xhtml/css3-modsel-76-expected.png
+++ b/third_party/WebKit/LayoutTests/platform/linux/css3/selectors3/xhtml/css3-modsel-76-expected.png
Binary files differ
diff --git a/third_party/WebKit/LayoutTests/platform/linux/css3/selectors3/xhtml/css3-modsel-76b-expected.png b/third_party/WebKit/LayoutTests/platform/linux/css3/selectors3/xhtml/css3-modsel-76b-expected.png
index 6961ee9..a508c321 100644
--- a/third_party/WebKit/LayoutTests/platform/linux/css3/selectors3/xhtml/css3-modsel-76b-expected.png
+++ b/third_party/WebKit/LayoutTests/platform/linux/css3/selectors3/xhtml/css3-modsel-76b-expected.png
Binary files differ
diff --git a/third_party/WebKit/LayoutTests/platform/linux/css3/selectors3/xhtml/css3-modsel-79-expected.png b/third_party/WebKit/LayoutTests/platform/linux/css3/selectors3/xhtml/css3-modsel-79-expected.png
index c672df7..7bcf94b7 100644
--- a/third_party/WebKit/LayoutTests/platform/linux/css3/selectors3/xhtml/css3-modsel-79-expected.png
+++ b/third_party/WebKit/LayoutTests/platform/linux/css3/selectors3/xhtml/css3-modsel-79-expected.png
Binary files differ
diff --git a/third_party/WebKit/LayoutTests/platform/linux/css3/selectors3/xhtml/css3-modsel-8-expected.png b/third_party/WebKit/LayoutTests/platform/linux/css3/selectors3/xhtml/css3-modsel-8-expected.png
index 00de5f4..4f2c3c8 100644
--- a/third_party/WebKit/LayoutTests/platform/linux/css3/selectors3/xhtml/css3-modsel-8-expected.png
+++ b/third_party/WebKit/LayoutTests/platform/linux/css3/selectors3/xhtml/css3-modsel-8-expected.png
Binary files differ
diff --git a/third_party/WebKit/LayoutTests/platform/linux/css3/selectors3/xhtml/css3-modsel-80-expected.png b/third_party/WebKit/LayoutTests/platform/linux/css3/selectors3/xhtml/css3-modsel-80-expected.png
index f845909..378470e 100644
--- a/third_party/WebKit/LayoutTests/platform/linux/css3/selectors3/xhtml/css3-modsel-80-expected.png
+++ b/third_party/WebKit/LayoutTests/platform/linux/css3/selectors3/xhtml/css3-modsel-80-expected.png
Binary files differ
diff --git a/third_party/WebKit/LayoutTests/platform/linux/css3/selectors3/xhtml/css3-modsel-82-expected.png b/third_party/WebKit/LayoutTests/platform/linux/css3/selectors3/xhtml/css3-modsel-82-expected.png
index aa5c739f..9956da9 100644
--- a/third_party/WebKit/LayoutTests/platform/linux/css3/selectors3/xhtml/css3-modsel-82-expected.png
+++ b/third_party/WebKit/LayoutTests/platform/linux/css3/selectors3/xhtml/css3-modsel-82-expected.png
Binary files differ
diff --git a/third_party/WebKit/LayoutTests/platform/linux/css3/selectors3/xhtml/css3-modsel-82b-expected.png b/third_party/WebKit/LayoutTests/platform/linux/css3/selectors3/xhtml/css3-modsel-82b-expected.png
index aa5c739f..9956da9 100644
--- a/third_party/WebKit/LayoutTests/platform/linux/css3/selectors3/xhtml/css3-modsel-82b-expected.png
+++ b/third_party/WebKit/LayoutTests/platform/linux/css3/selectors3/xhtml/css3-modsel-82b-expected.png
Binary files differ
diff --git a/third_party/WebKit/LayoutTests/platform/linux/css3/selectors3/xml/css3-modsel-113-expected.png b/third_party/WebKit/LayoutTests/platform/linux/css3/selectors3/xml/css3-modsel-113-expected.png
index 3fe8f310..edaa1d7 100644
--- a/third_party/WebKit/LayoutTests/platform/linux/css3/selectors3/xml/css3-modsel-113-expected.png
+++ b/third_party/WebKit/LayoutTests/platform/linux/css3/selectors3/xml/css3-modsel-113-expected.png
Binary files differ
diff --git a/third_party/WebKit/LayoutTests/platform/linux/css3/selectors3/xml/css3-modsel-113b-expected.png b/third_party/WebKit/LayoutTests/platform/linux/css3/selectors3/xml/css3-modsel-113b-expected.png
index 3fe8f310..edaa1d7 100644
--- a/third_party/WebKit/LayoutTests/platform/linux/css3/selectors3/xml/css3-modsel-113b-expected.png
+++ b/third_party/WebKit/LayoutTests/platform/linux/css3/selectors3/xml/css3-modsel-113b-expected.png
Binary files differ
diff --git a/third_party/WebKit/LayoutTests/platform/linux/css3/selectors3/xml/css3-modsel-114-expected.png b/third_party/WebKit/LayoutTests/platform/linux/css3/selectors3/xml/css3-modsel-114-expected.png
index e9a9ab9..c1501ce 100644
--- a/third_party/WebKit/LayoutTests/platform/linux/css3/selectors3/xml/css3-modsel-114-expected.png
+++ b/third_party/WebKit/LayoutTests/platform/linux/css3/selectors3/xml/css3-modsel-114-expected.png
Binary files differ
diff --git a/third_party/WebKit/LayoutTests/platform/linux/css3/selectors3/xml/css3-modsel-114b-expected.png b/third_party/WebKit/LayoutTests/platform/linux/css3/selectors3/xml/css3-modsel-114b-expected.png
index e9a9ab9..c1501ce 100644
--- a/third_party/WebKit/LayoutTests/platform/linux/css3/selectors3/xml/css3-modsel-114b-expected.png
+++ b/third_party/WebKit/LayoutTests/platform/linux/css3/selectors3/xml/css3-modsel-114b-expected.png
Binary files differ
diff --git a/third_party/WebKit/LayoutTests/platform/linux/css3/selectors3/xml/css3-modsel-119-expected.png b/third_party/WebKit/LayoutTests/platform/linux/css3/selectors3/xml/css3-modsel-119-expected.png
index 75092ac5..d1c5af1 100644
--- a/third_party/WebKit/LayoutTests/platform/linux/css3/selectors3/xml/css3-modsel-119-expected.png
+++ b/third_party/WebKit/LayoutTests/platform/linux/css3/selectors3/xml/css3-modsel-119-expected.png
Binary files differ
diff --git a/third_party/WebKit/LayoutTests/platform/linux/css3/selectors3/xml/css3-modsel-121-expected.png b/third_party/WebKit/LayoutTests/platform/linux/css3/selectors3/xml/css3-modsel-121-expected.png
index f5a0ae64..efdd6289f 100644
--- a/third_party/WebKit/LayoutTests/platform/linux/css3/selectors3/xml/css3-modsel-121-expected.png
+++ b/third_party/WebKit/LayoutTests/platform/linux/css3/selectors3/xml/css3-modsel-121-expected.png
Binary files differ
diff --git a/third_party/WebKit/LayoutTests/platform/linux/css3/selectors3/xml/css3-modsel-122-expected.png b/third_party/WebKit/LayoutTests/platform/linux/css3/selectors3/xml/css3-modsel-122-expected.png
index 9967953f..610cefb 100644
--- a/third_party/WebKit/LayoutTests/platform/linux/css3/selectors3/xml/css3-modsel-122-expected.png
+++ b/third_party/WebKit/LayoutTests/platform/linux/css3/selectors3/xml/css3-modsel-122-expected.png
Binary files differ
diff --git a/third_party/WebKit/LayoutTests/platform/linux/css3/selectors3/xml/css3-modsel-123-expected.png b/third_party/WebKit/LayoutTests/platform/linux/css3/selectors3/xml/css3-modsel-123-expected.png
index e3b03d0..33cde2e 100644
--- a/third_party/WebKit/LayoutTests/platform/linux/css3/selectors3/xml/css3-modsel-123-expected.png
+++ b/third_party/WebKit/LayoutTests/platform/linux/css3/selectors3/xml/css3-modsel-123-expected.png
Binary files differ
diff --git a/third_party/WebKit/LayoutTests/platform/linux/css3/selectors3/xml/css3-modsel-139-expected.png b/third_party/WebKit/LayoutTests/platform/linux/css3/selectors3/xml/css3-modsel-139-expected.png
index 6415e34..001503518 100644
--- a/third_party/WebKit/LayoutTests/platform/linux/css3/selectors3/xml/css3-modsel-139-expected.png
+++ b/third_party/WebKit/LayoutTests/platform/linux/css3/selectors3/xml/css3-modsel-139-expected.png
Binary files differ
diff --git a/third_party/WebKit/LayoutTests/platform/linux/css3/selectors3/xml/css3-modsel-139b-expected.png b/third_party/WebKit/LayoutTests/platform/linux/css3/selectors3/xml/css3-modsel-139b-expected.png
index 6415e34..001503518 100644
--- a/third_party/WebKit/LayoutTests/platform/linux/css3/selectors3/xml/css3-modsel-139b-expected.png
+++ b/third_party/WebKit/LayoutTests/platform/linux/css3/selectors3/xml/css3-modsel-139b-expected.png
Binary files differ
diff --git a/third_party/WebKit/LayoutTests/platform/linux/css3/selectors3/xml/css3-modsel-140-expected.png b/third_party/WebKit/LayoutTests/platform/linux/css3/selectors3/xml/css3-modsel-140-expected.png
index 0c6061d..6df463b8 100644
--- a/third_party/WebKit/LayoutTests/platform/linux/css3/selectors3/xml/css3-modsel-140-expected.png
+++ b/third_party/WebKit/LayoutTests/platform/linux/css3/selectors3/xml/css3-modsel-140-expected.png
Binary files differ
diff --git a/third_party/WebKit/LayoutTests/platform/linux/css3/selectors3/xml/css3-modsel-140b-expected.png b/third_party/WebKit/LayoutTests/platform/linux/css3/selectors3/xml/css3-modsel-140b-expected.png
index 0c6061d..6df463b8 100644
--- a/third_party/WebKit/LayoutTests/platform/linux/css3/selectors3/xml/css3-modsel-140b-expected.png
+++ b/third_party/WebKit/LayoutTests/platform/linux/css3/selectors3/xml/css3-modsel-140b-expected.png
Binary files differ
diff --git a/third_party/WebKit/LayoutTests/platform/linux/css3/selectors3/xml/css3-modsel-14c-expected.png b/third_party/WebKit/LayoutTests/platform/linux/css3/selectors3/xml/css3-modsel-14c-expected.png
index c0b68e6..1405c84 100644
--- a/third_party/WebKit/LayoutTests/platform/linux/css3/selectors3/xml/css3-modsel-14c-expected.png
+++ b/third_party/WebKit/LayoutTests/platform/linux/css3/selectors3/xml/css3-modsel-14c-expected.png
Binary files differ
diff --git a/third_party/WebKit/LayoutTests/platform/linux/css3/selectors3/xml/css3-modsel-14e-expected.png b/third_party/WebKit/LayoutTests/platform/linux/css3/selectors3/xml/css3-modsel-14e-expected.png
index c0b68e6..1405c84 100644
--- a/third_party/WebKit/LayoutTests/platform/linux/css3/selectors3/xml/css3-modsel-14e-expected.png
+++ b/third_party/WebKit/LayoutTests/platform/linux/css3/selectors3/xml/css3-modsel-14e-expected.png
Binary files differ
diff --git a/third_party/WebKit/LayoutTests/platform/linux/css3/selectors3/xml/css3-modsel-18-expected.png b/third_party/WebKit/LayoutTests/platform/linux/css3/selectors3/xml/css3-modsel-18-expected.png
index c2aa2b0..d90c231 100644
--- a/third_party/WebKit/LayoutTests/platform/linux/css3/selectors3/xml/css3-modsel-18-expected.png
+++ b/third_party/WebKit/LayoutTests/platform/linux/css3/selectors3/xml/css3-modsel-18-expected.png
Binary files differ
diff --git a/third_party/WebKit/LayoutTests/platform/linux/css3/selectors3/xml/css3-modsel-2-expected.png b/third_party/WebKit/LayoutTests/platform/linux/css3/selectors3/xml/css3-modsel-2-expected.png
index d960e14..087705b4 100644
--- a/third_party/WebKit/LayoutTests/platform/linux/css3/selectors3/xml/css3-modsel-2-expected.png
+++ b/third_party/WebKit/LayoutTests/platform/linux/css3/selectors3/xml/css3-modsel-2-expected.png
Binary files differ
diff --git a/third_party/WebKit/LayoutTests/platform/linux/css3/selectors3/xml/css3-modsel-30-expected.png b/third_party/WebKit/LayoutTests/platform/linux/css3/selectors3/xml/css3-modsel-30-expected.png
index 3d8bc0e..868ae2e 100644
--- a/third_party/WebKit/LayoutTests/platform/linux/css3/selectors3/xml/css3-modsel-30-expected.png
+++ b/third_party/WebKit/LayoutTests/platform/linux/css3/selectors3/xml/css3-modsel-30-expected.png
Binary files differ
diff --git a/third_party/WebKit/LayoutTests/platform/linux/css3/selectors3/xml/css3-modsel-31-expected.png b/third_party/WebKit/LayoutTests/platform/linux/css3/selectors3/xml/css3-modsel-31-expected.png
index a1b9d7a..1952040f 100644
--- a/third_party/WebKit/LayoutTests/platform/linux/css3/selectors3/xml/css3-modsel-31-expected.png
+++ b/third_party/WebKit/LayoutTests/platform/linux/css3/selectors3/xml/css3-modsel-31-expected.png
Binary files differ
diff --git a/third_party/WebKit/LayoutTests/platform/linux/css3/selectors3/xml/css3-modsel-34-expected.png b/third_party/WebKit/LayoutTests/platform/linux/css3/selectors3/xml/css3-modsel-34-expected.png
index 716d998..f2ab294 100644
--- a/third_party/WebKit/LayoutTests/platform/linux/css3/selectors3/xml/css3-modsel-34-expected.png
+++ b/third_party/WebKit/LayoutTests/platform/linux/css3/selectors3/xml/css3-modsel-34-expected.png
Binary files differ
diff --git a/third_party/WebKit/LayoutTests/platform/linux/css3/selectors3/xml/css3-modsel-35-expected.png b/third_party/WebKit/LayoutTests/platform/linux/css3/selectors3/xml/css3-modsel-35-expected.png
index 62a57fae..62c4a80 100644
--- a/third_party/WebKit/LayoutTests/platform/linux/css3/selectors3/xml/css3-modsel-35-expected.png
+++ b/third_party/WebKit/LayoutTests/platform/linux/css3/selectors3/xml/css3-modsel-35-expected.png
Binary files differ
diff --git a/third_party/WebKit/LayoutTests/platform/linux/css3/selectors3/xml/css3-modsel-37-expected.png b/third_party/WebKit/LayoutTests/platform/linux/css3/selectors3/xml/css3-modsel-37-expected.png
index b507445..7e2709b 100644
--- a/third_party/WebKit/LayoutTests/platform/linux/css3/selectors3/xml/css3-modsel-37-expected.png
+++ b/third_party/WebKit/LayoutTests/platform/linux/css3/selectors3/xml/css3-modsel-37-expected.png
Binary files differ
diff --git a/third_party/WebKit/LayoutTests/platform/linux/css3/selectors3/xml/css3-modsel-45-expected.png b/third_party/WebKit/LayoutTests/platform/linux/css3/selectors3/xml/css3-modsel-45-expected.png
index 0f6a810..6fd67b08 100644
--- a/third_party/WebKit/LayoutTests/platform/linux/css3/selectors3/xml/css3-modsel-45-expected.png
+++ b/third_party/WebKit/LayoutTests/platform/linux/css3/selectors3/xml/css3-modsel-45-expected.png
Binary files differ
diff --git a/third_party/WebKit/LayoutTests/platform/linux/css3/selectors3/xml/css3-modsel-45b-expected.png b/third_party/WebKit/LayoutTests/platform/linux/css3/selectors3/xml/css3-modsel-45b-expected.png
index d78e2ee9..5597650 100644
--- a/third_party/WebKit/LayoutTests/platform/linux/css3/selectors3/xml/css3-modsel-45b-expected.png
+++ b/third_party/WebKit/LayoutTests/platform/linux/css3/selectors3/xml/css3-modsel-45b-expected.png
Binary files differ
diff --git a/third_party/WebKit/LayoutTests/platform/linux/css3/selectors3/xml/css3-modsel-46-expected.png b/third_party/WebKit/LayoutTests/platform/linux/css3/selectors3/xml/css3-modsel-46-expected.png
index 1f15d217..cd1b5aa0 100644
--- a/third_party/WebKit/LayoutTests/platform/linux/css3/selectors3/xml/css3-modsel-46-expected.png
+++ b/third_party/WebKit/LayoutTests/platform/linux/css3/selectors3/xml/css3-modsel-46-expected.png
Binary files differ
diff --git a/third_party/WebKit/LayoutTests/platform/linux/css3/selectors3/xml/css3-modsel-46b-expected.png b/third_party/WebKit/LayoutTests/platform/linux/css3/selectors3/xml/css3-modsel-46b-expected.png
index 1f15d217..cd1b5aa0 100644
--- a/third_party/WebKit/LayoutTests/platform/linux/css3/selectors3/xml/css3-modsel-46b-expected.png
+++ b/third_party/WebKit/LayoutTests/platform/linux/css3/selectors3/xml/css3-modsel-46b-expected.png
Binary files differ
diff --git a/third_party/WebKit/LayoutTests/platform/linux/css3/selectors3/xml/css3-modsel-47-expected.png b/third_party/WebKit/LayoutTests/platform/linux/css3/selectors3/xml/css3-modsel-47-expected.png
index bace4f63..0241a5f6 100644
--- a/third_party/WebKit/LayoutTests/platform/linux/css3/selectors3/xml/css3-modsel-47-expected.png
+++ b/third_party/WebKit/LayoutTests/platform/linux/css3/selectors3/xml/css3-modsel-47-expected.png
Binary files differ
diff --git a/third_party/WebKit/LayoutTests/platform/linux/css3/selectors3/xml/css3-modsel-48-expected.png b/third_party/WebKit/LayoutTests/platform/linux/css3/selectors3/xml/css3-modsel-48-expected.png
index 9967953f..610cefb 100644
--- a/third_party/WebKit/LayoutTests/platform/linux/css3/selectors3/xml/css3-modsel-48-expected.png
+++ b/third_party/WebKit/LayoutTests/platform/linux/css3/selectors3/xml/css3-modsel-48-expected.png
Binary files differ
diff --git a/third_party/WebKit/LayoutTests/platform/linux/css3/selectors3/xml/css3-modsel-49-expected.png b/third_party/WebKit/LayoutTests/platform/linux/css3/selectors3/xml/css3-modsel-49-expected.png
index 9967953f..610cefb 100644
--- a/third_party/WebKit/LayoutTests/platform/linux/css3/selectors3/xml/css3-modsel-49-expected.png
+++ b/third_party/WebKit/LayoutTests/platform/linux/css3/selectors3/xml/css3-modsel-49-expected.png
Binary files differ
diff --git a/third_party/WebKit/LayoutTests/platform/linux/css3/selectors3/xml/css3-modsel-6-expected.png b/third_party/WebKit/LayoutTests/platform/linux/css3/selectors3/xml/css3-modsel-6-expected.png
index 359f3d08..541c88e 100644
--- a/third_party/WebKit/LayoutTests/platform/linux/css3/selectors3/xml/css3-modsel-6-expected.png
+++ b/third_party/WebKit/LayoutTests/platform/linux/css3/selectors3/xml/css3-modsel-6-expected.png
Binary files differ
diff --git a/third_party/WebKit/LayoutTests/platform/linux/css3/selectors3/xml/css3-modsel-7-expected.png b/third_party/WebKit/LayoutTests/platform/linux/css3/selectors3/xml/css3-modsel-7-expected.png
index 0ff1f8a..7c3cbf3 100644
--- a/third_party/WebKit/LayoutTests/platform/linux/css3/selectors3/xml/css3-modsel-7-expected.png
+++ b/third_party/WebKit/LayoutTests/platform/linux/css3/selectors3/xml/css3-modsel-7-expected.png
Binary files differ
diff --git a/third_party/WebKit/LayoutTests/platform/linux/css3/selectors3/xml/css3-modsel-75-expected.png b/third_party/WebKit/LayoutTests/platform/linux/css3/selectors3/xml/css3-modsel-75-expected.png
index d25480d..d3ca28c 100644
--- a/third_party/WebKit/LayoutTests/platform/linux/css3/selectors3/xml/css3-modsel-75-expected.png
+++ b/third_party/WebKit/LayoutTests/platform/linux/css3/selectors3/xml/css3-modsel-75-expected.png
Binary files differ
diff --git a/third_party/WebKit/LayoutTests/platform/linux/css3/selectors3/xml/css3-modsel-75b-expected.png b/third_party/WebKit/LayoutTests/platform/linux/css3/selectors3/xml/css3-modsel-75b-expected.png
index d25480d..d3ca28c 100644
--- a/third_party/WebKit/LayoutTests/platform/linux/css3/selectors3/xml/css3-modsel-75b-expected.png
+++ b/third_party/WebKit/LayoutTests/platform/linux/css3/selectors3/xml/css3-modsel-75b-expected.png
Binary files differ
diff --git a/third_party/WebKit/LayoutTests/platform/linux/css3/selectors3/xml/css3-modsel-76-expected.png b/third_party/WebKit/LayoutTests/platform/linux/css3/selectors3/xml/css3-modsel-76-expected.png
index e85061c5..b95765e 100644
--- a/third_party/WebKit/LayoutTests/platform/linux/css3/selectors3/xml/css3-modsel-76-expected.png
+++ b/third_party/WebKit/LayoutTests/platform/linux/css3/selectors3/xml/css3-modsel-76-expected.png
Binary files differ
diff --git a/third_party/WebKit/LayoutTests/platform/linux/css3/selectors3/xml/css3-modsel-76b-expected.png b/third_party/WebKit/LayoutTests/platform/linux/css3/selectors3/xml/css3-modsel-76b-expected.png
index e85061c5..b95765e 100644
--- a/third_party/WebKit/LayoutTests/platform/linux/css3/selectors3/xml/css3-modsel-76b-expected.png
+++ b/third_party/WebKit/LayoutTests/platform/linux/css3/selectors3/xml/css3-modsel-76b-expected.png
Binary files differ
diff --git a/third_party/WebKit/LayoutTests/platform/linux/css3/selectors3/xml/css3-modsel-79-expected.png b/third_party/WebKit/LayoutTests/platform/linux/css3/selectors3/xml/css3-modsel-79-expected.png
index c215e79b..41b8c6c3 100644
--- a/third_party/WebKit/LayoutTests/platform/linux/css3/selectors3/xml/css3-modsel-79-expected.png
+++ b/third_party/WebKit/LayoutTests/platform/linux/css3/selectors3/xml/css3-modsel-79-expected.png
Binary files differ
diff --git a/third_party/WebKit/LayoutTests/platform/linux/css3/selectors3/xml/css3-modsel-8-expected.png b/third_party/WebKit/LayoutTests/platform/linux/css3/selectors3/xml/css3-modsel-8-expected.png
index 57f75c2..be7dfda6 100644
--- a/third_party/WebKit/LayoutTests/platform/linux/css3/selectors3/xml/css3-modsel-8-expected.png
+++ b/third_party/WebKit/LayoutTests/platform/linux/css3/selectors3/xml/css3-modsel-8-expected.png
Binary files differ
diff --git a/third_party/WebKit/LayoutTests/platform/linux/css3/selectors3/xml/css3-modsel-80-expected.png b/third_party/WebKit/LayoutTests/platform/linux/css3/selectors3/xml/css3-modsel-80-expected.png
index c244f35..fc68f50 100644
--- a/third_party/WebKit/LayoutTests/platform/linux/css3/selectors3/xml/css3-modsel-80-expected.png
+++ b/third_party/WebKit/LayoutTests/platform/linux/css3/selectors3/xml/css3-modsel-80-expected.png
Binary files differ
diff --git a/third_party/WebKit/LayoutTests/platform/linux/css3/selectors3/xml/css3-modsel-82-expected.png b/third_party/WebKit/LayoutTests/platform/linux/css3/selectors3/xml/css3-modsel-82-expected.png
index 53882e2..f4d03ed13 100644
--- a/third_party/WebKit/LayoutTests/platform/linux/css3/selectors3/xml/css3-modsel-82-expected.png
+++ b/third_party/WebKit/LayoutTests/platform/linux/css3/selectors3/xml/css3-modsel-82-expected.png
Binary files differ
diff --git a/third_party/WebKit/LayoutTests/platform/linux/css3/selectors3/xml/css3-modsel-82b-expected.png b/third_party/WebKit/LayoutTests/platform/linux/css3/selectors3/xml/css3-modsel-82b-expected.png
index 53882e2..f4d03ed13 100644
--- a/third_party/WebKit/LayoutTests/platform/linux/css3/selectors3/xml/css3-modsel-82b-expected.png
+++ b/third_party/WebKit/LayoutTests/platform/linux/css3/selectors3/xml/css3-modsel-82b-expected.png
Binary files differ
diff --git a/third_party/WebKit/LayoutTests/platform/linux/editing/deleting/delete-3865854-fix-expected.png b/third_party/WebKit/LayoutTests/platform/linux/editing/deleting/delete-3865854-fix-expected.png
index 7ac8235a..f7e39b8 100644
--- a/third_party/WebKit/LayoutTests/platform/linux/editing/deleting/delete-3865854-fix-expected.png
+++ b/third_party/WebKit/LayoutTests/platform/linux/editing/deleting/delete-3865854-fix-expected.png
Binary files differ
diff --git a/third_party/WebKit/LayoutTests/platform/linux/editing/deleting/delete-line-015-expected.png b/third_party/WebKit/LayoutTests/platform/linux/editing/deleting/delete-line-015-expected.png
index 6651762..d7b97c3f 100644
--- a/third_party/WebKit/LayoutTests/platform/linux/editing/deleting/delete-line-015-expected.png
+++ b/third_party/WebKit/LayoutTests/platform/linux/editing/deleting/delete-line-015-expected.png
Binary files differ
diff --git a/third_party/WebKit/LayoutTests/platform/linux/editing/deleting/delete-line-016-expected.png b/third_party/WebKit/LayoutTests/platform/linux/editing/deleting/delete-line-016-expected.png
index b4e75d6..0e27591 100644
--- a/third_party/WebKit/LayoutTests/platform/linux/editing/deleting/delete-line-016-expected.png
+++ b/third_party/WebKit/LayoutTests/platform/linux/editing/deleting/delete-line-016-expected.png
Binary files differ
diff --git a/third_party/WebKit/LayoutTests/platform/linux/editing/deleting/delete-line-017-expected.png b/third_party/WebKit/LayoutTests/platform/linux/editing/deleting/delete-line-017-expected.png
index 951ab47..d131087 100644
--- a/third_party/WebKit/LayoutTests/platform/linux/editing/deleting/delete-line-017-expected.png
+++ b/third_party/WebKit/LayoutTests/platform/linux/editing/deleting/delete-line-017-expected.png
Binary files differ
diff --git a/third_party/WebKit/LayoutTests/platform/linux/editing/deleting/merge-endOfParagraph-expected.png b/third_party/WebKit/LayoutTests/platform/linux/editing/deleting/merge-endOfParagraph-expected.png
index b91e943b..9c258ed 100644
--- a/third_party/WebKit/LayoutTests/platform/linux/editing/deleting/merge-endOfParagraph-expected.png
+++ b/third_party/WebKit/LayoutTests/platform/linux/editing/deleting/merge-endOfParagraph-expected.png
Binary files differ
diff --git a/third_party/WebKit/LayoutTests/platform/linux/editing/input/reveal-caret-of-multiline-input-expected.png b/third_party/WebKit/LayoutTests/platform/linux/editing/input/reveal-caret-of-multiline-input-expected.png
index f16df3cd..d47bc5f 100644
--- a/third_party/WebKit/LayoutTests/platform/linux/editing/input/reveal-caret-of-multiline-input-expected.png
+++ b/third_party/WebKit/LayoutTests/platform/linux/editing/input/reveal-caret-of-multiline-input-expected.png
Binary files differ
diff --git a/third_party/WebKit/LayoutTests/platform/linux/editing/pasteboard/4631972-expected.png b/third_party/WebKit/LayoutTests/platform/linux/editing/pasteboard/4631972-expected.png
index f8290b1..cf9a8831 100644
--- a/third_party/WebKit/LayoutTests/platform/linux/editing/pasteboard/4631972-expected.png
+++ b/third_party/WebKit/LayoutTests/platform/linux/editing/pasteboard/4631972-expected.png
Binary files differ
diff --git a/third_party/WebKit/LayoutTests/platform/linux/editing/pasteboard/drop-text-without-selection-expected.png b/third_party/WebKit/LayoutTests/platform/linux/editing/pasteboard/drop-text-without-selection-expected.png
index fa30267..c29fa7f 100644
--- a/third_party/WebKit/LayoutTests/platform/linux/editing/pasteboard/drop-text-without-selection-expected.png
+++ b/third_party/WebKit/LayoutTests/platform/linux/editing/pasteboard/drop-text-without-selection-expected.png
Binary files differ
diff --git a/third_party/WebKit/LayoutTests/platform/linux/editing/pasteboard/paste-line-endings-001-expected.png b/third_party/WebKit/LayoutTests/platform/linux/editing/pasteboard/paste-line-endings-001-expected.png
index d34ce26d..8e3d5303 100644
--- a/third_party/WebKit/LayoutTests/platform/linux/editing/pasteboard/paste-line-endings-001-expected.png
+++ b/third_party/WebKit/LayoutTests/platform/linux/editing/pasteboard/paste-line-endings-001-expected.png
Binary files differ
diff --git a/third_party/WebKit/LayoutTests/platform/linux/editing/pasteboard/paste-line-endings-002-expected.png b/third_party/WebKit/LayoutTests/platform/linux/editing/pasteboard/paste-line-endings-002-expected.png
index d34ce26d..8e3d5303 100644
--- a/third_party/WebKit/LayoutTests/platform/linux/editing/pasteboard/paste-line-endings-002-expected.png
+++ b/third_party/WebKit/LayoutTests/platform/linux/editing/pasteboard/paste-line-endings-002-expected.png
Binary files differ
diff --git a/third_party/WebKit/LayoutTests/platform/linux/editing/pasteboard/paste-line-endings-003-expected.png b/third_party/WebKit/LayoutTests/platform/linux/editing/pasteboard/paste-line-endings-003-expected.png
index d34ce26d..8e3d5303 100644
--- a/third_party/WebKit/LayoutTests/platform/linux/editing/pasteboard/paste-line-endings-003-expected.png
+++ b/third_party/WebKit/LayoutTests/platform/linux/editing/pasteboard/paste-line-endings-003-expected.png
Binary files differ
diff --git a/third_party/WebKit/LayoutTests/platform/linux/editing/pasteboard/paste-line-endings-004-expected.png b/third_party/WebKit/LayoutTests/platform/linux/editing/pasteboard/paste-line-endings-004-expected.png
index d34ce26d..8e3d5303 100644
--- a/third_party/WebKit/LayoutTests/platform/linux/editing/pasteboard/paste-line-endings-004-expected.png
+++ b/third_party/WebKit/LayoutTests/platform/linux/editing/pasteboard/paste-line-endings-004-expected.png
Binary files differ
diff --git a/third_party/WebKit/LayoutTests/platform/linux/editing/pasteboard/paste-line-endings-005-expected.png b/third_party/WebKit/LayoutTests/platform/linux/editing/pasteboard/paste-line-endings-005-expected.png
index d34ce26d..8e3d5303 100644
--- a/third_party/WebKit/LayoutTests/platform/linux/editing/pasteboard/paste-line-endings-005-expected.png
+++ b/third_party/WebKit/LayoutTests/platform/linux/editing/pasteboard/paste-line-endings-005-expected.png
Binary files differ
diff --git a/third_party/WebKit/LayoutTests/platform/linux/editing/pasteboard/paste-text-016-expected.png b/third_party/WebKit/LayoutTests/platform/linux/editing/pasteboard/paste-text-016-expected.png
index 7e577ae..05aafa4 100644
--- a/third_party/WebKit/LayoutTests/platform/linux/editing/pasteboard/paste-text-016-expected.png
+++ b/third_party/WebKit/LayoutTests/platform/linux/editing/pasteboard/paste-text-016-expected.png
Binary files differ
diff --git a/third_party/WebKit/LayoutTests/platform/linux/editing/pasteboard/pasting-tabs-expected.png b/third_party/WebKit/LayoutTests/platform/linux/editing/pasteboard/pasting-tabs-expected.png
index 765bff5..1a7a656b 100644
--- a/third_party/WebKit/LayoutTests/platform/linux/editing/pasteboard/pasting-tabs-expected.png
+++ b/third_party/WebKit/LayoutTests/platform/linux/editing/pasteboard/pasting-tabs-expected.png
Binary files differ
diff --git a/third_party/WebKit/LayoutTests/platform/linux/editing/pasteboard/quirks-mode-br-1-expected.png b/third_party/WebKit/LayoutTests/platform/linux/editing/pasteboard/quirks-mode-br-1-expected.png
index e25209f..9f533696 100644
--- a/third_party/WebKit/LayoutTests/platform/linux/editing/pasteboard/quirks-mode-br-1-expected.png
+++ b/third_party/WebKit/LayoutTests/platform/linux/editing/pasteboard/quirks-mode-br-1-expected.png
Binary files differ
diff --git a/third_party/WebKit/LayoutTests/platform/linux/editing/selection/click-start-of-line-expected.png b/third_party/WebKit/LayoutTests/platform/linux/editing/selection/click-start-of-line-expected.png
index 8e9c3c8..86b11045 100644
--- a/third_party/WebKit/LayoutTests/platform/linux/editing/selection/click-start-of-line-expected.png
+++ b/third_party/WebKit/LayoutTests/platform/linux/editing/selection/click-start-of-line-expected.png
Binary files differ
diff --git a/third_party/WebKit/LayoutTests/platform/linux/editing/selection/contains-boundaries-expected.png b/third_party/WebKit/LayoutTests/platform/linux/editing/selection/contains-boundaries-expected.png
index 556612f..a54e43d 100644
--- a/third_party/WebKit/LayoutTests/platform/linux/editing/selection/contains-boundaries-expected.png
+++ b/third_party/WebKit/LayoutTests/platform/linux/editing/selection/contains-boundaries-expected.png
Binary files differ
diff --git a/third_party/WebKit/LayoutTests/platform/linux/editing/selection/inline-closest-leaf-child-expected.png b/third_party/WebKit/LayoutTests/platform/linux/editing/selection/inline-closest-leaf-child-expected.png
index 769439f6..2f40b04 100644
--- a/third_party/WebKit/LayoutTests/platform/linux/editing/selection/inline-closest-leaf-child-expected.png
+++ b/third_party/WebKit/LayoutTests/platform/linux/editing/selection/inline-closest-leaf-child-expected.png
Binary files differ
diff --git a/third_party/WebKit/LayoutTests/platform/linux/editing/style/block-styles-007-expected.png b/third_party/WebKit/LayoutTests/platform/linux/editing/style/block-styles-007-expected.png
index c49e377..9d7e567a 100644
--- a/third_party/WebKit/LayoutTests/platform/linux/editing/style/block-styles-007-expected.png
+++ b/third_party/WebKit/LayoutTests/platform/linux/editing/style/block-styles-007-expected.png
Binary files differ
diff --git a/third_party/WebKit/LayoutTests/platform/linux/editing/unsupported-content/list-delete-001-expected.png b/third_party/WebKit/LayoutTests/platform/linux/editing/unsupported-content/list-delete-001-expected.png
index 0659d9a..f54f855 100644
--- a/third_party/WebKit/LayoutTests/platform/linux/editing/unsupported-content/list-delete-001-expected.png
+++ b/third_party/WebKit/LayoutTests/platform/linux/editing/unsupported-content/list-delete-001-expected.png
Binary files differ
diff --git a/third_party/WebKit/LayoutTests/platform/linux/editing/unsupported-content/list-delete-003-expected.png b/third_party/WebKit/LayoutTests/platform/linux/editing/unsupported-content/list-delete-003-expected.png
index 3266f510..0432e1a 100644
--- a/third_party/WebKit/LayoutTests/platform/linux/editing/unsupported-content/list-delete-003-expected.png
+++ b/third_party/WebKit/LayoutTests/platform/linux/editing/unsupported-content/list-delete-003-expected.png
Binary files differ
diff --git a/third_party/WebKit/LayoutTests/platform/linux/editing/unsupported-content/list-type-after-expected.png b/third_party/WebKit/LayoutTests/platform/linux/editing/unsupported-content/list-type-after-expected.png
index 266d8dcaf..e63cf32 100644
--- a/third_party/WebKit/LayoutTests/platform/linux/editing/unsupported-content/list-type-after-expected.png
+++ b/third_party/WebKit/LayoutTests/platform/linux/editing/unsupported-content/list-type-after-expected.png
Binary files differ
diff --git a/third_party/WebKit/LayoutTests/platform/linux/editing/unsupported-content/list-type-before-expected.png b/third_party/WebKit/LayoutTests/platform/linux/editing/unsupported-content/list-type-before-expected.png
index a59b92eb..3fa13398 100644
--- a/third_party/WebKit/LayoutTests/platform/linux/editing/unsupported-content/list-type-before-expected.png
+++ b/third_party/WebKit/LayoutTests/platform/linux/editing/unsupported-content/list-type-before-expected.png
Binary files differ
diff --git a/third_party/WebKit/LayoutTests/platform/linux/editing/unsupported-content/table-delete-001-expected.png b/third_party/WebKit/LayoutTests/platform/linux/editing/unsupported-content/table-delete-001-expected.png
index 3607acc..bb9fd05 100644
--- a/third_party/WebKit/LayoutTests/platform/linux/editing/unsupported-content/table-delete-001-expected.png
+++ b/third_party/WebKit/LayoutTests/platform/linux/editing/unsupported-content/table-delete-001-expected.png
Binary files differ
diff --git a/third_party/WebKit/LayoutTests/platform/linux/editing/unsupported-content/table-delete-002-expected.png b/third_party/WebKit/LayoutTests/platform/linux/editing/unsupported-content/table-delete-002-expected.png
index aca5b21..a3b85b0c 100644
--- a/third_party/WebKit/LayoutTests/platform/linux/editing/unsupported-content/table-delete-002-expected.png
+++ b/third_party/WebKit/LayoutTests/platform/linux/editing/unsupported-content/table-delete-002-expected.png
Binary files differ
diff --git a/third_party/WebKit/LayoutTests/platform/linux/editing/unsupported-content/table-delete-003-expected.png b/third_party/WebKit/LayoutTests/platform/linux/editing/unsupported-content/table-delete-003-expected.png
index ac62a41..32604f1 100644
--- a/third_party/WebKit/LayoutTests/platform/linux/editing/unsupported-content/table-delete-003-expected.png
+++ b/third_party/WebKit/LayoutTests/platform/linux/editing/unsupported-content/table-delete-003-expected.png
Binary files differ
diff --git a/third_party/WebKit/LayoutTests/platform/linux/editing/unsupported-content/table-type-after-expected.png b/third_party/WebKit/LayoutTests/platform/linux/editing/unsupported-content/table-type-after-expected.png
index 4cccdbd..c0900e13 100644
--- a/third_party/WebKit/LayoutTests/platform/linux/editing/unsupported-content/table-type-after-expected.png
+++ b/third_party/WebKit/LayoutTests/platform/linux/editing/unsupported-content/table-type-after-expected.png
Binary files differ
diff --git a/third_party/WebKit/LayoutTests/platform/linux/editing/unsupported-content/table-type-before-expected.png b/third_party/WebKit/LayoutTests/platform/linux/editing/unsupported-content/table-type-before-expected.png
index cc3f4f0..c3564ca 100644
--- a/third_party/WebKit/LayoutTests/platform/linux/editing/unsupported-content/table-type-before-expected.png
+++ b/third_party/WebKit/LayoutTests/platform/linux/editing/unsupported-content/table-type-before-expected.png
Binary files differ
diff --git a/third_party/WebKit/LayoutTests/platform/linux/fast/backgrounds/body-generated-image-propagated-to-root-expected.png b/third_party/WebKit/LayoutTests/platform/linux/fast/backgrounds/body-generated-image-propagated-to-root-expected.png
index 328fcef55..f98ba25 100644
--- a/third_party/WebKit/LayoutTests/platform/linux/fast/backgrounds/body-generated-image-propagated-to-root-expected.png
+++ b/third_party/WebKit/LayoutTests/platform/linux/fast/backgrounds/body-generated-image-propagated-to-root-expected.png
Binary files differ
diff --git a/third_party/WebKit/LayoutTests/platform/linux/fast/backgrounds/repeat/mask-negative-offset-repeat-expected.png b/third_party/WebKit/LayoutTests/platform/linux/fast/backgrounds/repeat/mask-negative-offset-repeat-expected.png
index e0fc1326..30cfddb8 100644
--- a/third_party/WebKit/LayoutTests/platform/linux/fast/backgrounds/repeat/mask-negative-offset-repeat-expected.png
+++ b/third_party/WebKit/LayoutTests/platform/linux/fast/backgrounds/repeat/mask-negative-offset-repeat-expected.png
Binary files differ
diff --git a/third_party/WebKit/LayoutTests/platform/linux/fast/backgrounds/repeat/negative-offset-repeat-expected.png b/third_party/WebKit/LayoutTests/platform/linux/fast/backgrounds/repeat/negative-offset-repeat-expected.png
index 4b9315c..bce18bb 100644
--- a/third_party/WebKit/LayoutTests/platform/linux/fast/backgrounds/repeat/negative-offset-repeat-expected.png
+++ b/third_party/WebKit/LayoutTests/platform/linux/fast/backgrounds/repeat/negative-offset-repeat-expected.png
Binary files differ
diff --git a/third_party/WebKit/LayoutTests/platform/linux/fast/backgrounds/repeat/negative-offset-repeat-transformed-expected.png b/third_party/WebKit/LayoutTests/platform/linux/fast/backgrounds/repeat/negative-offset-repeat-transformed-expected.png
index 028e3c1a..c61c45e 100644
--- a/third_party/WebKit/LayoutTests/platform/linux/fast/backgrounds/repeat/negative-offset-repeat-transformed-expected.png
+++ b/third_party/WebKit/LayoutTests/platform/linux/fast/backgrounds/repeat/negative-offset-repeat-transformed-expected.png
Binary files differ
diff --git a/third_party/WebKit/LayoutTests/platform/linux/fast/backgrounds/size/zero-expected.png b/third_party/WebKit/LayoutTests/platform/linux/fast/backgrounds/size/zero-expected.png
index d45c045c..3fc6551 100644
--- a/third_party/WebKit/LayoutTests/platform/linux/fast/backgrounds/size/zero-expected.png
+++ b/third_party/WebKit/LayoutTests/platform/linux/fast/backgrounds/size/zero-expected.png
Binary files differ
diff --git a/third_party/WebKit/LayoutTests/platform/linux/fast/block/basic/001-expected.png b/third_party/WebKit/LayoutTests/platform/linux/fast/block/basic/001-expected.png
index 91b01d65..a7dc67f 100644
--- a/third_party/WebKit/LayoutTests/platform/linux/fast/block/basic/001-expected.png
+++ b/third_party/WebKit/LayoutTests/platform/linux/fast/block/basic/001-expected.png
Binary files differ
diff --git a/third_party/WebKit/LayoutTests/platform/linux/fast/block/basic/018-expected.png b/third_party/WebKit/LayoutTests/platform/linux/fast/block/basic/018-expected.png
index 53a5ae6..09fd19c8 100644
--- a/third_party/WebKit/LayoutTests/platform/linux/fast/block/basic/018-expected.png
+++ b/third_party/WebKit/LayoutTests/platform/linux/fast/block/basic/018-expected.png
Binary files differ
diff --git a/third_party/WebKit/LayoutTests/platform/linux/fast/block/basic/019-expected.png b/third_party/WebKit/LayoutTests/platform/linux/fast/block/basic/019-expected.png
index 21c2d43..ec5f39d 100644
--- a/third_party/WebKit/LayoutTests/platform/linux/fast/block/basic/019-expected.png
+++ b/third_party/WebKit/LayoutTests/platform/linux/fast/block/basic/019-expected.png
Binary files differ
diff --git a/third_party/WebKit/LayoutTests/platform/linux/fast/block/basic/adding-near-anonymous-block-expected.png b/third_party/WebKit/LayoutTests/platform/linux/fast/block/basic/adding-near-anonymous-block-expected.png
index 7c7cd8a..bfa1bc1d 100644
--- a/third_party/WebKit/LayoutTests/platform/linux/fast/block/basic/adding-near-anonymous-block-expected.png
+++ b/third_party/WebKit/LayoutTests/platform/linux/fast/block/basic/adding-near-anonymous-block-expected.png
Binary files differ
diff --git a/third_party/WebKit/LayoutTests/platform/linux/fast/block/basic/text-indent-rtl-expected.png b/third_party/WebKit/LayoutTests/platform/linux/fast/block/basic/text-indent-rtl-expected.png
index 5abd69e..ea7d635f 100644
--- a/third_party/WebKit/LayoutTests/platform/linux/fast/block/basic/text-indent-rtl-expected.png
+++ b/third_party/WebKit/LayoutTests/platform/linux/fast/block/basic/text-indent-rtl-expected.png
Binary files differ
diff --git a/third_party/WebKit/LayoutTests/platform/linux/fast/block/basic/truncation-rtl-expected.png b/third_party/WebKit/LayoutTests/platform/linux/fast/block/basic/truncation-rtl-expected.png
index 882f1a2..08de8a9 100644
--- a/third_party/WebKit/LayoutTests/platform/linux/fast/block/basic/truncation-rtl-expected.png
+++ b/third_party/WebKit/LayoutTests/platform/linux/fast/block/basic/truncation-rtl-expected.png
Binary files differ
diff --git a/third_party/WebKit/LayoutTests/platform/linux/fast/block/basic/white-space-pre-wraps-expected.png b/third_party/WebKit/LayoutTests/platform/linux/fast/block/basic/white-space-pre-wraps-expected.png
index 958beb4..4cc8f847 100644
--- a/third_party/WebKit/LayoutTests/platform/linux/fast/block/basic/white-space-pre-wraps-expected.png
+++ b/third_party/WebKit/LayoutTests/platform/linux/fast/block/basic/white-space-pre-wraps-expected.png
Binary files differ
diff --git a/third_party/WebKit/LayoutTests/platform/linux/fast/block/float/add-inline-between-floats-with-preceding-anonymous-box-expected.png b/third_party/WebKit/LayoutTests/platform/linux/fast/block/float/add-inline-between-floats-with-preceding-anonymous-box-expected.png
index c0df2d4..12f2ab2e 100644
--- a/third_party/WebKit/LayoutTests/platform/linux/fast/block/float/add-inline-between-floats-with-preceding-anonymous-box-expected.png
+++ b/third_party/WebKit/LayoutTests/platform/linux/fast/block/float/add-inline-between-floats-with-preceding-anonymous-box-expected.png
Binary files differ
diff --git a/third_party/WebKit/LayoutTests/platform/linux/fast/block/float/add-inline-to-block-flow-with-block-children-that-do-not-need-anonymous-boxes-expected.png b/third_party/WebKit/LayoutTests/platform/linux/fast/block/float/add-inline-to-block-flow-with-block-children-that-do-not-need-anonymous-boxes-expected.png
index b8668b7a..4646ec6 100644
--- a/third_party/WebKit/LayoutTests/platform/linux/fast/block/float/add-inline-to-block-flow-with-block-children-that-do-not-need-anonymous-boxes-expected.png
+++ b/third_party/WebKit/LayoutTests/platform/linux/fast/block/float/add-inline-to-block-flow-with-block-children-that-do-not-need-anonymous-boxes-expected.png
Binary files differ
diff --git a/third_party/WebKit/LayoutTests/platform/linux/fast/block/float/centered-float-avoidance-complexity-expected.png b/third_party/WebKit/LayoutTests/platform/linux/fast/block/float/centered-float-avoidance-complexity-expected.png
index 6812c17..e8bb24ae0 100644
--- a/third_party/WebKit/LayoutTests/platform/linux/fast/block/float/centered-float-avoidance-complexity-expected.png
+++ b/third_party/WebKit/LayoutTests/platform/linux/fast/block/float/centered-float-avoidance-complexity-expected.png
Binary files differ
diff --git a/third_party/WebKit/LayoutTests/platform/linux/fast/block/float/intruding-painted-twice-expected.png b/third_party/WebKit/LayoutTests/platform/linux/fast/block/float/intruding-painted-twice-expected.png
index 76088710..7ee2a49 100644
--- a/third_party/WebKit/LayoutTests/platform/linux/fast/block/float/intruding-painted-twice-expected.png
+++ b/third_party/WebKit/LayoutTests/platform/linux/fast/block/float/intruding-painted-twice-expected.png
Binary files differ
diff --git a/third_party/WebKit/LayoutTests/platform/linux/fast/block/float/nopaint-after-layer-destruction-expected.png b/third_party/WebKit/LayoutTests/platform/linux/fast/block/float/nopaint-after-layer-destruction-expected.png
index 475e890..4b3176d 100644
--- a/third_party/WebKit/LayoutTests/platform/linux/fast/block/float/nopaint-after-layer-destruction-expected.png
+++ b/third_party/WebKit/LayoutTests/platform/linux/fast/block/float/nopaint-after-layer-destruction-expected.png
Binary files differ
diff --git a/third_party/WebKit/LayoutTests/platform/linux/fast/block/float/nopaint-after-layer-destruction2-expected.png b/third_party/WebKit/LayoutTests/platform/linux/fast/block/float/nopaint-after-layer-destruction2-expected.png
index f6dbf8f..b041b00 100644
--- a/third_party/WebKit/LayoutTests/platform/linux/fast/block/float/nopaint-after-layer-destruction2-expected.png
+++ b/third_party/WebKit/LayoutTests/platform/linux/fast/block/float/nopaint-after-layer-destruction2-expected.png
Binary files differ
diff --git a/third_party/WebKit/LayoutTests/platform/linux/fast/block/float/shrink-to-fit-width-expected.png b/third_party/WebKit/LayoutTests/platform/linux/fast/block/float/shrink-to-fit-width-expected.png
index a531e4b..c0e8429 100644
--- a/third_party/WebKit/LayoutTests/platform/linux/fast/block/float/shrink-to-fit-width-expected.png
+++ b/third_party/WebKit/LayoutTests/platform/linux/fast/block/float/shrink-to-fit-width-expected.png
Binary files differ
diff --git a/third_party/WebKit/LayoutTests/platform/linux/fast/block/float/table-relayout-expected.png b/third_party/WebKit/LayoutTests/platform/linux/fast/block/float/table-relayout-expected.png
index b6d54683..e2038ab 100644
--- a/third_party/WebKit/LayoutTests/platform/linux/fast/block/float/table-relayout-expected.png
+++ b/third_party/WebKit/LayoutTests/platform/linux/fast/block/float/table-relayout-expected.png
Binary files differ
diff --git a/third_party/WebKit/LayoutTests/platform/linux/fast/block/float/vertical-move-relayout-expected.png b/third_party/WebKit/LayoutTests/platform/linux/fast/block/float/vertical-move-relayout-expected.png
index f0a9f25a..33f13c13 100644
--- a/third_party/WebKit/LayoutTests/platform/linux/fast/block/float/vertical-move-relayout-expected.png
+++ b/third_party/WebKit/LayoutTests/platform/linux/fast/block/float/vertical-move-relayout-expected.png
Binary files differ
diff --git a/third_party/WebKit/LayoutTests/platform/linux/fast/block/positioning/059-expected.png b/third_party/WebKit/LayoutTests/platform/linux/fast/block/positioning/059-expected.png
index 811d6ee..7202116 100644
--- a/third_party/WebKit/LayoutTests/platform/linux/fast/block/positioning/059-expected.png
+++ b/third_party/WebKit/LayoutTests/platform/linux/fast/block/positioning/059-expected.png
Binary files differ
diff --git a/third_party/WebKit/LayoutTests/platform/linux/fast/block/positioning/height-change-expected.png b/third_party/WebKit/LayoutTests/platform/linux/fast/block/positioning/height-change-expected.png
index 12d7bf3..0688630 100644
--- a/third_party/WebKit/LayoutTests/platform/linux/fast/block/positioning/height-change-expected.png
+++ b/third_party/WebKit/LayoutTests/platform/linux/fast/block/positioning/height-change-expected.png
Binary files differ
diff --git a/third_party/WebKit/LayoutTests/platform/linux/fast/block/positioning/relayout-on-position-change-expected.png b/third_party/WebKit/LayoutTests/platform/linux/fast/block/positioning/relayout-on-position-change-expected.png
index f72f3af9..6c4c191 100644
--- a/third_party/WebKit/LayoutTests/platform/linux/fast/block/positioning/relayout-on-position-change-expected.png
+++ b/third_party/WebKit/LayoutTests/platform/linux/fast/block/positioning/relayout-on-position-change-expected.png
Binary files differ
diff --git a/third_party/WebKit/LayoutTests/platform/linux/fast/block/positioning/window-height-change-expected.png b/third_party/WebKit/LayoutTests/platform/linux/fast/block/positioning/window-height-change-expected.png
index 55b48ae..b1951ad7 100644
--- a/third_party/WebKit/LayoutTests/platform/linux/fast/block/positioning/window-height-change-expected.png
+++ b/third_party/WebKit/LayoutTests/platform/linux/fast/block/positioning/window-height-change-expected.png
Binary files differ
diff --git a/third_party/WebKit/LayoutTests/platform/linux/fast/body-propagation/background-image/009-expected.png b/third_party/WebKit/LayoutTests/platform/linux/fast/body-propagation/background-image/009-expected.png
index aaf4eb7ed..966a190 100644
--- a/third_party/WebKit/LayoutTests/platform/linux/fast/body-propagation/background-image/009-expected.png
+++ b/third_party/WebKit/LayoutTests/platform/linux/fast/body-propagation/background-image/009-expected.png
Binary files differ
diff --git a/third_party/WebKit/LayoutTests/platform/linux/fast/body-propagation/background-image/009-xhtml-expected.png b/third_party/WebKit/LayoutTests/platform/linux/fast/body-propagation/background-image/009-xhtml-expected.png
index aaf4eb7ed..966a190 100644
--- a/third_party/WebKit/LayoutTests/platform/linux/fast/body-propagation/background-image/009-xhtml-expected.png
+++ b/third_party/WebKit/LayoutTests/platform/linux/fast/body-propagation/background-image/009-xhtml-expected.png
Binary files differ
diff --git a/third_party/WebKit/LayoutTests/platform/linux/fast/borders/border-radius-huge-assert-expected.png b/third_party/WebKit/LayoutTests/platform/linux/fast/borders/border-radius-huge-assert-expected.png
index 4610e913..0edf5082 100644
--- a/third_party/WebKit/LayoutTests/platform/linux/fast/borders/border-radius-huge-assert-expected.png
+++ b/third_party/WebKit/LayoutTests/platform/linux/fast/borders/border-radius-huge-assert-expected.png
Binary files differ
diff --git a/third_party/WebKit/LayoutTests/platform/linux/fast/css-generated-content/014-expected.png b/third_party/WebKit/LayoutTests/platform/linux/fast/css-generated-content/014-expected.png
index c9d89b1..148dd6c 100644
--- a/third_party/WebKit/LayoutTests/platform/linux/fast/css-generated-content/014-expected.png
+++ b/third_party/WebKit/LayoutTests/platform/linux/fast/css-generated-content/014-expected.png
Binary files differ
diff --git a/third_party/WebKit/LayoutTests/platform/linux/fast/css-generated-content/after-duplicated-after-split-expected.png b/third_party/WebKit/LayoutTests/platform/linux/fast/css-generated-content/after-duplicated-after-split-expected.png
index 0a06889..7e0161e7 100644
--- a/third_party/WebKit/LayoutTests/platform/linux/fast/css-generated-content/after-duplicated-after-split-expected.png
+++ b/third_party/WebKit/LayoutTests/platform/linux/fast/css-generated-content/after-duplicated-after-split-expected.png
Binary files differ
diff --git a/third_party/WebKit/LayoutTests/platform/linux/fast/css-generated-content/after-order-expected.png b/third_party/WebKit/LayoutTests/platform/linux/fast/css-generated-content/after-order-expected.png
index a9ee08f..c85da36 100644
--- a/third_party/WebKit/LayoutTests/platform/linux/fast/css-generated-content/after-order-expected.png
+++ b/third_party/WebKit/LayoutTests/platform/linux/fast/css-generated-content/after-order-expected.png
Binary files differ
diff --git a/third_party/WebKit/LayoutTests/platform/linux/fast/css-generated-content/before-with-first-letter-expected.png b/third_party/WebKit/LayoutTests/platform/linux/fast/css-generated-content/before-with-first-letter-expected.png
index 85526a1..f1eb5ae8 100644
--- a/third_party/WebKit/LayoutTests/platform/linux/fast/css-generated-content/before-with-first-letter-expected.png
+++ b/third_party/WebKit/LayoutTests/platform/linux/fast/css-generated-content/before-with-first-letter-expected.png
Binary files differ
diff --git a/third_party/WebKit/LayoutTests/platform/linux/fast/css-generated-content/hover-style-change-expected.png b/third_party/WebKit/LayoutTests/platform/linux/fast/css-generated-content/hover-style-change-expected.png
index 8203ac1..5ce6b662 100644
--- a/third_party/WebKit/LayoutTests/platform/linux/fast/css-generated-content/hover-style-change-expected.png
+++ b/third_party/WebKit/LayoutTests/platform/linux/fast/css-generated-content/hover-style-change-expected.png
Binary files differ
diff --git a/third_party/WebKit/LayoutTests/platform/linux/fast/css/005-expected.png b/third_party/WebKit/LayoutTests/platform/linux/fast/css/005-expected.png
index 9b29c85..9947c6d 100644
--- a/third_party/WebKit/LayoutTests/platform/linux/fast/css/005-expected.png
+++ b/third_party/WebKit/LayoutTests/platform/linux/fast/css/005-expected.png
Binary files differ
diff --git a/third_party/WebKit/LayoutTests/platform/linux/fast/css/attribute-selector-empty-value-expected.png b/third_party/WebKit/LayoutTests/platform/linux/fast/css/attribute-selector-empty-value-expected.png
index ac988f65..e5565f43 100644
--- a/third_party/WebKit/LayoutTests/platform/linux/fast/css/attribute-selector-empty-value-expected.png
+++ b/third_party/WebKit/LayoutTests/platform/linux/fast/css/attribute-selector-empty-value-expected.png
Binary files differ
diff --git a/third_party/WebKit/LayoutTests/platform/linux/fast/css/border-radius-outline-offset-expected.png b/third_party/WebKit/LayoutTests/platform/linux/fast/css/border-radius-outline-offset-expected.png
index 81cee64..3f58c15 100644
--- a/third_party/WebKit/LayoutTests/platform/linux/fast/css/border-radius-outline-offset-expected.png
+++ b/third_party/WebKit/LayoutTests/platform/linux/fast/css/border-radius-outline-offset-expected.png
Binary files differ
diff --git a/third_party/WebKit/LayoutTests/platform/linux/fast/css/css3-nth-child-expected.png b/third_party/WebKit/LayoutTests/platform/linux/fast/css/css3-nth-child-expected.png
index b65d6ae5..942d6216 100644
--- a/third_party/WebKit/LayoutTests/platform/linux/fast/css/css3-nth-child-expected.png
+++ b/third_party/WebKit/LayoutTests/platform/linux/fast/css/css3-nth-child-expected.png
Binary files differ
diff --git a/third_party/WebKit/LayoutTests/platform/linux/fast/css/ex-after-font-variant-expected.png b/third_party/WebKit/LayoutTests/platform/linux/fast/css/ex-after-font-variant-expected.png
index b89551f..6ca63f1 100644
--- a/third_party/WebKit/LayoutTests/platform/linux/fast/css/ex-after-font-variant-expected.png
+++ b/third_party/WebKit/LayoutTests/platform/linux/fast/css/ex-after-font-variant-expected.png
Binary files differ
diff --git a/third_party/WebKit/LayoutTests/platform/linux/fast/css/find-next-layer-expected.png b/third_party/WebKit/LayoutTests/platform/linux/fast/css/find-next-layer-expected.png
index 8183490..3d49e68 100644
--- a/third_party/WebKit/LayoutTests/platform/linux/fast/css/find-next-layer-expected.png
+++ b/third_party/WebKit/LayoutTests/platform/linux/fast/css/find-next-layer-expected.png
Binary files differ
diff --git a/third_party/WebKit/LayoutTests/platform/linux/fast/css/first-child-pseudo-class-expected.png b/third_party/WebKit/LayoutTests/platform/linux/fast/css/first-child-pseudo-class-expected.png
index 34f1c24..a225eae 100644
--- a/third_party/WebKit/LayoutTests/platform/linux/fast/css/first-child-pseudo-class-expected.png
+++ b/third_party/WebKit/LayoutTests/platform/linux/fast/css/first-child-pseudo-class-expected.png
Binary files differ
diff --git a/third_party/WebKit/LayoutTests/platform/linux/fast/css/first-letter-capitalized-expected.png b/third_party/WebKit/LayoutTests/platform/linux/fast/css/first-letter-capitalized-expected.png
index 05ce789..22dfb2a 100644
--- a/third_party/WebKit/LayoutTests/platform/linux/fast/css/first-letter-capitalized-expected.png
+++ b/third_party/WebKit/LayoutTests/platform/linux/fast/css/first-letter-capitalized-expected.png
Binary files differ
diff --git a/third_party/WebKit/LayoutTests/platform/linux/fast/css/first-letter-detach-expected.png b/third_party/WebKit/LayoutTests/platform/linux/fast/css/first-letter-detach-expected.png
index 6ddb3da..f4b11f03 100644
--- a/third_party/WebKit/LayoutTests/platform/linux/fast/css/first-letter-detach-expected.png
+++ b/third_party/WebKit/LayoutTests/platform/linux/fast/css/first-letter-detach-expected.png
Binary files differ
diff --git a/third_party/WebKit/LayoutTests/platform/linux/fast/css/first-letter-float-after-float-expected.png b/third_party/WebKit/LayoutTests/platform/linux/fast/css/first-letter-float-after-float-expected.png
index cb63f7d2..a17d3b7 100644
--- a/third_party/WebKit/LayoutTests/platform/linux/fast/css/first-letter-float-after-float-expected.png
+++ b/third_party/WebKit/LayoutTests/platform/linux/fast/css/first-letter-float-after-float-expected.png
Binary files differ
diff --git a/third_party/WebKit/LayoutTests/platform/linux/fast/css/first-letter-float-expected.png b/third_party/WebKit/LayoutTests/platform/linux/fast/css/first-letter-float-expected.png
index b5443a8f..816920c 100644
--- a/third_party/WebKit/LayoutTests/platform/linux/fast/css/first-letter-float-expected.png
+++ b/third_party/WebKit/LayoutTests/platform/linux/fast/css/first-letter-float-expected.png
Binary files differ
diff --git a/third_party/WebKit/LayoutTests/platform/linux/fast/css/first-of-type-pseudo-class-expected.png b/third_party/WebKit/LayoutTests/platform/linux/fast/css/first-of-type-pseudo-class-expected.png
index 66ca7ab..9125625 100644
--- a/third_party/WebKit/LayoutTests/platform/linux/fast/css/first-of-type-pseudo-class-expected.png
+++ b/third_party/WebKit/LayoutTests/platform/linux/fast/css/first-of-type-pseudo-class-expected.png
Binary files differ
diff --git a/third_party/WebKit/LayoutTests/platform/linux/fast/css/font-face-opentype-expected.png b/third_party/WebKit/LayoutTests/platform/linux/fast/css/font-face-opentype-expected.png
index c0e44b4a..b7421a0 100644
--- a/third_party/WebKit/LayoutTests/platform/linux/fast/css/font-face-opentype-expected.png
+++ b/third_party/WebKit/LayoutTests/platform/linux/fast/css/font-face-opentype-expected.png
Binary files differ
diff --git a/third_party/WebKit/LayoutTests/platform/linux/fast/css/font-face-synthetic-bold-italic-expected.png b/third_party/WebKit/LayoutTests/platform/linux/fast/css/font-face-synthetic-bold-italic-expected.png
index 2d13ed8a..f9ddad5 100644
--- a/third_party/WebKit/LayoutTests/platform/linux/fast/css/font-face-synthetic-bold-italic-expected.png
+++ b/third_party/WebKit/LayoutTests/platform/linux/fast/css/font-face-synthetic-bold-italic-expected.png
Binary files differ
diff --git a/third_party/WebKit/LayoutTests/platform/linux/fast/css/font-face-synthetic-bold-italic-for-locally-installed-expected.png b/third_party/WebKit/LayoutTests/platform/linux/fast/css/font-face-synthetic-bold-italic-for-locally-installed-expected.png
index 7119bea7..974132f 100644
--- a/third_party/WebKit/LayoutTests/platform/linux/fast/css/font-face-synthetic-bold-italic-for-locally-installed-expected.png
+++ b/third_party/WebKit/LayoutTests/platform/linux/fast/css/font-face-synthetic-bold-italic-for-locally-installed-expected.png
Binary files differ
diff --git a/third_party/WebKit/LayoutTests/platform/linux/fast/css/font-face-weight-matching-expected.png b/third_party/WebKit/LayoutTests/platform/linux/fast/css/font-face-weight-matching-expected.png
index 8fdcf3a..6aa0e5b 100644
--- a/third_party/WebKit/LayoutTests/platform/linux/fast/css/font-face-weight-matching-expected.png
+++ b/third_party/WebKit/LayoutTests/platform/linux/fast/css/font-face-weight-matching-expected.png
Binary files differ
diff --git a/third_party/WebKit/LayoutTests/platform/linux/fast/css/font-shorthand-weight-only-expected.png b/third_party/WebKit/LayoutTests/platform/linux/fast/css/font-shorthand-weight-only-expected.png
index c93c3c9..0021efe 100644
--- a/third_party/WebKit/LayoutTests/platform/linux/fast/css/font-shorthand-weight-only-expected.png
+++ b/third_party/WebKit/LayoutTests/platform/linux/fast/css/font-shorthand-weight-only-expected.png
Binary files differ
diff --git a/third_party/WebKit/LayoutTests/platform/linux/fast/css/font_property_normal-expected.png b/third_party/WebKit/LayoutTests/platform/linux/fast/css/font_property_normal-expected.png
index 0ac759d..fb6839a0 100644
--- a/third_party/WebKit/LayoutTests/platform/linux/fast/css/font_property_normal-expected.png
+++ b/third_party/WebKit/LayoutTests/platform/linux/fast/css/font_property_normal-expected.png
Binary files differ
diff --git a/third_party/WebKit/LayoutTests/platform/linux/fast/css/hover-subselector-expected.png b/third_party/WebKit/LayoutTests/platform/linux/fast/css/hover-subselector-expected.png
index 6b54afa..572d257 100644
--- a/third_party/WebKit/LayoutTests/platform/linux/fast/css/hover-subselector-expected.png
+++ b/third_party/WebKit/LayoutTests/platform/linux/fast/css/hover-subselector-expected.png
Binary files differ
diff --git a/third_party/WebKit/LayoutTests/platform/linux/fast/css/invalidation-errors-2-expected.png b/third_party/WebKit/LayoutTests/platform/linux/fast/css/invalidation-errors-2-expected.png
index ee937d2..f75230f 100644
--- a/third_party/WebKit/LayoutTests/platform/linux/fast/css/invalidation-errors-2-expected.png
+++ b/third_party/WebKit/LayoutTests/platform/linux/fast/css/invalidation-errors-2-expected.png
Binary files differ
diff --git a/third_party/WebKit/LayoutTests/platform/linux/fast/css/invalidation-errors-2-expected.txt b/third_party/WebKit/LayoutTests/platform/linux/fast/css/invalidation-errors-2-expected.txt
index b6a2b8d..6da1f10 100644
--- a/third_party/WebKit/LayoutTests/platform/linux/fast/css/invalidation-errors-2-expected.txt
+++ b/third_party/WebKit/LayoutTests/platform/linux/fast/css/invalidation-errors-2-expected.txt
@@ -16,8 +16,8 @@
 layer at (8,44) size 200x200
   LayoutBlockFlow (floating) {DIV} at (0,0) size 200x200 [color=#FFFFFF] [bgcolor=#006400]
     LayoutText {#text} at (0,0) size 194x128
-      text run at (0,0) width 159: "this text should be left-"
-      text run at (0,16) width 156: "aligned, all lower-case,"
+      text run at (0,0) width 160: "this text should be left-"
+      text run at (0,16) width 157: "aligned, all lower-case,"
       text run at (0,32) width 169: "normal font, white, 14px,"
       text run at (0,48) width 182: "bold, normally spaced and"
       text run at (0,64) width 165: "wrapped, in a darkgreen"
diff --git a/third_party/WebKit/LayoutTests/platform/linux/fast/css/invalidation-errors-expected.png b/third_party/WebKit/LayoutTests/platform/linux/fast/css/invalidation-errors-expected.png
index ee937d2..f75230f 100644
--- a/third_party/WebKit/LayoutTests/platform/linux/fast/css/invalidation-errors-expected.png
+++ b/third_party/WebKit/LayoutTests/platform/linux/fast/css/invalidation-errors-expected.png
Binary files differ
diff --git a/third_party/WebKit/LayoutTests/platform/linux/fast/css/invalidation-errors-expected.txt b/third_party/WebKit/LayoutTests/platform/linux/fast/css/invalidation-errors-expected.txt
index b6a2b8d..6da1f10 100644
--- a/third_party/WebKit/LayoutTests/platform/linux/fast/css/invalidation-errors-expected.txt
+++ b/third_party/WebKit/LayoutTests/platform/linux/fast/css/invalidation-errors-expected.txt
@@ -16,8 +16,8 @@
 layer at (8,44) size 200x200
   LayoutBlockFlow (floating) {DIV} at (0,0) size 200x200 [color=#FFFFFF] [bgcolor=#006400]
     LayoutText {#text} at (0,0) size 194x128
-      text run at (0,0) width 159: "this text should be left-"
-      text run at (0,16) width 156: "aligned, all lower-case,"
+      text run at (0,0) width 160: "this text should be left-"
+      text run at (0,16) width 157: "aligned, all lower-case,"
       text run at (0,32) width 169: "normal font, white, 14px,"
       text run at (0,48) width 182: "bold, normally spaced and"
       text run at (0,64) width 165: "wrapped, in a darkgreen"
diff --git a/third_party/WebKit/LayoutTests/platform/linux/fast/css/last-child-pseudo-class-expected.png b/third_party/WebKit/LayoutTests/platform/linux/fast/css/last-child-pseudo-class-expected.png
index 9c1b95fa..06fbb18 100644
--- a/third_party/WebKit/LayoutTests/platform/linux/fast/css/last-child-pseudo-class-expected.png
+++ b/third_party/WebKit/LayoutTests/platform/linux/fast/css/last-child-pseudo-class-expected.png
Binary files differ
diff --git a/third_party/WebKit/LayoutTests/platform/linux/fast/css/last-of-type-pseudo-class-expected.png b/third_party/WebKit/LayoutTests/platform/linux/fast/css/last-of-type-pseudo-class-expected.png
index c7fb147..f15efdc 100644
--- a/third_party/WebKit/LayoutTests/platform/linux/fast/css/last-of-type-pseudo-class-expected.png
+++ b/third_party/WebKit/LayoutTests/platform/linux/fast/css/last-of-type-pseudo-class-expected.png
Binary files differ
diff --git a/third_party/WebKit/LayoutTests/platform/linux/fast/css/only-child-pseudo-class-expected.png b/third_party/WebKit/LayoutTests/platform/linux/fast/css/only-child-pseudo-class-expected.png
index 9d36734..8a05035 100644
--- a/third_party/WebKit/LayoutTests/platform/linux/fast/css/only-child-pseudo-class-expected.png
+++ b/third_party/WebKit/LayoutTests/platform/linux/fast/css/only-child-pseudo-class-expected.png
Binary files differ
diff --git a/third_party/WebKit/LayoutTests/platform/linux/fast/css/only-of-type-pseudo-class-expected.png b/third_party/WebKit/LayoutTests/platform/linux/fast/css/only-of-type-pseudo-class-expected.png
index 0fe2d3b..13bdbc82 100644
--- a/third_party/WebKit/LayoutTests/platform/linux/fast/css/only-of-type-pseudo-class-expected.png
+++ b/third_party/WebKit/LayoutTests/platform/linux/fast/css/only-of-type-pseudo-class-expected.png
Binary files differ
diff --git a/third_party/WebKit/LayoutTests/platform/linux/fast/css/relative-positioned-block-with-inline-ancestor-and-parent-dynamic-expected.png b/third_party/WebKit/LayoutTests/platform/linux/fast/css/relative-positioned-block-with-inline-ancestor-and-parent-dynamic-expected.png
index 6f2d9b1..ebf5727 100644
--- a/third_party/WebKit/LayoutTests/platform/linux/fast/css/relative-positioned-block-with-inline-ancestor-and-parent-dynamic-expected.png
+++ b/third_party/WebKit/LayoutTests/platform/linux/fast/css/relative-positioned-block-with-inline-ancestor-and-parent-dynamic-expected.png
Binary files differ
diff --git a/third_party/WebKit/LayoutTests/platform/linux/fast/css/relative-positioned-block-with-inline-ancestor-dynamic-expected.png b/third_party/WebKit/LayoutTests/platform/linux/fast/css/relative-positioned-block-with-inline-ancestor-dynamic-expected.png
index 6f2d9b1..ebf5727 100644
--- a/third_party/WebKit/LayoutTests/platform/linux/fast/css/relative-positioned-block-with-inline-ancestor-dynamic-expected.png
+++ b/third_party/WebKit/LayoutTests/platform/linux/fast/css/relative-positioned-block-with-inline-ancestor-dynamic-expected.png
Binary files differ
diff --git a/third_party/WebKit/LayoutTests/platform/linux/fast/css/relative-positioned-block-with-inline-ancestor-dynamic-removed-expected.png b/third_party/WebKit/LayoutTests/platform/linux/fast/css/relative-positioned-block-with-inline-ancestor-dynamic-removed-expected.png
index 8628278a..3bcf8f9 100644
--- a/third_party/WebKit/LayoutTests/platform/linux/fast/css/relative-positioned-block-with-inline-ancestor-dynamic-removed-expected.png
+++ b/third_party/WebKit/LayoutTests/platform/linux/fast/css/relative-positioned-block-with-inline-ancestor-dynamic-removed-expected.png
Binary files differ
diff --git a/third_party/WebKit/LayoutTests/platform/linux/fast/css/relative-positioned-block-with-inline-ancestor-expected.png b/third_party/WebKit/LayoutTests/platform/linux/fast/css/relative-positioned-block-with-inline-ancestor-expected.png
index 6f2d9b1..ebf5727 100644
--- a/third_party/WebKit/LayoutTests/platform/linux/fast/css/relative-positioned-block-with-inline-ancestor-expected.png
+++ b/third_party/WebKit/LayoutTests/platform/linux/fast/css/relative-positioned-block-with-inline-ancestor-expected.png
Binary files differ
diff --git a/third_party/WebKit/LayoutTests/platform/linux/fast/css/relative-positioned-block-with-inline-parent-dynamic-expected.png b/third_party/WebKit/LayoutTests/platform/linux/fast/css/relative-positioned-block-with-inline-parent-dynamic-expected.png
index 6f2d9b1..ebf5727 100644
--- a/third_party/WebKit/LayoutTests/platform/linux/fast/css/relative-positioned-block-with-inline-parent-dynamic-expected.png
+++ b/third_party/WebKit/LayoutTests/platform/linux/fast/css/relative-positioned-block-with-inline-parent-dynamic-expected.png
Binary files differ
diff --git a/third_party/WebKit/LayoutTests/platform/linux/fast/css/relative-positioned-block-with-inline-parent-dynamic-removed-expected.png b/third_party/WebKit/LayoutTests/platform/linux/fast/css/relative-positioned-block-with-inline-parent-dynamic-removed-expected.png
index 6bf41ee..0d549b7 100644
--- a/third_party/WebKit/LayoutTests/platform/linux/fast/css/relative-positioned-block-with-inline-parent-dynamic-removed-expected.png
+++ b/third_party/WebKit/LayoutTests/platform/linux/fast/css/relative-positioned-block-with-inline-parent-dynamic-removed-expected.png
Binary files differ
diff --git a/third_party/WebKit/LayoutTests/platform/linux/fast/css/resize-corner-tracking-expected.png b/third_party/WebKit/LayoutTests/platform/linux/fast/css/resize-corner-tracking-expected.png
index 108ecd25..8361c64 100644
--- a/third_party/WebKit/LayoutTests/platform/linux/fast/css/resize-corner-tracking-expected.png
+++ b/third_party/WebKit/LayoutTests/platform/linux/fast/css/resize-corner-tracking-expected.png
Binary files differ
diff --git a/third_party/WebKit/LayoutTests/platform/linux/fast/css/resize-corner-tracking-transformed-expected.png b/third_party/WebKit/LayoutTests/platform/linux/fast/css/resize-corner-tracking-transformed-expected.png
index c1e7edf..4c9a194 100644
--- a/third_party/WebKit/LayoutTests/platform/linux/fast/css/resize-corner-tracking-transformed-expected.png
+++ b/third_party/WebKit/LayoutTests/platform/linux/fast/css/resize-corner-tracking-transformed-expected.png
Binary files differ
diff --git a/third_party/WebKit/LayoutTests/platform/linux/fast/css/resize-corner-tracking-transformed-iframe-expected.png b/third_party/WebKit/LayoutTests/platform/linux/fast/css/resize-corner-tracking-transformed-iframe-expected.png
index 4698598c..07e11ca2 100644
--- a/third_party/WebKit/LayoutTests/platform/linux/fast/css/resize-corner-tracking-transformed-iframe-expected.png
+++ b/third_party/WebKit/LayoutTests/platform/linux/fast/css/resize-corner-tracking-transformed-iframe-expected.png
Binary files differ
diff --git a/third_party/WebKit/LayoutTests/platform/linux/fast/css/rtl-ordering-expected.png b/third_party/WebKit/LayoutTests/platform/linux/fast/css/rtl-ordering-expected.png
index 5c49e08..575a42d3 100644
--- a/third_party/WebKit/LayoutTests/platform/linux/fast/css/rtl-ordering-expected.png
+++ b/third_party/WebKit/LayoutTests/platform/linux/fast/css/rtl-ordering-expected.png
Binary files differ
diff --git a/third_party/WebKit/LayoutTests/platform/linux/fast/css/universal-hover-quirk-expected.png b/third_party/WebKit/LayoutTests/platform/linux/fast/css/universal-hover-quirk-expected.png
index af64d5f..a8426946 100644
--- a/third_party/WebKit/LayoutTests/platform/linux/fast/css/universal-hover-quirk-expected.png
+++ b/third_party/WebKit/LayoutTests/platform/linux/fast/css/universal-hover-quirk-expected.png
Binary files differ
diff --git a/third_party/WebKit/LayoutTests/platform/linux/fast/css/universal-hover-quirk-expected.txt b/third_party/WebKit/LayoutTests/platform/linux/fast/css/universal-hover-quirk-expected.txt
index 11bb2d4..e37ff5f0 100644
--- a/third_party/WebKit/LayoutTests/platform/linux/fast/css/universal-hover-quirk-expected.txt
+++ b/third_party/WebKit/LayoutTests/platform/linux/fast/css/universal-hover-quirk-expected.txt
@@ -19,12 +19,11 @@
             text run at (399,0) width 199: " Text underlined on mouse over"
         LayoutText {#text} at (597,0) size 99x19
           text run at (597,0) width 99: ". This tests that "
-        LayoutInline {CODE} at (0,0) size 56x16
-          LayoutText {#text} at (695,3) size 56x16
-            text run at (695,3) width 56: "*:hover"
-        LayoutText {#text} at (750,0) size 784x39
-          text run at (750,0) width 34: " does"
-          text run at (0,20) width 223: "not match anything in quirks mode."
+        LayoutInline {CODE} at (0,0) size 57x16
+          LayoutText {#text} at (695,3) size 57x16
+            text run at (695,3) width 57: "*:hover"
+        LayoutText {#text} at (0,20) size 256x19
+          text run at (0,20) width 256: "does not match anything in quirks mode."
 layer at (8,36) size 784x2 clip at (0,0) size 0x0
   LayoutBlockFlow {HR} at (0,28) size 784x2 [border: (1px inset #EEEEEE)]
 caret: position 1 of child 0 {#text} of child 1 {SPAN} of child 1 {DIV} of body
diff --git a/third_party/WebKit/LayoutTests/platform/linux/fast/css/word-space-extra-expected.png b/third_party/WebKit/LayoutTests/platform/linux/fast/css/word-space-extra-expected.png
index fbf53ff..6eb7132 100644
--- a/third_party/WebKit/LayoutTests/platform/linux/fast/css/word-space-extra-expected.png
+++ b/third_party/WebKit/LayoutTests/platform/linux/fast/css/word-space-extra-expected.png
Binary files differ
diff --git a/third_party/WebKit/LayoutTests/platform/linux/fast/dnd/link-dragging-draggable-div-with-dragged-link-expected.png b/third_party/WebKit/LayoutTests/platform/linux/fast/dnd/link-dragging-draggable-div-with-dragged-link-expected.png
index 5d0b465..6be5b01 100644
--- a/third_party/WebKit/LayoutTests/platform/linux/fast/dnd/link-dragging-draggable-div-with-dragged-link-expected.png
+++ b/third_party/WebKit/LayoutTests/platform/linux/fast/dnd/link-dragging-draggable-div-with-dragged-link-expected.png
Binary files differ
diff --git a/third_party/WebKit/LayoutTests/platform/linux/fast/dom/34176-expected.png b/third_party/WebKit/LayoutTests/platform/linux/fast/dom/34176-expected.png
index 02a5061..7ec170d 100644
--- a/third_party/WebKit/LayoutTests/platform/linux/fast/dom/34176-expected.png
+++ b/third_party/WebKit/LayoutTests/platform/linux/fast/dom/34176-expected.png
Binary files differ
diff --git a/third_party/WebKit/LayoutTests/platform/linux/fast/dom/Element/class-attribute-whitespace-expected.png b/third_party/WebKit/LayoutTests/platform/linux/fast/dom/Element/class-attribute-whitespace-expected.png
index c480e2c9..82d3048d 100644
--- a/third_party/WebKit/LayoutTests/platform/linux/fast/dom/Element/class-attribute-whitespace-expected.png
+++ b/third_party/WebKit/LayoutTests/platform/linux/fast/dom/Element/class-attribute-whitespace-expected.png
Binary files differ
diff --git a/third_party/WebKit/LayoutTests/platform/linux/fast/dom/HTMLLinkElement/pending-stylesheet-count-expected.png b/third_party/WebKit/LayoutTests/platform/linux/fast/dom/HTMLLinkElement/pending-stylesheet-count-expected.png
index 2d1f9e0..3e11435 100644
--- a/third_party/WebKit/LayoutTests/platform/linux/fast/dom/HTMLLinkElement/pending-stylesheet-count-expected.png
+++ b/third_party/WebKit/LayoutTests/platform/linux/fast/dom/HTMLLinkElement/pending-stylesheet-count-expected.png
Binary files differ
diff --git a/third_party/WebKit/LayoutTests/platform/linux/fast/dom/children-nodes-expected.png b/third_party/WebKit/LayoutTests/platform/linux/fast/dom/children-nodes-expected.png
index 29a0104b..45fd638 100644
--- a/third_party/WebKit/LayoutTests/platform/linux/fast/dom/children-nodes-expected.png
+++ b/third_party/WebKit/LayoutTests/platform/linux/fast/dom/children-nodes-expected.png
Binary files differ
diff --git a/third_party/WebKit/LayoutTests/platform/linux/fast/dom/clone-node-dynamic-style-expected.png b/third_party/WebKit/LayoutTests/platform/linux/fast/dom/clone-node-dynamic-style-expected.png
index ad95a64..bdca9d51 100644
--- a/third_party/WebKit/LayoutTests/platform/linux/fast/dom/clone-node-dynamic-style-expected.png
+++ b/third_party/WebKit/LayoutTests/platform/linux/fast/dom/clone-node-dynamic-style-expected.png
Binary files differ
diff --git a/third_party/WebKit/LayoutTests/platform/linux/fast/dom/clone-node-dynamic-style-expected.txt b/third_party/WebKit/LayoutTests/platform/linux/fast/dom/clone-node-dynamic-style-expected.txt
index 7d42391..43c420d 100644
--- a/third_party/WebKit/LayoutTests/platform/linux/fast/dom/clone-node-dynamic-style-expected.txt
+++ b/third_party/WebKit/LayoutTests/platform/linux/fast/dom/clone-node-dynamic-style-expected.txt
@@ -1,4 +1,4 @@
-layer at (0,0) size 800x600 scrollWidth 840
+layer at (0,0) size 800x600 scrollWidth 838
   LayoutView at (0,0) size 800x600
 layer at (0,0) size 800x600
   LayoutBlockFlow {HTML} at (0,0) size 800x600
@@ -7,19 +7,19 @@
         LayoutText {#text} at (0,0) size 195x36
           text run at (0,0) width 195: "Cloning nodes"
       LayoutBlockFlow {DIV} at (0,58.44) size 784x40 [bgcolor=#FFFF00] [border: (2px ridge #EEEEEE)]
-        LayoutInline {SPAN} at (0,0) size 830x35
+        LayoutInline {SPAN} at (0,0) size 828x35
           LayoutText {#text} at (2,2) size 60x35
             text run at (2,2) width 60: "Bold"
-          LayoutInline {SPAN} at (0,0) size 710x35
+          LayoutInline {SPAN} at (0,0) size 708x35
             LayoutText {#text} at (62,2) size 205x35
               text run at (62,2) width 205: "Bold+Underline"
-            LayoutInline {SPAN} at (0,0) size 283x34
-              LayoutText {#text} at (267,2) size 283x34
-                text run at (267,2) width 283: "Bold+Underline+Italic"
-            LayoutText {#text} at (550,2) size 222x35
-              text run at (550,2) width 222: "Bold+Uunderline"
-          LayoutText {#text} at (772,2) size 60x35
-            text run at (772,2) width 60: "Bold"
+            LayoutInline {SPAN} at (0,0) size 281x34
+              LayoutText {#text} at (267,2) size 281x34
+                text run at (267,2) width 281: "Bold+Underline+Italic"
+            LayoutText {#text} at (548,2) size 222x35
+              text run at (548,2) width 222: "Bold+Uunderline"
+          LayoutText {#text} at (770,2) size 60x35
+            text run at (770,2) width 60: "Bold"
         LayoutText {#text} at (0,0) size 0x0
       LayoutBlockFlow (anonymous) at (0,98.44) size 784x20
         LayoutText {#text} at (0,0) size 189x19
@@ -30,17 +30,17 @@
         LayoutText {#text} at (0,0) size 184x19
           text run at (0,0) width 184: "Cloned Node with deep=true"
       LayoutBlockFlow {DIV} at (0,177.44) size 784x40 [bgcolor=#FFFF00] [border: (2px ridge #EEEEEE)]
-        LayoutInline {SPAN} at (0,0) size 830x35
+        LayoutInline {SPAN} at (0,0) size 828x35
           LayoutText {#text} at (2,2) size 60x35
             text run at (2,2) width 60: "Bold"
-          LayoutInline {SPAN} at (0,0) size 710x35
+          LayoutInline {SPAN} at (0,0) size 708x35
             LayoutText {#text} at (62,2) size 205x35
               text run at (62,2) width 205: "Bold+Underline"
-            LayoutInline {SPAN} at (0,0) size 283x34
-              LayoutText {#text} at (267,2) size 283x34
-                text run at (267,2) width 283: "Bold+Underline+Italic"
-            LayoutText {#text} at (550,2) size 222x35
-              text run at (550,2) width 222: "Bold+Uunderline"
-          LayoutText {#text} at (772,2) size 60x35
-            text run at (772,2) width 60: "Bold"
+            LayoutInline {SPAN} at (0,0) size 281x34
+              LayoutText {#text} at (267,2) size 281x34
+                text run at (267,2) width 281: "Bold+Underline+Italic"
+            LayoutText {#text} at (548,2) size 222x35
+              text run at (548,2) width 222: "Bold+Uunderline"
+          LayoutText {#text} at (770,2) size 60x35
+            text run at (770,2) width 60: "Bold"
         LayoutText {#text} at (0,0) size 0x0
diff --git a/third_party/WebKit/LayoutTests/platform/linux/fast/dom/row-inner-text-expected.png b/third_party/WebKit/LayoutTests/platform/linux/fast/dom/row-inner-text-expected.png
index ccc707bd..e1f3b324 100644
--- a/third_party/WebKit/LayoutTests/platform/linux/fast/dom/row-inner-text-expected.png
+++ b/third_party/WebKit/LayoutTests/platform/linux/fast/dom/row-inner-text-expected.png
Binary files differ
diff --git a/third_party/WebKit/LayoutTests/platform/linux/fast/dynamic/anonymous-block-orphaned-lines-expected.png b/third_party/WebKit/LayoutTests/platform/linux/fast/dynamic/anonymous-block-orphaned-lines-expected.png
index 881b3c5..8e00dc1 100644
--- a/third_party/WebKit/LayoutTests/platform/linux/fast/dynamic/anonymous-block-orphaned-lines-expected.png
+++ b/third_party/WebKit/LayoutTests/platform/linux/fast/dynamic/anonymous-block-orphaned-lines-expected.png
Binary files differ
diff --git a/third_party/WebKit/LayoutTests/platform/linux/fast/dynamic/containing-block-change-expected.png b/third_party/WebKit/LayoutTests/platform/linux/fast/dynamic/containing-block-change-expected.png
index 143dfaf..13293743 100644
--- a/third_party/WebKit/LayoutTests/platform/linux/fast/dynamic/containing-block-change-expected.png
+++ b/third_party/WebKit/LayoutTests/platform/linux/fast/dynamic/containing-block-change-expected.png
Binary files differ
diff --git a/third_party/WebKit/LayoutTests/platform/linux/fast/dynamic/create-renderer-for-whitespace-only-text-expected.png b/third_party/WebKit/LayoutTests/platform/linux/fast/dynamic/create-renderer-for-whitespace-only-text-expected.png
index 180c7bd..9a4b8831 100644
--- a/third_party/WebKit/LayoutTests/platform/linux/fast/dynamic/create-renderer-for-whitespace-only-text-expected.png
+++ b/third_party/WebKit/LayoutTests/platform/linux/fast/dynamic/create-renderer-for-whitespace-only-text-expected.png
Binary files differ
diff --git a/third_party/WebKit/LayoutTests/platform/linux/fast/dynamic/float-in-trailing-whitespace-after-last-line-break-expected.png b/third_party/WebKit/LayoutTests/platform/linux/fast/dynamic/float-in-trailing-whitespace-after-last-line-break-expected.png
index 15a33ff5..22214385 100644
--- a/third_party/WebKit/LayoutTests/platform/linux/fast/dynamic/float-in-trailing-whitespace-after-last-line-break-expected.png
+++ b/third_party/WebKit/LayoutTests/platform/linux/fast/dynamic/float-in-trailing-whitespace-after-last-line-break-expected.png
Binary files differ
diff --git a/third_party/WebKit/LayoutTests/platform/linux/fast/dynamic/float-withdrawal-expected.png b/third_party/WebKit/LayoutTests/platform/linux/fast/dynamic/float-withdrawal-expected.png
index 55bdfaf..9846bcd 100644
--- a/third_party/WebKit/LayoutTests/platform/linux/fast/dynamic/float-withdrawal-expected.png
+++ b/third_party/WebKit/LayoutTests/platform/linux/fast/dynamic/float-withdrawal-expected.png
Binary files differ
diff --git a/third_party/WebKit/LayoutTests/platform/linux/fast/dynamic/insert-before-table-part-in-continuation-expected.png b/third_party/WebKit/LayoutTests/platform/linux/fast/dynamic/insert-before-table-part-in-continuation-expected.png
index 735f0ee..97f5fb2 100644
--- a/third_party/WebKit/LayoutTests/platform/linux/fast/dynamic/insert-before-table-part-in-continuation-expected.png
+++ b/third_party/WebKit/LayoutTests/platform/linux/fast/dynamic/insert-before-table-part-in-continuation-expected.png
Binary files differ
diff --git a/third_party/WebKit/LayoutTests/platform/linux/fast/dynamic/selection-highlight-adjust-expected.png b/third_party/WebKit/LayoutTests/platform/linux/fast/dynamic/selection-highlight-adjust-expected.png
index 65986b7..3edf0471 100644
--- a/third_party/WebKit/LayoutTests/platform/linux/fast/dynamic/selection-highlight-adjust-expected.png
+++ b/third_party/WebKit/LayoutTests/platform/linux/fast/dynamic/selection-highlight-adjust-expected.png
Binary files differ
diff --git a/third_party/WebKit/LayoutTests/platform/linux/fast/dynamic/staticY-marking-parents-regression-expected.png b/third_party/WebKit/LayoutTests/platform/linux/fast/dynamic/staticY-marking-parents-regression-expected.png
index 6ccd788..7d278bc 100644
--- a/third_party/WebKit/LayoutTests/platform/linux/fast/dynamic/staticY-marking-parents-regression-expected.png
+++ b/third_party/WebKit/LayoutTests/platform/linux/fast/dynamic/staticY-marking-parents-regression-expected.png
Binary files differ
diff --git a/third_party/WebKit/LayoutTests/platform/linux/fast/dynamic/view-overflow-expected.png b/third_party/WebKit/LayoutTests/platform/linux/fast/dynamic/view-overflow-expected.png
index 2a59922..c412cc0 100644
--- a/third_party/WebKit/LayoutTests/platform/linux/fast/dynamic/view-overflow-expected.png
+++ b/third_party/WebKit/LayoutTests/platform/linux/fast/dynamic/view-overflow-expected.png
Binary files differ
diff --git a/third_party/WebKit/LayoutTests/platform/linux/fast/forms/basic-buttons-expected.png b/third_party/WebKit/LayoutTests/platform/linux/fast/forms/basic-buttons-expected.png
index 05c1d4e2..727a7925 100644
--- a/third_party/WebKit/LayoutTests/platform/linux/fast/forms/basic-buttons-expected.png
+++ b/third_party/WebKit/LayoutTests/platform/linux/fast/forms/basic-buttons-expected.png
Binary files differ
diff --git a/third_party/WebKit/LayoutTests/platform/linux/fast/forms/button-text-transform-expected.png b/third_party/WebKit/LayoutTests/platform/linux/fast/forms/button-text-transform-expected.png
index 69b55d4..4c178e6 100644
--- a/third_party/WebKit/LayoutTests/platform/linux/fast/forms/button-text-transform-expected.png
+++ b/third_party/WebKit/LayoutTests/platform/linux/fast/forms/button-text-transform-expected.png
Binary files differ
diff --git a/third_party/WebKit/LayoutTests/platform/linux/fast/forms/button/button-inner-block-reuse-expected.png b/third_party/WebKit/LayoutTests/platform/linux/fast/forms/button/button-inner-block-reuse-expected.png
index 33698dc..644cf412 100644
--- a/third_party/WebKit/LayoutTests/platform/linux/fast/forms/button/button-inner-block-reuse-expected.png
+++ b/third_party/WebKit/LayoutTests/platform/linux/fast/forms/button/button-inner-block-reuse-expected.png
Binary files differ
diff --git a/third_party/WebKit/LayoutTests/platform/linux/fast/forms/calendar-picker/month-picker-appearance-step-expected.png b/third_party/WebKit/LayoutTests/platform/linux/fast/forms/calendar-picker/month-picker-appearance-step-expected.png
index e983037..ca87c101 100644
--- a/third_party/WebKit/LayoutTests/platform/linux/fast/forms/calendar-picker/month-picker-appearance-step-expected.png
+++ b/third_party/WebKit/LayoutTests/platform/linux/fast/forms/calendar-picker/month-picker-appearance-step-expected.png
Binary files differ
diff --git a/third_party/WebKit/LayoutTests/platform/linux/fast/forms/control-clip-overflow-expected.png b/third_party/WebKit/LayoutTests/platform/linux/fast/forms/control-clip-overflow-expected.png
index 1b288ba..7c7ecaa 100644
--- a/third_party/WebKit/LayoutTests/platform/linux/fast/forms/control-clip-overflow-expected.png
+++ b/third_party/WebKit/LayoutTests/platform/linux/fast/forms/control-clip-overflow-expected.png
Binary files differ
diff --git a/third_party/WebKit/LayoutTests/platform/linux/fast/forms/date/date-appearance-pseudo-elements-expected.png b/third_party/WebKit/LayoutTests/platform/linux/fast/forms/date/date-appearance-pseudo-elements-expected.png
index 5c1a256..36b108c 100644
--- a/third_party/WebKit/LayoutTests/platform/linux/fast/forms/date/date-appearance-pseudo-elements-expected.png
+++ b/third_party/WebKit/LayoutTests/platform/linux/fast/forms/date/date-appearance-pseudo-elements-expected.png
Binary files differ
diff --git a/third_party/WebKit/LayoutTests/platform/linux/fast/forms/datetimelocal/datetimelocal-appearance-l10n-expected.png b/third_party/WebKit/LayoutTests/platform/linux/fast/forms/datetimelocal/datetimelocal-appearance-l10n-expected.png
index fd43a1d..4d5e120 100644
--- a/third_party/WebKit/LayoutTests/platform/linux/fast/forms/datetimelocal/datetimelocal-appearance-l10n-expected.png
+++ b/third_party/WebKit/LayoutTests/platform/linux/fast/forms/datetimelocal/datetimelocal-appearance-l10n-expected.png
Binary files differ
diff --git a/third_party/WebKit/LayoutTests/platform/linux/fast/forms/floating-textfield-relayout-expected.png b/third_party/WebKit/LayoutTests/platform/linux/fast/forms/floating-textfield-relayout-expected.png
index cfeea6d..aaf7f555 100644
--- a/third_party/WebKit/LayoutTests/platform/linux/fast/forms/floating-textfield-relayout-expected.png
+++ b/third_party/WebKit/LayoutTests/platform/linux/fast/forms/floating-textfield-relayout-expected.png
Binary files differ
diff --git a/third_party/WebKit/LayoutTests/platform/linux/fast/forms/month/month-appearance-l10n-expected.png b/third_party/WebKit/LayoutTests/platform/linux/fast/forms/month/month-appearance-l10n-expected.png
index 9cc393f..d552b400 100644
--- a/third_party/WebKit/LayoutTests/platform/linux/fast/forms/month/month-appearance-l10n-expected.png
+++ b/third_party/WebKit/LayoutTests/platform/linux/fast/forms/month/month-appearance-l10n-expected.png
Binary files differ
diff --git a/third_party/WebKit/LayoutTests/platform/linux/fast/forms/month/month-appearance-pseudo-elements-expected.png b/third_party/WebKit/LayoutTests/platform/linux/fast/forms/month/month-appearance-pseudo-elements-expected.png
index 21e7ebe4..3280223 100644
--- a/third_party/WebKit/LayoutTests/platform/linux/fast/forms/month/month-appearance-pseudo-elements-expected.png
+++ b/third_party/WebKit/LayoutTests/platform/linux/fast/forms/month/month-appearance-pseudo-elements-expected.png
Binary files differ
diff --git a/third_party/WebKit/LayoutTests/platform/linux/fast/forms/plaintext-mode-2-expected.png b/third_party/WebKit/LayoutTests/platform/linux/fast/forms/plaintext-mode-2-expected.png
index 9d8b68761..627d8b2 100644
--- a/third_party/WebKit/LayoutTests/platform/linux/fast/forms/plaintext-mode-2-expected.png
+++ b/third_party/WebKit/LayoutTests/platform/linux/fast/forms/plaintext-mode-2-expected.png
Binary files differ
diff --git a/third_party/WebKit/LayoutTests/platform/linux/fast/forms/range/slider-thumb-shared-style-expected.png b/third_party/WebKit/LayoutTests/platform/linux/fast/forms/range/slider-thumb-shared-style-expected.png
index e178d91..1b8c895 100644
--- a/third_party/WebKit/LayoutTests/platform/linux/fast/forms/range/slider-thumb-shared-style-expected.png
+++ b/third_party/WebKit/LayoutTests/platform/linux/fast/forms/range/slider-thumb-shared-style-expected.png
Binary files differ
diff --git a/third_party/WebKit/LayoutTests/platform/linux/fast/forms/search/search-rtl-expected.png b/third_party/WebKit/LayoutTests/platform/linux/fast/forms/search/search-rtl-expected.png
index 4c0f69bc..84a4598f 100644
--- a/third_party/WebKit/LayoutTests/platform/linux/fast/forms/search/search-rtl-expected.png
+++ b/third_party/WebKit/LayoutTests/platform/linux/fast/forms/search/search-rtl-expected.png
Binary files differ
diff --git a/third_party/WebKit/LayoutTests/platform/linux/fast/forms/select/listbox-scrollbar-incremental-load-expected.png b/third_party/WebKit/LayoutTests/platform/linux/fast/forms/select/listbox-scrollbar-incremental-load-expected.png
index 2a4cb004..63d4031c 100644
--- a/third_party/WebKit/LayoutTests/platform/linux/fast/forms/select/listbox-scrollbar-incremental-load-expected.png
+++ b/third_party/WebKit/LayoutTests/platform/linux/fast/forms/select/listbox-scrollbar-incremental-load-expected.png
Binary files differ
diff --git a/third_party/WebKit/LayoutTests/platform/linux/fast/forms/select/menulist-appearance-none-expected.png b/third_party/WebKit/LayoutTests/platform/linux/fast/forms/select/menulist-appearance-none-expected.png
index 3a65f582..5596f99a 100644
--- a/third_party/WebKit/LayoutTests/platform/linux/fast/forms/select/menulist-appearance-none-expected.png
+++ b/third_party/WebKit/LayoutTests/platform/linux/fast/forms/select/menulist-appearance-none-expected.png
Binary files differ
diff --git a/third_party/WebKit/LayoutTests/platform/linux/fast/forms/select/menulist-clip-expected.png b/third_party/WebKit/LayoutTests/platform/linux/fast/forms/select/menulist-clip-expected.png
index ac27ae03..67a400b 100644
--- a/third_party/WebKit/LayoutTests/platform/linux/fast/forms/select/menulist-clip-expected.png
+++ b/third_party/WebKit/LayoutTests/platform/linux/fast/forms/select/menulist-clip-expected.png
Binary files differ
diff --git a/third_party/WebKit/LayoutTests/platform/linux/fast/forms/select/menulist-option-wrap-expected.png b/third_party/WebKit/LayoutTests/platform/linux/fast/forms/select/menulist-option-wrap-expected.png
index 5de83d3..c4e6d534e 100644
--- a/third_party/WebKit/LayoutTests/platform/linux/fast/forms/select/menulist-option-wrap-expected.png
+++ b/third_party/WebKit/LayoutTests/platform/linux/fast/forms/select/menulist-option-wrap-expected.png
Binary files differ
diff --git a/third_party/WebKit/LayoutTests/platform/linux/fast/forms/select/select-change-listbox-size-expected.png b/third_party/WebKit/LayoutTests/platform/linux/fast/forms/select/select-change-listbox-size-expected.png
index 59409f1..79cfcff 100644
--- a/third_party/WebKit/LayoutTests/platform/linux/fast/forms/select/select-change-listbox-size-expected.png
+++ b/third_party/WebKit/LayoutTests/platform/linux/fast/forms/select/select-change-listbox-size-expected.png
Binary files differ
diff --git a/third_party/WebKit/LayoutTests/platform/linux/fast/forms/select/select-disabled-appearance-expected.png b/third_party/WebKit/LayoutTests/platform/linux/fast/forms/select/select-disabled-appearance-expected.png
index 08873f0..1d43c84 100644
--- a/third_party/WebKit/LayoutTests/platform/linux/fast/forms/select/select-disabled-appearance-expected.png
+++ b/third_party/WebKit/LayoutTests/platform/linux/fast/forms/select/select-disabled-appearance-expected.png
Binary files differ
diff --git a/third_party/WebKit/LayoutTests/platform/linux/fast/forms/select/select-display-none-style-resolve-expected.png b/third_party/WebKit/LayoutTests/platform/linux/fast/forms/select/select-display-none-style-resolve-expected.png
index bd28f48..4be398a 100644
--- a/third_party/WebKit/LayoutTests/platform/linux/fast/forms/select/select-display-none-style-resolve-expected.png
+++ b/third_party/WebKit/LayoutTests/platform/linux/fast/forms/select/select-display-none-style-resolve-expected.png
Binary files differ
diff --git a/third_party/WebKit/LayoutTests/platform/linux/fast/forms/select/select-item-background-clip-expected.png b/third_party/WebKit/LayoutTests/platform/linux/fast/forms/select/select-item-background-clip-expected.png
index 3825679..207f02d 100644
--- a/third_party/WebKit/LayoutTests/platform/linux/fast/forms/select/select-item-background-clip-expected.png
+++ b/third_party/WebKit/LayoutTests/platform/linux/fast/forms/select/select-item-background-clip-expected.png
Binary files differ
diff --git a/third_party/WebKit/LayoutTests/platform/linux/fast/forms/select/select-writing-direction-natural-expected.png b/third_party/WebKit/LayoutTests/platform/linux/fast/forms/select/select-writing-direction-natural-expected.png
index 32a6816..b394990 100644
--- a/third_party/WebKit/LayoutTests/platform/linux/fast/forms/select/select-writing-direction-natural-expected.png
+++ b/third_party/WebKit/LayoutTests/platform/linux/fast/forms/select/select-writing-direction-natural-expected.png
Binary files differ
diff --git a/third_party/WebKit/LayoutTests/platform/linux/fast/forms/textarea/basic-textareas-expected.png b/third_party/WebKit/LayoutTests/platform/linux/fast/forms/textarea/basic-textareas-expected.png
index 74fa8b6..4cca8ede 100644
--- a/third_party/WebKit/LayoutTests/platform/linux/fast/forms/textarea/basic-textareas-expected.png
+++ b/third_party/WebKit/LayoutTests/platform/linux/fast/forms/textarea/basic-textareas-expected.png
Binary files differ
diff --git a/third_party/WebKit/LayoutTests/platform/linux/fast/forms/textarea/basic-textareas-quirks-expected.png b/third_party/WebKit/LayoutTests/platform/linux/fast/forms/textarea/basic-textareas-quirks-expected.png
index 598d034..d211c50 100644
--- a/third_party/WebKit/LayoutTests/platform/linux/fast/forms/textarea/basic-textareas-quirks-expected.png
+++ b/third_party/WebKit/LayoutTests/platform/linux/fast/forms/textarea/basic-textareas-quirks-expected.png
Binary files differ
diff --git a/third_party/WebKit/LayoutTests/platform/linux/fast/forms/time/time-appearance-pseudo-elements-expected.png b/third_party/WebKit/LayoutTests/platform/linux/fast/forms/time/time-appearance-pseudo-elements-expected.png
index c08d2d36..d013ff9 100644
--- a/third_party/WebKit/LayoutTests/platform/linux/fast/forms/time/time-appearance-pseudo-elements-expected.png
+++ b/third_party/WebKit/LayoutTests/platform/linux/fast/forms/time/time-appearance-pseudo-elements-expected.png
Binary files differ
diff --git a/third_party/WebKit/LayoutTests/platform/linux/fast/forms/visual-hebrew-text-field-expected.png b/third_party/WebKit/LayoutTests/platform/linux/fast/forms/visual-hebrew-text-field-expected.png
index e8f970f96..d2e3b8a 100644
--- a/third_party/WebKit/LayoutTests/platform/linux/fast/forms/visual-hebrew-text-field-expected.png
+++ b/third_party/WebKit/LayoutTests/platform/linux/fast/forms/visual-hebrew-text-field-expected.png
Binary files differ
diff --git a/third_party/WebKit/LayoutTests/platform/linux/fast/forms/week/week-appearance-pseudo-elements-expected.png b/third_party/WebKit/LayoutTests/platform/linux/fast/forms/week/week-appearance-pseudo-elements-expected.png
index dd437752..b4f6cfc 100644
--- a/third_party/WebKit/LayoutTests/platform/linux/fast/forms/week/week-appearance-pseudo-elements-expected.png
+++ b/third_party/WebKit/LayoutTests/platform/linux/fast/forms/week/week-appearance-pseudo-elements-expected.png
Binary files differ
diff --git a/third_party/WebKit/LayoutTests/platform/linux/fast/frames/frameset-style-recalc-expected.png b/third_party/WebKit/LayoutTests/platform/linux/fast/frames/frameset-style-recalc-expected.png
index d16f2143..944a388 100644
--- a/third_party/WebKit/LayoutTests/platform/linux/fast/frames/frameset-style-recalc-expected.png
+++ b/third_party/WebKit/LayoutTests/platform/linux/fast/frames/frameset-style-recalc-expected.png
Binary files differ
diff --git a/third_party/WebKit/LayoutTests/platform/linux/fast/frames/iframe-scrolling-attribute-expected.png b/third_party/WebKit/LayoutTests/platform/linux/fast/frames/iframe-scrolling-attribute-expected.png
index b519e74..0fd08c9 100644
--- a/third_party/WebKit/LayoutTests/platform/linux/fast/frames/iframe-scrolling-attribute-expected.png
+++ b/third_party/WebKit/LayoutTests/platform/linux/fast/frames/iframe-scrolling-attribute-expected.png
Binary files differ
diff --git a/third_party/WebKit/LayoutTests/platform/linux/fast/inline-block/overflow-clip-expected.png b/third_party/WebKit/LayoutTests/platform/linux/fast/inline-block/overflow-clip-expected.png
index 46d9243..fb4ba1d 100644
--- a/third_party/WebKit/LayoutTests/platform/linux/fast/inline-block/overflow-clip-expected.png
+++ b/third_party/WebKit/LayoutTests/platform/linux/fast/inline-block/overflow-clip-expected.png
Binary files differ
diff --git a/third_party/WebKit/LayoutTests/platform/linux/fast/inline/br-text-decoration-expected.png b/third_party/WebKit/LayoutTests/platform/linux/fast/inline/br-text-decoration-expected.png
index 8fb5711..69875055 100644
--- a/third_party/WebKit/LayoutTests/platform/linux/fast/inline/br-text-decoration-expected.png
+++ b/third_party/WebKit/LayoutTests/platform/linux/fast/inline/br-text-decoration-expected.png
Binary files differ
diff --git a/third_party/WebKit/LayoutTests/platform/linux/fast/invalid/002-expected.png b/third_party/WebKit/LayoutTests/platform/linux/fast/invalid/002-expected.png
index d1528237..f116df7 100644
--- a/third_party/WebKit/LayoutTests/platform/linux/fast/invalid/002-expected.png
+++ b/third_party/WebKit/LayoutTests/platform/linux/fast/invalid/002-expected.png
Binary files differ
diff --git a/third_party/WebKit/LayoutTests/platform/linux/fast/invalid/003-expected.png b/third_party/WebKit/LayoutTests/platform/linux/fast/invalid/003-expected.png
index a902bc7..eddb7cf 100644
--- a/third_party/WebKit/LayoutTests/platform/linux/fast/invalid/003-expected.png
+++ b/third_party/WebKit/LayoutTests/platform/linux/fast/invalid/003-expected.png
Binary files differ
diff --git a/third_party/WebKit/LayoutTests/platform/linux/fast/invalid/004-expected.png b/third_party/WebKit/LayoutTests/platform/linux/fast/invalid/004-expected.png
index 6151970..92fafe2 100644
--- a/third_party/WebKit/LayoutTests/platform/linux/fast/invalid/004-expected.png
+++ b/third_party/WebKit/LayoutTests/platform/linux/fast/invalid/004-expected.png
Binary files differ
diff --git a/third_party/WebKit/LayoutTests/platform/linux/fast/invalid/missing-address-end-tag-expected.png b/third_party/WebKit/LayoutTests/platform/linux/fast/invalid/missing-address-end-tag-expected.png
index 892648e..d0f1e11 100644
--- a/third_party/WebKit/LayoutTests/platform/linux/fast/invalid/missing-address-end-tag-expected.png
+++ b/third_party/WebKit/LayoutTests/platform/linux/fast/invalid/missing-address-end-tag-expected.png
Binary files differ
diff --git a/third_party/WebKit/LayoutTests/platform/linux/fast/invalid/missing-end-tag-expected.png b/third_party/WebKit/LayoutTests/platform/linux/fast/invalid/missing-end-tag-expected.png
index 8e86807..dbf9688 100644
--- a/third_party/WebKit/LayoutTests/platform/linux/fast/invalid/missing-end-tag-expected.png
+++ b/third_party/WebKit/LayoutTests/platform/linux/fast/invalid/missing-end-tag-expected.png
Binary files differ
diff --git a/third_party/WebKit/LayoutTests/platform/linux/fast/invalid/missing-end-tag-expected.txt b/third_party/WebKit/LayoutTests/platform/linux/fast/invalid/missing-end-tag-expected.txt
index e3107ce..fb793dc 100644
--- a/third_party/WebKit/LayoutTests/platform/linux/fast/invalid/missing-end-tag-expected.txt
+++ b/third_party/WebKit/LayoutTests/platform/linux/fast/invalid/missing-end-tag-expected.txt
@@ -7,9 +7,9 @@
         LayoutText {#text} at (0,0) size 324x22
           text run at (0,0) width 324: "This page contains the following errors:"
       LayoutBlockFlow {div} at (18,62.44) size 732x15
-        LayoutText {#text} at (0,0) size 554x15
-          text run at (0,0) width 554: "error on line 7 at column 8: Opening and ending tag mismatch: p line 0 and body"
-          text run at (554,0) width 0: " "
+        LayoutText {#text} at (0,0) size 553x15
+          text run at (0,0) width 553: "error on line 7 at column 8: Opening and ending tag mismatch: p line 0 and body"
+          text run at (553,0) width 0: " "
       LayoutBlockFlow {h3} at (18,96.16) size 732x23
         LayoutText {#text} at (0,0) size 427x22
           text run at (0,0) width 427: "Below is a rendering of the page up to the first error."
diff --git a/third_party/WebKit/LayoutTests/platform/linux/fast/invalid/nestedh3s-expected.png b/third_party/WebKit/LayoutTests/platform/linux/fast/invalid/nestedh3s-expected.png
index bf65efa..7a625348 100644
--- a/third_party/WebKit/LayoutTests/platform/linux/fast/invalid/nestedh3s-expected.png
+++ b/third_party/WebKit/LayoutTests/platform/linux/fast/invalid/nestedh3s-expected.png
Binary files differ
diff --git a/third_party/WebKit/LayoutTests/platform/linux/fast/layers/inline-dirty-z-order-lists-expected.png b/third_party/WebKit/LayoutTests/platform/linux/fast/layers/inline-dirty-z-order-lists-expected.png
index 74999b9..9942a4a 100644
--- a/third_party/WebKit/LayoutTests/platform/linux/fast/layers/inline-dirty-z-order-lists-expected.png
+++ b/third_party/WebKit/LayoutTests/platform/linux/fast/layers/inline-dirty-z-order-lists-expected.png
Binary files differ
diff --git a/third_party/WebKit/LayoutTests/platform/linux/fast/layers/opacity-outline-expected.png b/third_party/WebKit/LayoutTests/platform/linux/fast/layers/opacity-outline-expected.png
index dc830e2..8aa64219 100644
--- a/third_party/WebKit/LayoutTests/platform/linux/fast/layers/opacity-outline-expected.png
+++ b/third_party/WebKit/LayoutTests/platform/linux/fast/layers/opacity-outline-expected.png
Binary files differ
diff --git a/third_party/WebKit/LayoutTests/platform/linux/fast/layers/scroll-rect-to-visible-expected.png b/third_party/WebKit/LayoutTests/platform/linux/fast/layers/scroll-rect-to-visible-expected.png
index 76c5dc73..90c5a54 100644
--- a/third_party/WebKit/LayoutTests/platform/linux/fast/layers/scroll-rect-to-visible-expected.png
+++ b/third_party/WebKit/LayoutTests/platform/linux/fast/layers/scroll-rect-to-visible-expected.png
Binary files differ
diff --git a/third_party/WebKit/LayoutTests/platform/linux/fast/lists/006-expected.png b/third_party/WebKit/LayoutTests/platform/linux/fast/lists/006-expected.png
index ad35b08..658aaa3 100644
--- a/third_party/WebKit/LayoutTests/platform/linux/fast/lists/006-expected.png
+++ b/third_party/WebKit/LayoutTests/platform/linux/fast/lists/006-expected.png
Binary files differ
diff --git a/third_party/WebKit/LayoutTests/platform/linux/fast/lists/006-vertical-expected.png b/third_party/WebKit/LayoutTests/platform/linux/fast/lists/006-vertical-expected.png
index a33a893..aed2eee 100644
--- a/third_party/WebKit/LayoutTests/platform/linux/fast/lists/006-vertical-expected.png
+++ b/third_party/WebKit/LayoutTests/platform/linux/fast/lists/006-vertical-expected.png
Binary files differ
diff --git a/third_party/WebKit/LayoutTests/platform/linux/fast/lists/marker-before-empty-inline-expected.png b/third_party/WebKit/LayoutTests/platform/linux/fast/lists/marker-before-empty-inline-expected.png
index 34c4bf8..a693118 100644
--- a/third_party/WebKit/LayoutTests/platform/linux/fast/lists/marker-before-empty-inline-expected.png
+++ b/third_party/WebKit/LayoutTests/platform/linux/fast/lists/marker-before-empty-inline-expected.png
Binary files differ
diff --git a/third_party/WebKit/LayoutTests/platform/linux/fast/lists/marker-image-error-expected.png b/third_party/WebKit/LayoutTests/platform/linux/fast/lists/marker-image-error-expected.png
index 57dcddc..a0503908 100644
--- a/third_party/WebKit/LayoutTests/platform/linux/fast/lists/marker-image-error-expected.png
+++ b/third_party/WebKit/LayoutTests/platform/linux/fast/lists/marker-image-error-expected.png
Binary files differ
diff --git a/third_party/WebKit/LayoutTests/platform/linux/fast/lists/markers-in-selection-expected.png b/third_party/WebKit/LayoutTests/platform/linux/fast/lists/markers-in-selection-expected.png
index a32bd51..530100e 100644
--- a/third_party/WebKit/LayoutTests/platform/linux/fast/lists/markers-in-selection-expected.png
+++ b/third_party/WebKit/LayoutTests/platform/linux/fast/lists/markers-in-selection-expected.png
Binary files differ
diff --git a/third_party/WebKit/LayoutTests/platform/linux/fast/multicol/composited-opacity-2nd-and-3rd-column-expected.png b/third_party/WebKit/LayoutTests/platform/linux/fast/multicol/composited-opacity-2nd-and-3rd-column-expected.png
index 692bdf43..23e5f0d 100644
--- a/third_party/WebKit/LayoutTests/platform/linux/fast/multicol/composited-opacity-2nd-and-3rd-column-expected.png
+++ b/third_party/WebKit/LayoutTests/platform/linux/fast/multicol/composited-opacity-2nd-and-3rd-column-expected.png
Binary files differ
diff --git a/third_party/WebKit/LayoutTests/platform/linux/fast/multicol/composited-relpos-overlapping-will-change-expected.png b/third_party/WebKit/LayoutTests/platform/linux/fast/multicol/composited-relpos-overlapping-will-change-expected.png
index b54d511..e9aee8f 100644
--- a/third_party/WebKit/LayoutTests/platform/linux/fast/multicol/composited-relpos-overlapping-will-change-expected.png
+++ b/third_party/WebKit/LayoutTests/platform/linux/fast/multicol/composited-relpos-overlapping-will-change-expected.png
Binary files differ
diff --git a/third_party/WebKit/LayoutTests/platform/linux/fast/multicol/vertical-lr/composited-relpos-overlapping-will-change-expected.png b/third_party/WebKit/LayoutTests/platform/linux/fast/multicol/vertical-lr/composited-relpos-overlapping-will-change-expected.png
index c0ae50d..871fc5ee 100644
--- a/third_party/WebKit/LayoutTests/platform/linux/fast/multicol/vertical-lr/composited-relpos-overlapping-will-change-expected.png
+++ b/third_party/WebKit/LayoutTests/platform/linux/fast/multicol/vertical-lr/composited-relpos-overlapping-will-change-expected.png
Binary files differ
diff --git a/third_party/WebKit/LayoutTests/platform/linux/fast/multicol/vertical-rl/composited-relpos-overlapping-will-change-expected.png b/third_party/WebKit/LayoutTests/platform/linux/fast/multicol/vertical-rl/composited-relpos-overlapping-will-change-expected.png
index 5c7bb068..5084fee24 100644
--- a/third_party/WebKit/LayoutTests/platform/linux/fast/multicol/vertical-rl/composited-relpos-overlapping-will-change-expected.png
+++ b/third_party/WebKit/LayoutTests/platform/linux/fast/multicol/vertical-rl/composited-relpos-overlapping-will-change-expected.png
Binary files differ
diff --git a/third_party/WebKit/LayoutTests/platform/linux/fast/overflow/007-expected.png b/third_party/WebKit/LayoutTests/platform/linux/fast/overflow/007-expected.png
index 232b97f..f88876d 100644
--- a/third_party/WebKit/LayoutTests/platform/linux/fast/overflow/007-expected.png
+++ b/third_party/WebKit/LayoutTests/platform/linux/fast/overflow/007-expected.png
Binary files differ
diff --git a/third_party/WebKit/LayoutTests/platform/linux/fast/overflow/clip-rects-fixed-ancestor-expected.png b/third_party/WebKit/LayoutTests/platform/linux/fast/overflow/clip-rects-fixed-ancestor-expected.png
index 3b51a3c9..8f840f6 100644
--- a/third_party/WebKit/LayoutTests/platform/linux/fast/overflow/clip-rects-fixed-ancestor-expected.png
+++ b/third_party/WebKit/LayoutTests/platform/linux/fast/overflow/clip-rects-fixed-ancestor-expected.png
Binary files differ
diff --git a/third_party/WebKit/LayoutTests/platform/linux/fast/overflow/float-in-relpositioned-expected.png b/third_party/WebKit/LayoutTests/platform/linux/fast/overflow/float-in-relpositioned-expected.png
index 80dd3f2..dd792f2 100644
--- a/third_party/WebKit/LayoutTests/platform/linux/fast/overflow/float-in-relpositioned-expected.png
+++ b/third_party/WebKit/LayoutTests/platform/linux/fast/overflow/float-in-relpositioned-expected.png
Binary files differ
diff --git a/third_party/WebKit/LayoutTests/platform/linux/fast/overflow/hit-test-overflow-controls-expected.png b/third_party/WebKit/LayoutTests/platform/linux/fast/overflow/hit-test-overflow-controls-expected.png
index 90f446568..0a0548e 100644
--- a/third_party/WebKit/LayoutTests/platform/linux/fast/overflow/hit-test-overflow-controls-expected.png
+++ b/third_party/WebKit/LayoutTests/platform/linux/fast/overflow/hit-test-overflow-controls-expected.png
Binary files differ
diff --git a/third_party/WebKit/LayoutTests/platform/linux/fast/overflow/image-selection-highlight-expected.png b/third_party/WebKit/LayoutTests/platform/linux/fast/overflow/image-selection-highlight-expected.png
index 7df092b..116e677 100644
--- a/third_party/WebKit/LayoutTests/platform/linux/fast/overflow/image-selection-highlight-expected.png
+++ b/third_party/WebKit/LayoutTests/platform/linux/fast/overflow/image-selection-highlight-expected.png
Binary files differ
diff --git a/third_party/WebKit/LayoutTests/platform/linux/fast/overflow/overflow-rtl-expected.png b/third_party/WebKit/LayoutTests/platform/linux/fast/overflow/overflow-rtl-expected.png
index 77a40af..1938434 100644
--- a/third_party/WebKit/LayoutTests/platform/linux/fast/overflow/overflow-rtl-expected.png
+++ b/third_party/WebKit/LayoutTests/platform/linux/fast/overflow/overflow-rtl-expected.png
Binary files differ
diff --git a/third_party/WebKit/LayoutTests/platform/linux/fast/overflow/overflow-rtl-inline-scrollbar-expected.png b/third_party/WebKit/LayoutTests/platform/linux/fast/overflow/overflow-rtl-inline-scrollbar-expected.png
index 57e5cab..c59abab7 100644
--- a/third_party/WebKit/LayoutTests/platform/linux/fast/overflow/overflow-rtl-inline-scrollbar-expected.png
+++ b/third_party/WebKit/LayoutTests/platform/linux/fast/overflow/overflow-rtl-inline-scrollbar-expected.png
Binary files differ
diff --git a/third_party/WebKit/LayoutTests/platform/linux/fast/overflow/overflow-rtl-vertical-expected.png b/third_party/WebKit/LayoutTests/platform/linux/fast/overflow/overflow-rtl-vertical-expected.png
index f2c7c661..fbbf4c9 100644
--- a/third_party/WebKit/LayoutTests/platform/linux/fast/overflow/overflow-rtl-vertical-expected.png
+++ b/third_party/WebKit/LayoutTests/platform/linux/fast/overflow/overflow-rtl-vertical-expected.png
Binary files differ
diff --git a/third_party/WebKit/LayoutTests/platform/linux/fast/overflow/overflow-text-hit-testing-expected.png b/third_party/WebKit/LayoutTests/platform/linux/fast/overflow/overflow-text-hit-testing-expected.png
index a9043748..91d4057b 100644
--- a/third_party/WebKit/LayoutTests/platform/linux/fast/overflow/overflow-text-hit-testing-expected.png
+++ b/third_party/WebKit/LayoutTests/platform/linux/fast/overflow/overflow-text-hit-testing-expected.png
Binary files differ
diff --git a/third_party/WebKit/LayoutTests/platform/linux/fast/overflow/scrollbar-position-update-expected.png b/third_party/WebKit/LayoutTests/platform/linux/fast/overflow/scrollbar-position-update-expected.png
index 0bc2303..f569292 100644
--- a/third_party/WebKit/LayoutTests/platform/linux/fast/overflow/scrollbar-position-update-expected.png
+++ b/third_party/WebKit/LayoutTests/platform/linux/fast/overflow/scrollbar-position-update-expected.png
Binary files differ
diff --git a/third_party/WebKit/LayoutTests/platform/linux/fast/overflow/table-overflow-float-expected.png b/third_party/WebKit/LayoutTests/platform/linux/fast/overflow/table-overflow-float-expected.png
index 01ca4b1..59feef25 100644
--- a/third_party/WebKit/LayoutTests/platform/linux/fast/overflow/table-overflow-float-expected.png
+++ b/third_party/WebKit/LayoutTests/platform/linux/fast/overflow/table-overflow-float-expected.png
Binary files differ
diff --git a/third_party/WebKit/LayoutTests/platform/linux/fast/parser/entity-comment-in-textarea-expected.png b/third_party/WebKit/LayoutTests/platform/linux/fast/parser/entity-comment-in-textarea-expected.png
index 02108e25..cfc2c6c 100644
--- a/third_party/WebKit/LayoutTests/platform/linux/fast/parser/entity-comment-in-textarea-expected.png
+++ b/third_party/WebKit/LayoutTests/platform/linux/fast/parser/entity-comment-in-textarea-expected.png
Binary files differ
diff --git a/third_party/WebKit/LayoutTests/platform/linux/fast/parser/open-comment-in-textarea-expected.png b/third_party/WebKit/LayoutTests/platform/linux/fast/parser/open-comment-in-textarea-expected.png
index e5ad47a..8df84d59 100644
--- a/third_party/WebKit/LayoutTests/platform/linux/fast/parser/open-comment-in-textarea-expected.png
+++ b/third_party/WebKit/LayoutTests/platform/linux/fast/parser/open-comment-in-textarea-expected.png
Binary files differ
diff --git a/third_party/WebKit/LayoutTests/platform/linux/fast/reflections/inline-crash-expected.png b/third_party/WebKit/LayoutTests/platform/linux/fast/reflections/inline-crash-expected.png
index 199a2854..004d77a 100644
--- a/third_party/WebKit/LayoutTests/platform/linux/fast/reflections/inline-crash-expected.png
+++ b/third_party/WebKit/LayoutTests/platform/linux/fast/reflections/inline-crash-expected.png
Binary files differ
diff --git a/third_party/WebKit/LayoutTests/platform/linux/fast/replaced/absolute-position-percentage-height-expected.png b/third_party/WebKit/LayoutTests/platform/linux/fast/replaced/absolute-position-percentage-height-expected.png
index 84aac0c..c180b92 100644
--- a/third_party/WebKit/LayoutTests/platform/linux/fast/replaced/absolute-position-percentage-height-expected.png
+++ b/third_party/WebKit/LayoutTests/platform/linux/fast/replaced/absolute-position-percentage-height-expected.png
Binary files differ
diff --git a/third_party/WebKit/LayoutTests/platform/linux/fast/replaced/image-resize-width-expected.png b/third_party/WebKit/LayoutTests/platform/linux/fast/replaced/image-resize-width-expected.png
index 7d0cb17a..cb708ec 100644
--- a/third_party/WebKit/LayoutTests/platform/linux/fast/replaced/image-resize-width-expected.png
+++ b/third_party/WebKit/LayoutTests/platform/linux/fast/replaced/image-resize-width-expected.png
Binary files differ
diff --git a/third_party/WebKit/LayoutTests/platform/linux/fast/replaced/inline-box-wrapper-handover-expected.png b/third_party/WebKit/LayoutTests/platform/linux/fast/replaced/inline-box-wrapper-handover-expected.png
index 97d1390a..773892b 100644
--- a/third_party/WebKit/LayoutTests/platform/linux/fast/replaced/inline-box-wrapper-handover-expected.png
+++ b/third_party/WebKit/LayoutTests/platform/linux/fast/replaced/inline-box-wrapper-handover-expected.png
Binary files differ
diff --git a/third_party/WebKit/LayoutTests/platform/linux/fast/replaced/max-width-percent-expected.png b/third_party/WebKit/LayoutTests/platform/linux/fast/replaced/max-width-percent-expected.png
index 3c63659c..3f568d27 100644
--- a/third_party/WebKit/LayoutTests/platform/linux/fast/replaced/max-width-percent-expected.png
+++ b/third_party/WebKit/LayoutTests/platform/linux/fast/replaced/max-width-percent-expected.png
Binary files differ
diff --git a/third_party/WebKit/LayoutTests/platform/linux/fast/replaced/outline-replaced-elements-expected.png b/third_party/WebKit/LayoutTests/platform/linux/fast/replaced/outline-replaced-elements-expected.png
index e59cfc7..26fe8fc 100644
--- a/third_party/WebKit/LayoutTests/platform/linux/fast/replaced/outline-replaced-elements-expected.png
+++ b/third_party/WebKit/LayoutTests/platform/linux/fast/replaced/outline-replaced-elements-expected.png
Binary files differ
diff --git a/third_party/WebKit/LayoutTests/platform/linux/fast/replaced/percent-height-in-anonymous-block-in-table-expected.png b/third_party/WebKit/LayoutTests/platform/linux/fast/replaced/percent-height-in-anonymous-block-in-table-expected.png
index d5f0431..312bec7 100644
--- a/third_party/WebKit/LayoutTests/platform/linux/fast/replaced/percent-height-in-anonymous-block-in-table-expected.png
+++ b/third_party/WebKit/LayoutTests/platform/linux/fast/replaced/percent-height-in-anonymous-block-in-table-expected.png
Binary files differ
diff --git a/third_party/WebKit/LayoutTests/platform/linux/fast/replaced/selection-rect-in-table-cell-expected.png b/third_party/WebKit/LayoutTests/platform/linux/fast/replaced/selection-rect-in-table-cell-expected.png
index 48243f5b..87942e7 100644
--- a/third_party/WebKit/LayoutTests/platform/linux/fast/replaced/selection-rect-in-table-cell-expected.png
+++ b/third_party/WebKit/LayoutTests/platform/linux/fast/replaced/selection-rect-in-table-cell-expected.png
Binary files differ
diff --git a/third_party/WebKit/LayoutTests/platform/linux/fast/ruby/ruby-empty-rt-expected.png b/third_party/WebKit/LayoutTests/platform/linux/fast/ruby/ruby-empty-rt-expected.png
index 4d54e1f..3f52253 100644
--- a/third_party/WebKit/LayoutTests/platform/linux/fast/ruby/ruby-empty-rt-expected.png
+++ b/third_party/WebKit/LayoutTests/platform/linux/fast/ruby/ruby-empty-rt-expected.png
Binary files differ
diff --git a/third_party/WebKit/LayoutTests/platform/linux/fast/ruby/ruby-inline-table-expected.png b/third_party/WebKit/LayoutTests/platform/linux/fast/ruby/ruby-inline-table-expected.png
index 5d80e26..0e83efd 100644
--- a/third_party/WebKit/LayoutTests/platform/linux/fast/ruby/ruby-inline-table-expected.png
+++ b/third_party/WebKit/LayoutTests/platform/linux/fast/ruby/ruby-inline-table-expected.png
Binary files differ
diff --git a/third_party/WebKit/LayoutTests/platform/linux/fast/ruby/ruby-length-expected.png b/third_party/WebKit/LayoutTests/platform/linux/fast/ruby/ruby-length-expected.png
index e71ba625..55e942b 100644
--- a/third_party/WebKit/LayoutTests/platform/linux/fast/ruby/ruby-length-expected.png
+++ b/third_party/WebKit/LayoutTests/platform/linux/fast/ruby/ruby-length-expected.png
Binary files differ
diff --git a/third_party/WebKit/LayoutTests/platform/linux/fast/ruby/ruby-run-break-expected.png b/third_party/WebKit/LayoutTests/platform/linux/fast/ruby/ruby-run-break-expected.png
index 583c03f7..45947b9 100644
--- a/third_party/WebKit/LayoutTests/platform/linux/fast/ruby/ruby-run-break-expected.png
+++ b/third_party/WebKit/LayoutTests/platform/linux/fast/ruby/ruby-run-break-expected.png
Binary files differ
diff --git a/third_party/WebKit/LayoutTests/platform/linux/fast/ruby/ruby-runs-expected.png b/third_party/WebKit/LayoutTests/platform/linux/fast/ruby/ruby-runs-expected.png
index 68ebdcf..17fd684 100644
--- a/third_party/WebKit/LayoutTests/platform/linux/fast/ruby/ruby-runs-expected.png
+++ b/third_party/WebKit/LayoutTests/platform/linux/fast/ruby/ruby-runs-expected.png
Binary files differ
diff --git a/third_party/WebKit/LayoutTests/platform/linux/fast/ruby/ruby-runs-spans-expected.png b/third_party/WebKit/LayoutTests/platform/linux/fast/ruby/ruby-runs-spans-expected.png
index 01709a35..ef972f05 100644
--- a/third_party/WebKit/LayoutTests/platform/linux/fast/ruby/ruby-runs-spans-expected.png
+++ b/third_party/WebKit/LayoutTests/platform/linux/fast/ruby/ruby-runs-spans-expected.png
Binary files differ
diff --git a/third_party/WebKit/LayoutTests/platform/linux/fast/ruby/ruby-simple-rp-expected.png b/third_party/WebKit/LayoutTests/platform/linux/fast/ruby/ruby-simple-rp-expected.png
index 3e86ad0..fb4095d 100644
--- a/third_party/WebKit/LayoutTests/platform/linux/fast/ruby/ruby-simple-rp-expected.png
+++ b/third_party/WebKit/LayoutTests/platform/linux/fast/ruby/ruby-simple-rp-expected.png
Binary files differ
diff --git a/third_party/WebKit/LayoutTests/platform/linux/fast/ruby/ruby-trailing-expected.png b/third_party/WebKit/LayoutTests/platform/linux/fast/ruby/ruby-trailing-expected.png
index 7f7702f..f6843c9 100644
--- a/third_party/WebKit/LayoutTests/platform/linux/fast/ruby/ruby-trailing-expected.png
+++ b/third_party/WebKit/LayoutTests/platform/linux/fast/ruby/ruby-trailing-expected.png
Binary files differ
diff --git a/third_party/WebKit/LayoutTests/platform/linux/fast/ruby/rubyDOM-insert-rt-expected.png b/third_party/WebKit/LayoutTests/platform/linux/fast/ruby/rubyDOM-insert-rt-expected.png
index defc0ae..7d53089 100644
--- a/third_party/WebKit/LayoutTests/platform/linux/fast/ruby/rubyDOM-insert-rt-expected.png
+++ b/third_party/WebKit/LayoutTests/platform/linux/fast/ruby/rubyDOM-insert-rt-expected.png
Binary files differ
diff --git a/third_party/WebKit/LayoutTests/platform/linux/fast/ruby/rubyDOM-insert-text1-expected.png b/third_party/WebKit/LayoutTests/platform/linux/fast/ruby/rubyDOM-insert-text1-expected.png
index 2137f10..1247341 100644
--- a/third_party/WebKit/LayoutTests/platform/linux/fast/ruby/rubyDOM-insert-text1-expected.png
+++ b/third_party/WebKit/LayoutTests/platform/linux/fast/ruby/rubyDOM-insert-text1-expected.png
Binary files differ
diff --git a/third_party/WebKit/LayoutTests/platform/linux/fast/ruby/rubyDOM-insert-text2-expected.png b/third_party/WebKit/LayoutTests/platform/linux/fast/ruby/rubyDOM-insert-text2-expected.png
index 0cb72e8..ace64718 100644
--- a/third_party/WebKit/LayoutTests/platform/linux/fast/ruby/rubyDOM-insert-text2-expected.png
+++ b/third_party/WebKit/LayoutTests/platform/linux/fast/ruby/rubyDOM-insert-text2-expected.png
Binary files differ
diff --git a/third_party/WebKit/LayoutTests/platform/linux/fast/ruby/rubyDOM-insert-text3-expected.png b/third_party/WebKit/LayoutTests/platform/linux/fast/ruby/rubyDOM-insert-text3-expected.png
index 02289af4..e2bdbf0 100644
--- a/third_party/WebKit/LayoutTests/platform/linux/fast/ruby/rubyDOM-insert-text3-expected.png
+++ b/third_party/WebKit/LayoutTests/platform/linux/fast/ruby/rubyDOM-insert-text3-expected.png
Binary files differ
diff --git a/third_party/WebKit/LayoutTests/platform/linux/fast/ruby/rubyDOM-remove-rt1-expected.png b/third_party/WebKit/LayoutTests/platform/linux/fast/ruby/rubyDOM-remove-rt1-expected.png
index 05682d7..8aeeecd 100644
--- a/third_party/WebKit/LayoutTests/platform/linux/fast/ruby/rubyDOM-remove-rt1-expected.png
+++ b/third_party/WebKit/LayoutTests/platform/linux/fast/ruby/rubyDOM-remove-rt1-expected.png
Binary files differ
diff --git a/third_party/WebKit/LayoutTests/platform/linux/fast/ruby/rubyDOM-remove-rt2-expected.png b/third_party/WebKit/LayoutTests/platform/linux/fast/ruby/rubyDOM-remove-rt2-expected.png
index 69bdbc8..9419630e 100644
--- a/third_party/WebKit/LayoutTests/platform/linux/fast/ruby/rubyDOM-remove-rt2-expected.png
+++ b/third_party/WebKit/LayoutTests/platform/linux/fast/ruby/rubyDOM-remove-rt2-expected.png
Binary files differ
diff --git a/third_party/WebKit/LayoutTests/platform/linux/fast/ruby/rubyDOM-remove-text1-expected.png b/third_party/WebKit/LayoutTests/platform/linux/fast/ruby/rubyDOM-remove-text1-expected.png
index 304a7dd..2890b745 100644
--- a/third_party/WebKit/LayoutTests/platform/linux/fast/ruby/rubyDOM-remove-text1-expected.png
+++ b/third_party/WebKit/LayoutTests/platform/linux/fast/ruby/rubyDOM-remove-text1-expected.png
Binary files differ
diff --git a/third_party/WebKit/LayoutTests/platform/linux/fast/ruby/rubyDOM-remove-text2-expected.png b/third_party/WebKit/LayoutTests/platform/linux/fast/ruby/rubyDOM-remove-text2-expected.png
index d25b308..390643b 100644
--- a/third_party/WebKit/LayoutTests/platform/linux/fast/ruby/rubyDOM-remove-text2-expected.png
+++ b/third_party/WebKit/LayoutTests/platform/linux/fast/ruby/rubyDOM-remove-text2-expected.png
Binary files differ
diff --git a/third_party/WebKit/LayoutTests/platform/linux/fast/selectors/018-expected.png b/third_party/WebKit/LayoutTests/platform/linux/fast/selectors/018-expected.png
index f4acd0fc..140e13a 100644
--- a/third_party/WebKit/LayoutTests/platform/linux/fast/selectors/018-expected.png
+++ b/third_party/WebKit/LayoutTests/platform/linux/fast/selectors/018-expected.png
Binary files differ
diff --git a/third_party/WebKit/LayoutTests/platform/linux/fast/selectors/034-expected.png b/third_party/WebKit/LayoutTests/platform/linux/fast/selectors/034-expected.png
index a3383b82..241ad98 100644
--- a/third_party/WebKit/LayoutTests/platform/linux/fast/selectors/034-expected.png
+++ b/third_party/WebKit/LayoutTests/platform/linux/fast/selectors/034-expected.png
Binary files differ
diff --git a/third_party/WebKit/LayoutTests/platform/linux/fast/selectors/045-expected.png b/third_party/WebKit/LayoutTests/platform/linux/fast/selectors/045-expected.png
index 144a795b..b3f7eea 100644
--- a/third_party/WebKit/LayoutTests/platform/linux/fast/selectors/045-expected.png
+++ b/third_party/WebKit/LayoutTests/platform/linux/fast/selectors/045-expected.png
Binary files differ
diff --git a/third_party/WebKit/LayoutTests/platform/linux/fast/selectors/045b-expected.png b/third_party/WebKit/LayoutTests/platform/linux/fast/selectors/045b-expected.png
index 7e2ffce..66d12b43 100644
--- a/third_party/WebKit/LayoutTests/platform/linux/fast/selectors/045b-expected.png
+++ b/third_party/WebKit/LayoutTests/platform/linux/fast/selectors/045b-expected.png
Binary files differ
diff --git a/third_party/WebKit/LayoutTests/platform/linux/fast/selectors/046-expected.png b/third_party/WebKit/LayoutTests/platform/linux/fast/selectors/046-expected.png
index cab3a5f1a..b0c0e21a 100644
--- a/third_party/WebKit/LayoutTests/platform/linux/fast/selectors/046-expected.png
+++ b/third_party/WebKit/LayoutTests/platform/linux/fast/selectors/046-expected.png
Binary files differ
diff --git a/third_party/WebKit/LayoutTests/platform/linux/fast/selectors/166-expected.png b/third_party/WebKit/LayoutTests/platform/linux/fast/selectors/166-expected.png
index 87f4f4f..a408608 100644
--- a/third_party/WebKit/LayoutTests/platform/linux/fast/selectors/166-expected.png
+++ b/third_party/WebKit/LayoutTests/platform/linux/fast/selectors/166-expected.png
Binary files differ
diff --git a/third_party/WebKit/LayoutTests/platform/linux/fast/table/018-expected.png b/third_party/WebKit/LayoutTests/platform/linux/fast/table/018-expected.png
index 52e7f17..f280ad41 100644
--- a/third_party/WebKit/LayoutTests/platform/linux/fast/table/018-expected.png
+++ b/third_party/WebKit/LayoutTests/platform/linux/fast/table/018-expected.png
Binary files differ
diff --git a/third_party/WebKit/LayoutTests/platform/linux/fast/table/022-expected.png b/third_party/WebKit/LayoutTests/platform/linux/fast/table/022-expected.png
index fefacaa..bd0d2b8 100644
--- a/third_party/WebKit/LayoutTests/platform/linux/fast/table/022-expected.png
+++ b/third_party/WebKit/LayoutTests/platform/linux/fast/table/022-expected.png
Binary files differ
diff --git a/third_party/WebKit/LayoutTests/platform/linux/fast/table/100-percent-cell-width-expected.png b/third_party/WebKit/LayoutTests/platform/linux/fast/table/100-percent-cell-width-expected.png
index df8686e..cfee0433 100644
--- a/third_party/WebKit/LayoutTests/platform/linux/fast/table/100-percent-cell-width-expected.png
+++ b/third_party/WebKit/LayoutTests/platform/linux/fast/table/100-percent-cell-width-expected.png
Binary files differ
diff --git a/third_party/WebKit/LayoutTests/platform/linux/fast/table/add-before-anonymous-child-expected.png b/third_party/WebKit/LayoutTests/platform/linux/fast/table/add-before-anonymous-child-expected.png
index 0cc2181..c56d020 100644
--- a/third_party/WebKit/LayoutTests/platform/linux/fast/table/add-before-anonymous-child-expected.png
+++ b/third_party/WebKit/LayoutTests/platform/linux/fast/table/add-before-anonymous-child-expected.png
Binary files differ
diff --git a/third_party/WebKit/LayoutTests/platform/linux/fast/table/backgr_border-table-cell-collapsed-border-expected.png b/third_party/WebKit/LayoutTests/platform/linux/fast/table/backgr_border-table-cell-collapsed-border-expected.png
index 1806f1b..af186ec 100644
--- a/third_party/WebKit/LayoutTests/platform/linux/fast/table/backgr_border-table-cell-collapsed-border-expected.png
+++ b/third_party/WebKit/LayoutTests/platform/linux/fast/table/backgr_border-table-cell-collapsed-border-expected.png
Binary files differ
diff --git a/third_party/WebKit/LayoutTests/platform/linux/fast/table/backgr_border-table-cell-expected.png b/third_party/WebKit/LayoutTests/platform/linux/fast/table/backgr_border-table-cell-expected.png
index 35651b1..a6ef896 100644
--- a/third_party/WebKit/LayoutTests/platform/linux/fast/table/backgr_border-table-cell-expected.png
+++ b/third_party/WebKit/LayoutTests/platform/linux/fast/table/backgr_border-table-cell-expected.png
Binary files differ
diff --git a/third_party/WebKit/LayoutTests/platform/linux/fast/table/backgr_border-table-collapsed-border-expected.png b/third_party/WebKit/LayoutTests/platform/linux/fast/table/backgr_border-table-collapsed-border-expected.png
index aa3a021..e80a8b61 100644
--- a/third_party/WebKit/LayoutTests/platform/linux/fast/table/backgr_border-table-collapsed-border-expected.png
+++ b/third_party/WebKit/LayoutTests/platform/linux/fast/table/backgr_border-table-collapsed-border-expected.png
Binary files differ
diff --git a/third_party/WebKit/LayoutTests/platform/linux/fast/table/backgr_border-table-column-collapsed-border-expected.png b/third_party/WebKit/LayoutTests/platform/linux/fast/table/backgr_border-table-column-collapsed-border-expected.png
index 198e231..6034610 100644
--- a/third_party/WebKit/LayoutTests/platform/linux/fast/table/backgr_border-table-column-collapsed-border-expected.png
+++ b/third_party/WebKit/LayoutTests/platform/linux/fast/table/backgr_border-table-column-collapsed-border-expected.png
Binary files differ
diff --git a/third_party/WebKit/LayoutTests/platform/linux/fast/table/backgr_border-table-column-expected.png b/third_party/WebKit/LayoutTests/platform/linux/fast/table/backgr_border-table-column-expected.png
index 9e88bd1..cadc5a1 100644
--- a/third_party/WebKit/LayoutTests/platform/linux/fast/table/backgr_border-table-column-expected.png
+++ b/third_party/WebKit/LayoutTests/platform/linux/fast/table/backgr_border-table-column-expected.png
Binary files differ
diff --git a/third_party/WebKit/LayoutTests/platform/linux/fast/table/backgr_border-table-column-group-collapsed-border-expected.png b/third_party/WebKit/LayoutTests/platform/linux/fast/table/backgr_border-table-column-group-collapsed-border-expected.png
index be1ef0ba..c9e89fb3 100644
--- a/third_party/WebKit/LayoutTests/platform/linux/fast/table/backgr_border-table-column-group-collapsed-border-expected.png
+++ b/third_party/WebKit/LayoutTests/platform/linux/fast/table/backgr_border-table-column-group-collapsed-border-expected.png
Binary files differ
diff --git a/third_party/WebKit/LayoutTests/platform/linux/fast/table/backgr_border-table-column-group-expected.png b/third_party/WebKit/LayoutTests/platform/linux/fast/table/backgr_border-table-column-group-expected.png
index a6ad508..05883dc 100644
--- a/third_party/WebKit/LayoutTests/platform/linux/fast/table/backgr_border-table-column-group-expected.png
+++ b/third_party/WebKit/LayoutTests/platform/linux/fast/table/backgr_border-table-column-group-expected.png
Binary files differ
diff --git a/third_party/WebKit/LayoutTests/platform/linux/fast/table/backgr_border-table-expected.png b/third_party/WebKit/LayoutTests/platform/linux/fast/table/backgr_border-table-expected.png
index 346bd88..66c969a4 100644
--- a/third_party/WebKit/LayoutTests/platform/linux/fast/table/backgr_border-table-expected.png
+++ b/third_party/WebKit/LayoutTests/platform/linux/fast/table/backgr_border-table-expected.png
Binary files differ
diff --git a/third_party/WebKit/LayoutTests/platform/linux/fast/table/backgr_border-table-quirks-collapsed-border-expected.png b/third_party/WebKit/LayoutTests/platform/linux/fast/table/backgr_border-table-quirks-collapsed-border-expected.png
index 82438177..92b122b 100644
--- a/third_party/WebKit/LayoutTests/platform/linux/fast/table/backgr_border-table-quirks-collapsed-border-expected.png
+++ b/third_party/WebKit/LayoutTests/platform/linux/fast/table/backgr_border-table-quirks-collapsed-border-expected.png
Binary files differ
diff --git a/third_party/WebKit/LayoutTests/platform/linux/fast/table/backgr_border-table-quirks-expected.png b/third_party/WebKit/LayoutTests/platform/linux/fast/table/backgr_border-table-quirks-expected.png
index a49e513..3aea3ba 100644
--- a/third_party/WebKit/LayoutTests/platform/linux/fast/table/backgr_border-table-quirks-expected.png
+++ b/third_party/WebKit/LayoutTests/platform/linux/fast/table/backgr_border-table-quirks-expected.png
Binary files differ
diff --git a/third_party/WebKit/LayoutTests/platform/linux/fast/table/backgr_border-table-row-collapsed-border-expected.png b/third_party/WebKit/LayoutTests/platform/linux/fast/table/backgr_border-table-row-collapsed-border-expected.png
index 6ba967c..3cb3102 100644
--- a/third_party/WebKit/LayoutTests/platform/linux/fast/table/backgr_border-table-row-collapsed-border-expected.png
+++ b/third_party/WebKit/LayoutTests/platform/linux/fast/table/backgr_border-table-row-collapsed-border-expected.png
Binary files differ
diff --git a/third_party/WebKit/LayoutTests/platform/linux/fast/table/backgr_border-table-row-expected.png b/third_party/WebKit/LayoutTests/platform/linux/fast/table/backgr_border-table-row-expected.png
index 5e24917..8aa6930 100644
--- a/third_party/WebKit/LayoutTests/platform/linux/fast/table/backgr_border-table-row-expected.png
+++ b/third_party/WebKit/LayoutTests/platform/linux/fast/table/backgr_border-table-row-expected.png
Binary files differ
diff --git a/third_party/WebKit/LayoutTests/platform/linux/fast/table/backgr_border-table-row-group-collapsed-border-expected.png b/third_party/WebKit/LayoutTests/platform/linux/fast/table/backgr_border-table-row-group-collapsed-border-expected.png
index 6a41c65..847d83be 100644
--- a/third_party/WebKit/LayoutTests/platform/linux/fast/table/backgr_border-table-row-group-collapsed-border-expected.png
+++ b/third_party/WebKit/LayoutTests/platform/linux/fast/table/backgr_border-table-row-group-collapsed-border-expected.png
Binary files differ
diff --git a/third_party/WebKit/LayoutTests/platform/linux/fast/table/backgr_border-table-row-group-expected.png b/third_party/WebKit/LayoutTests/platform/linux/fast/table/backgr_border-table-row-group-expected.png
index 4bd187d..6e4e7c9 100644
--- a/third_party/WebKit/LayoutTests/platform/linux/fast/table/backgr_border-table-row-group-expected.png
+++ b/third_party/WebKit/LayoutTests/platform/linux/fast/table/backgr_border-table-row-group-expected.png
Binary files differ
diff --git a/third_party/WebKit/LayoutTests/platform/linux/fast/table/backgr_layers-hide-collapsed-border-expected.png b/third_party/WebKit/LayoutTests/platform/linux/fast/table/backgr_layers-hide-collapsed-border-expected.png
index dcea118..1a2a9ba 100644
--- a/third_party/WebKit/LayoutTests/platform/linux/fast/table/backgr_layers-hide-collapsed-border-expected.png
+++ b/third_party/WebKit/LayoutTests/platform/linux/fast/table/backgr_layers-hide-collapsed-border-expected.png
Binary files differ
diff --git a/third_party/WebKit/LayoutTests/platform/linux/fast/table/backgr_layers-hide-expected.png b/third_party/WebKit/LayoutTests/platform/linux/fast/table/backgr_layers-hide-expected.png
index ccf013c6..449a74d 100644
--- a/third_party/WebKit/LayoutTests/platform/linux/fast/table/backgr_layers-hide-expected.png
+++ b/third_party/WebKit/LayoutTests/platform/linux/fast/table/backgr_layers-hide-expected.png
Binary files differ
diff --git a/third_party/WebKit/LayoutTests/platform/linux/fast/table/backgr_layers-opacity-collapsed-border-expected.png b/third_party/WebKit/LayoutTests/platform/linux/fast/table/backgr_layers-opacity-collapsed-border-expected.png
index ae1c6c8..933de89 100644
--- a/third_party/WebKit/LayoutTests/platform/linux/fast/table/backgr_layers-opacity-collapsed-border-expected.png
+++ b/third_party/WebKit/LayoutTests/platform/linux/fast/table/backgr_layers-opacity-collapsed-border-expected.png
Binary files differ
diff --git a/third_party/WebKit/LayoutTests/platform/linux/fast/table/backgr_layers-opacity-expected.png b/third_party/WebKit/LayoutTests/platform/linux/fast/table/backgr_layers-opacity-expected.png
index ae1c6c8..933de89 100644
--- a/third_party/WebKit/LayoutTests/platform/linux/fast/table/backgr_layers-opacity-expected.png
+++ b/third_party/WebKit/LayoutTests/platform/linux/fast/table/backgr_layers-opacity-expected.png
Binary files differ
diff --git a/third_party/WebKit/LayoutTests/platform/linux/fast/table/backgr_layers-show-collapsed-border-expected.png b/third_party/WebKit/LayoutTests/platform/linux/fast/table/backgr_layers-show-collapsed-border-expected.png
index 06fd3954..59728f5 100644
--- a/third_party/WebKit/LayoutTests/platform/linux/fast/table/backgr_layers-show-collapsed-border-expected.png
+++ b/third_party/WebKit/LayoutTests/platform/linux/fast/table/backgr_layers-show-collapsed-border-expected.png
Binary files differ
diff --git a/third_party/WebKit/LayoutTests/platform/linux/fast/table/backgr_layers-show-expected.png b/third_party/WebKit/LayoutTests/platform/linux/fast/table/backgr_layers-show-expected.png
index 475491f..6fd0aba 100644
--- a/third_party/WebKit/LayoutTests/platform/linux/fast/table/backgr_layers-show-expected.png
+++ b/third_party/WebKit/LayoutTests/platform/linux/fast/table/backgr_layers-show-expected.png
Binary files differ
diff --git a/third_party/WebKit/LayoutTests/platform/linux/fast/table/backgr_position-table-cell-collapsed-border-expected.png b/third_party/WebKit/LayoutTests/platform/linux/fast/table/backgr_position-table-cell-collapsed-border-expected.png
index 2acb75ece..5e2d15b 100644
--- a/third_party/WebKit/LayoutTests/platform/linux/fast/table/backgr_position-table-cell-collapsed-border-expected.png
+++ b/third_party/WebKit/LayoutTests/platform/linux/fast/table/backgr_position-table-cell-collapsed-border-expected.png
Binary files differ
diff --git a/third_party/WebKit/LayoutTests/platform/linux/fast/table/backgr_position-table-cell-expected.png b/third_party/WebKit/LayoutTests/platform/linux/fast/table/backgr_position-table-cell-expected.png
index ade03db1..28ea718 100644
--- a/third_party/WebKit/LayoutTests/platform/linux/fast/table/backgr_position-table-cell-expected.png
+++ b/third_party/WebKit/LayoutTests/platform/linux/fast/table/backgr_position-table-cell-expected.png
Binary files differ
diff --git a/third_party/WebKit/LayoutTests/platform/linux/fast/table/backgr_position-table-collapsed-border-expected.png b/third_party/WebKit/LayoutTests/platform/linux/fast/table/backgr_position-table-collapsed-border-expected.png
index f887128..97733b76 100644
--- a/third_party/WebKit/LayoutTests/platform/linux/fast/table/backgr_position-table-collapsed-border-expected.png
+++ b/third_party/WebKit/LayoutTests/platform/linux/fast/table/backgr_position-table-collapsed-border-expected.png
Binary files differ
diff --git a/third_party/WebKit/LayoutTests/platform/linux/fast/table/backgr_position-table-column-collapsed-border-expected.png b/third_party/WebKit/LayoutTests/platform/linux/fast/table/backgr_position-table-column-collapsed-border-expected.png
index 1f9f904a..25e14eb 100644
--- a/third_party/WebKit/LayoutTests/platform/linux/fast/table/backgr_position-table-column-collapsed-border-expected.png
+++ b/third_party/WebKit/LayoutTests/platform/linux/fast/table/backgr_position-table-column-collapsed-border-expected.png
Binary files differ
diff --git a/third_party/WebKit/LayoutTests/platform/linux/fast/table/backgr_position-table-column-expected.png b/third_party/WebKit/LayoutTests/platform/linux/fast/table/backgr_position-table-column-expected.png
index 021acf7c..19426891 100644
--- a/third_party/WebKit/LayoutTests/platform/linux/fast/table/backgr_position-table-column-expected.png
+++ b/third_party/WebKit/LayoutTests/platform/linux/fast/table/backgr_position-table-column-expected.png
Binary files differ
diff --git a/third_party/WebKit/LayoutTests/platform/linux/fast/table/backgr_position-table-column-group-collapsed-border-expected.png b/third_party/WebKit/LayoutTests/platform/linux/fast/table/backgr_position-table-column-group-collapsed-border-expected.png
index 3e97fca8..a27b14f 100644
--- a/third_party/WebKit/LayoutTests/platform/linux/fast/table/backgr_position-table-column-group-collapsed-border-expected.png
+++ b/third_party/WebKit/LayoutTests/platform/linux/fast/table/backgr_position-table-column-group-collapsed-border-expected.png
Binary files differ
diff --git a/third_party/WebKit/LayoutTests/platform/linux/fast/table/backgr_position-table-column-group-expected.png b/third_party/WebKit/LayoutTests/platform/linux/fast/table/backgr_position-table-column-group-expected.png
index dd6bf6fd..8c39206 100644
--- a/third_party/WebKit/LayoutTests/platform/linux/fast/table/backgr_position-table-column-group-expected.png
+++ b/third_party/WebKit/LayoutTests/platform/linux/fast/table/backgr_position-table-column-group-expected.png
Binary files differ
diff --git a/third_party/WebKit/LayoutTests/platform/linux/fast/table/backgr_position-table-expected.png b/third_party/WebKit/LayoutTests/platform/linux/fast/table/backgr_position-table-expected.png
index 31d690b..4008f02 100644
--- a/third_party/WebKit/LayoutTests/platform/linux/fast/table/backgr_position-table-expected.png
+++ b/third_party/WebKit/LayoutTests/platform/linux/fast/table/backgr_position-table-expected.png
Binary files differ
diff --git a/third_party/WebKit/LayoutTests/platform/linux/fast/table/backgr_position-table-row-collapsed-border-expected.png b/third_party/WebKit/LayoutTests/platform/linux/fast/table/backgr_position-table-row-collapsed-border-expected.png
index 50414aa..0e3a429 100644
--- a/third_party/WebKit/LayoutTests/platform/linux/fast/table/backgr_position-table-row-collapsed-border-expected.png
+++ b/third_party/WebKit/LayoutTests/platform/linux/fast/table/backgr_position-table-row-collapsed-border-expected.png
Binary files differ
diff --git a/third_party/WebKit/LayoutTests/platform/linux/fast/table/backgr_position-table-row-expected.png b/third_party/WebKit/LayoutTests/platform/linux/fast/table/backgr_position-table-row-expected.png
index 23aea2f..76b2ce61 100644
--- a/third_party/WebKit/LayoutTests/platform/linux/fast/table/backgr_position-table-row-expected.png
+++ b/third_party/WebKit/LayoutTests/platform/linux/fast/table/backgr_position-table-row-expected.png
Binary files differ
diff --git a/third_party/WebKit/LayoutTests/platform/linux/fast/table/backgr_position-table-row-group-collapsed-border-expected.png b/third_party/WebKit/LayoutTests/platform/linux/fast/table/backgr_position-table-row-group-collapsed-border-expected.png
index 93a4e38..839b902 100644
--- a/third_party/WebKit/LayoutTests/platform/linux/fast/table/backgr_position-table-row-group-collapsed-border-expected.png
+++ b/third_party/WebKit/LayoutTests/platform/linux/fast/table/backgr_position-table-row-group-collapsed-border-expected.png
Binary files differ
diff --git a/third_party/WebKit/LayoutTests/platform/linux/fast/table/backgr_position-table-row-group-expected.png b/third_party/WebKit/LayoutTests/platform/linux/fast/table/backgr_position-table-row-group-expected.png
index 72d561a..61e56fc 100644
--- a/third_party/WebKit/LayoutTests/platform/linux/fast/table/backgr_position-table-row-group-expected.png
+++ b/third_party/WebKit/LayoutTests/platform/linux/fast/table/backgr_position-table-row-group-expected.png
Binary files differ
diff --git a/third_party/WebKit/LayoutTests/platform/linux/fast/table/backgr_simple-table-cell-collapsed-border-expected.png b/third_party/WebKit/LayoutTests/platform/linux/fast/table/backgr_simple-table-cell-collapsed-border-expected.png
index 2546b77..0dedaae 100644
--- a/third_party/WebKit/LayoutTests/platform/linux/fast/table/backgr_simple-table-cell-collapsed-border-expected.png
+++ b/third_party/WebKit/LayoutTests/platform/linux/fast/table/backgr_simple-table-cell-collapsed-border-expected.png
Binary files differ
diff --git a/third_party/WebKit/LayoutTests/platform/linux/fast/table/backgr_simple-table-cell-expected.png b/third_party/WebKit/LayoutTests/platform/linux/fast/table/backgr_simple-table-cell-expected.png
index 15a91c49..4996351 100644
--- a/third_party/WebKit/LayoutTests/platform/linux/fast/table/backgr_simple-table-cell-expected.png
+++ b/third_party/WebKit/LayoutTests/platform/linux/fast/table/backgr_simple-table-cell-expected.png
Binary files differ
diff --git a/third_party/WebKit/LayoutTests/platform/linux/fast/table/backgr_simple-table-collapsed-border-expected.png b/third_party/WebKit/LayoutTests/platform/linux/fast/table/backgr_simple-table-collapsed-border-expected.png
index 95393712..59e0ff4 100644
--- a/third_party/WebKit/LayoutTests/platform/linux/fast/table/backgr_simple-table-collapsed-border-expected.png
+++ b/third_party/WebKit/LayoutTests/platform/linux/fast/table/backgr_simple-table-collapsed-border-expected.png
Binary files differ
diff --git a/third_party/WebKit/LayoutTests/platform/linux/fast/table/backgr_simple-table-column-collapsed-border-expected.png b/third_party/WebKit/LayoutTests/platform/linux/fast/table/backgr_simple-table-column-collapsed-border-expected.png
index e760402..2c9ea75e 100644
--- a/third_party/WebKit/LayoutTests/platform/linux/fast/table/backgr_simple-table-column-collapsed-border-expected.png
+++ b/third_party/WebKit/LayoutTests/platform/linux/fast/table/backgr_simple-table-column-collapsed-border-expected.png
Binary files differ
diff --git a/third_party/WebKit/LayoutTests/platform/linux/fast/table/backgr_simple-table-column-expected.png b/third_party/WebKit/LayoutTests/platform/linux/fast/table/backgr_simple-table-column-expected.png
index 55bb5e3..36d4c0e4 100644
--- a/third_party/WebKit/LayoutTests/platform/linux/fast/table/backgr_simple-table-column-expected.png
+++ b/third_party/WebKit/LayoutTests/platform/linux/fast/table/backgr_simple-table-column-expected.png
Binary files differ
diff --git a/third_party/WebKit/LayoutTests/platform/linux/fast/table/backgr_simple-table-column-group-collapsed-border-expected.png b/third_party/WebKit/LayoutTests/platform/linux/fast/table/backgr_simple-table-column-group-collapsed-border-expected.png
index 12ab046e..eb15b87 100644
--- a/third_party/WebKit/LayoutTests/platform/linux/fast/table/backgr_simple-table-column-group-collapsed-border-expected.png
+++ b/third_party/WebKit/LayoutTests/platform/linux/fast/table/backgr_simple-table-column-group-collapsed-border-expected.png
Binary files differ
diff --git a/third_party/WebKit/LayoutTests/platform/linux/fast/table/backgr_simple-table-column-group-expected.png b/third_party/WebKit/LayoutTests/platform/linux/fast/table/backgr_simple-table-column-group-expected.png
index f79ae8ade..43c8a66 100644
--- a/third_party/WebKit/LayoutTests/platform/linux/fast/table/backgr_simple-table-column-group-expected.png
+++ b/third_party/WebKit/LayoutTests/platform/linux/fast/table/backgr_simple-table-column-group-expected.png
Binary files differ
diff --git a/third_party/WebKit/LayoutTests/platform/linux/fast/table/backgr_simple-table-expected.png b/third_party/WebKit/LayoutTests/platform/linux/fast/table/backgr_simple-table-expected.png
index cd74901..d6976ec 100644
--- a/third_party/WebKit/LayoutTests/platform/linux/fast/table/backgr_simple-table-expected.png
+++ b/third_party/WebKit/LayoutTests/platform/linux/fast/table/backgr_simple-table-expected.png
Binary files differ
diff --git a/third_party/WebKit/LayoutTests/platform/linux/fast/table/backgr_simple-table-row-collapsed-border-expected.png b/third_party/WebKit/LayoutTests/platform/linux/fast/table/backgr_simple-table-row-collapsed-border-expected.png
index b1d2d18..bd65d9e7c 100644
--- a/third_party/WebKit/LayoutTests/platform/linux/fast/table/backgr_simple-table-row-collapsed-border-expected.png
+++ b/third_party/WebKit/LayoutTests/platform/linux/fast/table/backgr_simple-table-row-collapsed-border-expected.png
Binary files differ
diff --git a/third_party/WebKit/LayoutTests/platform/linux/fast/table/backgr_simple-table-row-expected.png b/third_party/WebKit/LayoutTests/platform/linux/fast/table/backgr_simple-table-row-expected.png
index 9911e6b..ba52d1b 100644
--- a/third_party/WebKit/LayoutTests/platform/linux/fast/table/backgr_simple-table-row-expected.png
+++ b/third_party/WebKit/LayoutTests/platform/linux/fast/table/backgr_simple-table-row-expected.png
Binary files differ
diff --git a/third_party/WebKit/LayoutTests/platform/linux/fast/table/backgr_simple-table-row-group-collapsed-border-expected.png b/third_party/WebKit/LayoutTests/platform/linux/fast/table/backgr_simple-table-row-group-collapsed-border-expected.png
index ffdf3a1..a7f6465f 100644
--- a/third_party/WebKit/LayoutTests/platform/linux/fast/table/backgr_simple-table-row-group-collapsed-border-expected.png
+++ b/third_party/WebKit/LayoutTests/platform/linux/fast/table/backgr_simple-table-row-group-collapsed-border-expected.png
Binary files differ
diff --git a/third_party/WebKit/LayoutTests/platform/linux/fast/table/backgr_simple-table-row-group-expected.png b/third_party/WebKit/LayoutTests/platform/linux/fast/table/backgr_simple-table-row-group-expected.png
index 3263ca0d..a4a2b744 100644
--- a/third_party/WebKit/LayoutTests/platform/linux/fast/table/backgr_simple-table-row-group-expected.png
+++ b/third_party/WebKit/LayoutTests/platform/linux/fast/table/backgr_simple-table-row-group-expected.png
Binary files differ
diff --git a/third_party/WebKit/LayoutTests/platform/linux/fast/table/border-collapsing/003-expected.png b/third_party/WebKit/LayoutTests/platform/linux/fast/table/border-collapsing/003-expected.png
index a3217bf..6a82258 100644
--- a/third_party/WebKit/LayoutTests/platform/linux/fast/table/border-collapsing/003-expected.png
+++ b/third_party/WebKit/LayoutTests/platform/linux/fast/table/border-collapsing/003-expected.png
Binary files differ
diff --git a/third_party/WebKit/LayoutTests/platform/linux/fast/table/border-collapsing/003-vertical-expected.png b/third_party/WebKit/LayoutTests/platform/linux/fast/table/border-collapsing/003-vertical-expected.png
index 09f3eac0..09c54a1 100644
--- a/third_party/WebKit/LayoutTests/platform/linux/fast/table/border-collapsing/003-vertical-expected.png
+++ b/third_party/WebKit/LayoutTests/platform/linux/fast/table/border-collapsing/003-vertical-expected.png
Binary files differ
diff --git a/third_party/WebKit/LayoutTests/platform/linux/fast/table/border-collapsing/004-expected.png b/third_party/WebKit/LayoutTests/platform/linux/fast/table/border-collapsing/004-expected.png
index 9a7eb25..61687c48 100644
--- a/third_party/WebKit/LayoutTests/platform/linux/fast/table/border-collapsing/004-expected.png
+++ b/third_party/WebKit/LayoutTests/platform/linux/fast/table/border-collapsing/004-expected.png
Binary files differ
diff --git a/third_party/WebKit/LayoutTests/platform/linux/fast/table/border-collapsing/004-vertical-expected.png b/third_party/WebKit/LayoutTests/platform/linux/fast/table/border-collapsing/004-vertical-expected.png
index 7887ac2a..57bfbad 100644
--- a/third_party/WebKit/LayoutTests/platform/linux/fast/table/border-collapsing/004-vertical-expected.png
+++ b/third_party/WebKit/LayoutTests/platform/linux/fast/table/border-collapsing/004-vertical-expected.png
Binary files differ
diff --git a/third_party/WebKit/LayoutTests/platform/linux/fast/table/border-collapsing/border-collapsing-head-foot-expected.png b/third_party/WebKit/LayoutTests/platform/linux/fast/table/border-collapsing/border-collapsing-head-foot-expected.png
index c3bf1ef..e938da1 100644
--- a/third_party/WebKit/LayoutTests/platform/linux/fast/table/border-collapsing/border-collapsing-head-foot-expected.png
+++ b/third_party/WebKit/LayoutTests/platform/linux/fast/table/border-collapsing/border-collapsing-head-foot-expected.png
Binary files differ
diff --git a/third_party/WebKit/LayoutTests/platform/linux/fast/table/border-collapsing/border-collapsing-head-foot-vertical-expected.png b/third_party/WebKit/LayoutTests/platform/linux/fast/table/border-collapsing/border-collapsing-head-foot-vertical-expected.png
index b90ce0e23d..5dd4791 100644
--- a/third_party/WebKit/LayoutTests/platform/linux/fast/table/border-collapsing/border-collapsing-head-foot-vertical-expected.png
+++ b/third_party/WebKit/LayoutTests/platform/linux/fast/table/border-collapsing/border-collapsing-head-foot-vertical-expected.png
Binary files differ
diff --git a/third_party/WebKit/LayoutTests/platform/linux/fast/table/border-collapsing/rtl-border-collapsing-expected.png b/third_party/WebKit/LayoutTests/platform/linux/fast/table/border-collapsing/rtl-border-collapsing-expected.png
index b4dda72..1543be4c 100644
--- a/third_party/WebKit/LayoutTests/platform/linux/fast/table/border-collapsing/rtl-border-collapsing-expected.png
+++ b/third_party/WebKit/LayoutTests/platform/linux/fast/table/border-collapsing/rtl-border-collapsing-expected.png
Binary files differ
diff --git a/third_party/WebKit/LayoutTests/platform/linux/fast/table/border-collapsing/rtl-border-collapsing-vertical-expected.png b/third_party/WebKit/LayoutTests/platform/linux/fast/table/border-collapsing/rtl-border-collapsing-vertical-expected.png
index e8d31a1b..a545d36 100644
--- a/third_party/WebKit/LayoutTests/platform/linux/fast/table/border-collapsing/rtl-border-collapsing-vertical-expected.png
+++ b/third_party/WebKit/LayoutTests/platform/linux/fast/table/border-collapsing/rtl-border-collapsing-vertical-expected.png
Binary files differ
diff --git a/third_party/WebKit/LayoutTests/platform/linux/fast/table/cell-absolute-child-expected.png b/third_party/WebKit/LayoutTests/platform/linux/fast/table/cell-absolute-child-expected.png
index 39b3d64..56a79b0 100644
--- a/third_party/WebKit/LayoutTests/platform/linux/fast/table/cell-absolute-child-expected.png
+++ b/third_party/WebKit/LayoutTests/platform/linux/fast/table/cell-absolute-child-expected.png
Binary files differ
diff --git a/third_party/WebKit/LayoutTests/platform/linux/fast/table/cell-width-auto-expected.png b/third_party/WebKit/LayoutTests/platform/linux/fast/table/cell-width-auto-expected.png
index 1cf6ce0e..7385c18 100644
--- a/third_party/WebKit/LayoutTests/platform/linux/fast/table/cell-width-auto-expected.png
+++ b/third_party/WebKit/LayoutTests/platform/linux/fast/table/cell-width-auto-expected.png
Binary files differ
diff --git a/third_party/WebKit/LayoutTests/platform/linux/fast/table/click-near-anonymous-table-expected.png b/third_party/WebKit/LayoutTests/platform/linux/fast/table/click-near-anonymous-table-expected.png
index 8aa7ea8..f415106 100644
--- a/third_party/WebKit/LayoutTests/platform/linux/fast/table/click-near-anonymous-table-expected.png
+++ b/third_party/WebKit/LayoutTests/platform/linux/fast/table/click-near-anonymous-table-expected.png
Binary files differ
diff --git a/third_party/WebKit/LayoutTests/platform/linux/fast/table/edge-offsets-expected.png b/third_party/WebKit/LayoutTests/platform/linux/fast/table/edge-offsets-expected.png
index f7ad454..6aaa10c 100644
--- a/third_party/WebKit/LayoutTests/platform/linux/fast/table/edge-offsets-expected.png
+++ b/third_party/WebKit/LayoutTests/platform/linux/fast/table/edge-offsets-expected.png
Binary files differ
diff --git a/third_party/WebKit/LayoutTests/platform/linux/fast/table/frame-and-rules-expected.png b/third_party/WebKit/LayoutTests/platform/linux/fast/table/frame-and-rules-expected.png
index 3c578536..de5f502f 100644
--- a/third_party/WebKit/LayoutTests/platform/linux/fast/table/frame-and-rules-expected.png
+++ b/third_party/WebKit/LayoutTests/platform/linux/fast/table/frame-and-rules-expected.png
Binary files differ
diff --git a/third_party/WebKit/LayoutTests/platform/linux/fast/table/generated-caption-expected.png b/third_party/WebKit/LayoutTests/platform/linux/fast/table/generated-caption-expected.png
index e0a73a7..f9761f1 100644
--- a/third_party/WebKit/LayoutTests/platform/linux/fast/table/generated-caption-expected.png
+++ b/third_party/WebKit/LayoutTests/platform/linux/fast/table/generated-caption-expected.png
Binary files differ
diff --git a/third_party/WebKit/LayoutTests/platform/linux/fast/table/insert-before-anonymous-ancestors-expected.png b/third_party/WebKit/LayoutTests/platform/linux/fast/table/insert-before-anonymous-ancestors-expected.png
index 3922a8f..b98ce40 100644
--- a/third_party/WebKit/LayoutTests/platform/linux/fast/table/insert-before-anonymous-ancestors-expected.png
+++ b/third_party/WebKit/LayoutTests/platform/linux/fast/table/insert-before-anonymous-ancestors-expected.png
Binary files differ
diff --git a/third_party/WebKit/LayoutTests/platform/linux/fast/table/insert-cell-before-form-expected.png b/third_party/WebKit/LayoutTests/platform/linux/fast/table/insert-cell-before-form-expected.png
index 058b2ad..30cd7483 100644
--- a/third_party/WebKit/LayoutTests/platform/linux/fast/table/insert-cell-before-form-expected.png
+++ b/third_party/WebKit/LayoutTests/platform/linux/fast/table/insert-cell-before-form-expected.png
Binary files differ
diff --git a/third_party/WebKit/LayoutTests/platform/linux/fast/table/insert-row-before-form-expected.png b/third_party/WebKit/LayoutTests/platform/linux/fast/table/insert-row-before-form-expected.png
index 058b2ad..30cd7483 100644
--- a/third_party/WebKit/LayoutTests/platform/linux/fast/table/insert-row-before-form-expected.png
+++ b/third_party/WebKit/LayoutTests/platform/linux/fast/table/insert-row-before-form-expected.png
Binary files differ
diff --git a/third_party/WebKit/LayoutTests/platform/linux/fast/table/prepend-in-anonymous-table-expected.png b/third_party/WebKit/LayoutTests/platform/linux/fast/table/prepend-in-anonymous-table-expected.png
index d73fa11..7fd5e6a 100644
--- a/third_party/WebKit/LayoutTests/platform/linux/fast/table/prepend-in-anonymous-table-expected.png
+++ b/third_party/WebKit/LayoutTests/platform/linux/fast/table/prepend-in-anonymous-table-expected.png
Binary files differ
diff --git a/third_party/WebKit/LayoutTests/platform/linux/fast/table/row-height-recalc-expected.png b/third_party/WebKit/LayoutTests/platform/linux/fast/table/row-height-recalc-expected.png
index 58872c0..87b017c 100644
--- a/third_party/WebKit/LayoutTests/platform/linux/fast/table/row-height-recalc-expected.png
+++ b/third_party/WebKit/LayoutTests/platform/linux/fast/table/row-height-recalc-expected.png
Binary files differ
diff --git a/third_party/WebKit/LayoutTests/platform/linux/fast/table/rtl-cell-display-none-assert-expected.png b/third_party/WebKit/LayoutTests/platform/linux/fast/table/rtl-cell-display-none-assert-expected.png
index 6f67262..3b1538f 100644
--- a/third_party/WebKit/LayoutTests/platform/linux/fast/table/rtl-cell-display-none-assert-expected.png
+++ b/third_party/WebKit/LayoutTests/platform/linux/fast/table/rtl-cell-display-none-assert-expected.png
Binary files differ
diff --git a/third_party/WebKit/LayoutTests/platform/linux/fast/table/stale-grid-crash-expected.png b/third_party/WebKit/LayoutTests/platform/linux/fast/table/stale-grid-crash-expected.png
index 5d44e631..8b51f53 100644
--- a/third_party/WebKit/LayoutTests/platform/linux/fast/table/stale-grid-crash-expected.png
+++ b/third_party/WebKit/LayoutTests/platform/linux/fast/table/stale-grid-crash-expected.png
Binary files differ
diff --git a/third_party/WebKit/LayoutTests/platform/linux/fast/table/text-field-baseline-expected.png b/third_party/WebKit/LayoutTests/platform/linux/fast/table/text-field-baseline-expected.png
index 51e89ed4..e372709 100644
--- a/third_party/WebKit/LayoutTests/platform/linux/fast/table/text-field-baseline-expected.png
+++ b/third_party/WebKit/LayoutTests/platform/linux/fast/table/text-field-baseline-expected.png
Binary files differ
diff --git a/third_party/WebKit/LayoutTests/platform/linux/fast/text/atsui-kerning-and-ligatures-expected.png b/third_party/WebKit/LayoutTests/platform/linux/fast/text/atsui-kerning-and-ligatures-expected.png
index 612c87a0..c17e0213 100644
--- a/third_party/WebKit/LayoutTests/platform/linux/fast/text/atsui-kerning-and-ligatures-expected.png
+++ b/third_party/WebKit/LayoutTests/platform/linux/fast/text/atsui-kerning-and-ligatures-expected.png
Binary files differ
diff --git a/third_party/WebKit/LayoutTests/platform/linux/fast/text/atsui-multiple-renderers-expected.png b/third_party/WebKit/LayoutTests/platform/linux/fast/text/atsui-multiple-renderers-expected.png
index e2ec597..d704c66 100644
--- a/third_party/WebKit/LayoutTests/platform/linux/fast/text/atsui-multiple-renderers-expected.png
+++ b/third_party/WebKit/LayoutTests/platform/linux/fast/text/atsui-multiple-renderers-expected.png
Binary files differ
diff --git a/third_party/WebKit/LayoutTests/platform/linux/fast/text/atsui-partial-selection-expected.png b/third_party/WebKit/LayoutTests/platform/linux/fast/text/atsui-partial-selection-expected.png
index 34b440c..2778d44 100644
--- a/third_party/WebKit/LayoutTests/platform/linux/fast/text/atsui-partial-selection-expected.png
+++ b/third_party/WebKit/LayoutTests/platform/linux/fast/text/atsui-partial-selection-expected.png
Binary files differ
diff --git a/third_party/WebKit/LayoutTests/platform/linux/fast/text/atsui-pointtooffset-calls-cg-expected.png b/third_party/WebKit/LayoutTests/platform/linux/fast/text/atsui-pointtooffset-calls-cg-expected.png
index 3e430bd93..e261144 100644
--- a/third_party/WebKit/LayoutTests/platform/linux/fast/text/atsui-pointtooffset-calls-cg-expected.png
+++ b/third_party/WebKit/LayoutTests/platform/linux/fast/text/atsui-pointtooffset-calls-cg-expected.png
Binary files differ
diff --git a/third_party/WebKit/LayoutTests/platform/linux/fast/text/atsui-small-caps-punctuation-size-expected.png b/third_party/WebKit/LayoutTests/platform/linux/fast/text/atsui-small-caps-punctuation-size-expected.png
index 2f0b4c20..579ed92b 100644
--- a/third_party/WebKit/LayoutTests/platform/linux/fast/text/atsui-small-caps-punctuation-size-expected.png
+++ b/third_party/WebKit/LayoutTests/platform/linux/fast/text/atsui-small-caps-punctuation-size-expected.png
Binary files differ
diff --git a/third_party/WebKit/LayoutTests/platform/linux/fast/text/atsui-spacing-features-expected.png b/third_party/WebKit/LayoutTests/platform/linux/fast/text/atsui-spacing-features-expected.png
index d0a2b7a..c8abd099 100644
--- a/third_party/WebKit/LayoutTests/platform/linux/fast/text/atsui-spacing-features-expected.png
+++ b/third_party/WebKit/LayoutTests/platform/linux/fast/text/atsui-spacing-features-expected.png
Binary files differ
diff --git a/third_party/WebKit/LayoutTests/platform/linux/fast/text/basic/013-expected.png b/third_party/WebKit/LayoutTests/platform/linux/fast/text/basic/013-expected.png
index c07d0ce3..90506d8 100644
--- a/third_party/WebKit/LayoutTests/platform/linux/fast/text/basic/013-expected.png
+++ b/third_party/WebKit/LayoutTests/platform/linux/fast/text/basic/013-expected.png
Binary files differ
diff --git a/third_party/WebKit/LayoutTests/platform/linux/fast/text/basic/015-expected.png b/third_party/WebKit/LayoutTests/platform/linux/fast/text/basic/015-expected.png
index d71f879..50a4d1f 100644
--- a/third_party/WebKit/LayoutTests/platform/linux/fast/text/basic/015-expected.png
+++ b/third_party/WebKit/LayoutTests/platform/linux/fast/text/basic/015-expected.png
Binary files differ
diff --git a/third_party/WebKit/LayoutTests/platform/linux/fast/text/bidi-embedding-pop-and-push-same-expected.png b/third_party/WebKit/LayoutTests/platform/linux/fast/text/bidi-embedding-pop-and-push-same-expected.png
index c8bc513..bebb9f8 100644
--- a/third_party/WebKit/LayoutTests/platform/linux/fast/text/bidi-embedding-pop-and-push-same-expected.png
+++ b/third_party/WebKit/LayoutTests/platform/linux/fast/text/bidi-embedding-pop-and-push-same-expected.png
Binary files differ
diff --git a/third_party/WebKit/LayoutTests/platform/linux/fast/text/break-word-expected.png b/third_party/WebKit/LayoutTests/platform/linux/fast/text/break-word-expected.png
index e9e8c93..470ed04d 100644
--- a/third_party/WebKit/LayoutTests/platform/linux/fast/text/break-word-expected.png
+++ b/third_party/WebKit/LayoutTests/platform/linux/fast/text/break-word-expected.png
Binary files differ
diff --git a/third_party/WebKit/LayoutTests/platform/linux/fast/text/capitalize-boundaries-expected.png b/third_party/WebKit/LayoutTests/platform/linux/fast/text/capitalize-boundaries-expected.png
index ab21a4e..3755981 100644
--- a/third_party/WebKit/LayoutTests/platform/linux/fast/text/capitalize-boundaries-expected.png
+++ b/third_party/WebKit/LayoutTests/platform/linux/fast/text/capitalize-boundaries-expected.png
Binary files differ
diff --git a/third_party/WebKit/LayoutTests/platform/linux/fast/text/capitalize-empty-generated-string-expected.png b/third_party/WebKit/LayoutTests/platform/linux/fast/text/capitalize-empty-generated-string-expected.png
index c70af3c..b5b304a 100644
--- a/third_party/WebKit/LayoutTests/platform/linux/fast/text/capitalize-empty-generated-string-expected.png
+++ b/third_party/WebKit/LayoutTests/platform/linux/fast/text/capitalize-empty-generated-string-expected.png
Binary files differ
diff --git a/third_party/WebKit/LayoutTests/platform/linux/fast/text/capitalize-preserve-nbsp-expected.png b/third_party/WebKit/LayoutTests/platform/linux/fast/text/capitalize-preserve-nbsp-expected.png
index 89d1d7f..5e581d6 100644
--- a/third_party/WebKit/LayoutTests/platform/linux/fast/text/capitalize-preserve-nbsp-expected.png
+++ b/third_party/WebKit/LayoutTests/platform/linux/fast/text/capitalize-preserve-nbsp-expected.png
Binary files differ
diff --git a/third_party/WebKit/LayoutTests/platform/linux/fast/text/chromium-linux-fontconfig-renderstyle-expected.png b/third_party/WebKit/LayoutTests/platform/linux/fast/text/chromium-linux-fontconfig-renderstyle-expected.png
index e3bbdd4..e2265c2 100644
--- a/third_party/WebKit/LayoutTests/platform/linux/fast/text/chromium-linux-fontconfig-renderstyle-expected.png
+++ b/third_party/WebKit/LayoutTests/platform/linux/fast/text/chromium-linux-fontconfig-renderstyle-expected.png
Binary files differ
diff --git a/third_party/WebKit/LayoutTests/platform/linux/fast/text/delete-hard-break-character-expected.png b/third_party/WebKit/LayoutTests/platform/linux/fast/text/delete-hard-break-character-expected.png
index 2d6b02cd..6de437f 100644
--- a/third_party/WebKit/LayoutTests/platform/linux/fast/text/delete-hard-break-character-expected.png
+++ b/third_party/WebKit/LayoutTests/platform/linux/fast/text/delete-hard-break-character-expected.png
Binary files differ
diff --git a/third_party/WebKit/LayoutTests/platform/linux/fast/text/emoticons-expected.png b/third_party/WebKit/LayoutTests/platform/linux/fast/text/emoticons-expected.png
index c511a26..210ca3c 100644
--- a/third_party/WebKit/LayoutTests/platform/linux/fast/text/emoticons-expected.png
+++ b/third_party/WebKit/LayoutTests/platform/linux/fast/text/emoticons-expected.png
Binary files differ
diff --git a/third_party/WebKit/LayoutTests/platform/linux/fast/text/fallback-for-custom-font-expected.png b/third_party/WebKit/LayoutTests/platform/linux/fast/text/fallback-for-custom-font-expected.png
index 758b128..8cac4d5a 100644
--- a/third_party/WebKit/LayoutTests/platform/linux/fast/text/fallback-for-custom-font-expected.png
+++ b/third_party/WebKit/LayoutTests/platform/linux/fast/text/fallback-for-custom-font-expected.png
Binary files differ
diff --git a/third_party/WebKit/LayoutTests/platform/linux/fast/text/font-initial-expected.png b/third_party/WebKit/LayoutTests/platform/linux/fast/text/font-initial-expected.png
index ea924a2f..86c82360 100644
--- a/third_party/WebKit/LayoutTests/platform/linux/fast/text/font-initial-expected.png
+++ b/third_party/WebKit/LayoutTests/platform/linux/fast/text/font-initial-expected.png
Binary files differ
diff --git a/third_party/WebKit/LayoutTests/platform/linux/fast/text/font-weight-expected.png b/third_party/WebKit/LayoutTests/platform/linux/fast/text/font-weight-expected.png
index cf54b06..9b8efb9 100644
--- a/third_party/WebKit/LayoutTests/platform/linux/fast/text/font-weight-expected.png
+++ b/third_party/WebKit/LayoutTests/platform/linux/fast/text/font-weight-expected.png
Binary files differ
diff --git a/third_party/WebKit/LayoutTests/platform/linux/fast/text/in-rendered-text-rtl-expected.png b/third_party/WebKit/LayoutTests/platform/linux/fast/text/in-rendered-text-rtl-expected.png
index b2f58b6..8e949370 100644
--- a/third_party/WebKit/LayoutTests/platform/linux/fast/text/in-rendered-text-rtl-expected.png
+++ b/third_party/WebKit/LayoutTests/platform/linux/fast/text/in-rendered-text-rtl-expected.png
Binary files differ
diff --git a/third_party/WebKit/LayoutTests/platform/linux/fast/text/international/bidi-AN-after-empty-run-expected.png b/third_party/WebKit/LayoutTests/platform/linux/fast/text/international/bidi-AN-after-empty-run-expected.png
index 0b5617e..aa6b7a3 100644
--- a/third_party/WebKit/LayoutTests/platform/linux/fast/text/international/bidi-AN-after-empty-run-expected.png
+++ b/third_party/WebKit/LayoutTests/platform/linux/fast/text/international/bidi-AN-after-empty-run-expected.png
Binary files differ
diff --git a/third_party/WebKit/LayoutTests/platform/linux/fast/text/international/bidi-european-terminators-expected.png b/third_party/WebKit/LayoutTests/platform/linux/fast/text/international/bidi-european-terminators-expected.png
index b0ec839..477480a1 100644
--- a/third_party/WebKit/LayoutTests/platform/linux/fast/text/international/bidi-european-terminators-expected.png
+++ b/third_party/WebKit/LayoutTests/platform/linux/fast/text/international/bidi-european-terminators-expected.png
Binary files differ
diff --git a/third_party/WebKit/LayoutTests/platform/linux/fast/text/international/bidi-ignored-for-first-child-inline-expected.png b/third_party/WebKit/LayoutTests/platform/linux/fast/text/international/bidi-ignored-for-first-child-inline-expected.png
index 69f04ea..8293aa0 100644
--- a/third_party/WebKit/LayoutTests/platform/linux/fast/text/international/bidi-ignored-for-first-child-inline-expected.png
+++ b/third_party/WebKit/LayoutTests/platform/linux/fast/text/international/bidi-ignored-for-first-child-inline-expected.png
Binary files differ
diff --git a/third_party/WebKit/LayoutTests/platform/linux/fast/text/international/bidi-layout-across-linebreak-expected.png b/third_party/WebKit/LayoutTests/platform/linux/fast/text/international/bidi-layout-across-linebreak-expected.png
index b8ee7fd..4aa5725a 100644
--- a/third_party/WebKit/LayoutTests/platform/linux/fast/text/international/bidi-layout-across-linebreak-expected.png
+++ b/third_party/WebKit/LayoutTests/platform/linux/fast/text/international/bidi-layout-across-linebreak-expected.png
Binary files differ
diff --git a/third_party/WebKit/LayoutTests/platform/linux/fast/text/international/bold-bengali-expected.png b/third_party/WebKit/LayoutTests/platform/linux/fast/text/international/bold-bengali-expected.png
index 24dbc45..15a7155 100644
--- a/third_party/WebKit/LayoutTests/platform/linux/fast/text/international/bold-bengali-expected.png
+++ b/third_party/WebKit/LayoutTests/platform/linux/fast/text/international/bold-bengali-expected.png
Binary files differ
diff --git a/third_party/WebKit/LayoutTests/platform/linux/fast/text/international/khmer-selection-expected.png b/third_party/WebKit/LayoutTests/platform/linux/fast/text/international/khmer-selection-expected.png
index 25767c8..0cc8d7a 100644
--- a/third_party/WebKit/LayoutTests/platform/linux/fast/text/international/khmer-selection-expected.png
+++ b/third_party/WebKit/LayoutTests/platform/linux/fast/text/international/khmer-selection-expected.png
Binary files differ
diff --git a/third_party/WebKit/LayoutTests/platform/linux/fast/text/international/plane2-expected.png b/third_party/WebKit/LayoutTests/platform/linux/fast/text/international/plane2-expected.png
index 2ae96613..a42fa58 100644
--- a/third_party/WebKit/LayoutTests/platform/linux/fast/text/international/plane2-expected.png
+++ b/third_party/WebKit/LayoutTests/platform/linux/fast/text/international/plane2-expected.png
Binary files differ
diff --git a/third_party/WebKit/LayoutTests/platform/linux/fast/text/international/rtl-caret-expected.png b/third_party/WebKit/LayoutTests/platform/linux/fast/text/international/rtl-caret-expected.png
index 6c472b5..b2887783 100644
--- a/third_party/WebKit/LayoutTests/platform/linux/fast/text/international/rtl-caret-expected.png
+++ b/third_party/WebKit/LayoutTests/platform/linux/fast/text/international/rtl-caret-expected.png
Binary files differ
diff --git a/third_party/WebKit/LayoutTests/platform/linux/fast/text/international/rtl-white-space-pre-wrap-expected.png b/third_party/WebKit/LayoutTests/platform/linux/fast/text/international/rtl-white-space-pre-wrap-expected.png
index 780c2ea..2db6d321 100644
--- a/third_party/WebKit/LayoutTests/platform/linux/fast/text/international/rtl-white-space-pre-wrap-expected.png
+++ b/third_party/WebKit/LayoutTests/platform/linux/fast/text/international/rtl-white-space-pre-wrap-expected.png
Binary files differ
diff --git a/third_party/WebKit/LayoutTests/platform/linux/fast/text/line-initial-and-final-swashes-expected.png b/third_party/WebKit/LayoutTests/platform/linux/fast/text/line-initial-and-final-swashes-expected.png
index 6879d8d..dcf81ab 100644
--- a/third_party/WebKit/LayoutTests/platform/linux/fast/text/line-initial-and-final-swashes-expected.png
+++ b/third_party/WebKit/LayoutTests/platform/linux/fast/text/line-initial-and-final-swashes-expected.png
Binary files differ
diff --git a/third_party/WebKit/LayoutTests/platform/linux/fast/text/midword-break-after-breakable-char-expected.png b/third_party/WebKit/LayoutTests/platform/linux/fast/text/midword-break-after-breakable-char-expected.png
index afc01e3..cdbdcf6 100644
--- a/third_party/WebKit/LayoutTests/platform/linux/fast/text/midword-break-after-breakable-char-expected.png
+++ b/third_party/WebKit/LayoutTests/platform/linux/fast/text/midword-break-after-breakable-char-expected.png
Binary files differ
diff --git a/third_party/WebKit/LayoutTests/platform/linux/fast/text/midword-break-hang-expected.png b/third_party/WebKit/LayoutTests/platform/linux/fast/text/midword-break-hang-expected.png
index 6e59bd5..c13e748 100644
--- a/third_party/WebKit/LayoutTests/platform/linux/fast/text/midword-break-hang-expected.png
+++ b/third_party/WebKit/LayoutTests/platform/linux/fast/text/midword-break-hang-expected.png
Binary files differ
diff --git a/third_party/WebKit/LayoutTests/platform/linux/fast/text/monospace-width-cache-expected.png b/third_party/WebKit/LayoutTests/platform/linux/fast/text/monospace-width-cache-expected.png
index dfd6815..0056c924 100644
--- a/third_party/WebKit/LayoutTests/platform/linux/fast/text/monospace-width-cache-expected.png
+++ b/third_party/WebKit/LayoutTests/platform/linux/fast/text/monospace-width-cache-expected.png
Binary files differ
diff --git a/third_party/WebKit/LayoutTests/platform/linux/fast/text/reset-emptyRun-expected.png b/third_party/WebKit/LayoutTests/platform/linux/fast/text/reset-emptyRun-expected.png
index 00adaaa8..db7573d 100644
--- a/third_party/WebKit/LayoutTests/platform/linux/fast/text/reset-emptyRun-expected.png
+++ b/third_party/WebKit/LayoutTests/platform/linux/fast/text/reset-emptyRun-expected.png
Binary files differ
diff --git a/third_party/WebKit/LayoutTests/platform/linux/fast/text/selection-hard-linebreak-expected.png b/third_party/WebKit/LayoutTests/platform/linux/fast/text/selection-hard-linebreak-expected.png
index 8a504ab..08d494e 100644
--- a/third_party/WebKit/LayoutTests/platform/linux/fast/text/selection-hard-linebreak-expected.png
+++ b/third_party/WebKit/LayoutTests/platform/linux/fast/text/selection-hard-linebreak-expected.png
Binary files differ
diff --git a/third_party/WebKit/LayoutTests/platform/linux/fast/text/should-use-atsui-expected.png b/third_party/WebKit/LayoutTests/platform/linux/fast/text/should-use-atsui-expected.png
index 4f54abb..5f39750 100644
--- a/third_party/WebKit/LayoutTests/platform/linux/fast/text/should-use-atsui-expected.png
+++ b/third_party/WebKit/LayoutTests/platform/linux/fast/text/should-use-atsui-expected.png
Binary files differ
diff --git a/third_party/WebKit/LayoutTests/platform/linux/fast/text/sub-pixel/text-scaling-ltr-expected.txt b/third_party/WebKit/LayoutTests/platform/linux/fast/text/sub-pixel/text-scaling-ltr-expected.txt
index baad1c26..1a6af3ad 100644
--- a/third_party/WebKit/LayoutTests/platform/linux/fast/text/sub-pixel/text-scaling-ltr-expected.txt
+++ b/third_party/WebKit/LayoutTests/platform/linux/fast/text/sub-pixel/text-scaling-ltr-expected.txt
@@ -5,3 +5,4 @@
 Font Size Scaling (LTR, Latin)
 Size of the text should scale smoothly. Reported width should be within 0.02px of that of the highlighted reference row.
 
+
diff --git a/third_party/WebKit/LayoutTests/platform/linux/fast/text/sub-pixel/text-scaling-rtl-expected.txt b/third_party/WebKit/LayoutTests/platform/linux/fast/text/sub-pixel/text-scaling-rtl-expected.txt
index 906d1ed..616e423 100644
--- a/third_party/WebKit/LayoutTests/platform/linux/fast/text/sub-pixel/text-scaling-rtl-expected.txt
+++ b/third_party/WebKit/LayoutTests/platform/linux/fast/text/sub-pixel/text-scaling-rtl-expected.txt
@@ -5,3 +5,4 @@
 Font Size Scaling (RTL, Arabic)
 Size of the text should scale smoothly. Reported width should be within 0.02px of that of the highlighted reference row.
 
+
diff --git a/third_party/WebKit/LayoutTests/platform/linux/fast/text/sub-pixel/text-scaling-vertical-expected.txt b/third_party/WebKit/LayoutTests/platform/linux/fast/text/sub-pixel/text-scaling-vertical-expected.txt
index f3dc2272..908d157 100644
--- a/third_party/WebKit/LayoutTests/platform/linux/fast/text/sub-pixel/text-scaling-vertical-expected.txt
+++ b/third_party/WebKit/LayoutTests/platform/linux/fast/text/sub-pixel/text-scaling-vertical-expected.txt
@@ -5,3 +5,4 @@
 Font Size Scaling (vertical-rl, Latin)
 Size of the text should scale smoothly. Reported height (logical width) should be within 0.02px of that of the highlighted reference row.
 
+
diff --git a/third_party/WebKit/LayoutTests/platform/linux/fast/text/sub-pixel/text-scaling-webfont-expected.txt b/third_party/WebKit/LayoutTests/platform/linux/fast/text/sub-pixel/text-scaling-webfont-expected.txt
index 24a8cf4..ee9e37c5 100644
--- a/third_party/WebKit/LayoutTests/platform/linux/fast/text/sub-pixel/text-scaling-webfont-expected.txt
+++ b/third_party/WebKit/LayoutTests/platform/linux/fast/text/sub-pixel/text-scaling-webfont-expected.txt
@@ -5,3 +5,4 @@
 Font Size Scaling (WebFont, Latin)
 Size of the text should scale smoothly. Reported width should be within 0.02px of that of the highlighted reference row.
 
+
diff --git a/third_party/WebKit/LayoutTests/platform/linux/fast/text/unicode-fallback-font-expected.png b/third_party/WebKit/LayoutTests/platform/linux/fast/text/unicode-fallback-font-expected.png
index cf634e6f..15c47778 100644
--- a/third_party/WebKit/LayoutTests/platform/linux/fast/text/unicode-fallback-font-expected.png
+++ b/third_party/WebKit/LayoutTests/platform/linux/fast/text/unicode-fallback-font-expected.png
Binary files differ
diff --git a/third_party/WebKit/LayoutTests/platform/linux/fast/text/wbr-expected.png b/third_party/WebKit/LayoutTests/platform/linux/fast/text/wbr-expected.png
index e4213c1..a2f323f 100644
--- a/third_party/WebKit/LayoutTests/platform/linux/fast/text/wbr-expected.png
+++ b/third_party/WebKit/LayoutTests/platform/linux/fast/text/wbr-expected.png
Binary files differ
diff --git a/third_party/WebKit/LayoutTests/platform/linux/fast/text/wbr-in-pre-crash-expected.png b/third_party/WebKit/LayoutTests/platform/linux/fast/text/wbr-in-pre-crash-expected.png
index b3ba464..ed7eac7 100644
--- a/third_party/WebKit/LayoutTests/platform/linux/fast/text/wbr-in-pre-crash-expected.png
+++ b/third_party/WebKit/LayoutTests/platform/linux/fast/text/wbr-in-pre-crash-expected.png
Binary files differ
diff --git a/third_party/WebKit/LayoutTests/platform/linux/fast/text/wbr-pre-expected.png b/third_party/WebKit/LayoutTests/platform/linux/fast/text/wbr-pre-expected.png
index 741a34f2..e16d2a11 100644
--- a/third_party/WebKit/LayoutTests/platform/linux/fast/text/wbr-pre-expected.png
+++ b/third_party/WebKit/LayoutTests/platform/linux/fast/text/wbr-pre-expected.png
Binary files differ
diff --git a/third_party/WebKit/LayoutTests/platform/linux/fast/text/whitespace/022-expected.png b/third_party/WebKit/LayoutTests/platform/linux/fast/text/whitespace/022-expected.png
index bea8a90b6..6427f81 100644
--- a/third_party/WebKit/LayoutTests/platform/linux/fast/text/whitespace/022-expected.png
+++ b/third_party/WebKit/LayoutTests/platform/linux/fast/text/whitespace/022-expected.png
Binary files differ
diff --git a/third_party/WebKit/LayoutTests/platform/linux/fast/text/whitespace/024-expected.png b/third_party/WebKit/LayoutTests/platform/linux/fast/text/whitespace/024-expected.png
index 3a10cf3..b9f61c4 100644
--- a/third_party/WebKit/LayoutTests/platform/linux/fast/text/whitespace/024-expected.png
+++ b/third_party/WebKit/LayoutTests/platform/linux/fast/text/whitespace/024-expected.png
Binary files differ
diff --git a/third_party/WebKit/LayoutTests/platform/linux/fast/text/whitespace/pre-newline-box-test-expected.png b/third_party/WebKit/LayoutTests/platform/linux/fast/text/whitespace/pre-newline-box-test-expected.png
index 91eee1f..70ea8be 100644
--- a/third_party/WebKit/LayoutTests/platform/linux/fast/text/whitespace/pre-newline-box-test-expected.png
+++ b/third_party/WebKit/LayoutTests/platform/linux/fast/text/whitespace/pre-newline-box-test-expected.png
Binary files differ
diff --git a/third_party/WebKit/LayoutTests/platform/linux/fast/text/whitespace/pre-wrap-last-char-expected.png b/third_party/WebKit/LayoutTests/platform/linux/fast/text/whitespace/pre-wrap-last-char-expected.png
index a7f77a015..037acf3f 100644
--- a/third_party/WebKit/LayoutTests/platform/linux/fast/text/whitespace/pre-wrap-last-char-expected.png
+++ b/third_party/WebKit/LayoutTests/platform/linux/fast/text/whitespace/pre-wrap-last-char-expected.png
Binary files differ
diff --git a/third_party/WebKit/LayoutTests/platform/linux/fast/text/whitespace/pre-wrap-overflow-selection-expected.png b/third_party/WebKit/LayoutTests/platform/linux/fast/text/whitespace/pre-wrap-overflow-selection-expected.png
index 57de940..69836ae7 100644
--- a/third_party/WebKit/LayoutTests/platform/linux/fast/text/whitespace/pre-wrap-overflow-selection-expected.png
+++ b/third_party/WebKit/LayoutTests/platform/linux/fast/text/whitespace/pre-wrap-overflow-selection-expected.png
Binary files differ
diff --git a/third_party/WebKit/LayoutTests/platform/linux/fast/text/whitespace/pre-wrap-spaces-after-newline-expected.png b/third_party/WebKit/LayoutTests/platform/linux/fast/text/whitespace/pre-wrap-spaces-after-newline-expected.png
index 29280b3..6145d3d 100644
--- a/third_party/WebKit/LayoutTests/platform/linux/fast/text/whitespace/pre-wrap-spaces-after-newline-expected.png
+++ b/third_party/WebKit/LayoutTests/platform/linux/fast/text/whitespace/pre-wrap-spaces-after-newline-expected.png
Binary files differ
diff --git a/third_party/WebKit/LayoutTests/platform/linux/fast/text/word-break-run-rounding-expected.png b/third_party/WebKit/LayoutTests/platform/linux/fast/text/word-break-run-rounding-expected.png
index 9917060..b072d7b 100644
--- a/third_party/WebKit/LayoutTests/platform/linux/fast/text/word-break-run-rounding-expected.png
+++ b/third_party/WebKit/LayoutTests/platform/linux/fast/text/word-break-run-rounding-expected.png
Binary files differ
diff --git a/third_party/WebKit/LayoutTests/platform/linux/fast/text/word-break-soft-hyphen-expected.png b/third_party/WebKit/LayoutTests/platform/linux/fast/text/word-break-soft-hyphen-expected.png
index 514866619..e1f45d1 100644
--- a/third_party/WebKit/LayoutTests/platform/linux/fast/text/word-break-soft-hyphen-expected.png
+++ b/third_party/WebKit/LayoutTests/platform/linux/fast/text/word-break-soft-hyphen-expected.png
Binary files differ
diff --git a/third_party/WebKit/LayoutTests/platform/linux/fast/text/word-space-expected.png b/third_party/WebKit/LayoutTests/platform/linux/fast/text/word-space-expected.png
index 5461356..3011b7f 100644
--- a/third_party/WebKit/LayoutTests/platform/linux/fast/text/word-space-expected.png
+++ b/third_party/WebKit/LayoutTests/platform/linux/fast/text/word-space-expected.png
Binary files differ
diff --git a/third_party/WebKit/LayoutTests/platform/linux/fast/xsl/xslt-import-depth-expected.png b/third_party/WebKit/LayoutTests/platform/linux/fast/xsl/xslt-import-depth-expected.png
index ba72c62..5f597af 100644
--- a/third_party/WebKit/LayoutTests/platform/linux/fast/xsl/xslt-import-depth-expected.png
+++ b/third_party/WebKit/LayoutTests/platform/linux/fast/xsl/xslt-import-depth-expected.png
Binary files differ
diff --git a/third_party/WebKit/LayoutTests/platform/linux/fonts/cursive-expected.png b/third_party/WebKit/LayoutTests/platform/linux/fonts/cursive-expected.png
index 75711326..3ba397ae 100644
--- a/third_party/WebKit/LayoutTests/platform/linux/fonts/cursive-expected.png
+++ b/third_party/WebKit/LayoutTests/platform/linux/fonts/cursive-expected.png
Binary files differ
diff --git a/third_party/WebKit/LayoutTests/platform/linux/fonts/monospace-expected.png b/third_party/WebKit/LayoutTests/platform/linux/fonts/monospace-expected.png
index 0f39344..b4d196f 100644
--- a/third_party/WebKit/LayoutTests/platform/linux/fonts/monospace-expected.png
+++ b/third_party/WebKit/LayoutTests/platform/linux/fonts/monospace-expected.png
Binary files differ
diff --git a/third_party/WebKit/LayoutTests/platform/linux/fonts/sans-serif-expected.png b/third_party/WebKit/LayoutTests/platform/linux/fonts/sans-serif-expected.png
index 6a3e82e..86c45b6 100644
--- a/third_party/WebKit/LayoutTests/platform/linux/fonts/sans-serif-expected.png
+++ b/third_party/WebKit/LayoutTests/platform/linux/fonts/sans-serif-expected.png
Binary files differ
diff --git a/third_party/WebKit/LayoutTests/platform/linux/fonts/serif-expected.png b/third_party/WebKit/LayoutTests/platform/linux/fonts/serif-expected.png
index 55eb1cc33..eee6e06 100644
--- a/third_party/WebKit/LayoutTests/platform/linux/fonts/serif-expected.png
+++ b/third_party/WebKit/LayoutTests/platform/linux/fonts/serif-expected.png
Binary files differ
diff --git a/third_party/WebKit/LayoutTests/platform/linux/images/color-profile-munsell-adobe-to-srgb-expected.png b/third_party/WebKit/LayoutTests/platform/linux/images/color-profile-munsell-adobe-to-srgb-expected.png
index 2adc82b..2c83c28 100644
--- a/third_party/WebKit/LayoutTests/platform/linux/images/color-profile-munsell-adobe-to-srgb-expected.png
+++ b/third_party/WebKit/LayoutTests/platform/linux/images/color-profile-munsell-adobe-to-srgb-expected.png
Binary files differ
diff --git a/third_party/WebKit/LayoutTests/platform/linux/images/color-profile-munsell-srgb-to-srgb-expected.png b/third_party/WebKit/LayoutTests/platform/linux/images/color-profile-munsell-srgb-to-srgb-expected.png
index fbfa0ed..c350aa1 100644
--- a/third_party/WebKit/LayoutTests/platform/linux/images/color-profile-munsell-srgb-to-srgb-expected.png
+++ b/third_party/WebKit/LayoutTests/platform/linux/images/color-profile-munsell-srgb-to-srgb-expected.png
Binary files differ
diff --git a/third_party/WebKit/LayoutTests/platform/linux/images/imagemap-circle-focus-ring-expected.png b/third_party/WebKit/LayoutTests/platform/linux/images/imagemap-circle-focus-ring-expected.png
index bd740ba..c29f4840 100644
--- a/third_party/WebKit/LayoutTests/platform/linux/images/imagemap-circle-focus-ring-expected.png
+++ b/third_party/WebKit/LayoutTests/platform/linux/images/imagemap-circle-focus-ring-expected.png
Binary files differ
diff --git a/third_party/WebKit/LayoutTests/platform/linux/images/imagemap-focus-ring-expected.png b/third_party/WebKit/LayoutTests/platform/linux/images/imagemap-focus-ring-expected.png
index 79a01f5..5566c81 100644
--- a/third_party/WebKit/LayoutTests/platform/linux/images/imagemap-focus-ring-expected.png
+++ b/third_party/WebKit/LayoutTests/platform/linux/images/imagemap-focus-ring-expected.png
Binary files differ
diff --git a/third_party/WebKit/LayoutTests/platform/linux/images/imagemap-focus-ring-outline-color-expected.png b/third_party/WebKit/LayoutTests/platform/linux/images/imagemap-focus-ring-outline-color-expected.png
index b709fa1..53d72ba 100644
--- a/third_party/WebKit/LayoutTests/platform/linux/images/imagemap-focus-ring-outline-color-expected.png
+++ b/third_party/WebKit/LayoutTests/platform/linux/images/imagemap-focus-ring-outline-color-expected.png
Binary files differ
diff --git a/third_party/WebKit/LayoutTests/platform/linux/images/imagemap-focus-ring-outline-color-explicitly-inherited-from-map-expected.png b/third_party/WebKit/LayoutTests/platform/linux/images/imagemap-focus-ring-outline-color-explicitly-inherited-from-map-expected.png
index 4757544..46c2da4 100644
--- a/third_party/WebKit/LayoutTests/platform/linux/images/imagemap-focus-ring-outline-color-explicitly-inherited-from-map-expected.png
+++ b/third_party/WebKit/LayoutTests/platform/linux/images/imagemap-focus-ring-outline-color-explicitly-inherited-from-map-expected.png
Binary files differ
diff --git a/third_party/WebKit/LayoutTests/platform/linux/images/imagemap-focus-ring-outline-color-not-inherited-from-map-expected.png b/third_party/WebKit/LayoutTests/platform/linux/images/imagemap-focus-ring-outline-color-not-inherited-from-map-expected.png
index 8038086..5b7eedd 100644
--- a/third_party/WebKit/LayoutTests/platform/linux/images/imagemap-focus-ring-outline-color-not-inherited-from-map-expected.png
+++ b/third_party/WebKit/LayoutTests/platform/linux/images/imagemap-focus-ring-outline-color-not-inherited-from-map-expected.png
Binary files differ
diff --git a/third_party/WebKit/LayoutTests/platform/linux/images/imagemap-focus-ring-zero-outline-width-expected.png b/third_party/WebKit/LayoutTests/platform/linux/images/imagemap-focus-ring-zero-outline-width-expected.png
index 4f1129f..66b3986f15 100644
--- a/third_party/WebKit/LayoutTests/platform/linux/images/imagemap-focus-ring-zero-outline-width-expected.png
+++ b/third_party/WebKit/LayoutTests/platform/linux/images/imagemap-focus-ring-zero-outline-width-expected.png
Binary files differ
diff --git a/third_party/WebKit/LayoutTests/platform/linux/images/imagemap-focus-ring-zoom-expected.png b/third_party/WebKit/LayoutTests/platform/linux/images/imagemap-focus-ring-zoom-expected.png
index a0155f8..05e07b639 100644
--- a/third_party/WebKit/LayoutTests/platform/linux/images/imagemap-focus-ring-zoom-expected.png
+++ b/third_party/WebKit/LayoutTests/platform/linux/images/imagemap-focus-ring-zoom-expected.png
Binary files differ
diff --git a/third_party/WebKit/LayoutTests/platform/linux/images/imagemap-overflowing-circle-focus-ring-expected.png b/third_party/WebKit/LayoutTests/platform/linux/images/imagemap-overflowing-circle-focus-ring-expected.png
index 5eec0ae..2e10caa 100644
--- a/third_party/WebKit/LayoutTests/platform/linux/images/imagemap-overflowing-circle-focus-ring-expected.png
+++ b/third_party/WebKit/LayoutTests/platform/linux/images/imagemap-overflowing-circle-focus-ring-expected.png
Binary files differ
diff --git a/third_party/WebKit/LayoutTests/platform/linux/images/imagemap-overflowing-polygon-focus-ring-expected.png b/third_party/WebKit/LayoutTests/platform/linux/images/imagemap-overflowing-polygon-focus-ring-expected.png
index dba8d70c..34590f0 100644
--- a/third_party/WebKit/LayoutTests/platform/linux/images/imagemap-overflowing-polygon-focus-ring-expected.png
+++ b/third_party/WebKit/LayoutTests/platform/linux/images/imagemap-overflowing-polygon-focus-ring-expected.png
Binary files differ
diff --git a/third_party/WebKit/LayoutTests/platform/linux/images/imagemap-polygon-focus-ring-expected.png b/third_party/WebKit/LayoutTests/platform/linux/images/imagemap-polygon-focus-ring-expected.png
index 6e7a75c..62d7b48 100644
--- a/third_party/WebKit/LayoutTests/platform/linux/images/imagemap-polygon-focus-ring-expected.png
+++ b/third_party/WebKit/LayoutTests/platform/linux/images/imagemap-polygon-focus-ring-expected.png
Binary files differ
diff --git a/third_party/WebKit/LayoutTests/platform/linux/media/color-profile-munsell-bt601-smpte-to-srgb-expected.png b/third_party/WebKit/LayoutTests/platform/linux/media/color-profile-munsell-bt601-smpte-to-srgb-expected.png
index 8bb5a6a..9fbe51d 100644
--- a/third_party/WebKit/LayoutTests/platform/linux/media/color-profile-munsell-bt601-smpte-to-srgb-expected.png
+++ b/third_party/WebKit/LayoutTests/platform/linux/media/color-profile-munsell-bt601-smpte-to-srgb-expected.png
Binary files differ
diff --git a/third_party/WebKit/LayoutTests/platform/linux/media/color-profile-munsell-bt709-to-srgb-expected.png b/third_party/WebKit/LayoutTests/platform/linux/media/color-profile-munsell-bt709-to-srgb-expected.png
index 4de5fce..82dfcfb 100644
--- a/third_party/WebKit/LayoutTests/platform/linux/media/color-profile-munsell-bt709-to-srgb-expected.png
+++ b/third_party/WebKit/LayoutTests/platform/linux/media/color-profile-munsell-bt709-to-srgb-expected.png
Binary files differ
diff --git a/third_party/WebKit/LayoutTests/platform/linux/paint/invalidation/fixed-expected.png b/third_party/WebKit/LayoutTests/platform/linux/paint/invalidation/fixed-expected.png
index dd57984..4d56dffd 100644
--- a/third_party/WebKit/LayoutTests/platform/linux/paint/invalidation/fixed-expected.png
+++ b/third_party/WebKit/LayoutTests/platform/linux/paint/invalidation/fixed-expected.png
Binary files differ
diff --git a/third_party/WebKit/LayoutTests/platform/linux/paint/invalidation/flexible-box-overflow-expected.png b/third_party/WebKit/LayoutTests/platform/linux/paint/invalidation/flexible-box-overflow-expected.png
index 833b4ec8..4cb9000b 100644
--- a/third_party/WebKit/LayoutTests/platform/linux/paint/invalidation/flexible-box-overflow-expected.png
+++ b/third_party/WebKit/LayoutTests/platform/linux/paint/invalidation/flexible-box-overflow-expected.png
Binary files differ
diff --git a/third_party/WebKit/LayoutTests/platform/linux/paint/invalidation/flexible-box-overflow-horizontal-expected.png b/third_party/WebKit/LayoutTests/platform/linux/paint/invalidation/flexible-box-overflow-horizontal-expected.png
index 833b4ec8..4cb9000b 100644
--- a/third_party/WebKit/LayoutTests/platform/linux/paint/invalidation/flexible-box-overflow-horizontal-expected.png
+++ b/third_party/WebKit/LayoutTests/platform/linux/paint/invalidation/flexible-box-overflow-horizontal-expected.png
Binary files differ
diff --git a/third_party/WebKit/LayoutTests/platform/linux/paint/invalidation/layer-outline-expected.png b/third_party/WebKit/LayoutTests/platform/linux/paint/invalidation/layer-outline-expected.png
index 58483bb..fa7b29b 100644
--- a/third_party/WebKit/LayoutTests/platform/linux/paint/invalidation/layer-outline-expected.png
+++ b/third_party/WebKit/LayoutTests/platform/linux/paint/invalidation/layer-outline-expected.png
Binary files differ
diff --git a/third_party/WebKit/LayoutTests/platform/linux/paint/invalidation/layer-outline-horizontal-expected.png b/third_party/WebKit/LayoutTests/platform/linux/paint/invalidation/layer-outline-horizontal-expected.png
index 58483bb..fa7b29b 100644
--- a/third_party/WebKit/LayoutTests/platform/linux/paint/invalidation/layer-outline-horizontal-expected.png
+++ b/third_party/WebKit/LayoutTests/platform/linux/paint/invalidation/layer-outline-horizontal-expected.png
Binary files differ
diff --git a/third_party/WebKit/LayoutTests/platform/linux/paint/invalidation/list-marker-expected.png b/third_party/WebKit/LayoutTests/platform/linux/paint/invalidation/list-marker-expected.png
index 7745e41..73fa4b9 100644
--- a/third_party/WebKit/LayoutTests/platform/linux/paint/invalidation/list-marker-expected.png
+++ b/third_party/WebKit/LayoutTests/platform/linux/paint/invalidation/list-marker-expected.png
Binary files differ
diff --git a/third_party/WebKit/LayoutTests/platform/linux/paint/invalidation/overflow-scroll-delete-expected.png b/third_party/WebKit/LayoutTests/platform/linux/paint/invalidation/overflow-scroll-delete-expected.png
index 072f741..03ea26a 100644
--- a/third_party/WebKit/LayoutTests/platform/linux/paint/invalidation/overflow-scroll-delete-expected.png
+++ b/third_party/WebKit/LayoutTests/platform/linux/paint/invalidation/overflow-scroll-delete-expected.png
Binary files differ
diff --git a/third_party/WebKit/LayoutTests/platform/linux/paint/invalidation/selected-replaced-expected.png b/third_party/WebKit/LayoutTests/platform/linux/paint/invalidation/selected-replaced-expected.png
index 08c4eb0..838cbb63 100644
--- a/third_party/WebKit/LayoutTests/platform/linux/paint/invalidation/selected-replaced-expected.png
+++ b/third_party/WebKit/LayoutTests/platform/linux/paint/invalidation/selected-replaced-expected.png
Binary files differ
diff --git a/third_party/WebKit/LayoutTests/platform/linux/paint/invalidation/svg/embedded-svg-size-changes-expected.png b/third_party/WebKit/LayoutTests/platform/linux/paint/invalidation/svg/embedded-svg-size-changes-expected.png
index a366e42..282d12886 100644
--- a/third_party/WebKit/LayoutTests/platform/linux/paint/invalidation/svg/embedded-svg-size-changes-expected.png
+++ b/third_party/WebKit/LayoutTests/platform/linux/paint/invalidation/svg/embedded-svg-size-changes-expected.png
Binary files differ
diff --git a/third_party/WebKit/LayoutTests/platform/linux/paint/invalidation/svg/foreignObject-crash-on-hover-expected.png b/third_party/WebKit/LayoutTests/platform/linux/paint/invalidation/svg/foreignObject-crash-on-hover-expected.png
index 3955477..c26ba8a5 100644
--- a/third_party/WebKit/LayoutTests/platform/linux/paint/invalidation/svg/foreignObject-crash-on-hover-expected.png
+++ b/third_party/WebKit/LayoutTests/platform/linux/paint/invalidation/svg/foreignObject-crash-on-hover-expected.png
Binary files differ
diff --git a/third_party/WebKit/LayoutTests/platform/linux/paint/invalidation/svg/nested-embedded-svg-size-changes-expected.png b/third_party/WebKit/LayoutTests/platform/linux/paint/invalidation/svg/nested-embedded-svg-size-changes-expected.png
index 0dc9b81..4e4031c 100644
--- a/third_party/WebKit/LayoutTests/platform/linux/paint/invalidation/svg/nested-embedded-svg-size-changes-expected.png
+++ b/third_party/WebKit/LayoutTests/platform/linux/paint/invalidation/svg/nested-embedded-svg-size-changes-expected.png
Binary files differ
diff --git a/third_party/WebKit/LayoutTests/platform/linux/paint/invalidation/text-shadow-expected.png b/third_party/WebKit/LayoutTests/platform/linux/paint/invalidation/text-shadow-expected.png
index b1c100c..870b592 100644
--- a/third_party/WebKit/LayoutTests/platform/linux/paint/invalidation/text-shadow-expected.png
+++ b/third_party/WebKit/LayoutTests/platform/linux/paint/invalidation/text-shadow-expected.png
Binary files differ
diff --git a/third_party/WebKit/LayoutTests/platform/linux/paint/invalidation/text-shadow-horizontal-expected.png b/third_party/WebKit/LayoutTests/platform/linux/paint/invalidation/text-shadow-horizontal-expected.png
index b1c100c..870b592 100644
--- a/third_party/WebKit/LayoutTests/platform/linux/paint/invalidation/text-shadow-horizontal-expected.png
+++ b/third_party/WebKit/LayoutTests/platform/linux/paint/invalidation/text-shadow-horizontal-expected.png
Binary files differ
diff --git a/third_party/WebKit/LayoutTests/platform/linux/paint/roundedrects/circle-with-shadow-expected.png b/third_party/WebKit/LayoutTests/platform/linux/paint/roundedrects/circle-with-shadow-expected.png
index 93dff3e..1a74304 100644
--- a/third_party/WebKit/LayoutTests/platform/linux/paint/roundedrects/circle-with-shadow-expected.png
+++ b/third_party/WebKit/LayoutTests/platform/linux/paint/roundedrects/circle-with-shadow-expected.png
Binary files differ
diff --git a/third_party/WebKit/LayoutTests/platform/linux/svg/W3C-SVG-1.1/animate-elem-36-t-expected.png b/third_party/WebKit/LayoutTests/platform/linux/svg/W3C-SVG-1.1/animate-elem-36-t-expected.png
index 17bf1ce6..96c8efe 100644
--- a/third_party/WebKit/LayoutTests/platform/linux/svg/W3C-SVG-1.1/animate-elem-36-t-expected.png
+++ b/third_party/WebKit/LayoutTests/platform/linux/svg/W3C-SVG-1.1/animate-elem-36-t-expected.png
Binary files differ
diff --git a/third_party/WebKit/LayoutTests/platform/linux/svg/W3C-SVG-1.1/animate-elem-37-t-expected.png b/third_party/WebKit/LayoutTests/platform/linux/svg/W3C-SVG-1.1/animate-elem-37-t-expected.png
index e2e75c6..8b9108e 100644
--- a/third_party/WebKit/LayoutTests/platform/linux/svg/W3C-SVG-1.1/animate-elem-37-t-expected.png
+++ b/third_party/WebKit/LayoutTests/platform/linux/svg/W3C-SVG-1.1/animate-elem-37-t-expected.png
Binary files differ
diff --git a/third_party/WebKit/LayoutTests/platform/linux/svg/W3C-SVG-1.1/animate-elem-39-t-expected.png b/third_party/WebKit/LayoutTests/platform/linux/svg/W3C-SVG-1.1/animate-elem-39-t-expected.png
index 846924cc..ef05459 100644
--- a/third_party/WebKit/LayoutTests/platform/linux/svg/W3C-SVG-1.1/animate-elem-39-t-expected.png
+++ b/third_party/WebKit/LayoutTests/platform/linux/svg/W3C-SVG-1.1/animate-elem-39-t-expected.png
Binary files differ
diff --git a/third_party/WebKit/LayoutTests/platform/linux/svg/W3C-SVG-1.1/animate-elem-40-t-expected.png b/third_party/WebKit/LayoutTests/platform/linux/svg/W3C-SVG-1.1/animate-elem-40-t-expected.png
index 85eb1a3..6fb2e57 100644
--- a/third_party/WebKit/LayoutTests/platform/linux/svg/W3C-SVG-1.1/animate-elem-40-t-expected.png
+++ b/third_party/WebKit/LayoutTests/platform/linux/svg/W3C-SVG-1.1/animate-elem-40-t-expected.png
Binary files differ
diff --git a/third_party/WebKit/LayoutTests/platform/linux/svg/W3C-SVG-1.1/animate-elem-41-t-expected.png b/third_party/WebKit/LayoutTests/platform/linux/svg/W3C-SVG-1.1/animate-elem-41-t-expected.png
index c92592a3..ed4f4b116 100644
--- a/third_party/WebKit/LayoutTests/platform/linux/svg/W3C-SVG-1.1/animate-elem-41-t-expected.png
+++ b/third_party/WebKit/LayoutTests/platform/linux/svg/W3C-SVG-1.1/animate-elem-41-t-expected.png
Binary files differ
diff --git a/third_party/WebKit/LayoutTests/platform/linux/svg/W3C-SVG-1.1/animate-elem-46-t-expected.png b/third_party/WebKit/LayoutTests/platform/linux/svg/W3C-SVG-1.1/animate-elem-46-t-expected.png
index 46ce347a..a0ba0a7 100644
--- a/third_party/WebKit/LayoutTests/platform/linux/svg/W3C-SVG-1.1/animate-elem-46-t-expected.png
+++ b/third_party/WebKit/LayoutTests/platform/linux/svg/W3C-SVG-1.1/animate-elem-46-t-expected.png
Binary files differ
diff --git a/third_party/WebKit/LayoutTests/platform/linux/svg/W3C-SVG-1.1/animate-elem-65-t-expected.png b/third_party/WebKit/LayoutTests/platform/linux/svg/W3C-SVG-1.1/animate-elem-65-t-expected.png
index ea35f640..ce896e8 100644
--- a/third_party/WebKit/LayoutTests/platform/linux/svg/W3C-SVG-1.1/animate-elem-65-t-expected.png
+++ b/third_party/WebKit/LayoutTests/platform/linux/svg/W3C-SVG-1.1/animate-elem-65-t-expected.png
Binary files differ
diff --git a/third_party/WebKit/LayoutTests/platform/linux/svg/W3C-SVG-1.1/animate-elem-66-t-expected.png b/third_party/WebKit/LayoutTests/platform/linux/svg/W3C-SVG-1.1/animate-elem-66-t-expected.png
index 5978911..3a10c93 100644
--- a/third_party/WebKit/LayoutTests/platform/linux/svg/W3C-SVG-1.1/animate-elem-66-t-expected.png
+++ b/third_party/WebKit/LayoutTests/platform/linux/svg/W3C-SVG-1.1/animate-elem-66-t-expected.png
Binary files differ
diff --git a/third_party/WebKit/LayoutTests/platform/linux/svg/W3C-SVG-1.1/animate-elem-77-t-expected.png b/third_party/WebKit/LayoutTests/platform/linux/svg/W3C-SVG-1.1/animate-elem-77-t-expected.png
index 2f92050..08df49f 100644
--- a/third_party/WebKit/LayoutTests/platform/linux/svg/W3C-SVG-1.1/animate-elem-77-t-expected.png
+++ b/third_party/WebKit/LayoutTests/platform/linux/svg/W3C-SVG-1.1/animate-elem-77-t-expected.png
Binary files differ
diff --git a/third_party/WebKit/LayoutTests/platform/linux/svg/W3C-SVG-1.1/animate-elem-78-t-expected.png b/third_party/WebKit/LayoutTests/platform/linux/svg/W3C-SVG-1.1/animate-elem-78-t-expected.png
index 59e36c9..3c68e4ac 100644
--- a/third_party/WebKit/LayoutTests/platform/linux/svg/W3C-SVG-1.1/animate-elem-78-t-expected.png
+++ b/third_party/WebKit/LayoutTests/platform/linux/svg/W3C-SVG-1.1/animate-elem-78-t-expected.png
Binary files differ
diff --git a/third_party/WebKit/LayoutTests/platform/linux/svg/W3C-SVG-1.1/animate-elem-80-t-expected.png b/third_party/WebKit/LayoutTests/platform/linux/svg/W3C-SVG-1.1/animate-elem-80-t-expected.png
index 81272ef63..2024cbc 100644
--- a/third_party/WebKit/LayoutTests/platform/linux/svg/W3C-SVG-1.1/animate-elem-80-t-expected.png
+++ b/third_party/WebKit/LayoutTests/platform/linux/svg/W3C-SVG-1.1/animate-elem-80-t-expected.png
Binary files differ
diff --git a/third_party/WebKit/LayoutTests/platform/linux/svg/W3C-SVG-1.1/animate-elem-81-t-expected.png b/third_party/WebKit/LayoutTests/platform/linux/svg/W3C-SVG-1.1/animate-elem-81-t-expected.png
index e50930c2..362970fb 100644
--- a/third_party/WebKit/LayoutTests/platform/linux/svg/W3C-SVG-1.1/animate-elem-81-t-expected.png
+++ b/third_party/WebKit/LayoutTests/platform/linux/svg/W3C-SVG-1.1/animate-elem-81-t-expected.png
Binary files differ
diff --git a/third_party/WebKit/LayoutTests/platform/linux/svg/W3C-SVG-1.1/animate-elem-82-t-expected.png b/third_party/WebKit/LayoutTests/platform/linux/svg/W3C-SVG-1.1/animate-elem-82-t-expected.png
index 0144bf7f..750a89b3 100644
--- a/third_party/WebKit/LayoutTests/platform/linux/svg/W3C-SVG-1.1/animate-elem-82-t-expected.png
+++ b/third_party/WebKit/LayoutTests/platform/linux/svg/W3C-SVG-1.1/animate-elem-82-t-expected.png
Binary files differ
diff --git a/third_party/WebKit/LayoutTests/platform/linux/svg/W3C-SVG-1.1/animate-elem-83-t-expected.png b/third_party/WebKit/LayoutTests/platform/linux/svg/W3C-SVG-1.1/animate-elem-83-t-expected.png
index d98944fd..2061590 100644
--- a/third_party/WebKit/LayoutTests/platform/linux/svg/W3C-SVG-1.1/animate-elem-83-t-expected.png
+++ b/third_party/WebKit/LayoutTests/platform/linux/svg/W3C-SVG-1.1/animate-elem-83-t-expected.png
Binary files differ
diff --git a/third_party/WebKit/LayoutTests/platform/linux/svg/W3C-SVG-1.1/coords-viewattr-03-b-expected.png b/third_party/WebKit/LayoutTests/platform/linux/svg/W3C-SVG-1.1/coords-viewattr-03-b-expected.png
index fd71e23..eea903c 100644
--- a/third_party/WebKit/LayoutTests/platform/linux/svg/W3C-SVG-1.1/coords-viewattr-03-b-expected.png
+++ b/third_party/WebKit/LayoutTests/platform/linux/svg/W3C-SVG-1.1/coords-viewattr-03-b-expected.png
Binary files differ
diff --git a/third_party/WebKit/LayoutTests/platform/linux/svg/W3C-SVG-1.1/struct-frag-06-t-expected.png b/third_party/WebKit/LayoutTests/platform/linux/svg/W3C-SVG-1.1/struct-frag-06-t-expected.png
index d0788442..d0df6559 100644
--- a/third_party/WebKit/LayoutTests/platform/linux/svg/W3C-SVG-1.1/struct-frag-06-t-expected.png
+++ b/third_party/WebKit/LayoutTests/platform/linux/svg/W3C-SVG-1.1/struct-frag-06-t-expected.png
Binary files differ
diff --git a/third_party/WebKit/LayoutTests/platform/linux/svg/W3C-SVG-1.1/struct-use-01-t-expected.png b/third_party/WebKit/LayoutTests/platform/linux/svg/W3C-SVG-1.1/struct-use-01-t-expected.png
index 3206873..b8b9f296 100644
--- a/third_party/WebKit/LayoutTests/platform/linux/svg/W3C-SVG-1.1/struct-use-01-t-expected.png
+++ b/third_party/WebKit/LayoutTests/platform/linux/svg/W3C-SVG-1.1/struct-use-01-t-expected.png
Binary files differ
diff --git a/third_party/WebKit/LayoutTests/platform/linux/svg/W3C-SVG-1.1/struct-use-03-t-expected.png b/third_party/WebKit/LayoutTests/platform/linux/svg/W3C-SVG-1.1/struct-use-03-t-expected.png
index 5818545..7c6f6b0 100644
--- a/third_party/WebKit/LayoutTests/platform/linux/svg/W3C-SVG-1.1/struct-use-03-t-expected.png
+++ b/third_party/WebKit/LayoutTests/platform/linux/svg/W3C-SVG-1.1/struct-use-03-t-expected.png
Binary files differ
diff --git a/third_party/WebKit/LayoutTests/platform/linux/svg/W3C-SVG-1.1/styling-css-05-b-expected.png b/third_party/WebKit/LayoutTests/platform/linux/svg/W3C-SVG-1.1/styling-css-05-b-expected.png
index 3e516823..1cfe0a9 100644
--- a/third_party/WebKit/LayoutTests/platform/linux/svg/W3C-SVG-1.1/styling-css-05-b-expected.png
+++ b/third_party/WebKit/LayoutTests/platform/linux/svg/W3C-SVG-1.1/styling-css-05-b-expected.png
Binary files differ
diff --git a/third_party/WebKit/LayoutTests/platform/linux/svg/as-object/embedded-svg-immediate-offsetWidth-query-expected.png b/third_party/WebKit/LayoutTests/platform/linux/svg/as-object/embedded-svg-immediate-offsetWidth-query-expected.png
index b71f813..4836391 100644
--- a/third_party/WebKit/LayoutTests/platform/linux/svg/as-object/embedded-svg-immediate-offsetWidth-query-expected.png
+++ b/third_party/WebKit/LayoutTests/platform/linux/svg/as-object/embedded-svg-immediate-offsetWidth-query-expected.png
Binary files differ
diff --git a/third_party/WebKit/LayoutTests/platform/linux/svg/batik/text/smallFonts-expected.png b/third_party/WebKit/LayoutTests/platform/linux/svg/batik/text/smallFonts-expected.png
index 9baedf1..90620142 100644
--- a/third_party/WebKit/LayoutTests/platform/linux/svg/batik/text/smallFonts-expected.png
+++ b/third_party/WebKit/LayoutTests/platform/linux/svg/batik/text/smallFonts-expected.png
Binary files differ
diff --git a/third_party/WebKit/LayoutTests/platform/linux/svg/batik/text/textFeatures-expected.png b/third_party/WebKit/LayoutTests/platform/linux/svg/batik/text/textFeatures-expected.png
index b1c7cef..452b18c 100644
--- a/third_party/WebKit/LayoutTests/platform/linux/svg/batik/text/textFeatures-expected.png
+++ b/third_party/WebKit/LayoutTests/platform/linux/svg/batik/text/textFeatures-expected.png
Binary files differ
diff --git a/third_party/WebKit/LayoutTests/platform/linux/svg/batik/text/textLayout2-expected.png b/third_party/WebKit/LayoutTests/platform/linux/svg/batik/text/textLayout2-expected.png
index 5ef03b4..9a9bb7f5 100644
--- a/third_party/WebKit/LayoutTests/platform/linux/svg/batik/text/textLayout2-expected.png
+++ b/third_party/WebKit/LayoutTests/platform/linux/svg/batik/text/textLayout2-expected.png
Binary files differ
diff --git a/third_party/WebKit/LayoutTests/platform/linux/svg/batik/text/textPCDATA-expected.png b/third_party/WebKit/LayoutTests/platform/linux/svg/batik/text/textPCDATA-expected.png
index 71a6fcc..a2ca50d 100644
--- a/third_party/WebKit/LayoutTests/platform/linux/svg/batik/text/textPCDATA-expected.png
+++ b/third_party/WebKit/LayoutTests/platform/linux/svg/batik/text/textPCDATA-expected.png
Binary files differ
diff --git a/third_party/WebKit/LayoutTests/platform/linux/svg/batik/text/textProperties-expected.png b/third_party/WebKit/LayoutTests/platform/linux/svg/batik/text/textProperties-expected.png
index 69e91b7..d4ad910 100644
--- a/third_party/WebKit/LayoutTests/platform/linux/svg/batik/text/textProperties-expected.png
+++ b/third_party/WebKit/LayoutTests/platform/linux/svg/batik/text/textProperties-expected.png
Binary files differ
diff --git a/third_party/WebKit/LayoutTests/platform/linux/svg/batik/text/textStyles-expected.png b/third_party/WebKit/LayoutTests/platform/linux/svg/batik/text/textStyles-expected.png
index 48ea921..75a3d2a35 100644
--- a/third_party/WebKit/LayoutTests/platform/linux/svg/batik/text/textStyles-expected.png
+++ b/third_party/WebKit/LayoutTests/platform/linux/svg/batik/text/textStyles-expected.png
Binary files differ
diff --git a/third_party/WebKit/LayoutTests/platform/linux/svg/batik/text/verticalText-expected.png b/third_party/WebKit/LayoutTests/platform/linux/svg/batik/text/verticalText-expected.png
index a2071c2..a62e718 100644
--- a/third_party/WebKit/LayoutTests/platform/linux/svg/batik/text/verticalText-expected.png
+++ b/third_party/WebKit/LayoutTests/platform/linux/svg/batik/text/verticalText-expected.png
Binary files differ
diff --git a/third_party/WebKit/LayoutTests/platform/linux/svg/carto.net/selectionlist-expected.png b/third_party/WebKit/LayoutTests/platform/linux/svg/carto.net/selectionlist-expected.png
index 4e8d312..51e1429 100644
--- a/third_party/WebKit/LayoutTests/platform/linux/svg/carto.net/selectionlist-expected.png
+++ b/third_party/WebKit/LayoutTests/platform/linux/svg/carto.net/selectionlist-expected.png
Binary files differ
diff --git a/third_party/WebKit/LayoutTests/platform/linux/svg/custom/dominant-baseline-hanging-expected.png b/third_party/WebKit/LayoutTests/platform/linux/svg/custom/dominant-baseline-hanging-expected.png
index 105acb4..ca4a296 100644
--- a/third_party/WebKit/LayoutTests/platform/linux/svg/custom/dominant-baseline-hanging-expected.png
+++ b/third_party/WebKit/LayoutTests/platform/linux/svg/custom/dominant-baseline-hanging-expected.png
Binary files differ
diff --git a/third_party/WebKit/LayoutTests/platform/linux/svg/custom/image-small-width-height-expected.png b/third_party/WebKit/LayoutTests/platform/linux/svg/custom/image-small-width-height-expected.png
index 85b46a4..057914f 100644
--- a/third_party/WebKit/LayoutTests/platform/linux/svg/custom/image-small-width-height-expected.png
+++ b/third_party/WebKit/LayoutTests/platform/linux/svg/custom/image-small-width-height-expected.png
Binary files differ
diff --git a/third_party/WebKit/LayoutTests/platform/linux/svg/custom/load-non-wellformed-expected.png b/third_party/WebKit/LayoutTests/platform/linux/svg/custom/load-non-wellformed-expected.png
index 119386db..5f532d0 100644
--- a/third_party/WebKit/LayoutTests/platform/linux/svg/custom/load-non-wellformed-expected.png
+++ b/third_party/WebKit/LayoutTests/platform/linux/svg/custom/load-non-wellformed-expected.png
Binary files differ
diff --git a/third_party/WebKit/LayoutTests/platform/linux/svg/custom/load-non-wellformed-expected.txt b/third_party/WebKit/LayoutTests/platform/linux/svg/custom/load-non-wellformed-expected.txt
index 6d28545..d26730d 100644
--- a/third_party/WebKit/LayoutTests/platform/linux/svg/custom/load-non-wellformed-expected.txt
+++ b/third_party/WebKit/LayoutTests/platform/linux/svg/custom/load-non-wellformed-expected.txt
@@ -8,9 +8,9 @@
           LayoutText {#text} at (0,0) size 324x22
             text run at (0,0) width 324: "This page contains the following errors:"
         LayoutBlockFlow {div} at (18,62.44) size 701x15
-          LayoutText {#text} at (0,0) size 561x15
-            text run at (0,0) width 561: "error on line 6 at column 7: Opening and ending tag mismatch: use line 0 and svg"
-            text run at (561,0) width 0: " "
+          LayoutText {#text} at (0,0) size 560x15
+            text run at (0,0) width 560: "error on line 6 at column 7: Opening and ending tag mismatch: use line 0 and svg"
+            text run at (560,0) width 0: " "
         LayoutBlockFlow {h3} at (18,96.16) size 701x23
           LayoutText {#text} at (0,0) size 427x22
             text run at (0,0) width 427: "Below is a rendering of the page up to the first error."
diff --git a/third_party/WebKit/LayoutTests/platform/linux/svg/custom/rootmost-svg-xy-attrs-expected.png b/third_party/WebKit/LayoutTests/platform/linux/svg/custom/rootmost-svg-xy-attrs-expected.png
index 07dfc0a..ccceb9bb 100644
--- a/third_party/WebKit/LayoutTests/platform/linux/svg/custom/rootmost-svg-xy-attrs-expected.png
+++ b/third_party/WebKit/LayoutTests/platform/linux/svg/custom/rootmost-svg-xy-attrs-expected.png
Binary files differ
diff --git a/third_party/WebKit/LayoutTests/platform/linux/svg/custom/use-dynamic-append-expected.png b/third_party/WebKit/LayoutTests/platform/linux/svg/custom/use-dynamic-append-expected.png
index a19b33e..61431f9 100644
--- a/third_party/WebKit/LayoutTests/platform/linux/svg/custom/use-dynamic-append-expected.png
+++ b/third_party/WebKit/LayoutTests/platform/linux/svg/custom/use-dynamic-append-expected.png
Binary files differ
diff --git a/third_party/WebKit/LayoutTests/platform/linux/svg/dom/SVGLocatable-getCTM-svg-root-expected.png b/third_party/WebKit/LayoutTests/platform/linux/svg/dom/SVGLocatable-getCTM-svg-root-expected.png
index bcbd3e9f..4f7de02 100644
--- a/third_party/WebKit/LayoutTests/platform/linux/svg/dom/SVGLocatable-getCTM-svg-root-expected.png
+++ b/third_party/WebKit/LayoutTests/platform/linux/svg/dom/SVGLocatable-getCTM-svg-root-expected.png
Binary files differ
diff --git a/third_party/WebKit/LayoutTests/platform/linux/svg/dom/SVGStringList-basics-expected.png b/third_party/WebKit/LayoutTests/platform/linux/svg/dom/SVGStringList-basics-expected.png
index e2439191..6b7f0ab 100644
--- a/third_party/WebKit/LayoutTests/platform/linux/svg/dom/SVGStringList-basics-expected.png
+++ b/third_party/WebKit/LayoutTests/platform/linux/svg/dom/SVGStringList-basics-expected.png
Binary files differ
diff --git a/third_party/WebKit/LayoutTests/platform/linux/svg/dom/css-transforms-expected.png b/third_party/WebKit/LayoutTests/platform/linux/svg/dom/css-transforms-expected.png
index a0dcd89..c7ae42a 100644
--- a/third_party/WebKit/LayoutTests/platform/linux/svg/dom/css-transforms-expected.png
+++ b/third_party/WebKit/LayoutTests/platform/linux/svg/dom/css-transforms-expected.png
Binary files differ
diff --git a/third_party/WebKit/LayoutTests/platform/linux/svg/hixie/error/012-expected.png b/third_party/WebKit/LayoutTests/platform/linux/svg/hixie/error/012-expected.png
index 27843ff8..aa72df6 100644
--- a/third_party/WebKit/LayoutTests/platform/linux/svg/hixie/error/012-expected.png
+++ b/third_party/WebKit/LayoutTests/platform/linux/svg/hixie/error/012-expected.png
Binary files differ
diff --git a/third_party/WebKit/LayoutTests/platform/linux/svg/hixie/error/012-expected.txt b/third_party/WebKit/LayoutTests/platform/linux/svg/hixie/error/012-expected.txt
index a5642989..f91e1b5 100644
--- a/third_party/WebKit/LayoutTests/platform/linux/svg/hixie/error/012-expected.txt
+++ b/third_party/WebKit/LayoutTests/platform/linux/svg/hixie/error/012-expected.txt
@@ -8,9 +8,9 @@
           LayoutText {#text} at (0,0) size 324x22
             text run at (0,0) width 324: "This page contains the following errors:"
         LayoutBlockFlow {div} at (18,62.44) size 701x15
-          LayoutText {#text} at (0,0) size 568x15
-            text run at (0,0) width 568: "error on line 5 at column 7: Opening and ending tag mismatch: rect line 0 and svg"
-            text run at (568,0) width 0: " "
+          LayoutText {#text} at (0,0) size 567x15
+            text run at (0,0) width 567: "error on line 5 at column 7: Opening and ending tag mismatch: rect line 0 and svg"
+            text run at (567,0) width 0: " "
         LayoutBlockFlow {h3} at (18,96.16) size 701x23
           LayoutText {#text} at (0,0) size 427x22
             text run at (0,0) width 427: "Below is a rendering of the page up to the first error."
diff --git a/third_party/WebKit/LayoutTests/platform/linux/svg/text/bbox-with-glyph-overflow-expected.png b/third_party/WebKit/LayoutTests/platform/linux/svg/text/bbox-with-glyph-overflow-expected.png
index a11168f..ffba9ff 100644
--- a/third_party/WebKit/LayoutTests/platform/linux/svg/text/bbox-with-glyph-overflow-expected.png
+++ b/third_party/WebKit/LayoutTests/platform/linux/svg/text/bbox-with-glyph-overflow-expected.png
Binary files differ
diff --git a/third_party/WebKit/LayoutTests/platform/linux/svg/text/bbox-with-glyph-overflow-on-path-expected.png b/third_party/WebKit/LayoutTests/platform/linux/svg/text/bbox-with-glyph-overflow-on-path-expected.png
index 46eab7d..fd4d3d7f 100644
--- a/third_party/WebKit/LayoutTests/platform/linux/svg/text/bbox-with-glyph-overflow-on-path-expected.png
+++ b/third_party/WebKit/LayoutTests/platform/linux/svg/text/bbox-with-glyph-overflow-on-path-expected.png
Binary files differ
diff --git a/third_party/WebKit/LayoutTests/platform/linux/svg/text/bbox-with-glyph-overflow-zoomed-expected.png b/third_party/WebKit/LayoutTests/platform/linux/svg/text/bbox-with-glyph-overflow-zoomed-expected.png
index 19130dc..83a90172 100644
--- a/third_party/WebKit/LayoutTests/platform/linux/svg/text/bbox-with-glyph-overflow-zoomed-expected.png
+++ b/third_party/WebKit/LayoutTests/platform/linux/svg/text/bbox-with-glyph-overflow-zoomed-expected.png
Binary files differ
diff --git a/third_party/WebKit/LayoutTests/platform/linux/svg/text/combining-character-queries-expected.png b/third_party/WebKit/LayoutTests/platform/linux/svg/text/combining-character-queries-expected.png
index 39744bf4..da78192 100644
--- a/third_party/WebKit/LayoutTests/platform/linux/svg/text/combining-character-queries-expected.png
+++ b/third_party/WebKit/LayoutTests/platform/linux/svg/text/combining-character-queries-expected.png
Binary files differ
diff --git a/third_party/WebKit/LayoutTests/platform/linux/svg/text/surrogate-pair-queries-expected.png b/third_party/WebKit/LayoutTests/platform/linux/svg/text/surrogate-pair-queries-expected.png
index edbd2d7..2de2f6d 100644
--- a/third_party/WebKit/LayoutTests/platform/linux/svg/text/surrogate-pair-queries-expected.png
+++ b/third_party/WebKit/LayoutTests/platform/linux/svg/text/surrogate-pair-queries-expected.png
Binary files differ
diff --git a/third_party/WebKit/LayoutTests/platform/linux/svg/wicd/test-rightsizing-a-expected.png b/third_party/WebKit/LayoutTests/platform/linux/svg/wicd/test-rightsizing-a-expected.png
index 32676a2..d2c2970 100644
--- a/third_party/WebKit/LayoutTests/platform/linux/svg/wicd/test-rightsizing-a-expected.png
+++ b/third_party/WebKit/LayoutTests/platform/linux/svg/wicd/test-rightsizing-a-expected.png
Binary files differ
diff --git a/third_party/WebKit/LayoutTests/platform/linux/svg/wicd/test-rightsizing-b-expected.png b/third_party/WebKit/LayoutTests/platform/linux/svg/wicd/test-rightsizing-b-expected.png
index 198dc785..6152b74 100644
--- a/third_party/WebKit/LayoutTests/platform/linux/svg/wicd/test-rightsizing-b-expected.png
+++ b/third_party/WebKit/LayoutTests/platform/linux/svg/wicd/test-rightsizing-b-expected.png
Binary files differ
diff --git a/third_party/WebKit/LayoutTests/platform/linux/svg/wicd/test-scalable-background-image1-expected.png b/third_party/WebKit/LayoutTests/platform/linux/svg/wicd/test-scalable-background-image1-expected.png
index aab503f..91d8f01 100644
--- a/third_party/WebKit/LayoutTests/platform/linux/svg/wicd/test-scalable-background-image1-expected.png
+++ b/third_party/WebKit/LayoutTests/platform/linux/svg/wicd/test-scalable-background-image1-expected.png
Binary files differ
diff --git a/third_party/WebKit/LayoutTests/platform/linux/svg/wicd/test-scalable-background-image2-expected.png b/third_party/WebKit/LayoutTests/platform/linux/svg/wicd/test-scalable-background-image2-expected.png
index 5df6904..e593efa 100644
--- a/third_party/WebKit/LayoutTests/platform/linux/svg/wicd/test-scalable-background-image2-expected.png
+++ b/third_party/WebKit/LayoutTests/platform/linux/svg/wicd/test-scalable-background-image2-expected.png
Binary files differ
diff --git a/third_party/WebKit/LayoutTests/platform/linux/tables/mozilla/bugs/bug1188-expected.png b/third_party/WebKit/LayoutTests/platform/linux/tables/mozilla/bugs/bug1188-expected.png
index 0e95b5c..78b2afa 100644
--- a/third_party/WebKit/LayoutTests/platform/linux/tables/mozilla/bugs/bug1188-expected.png
+++ b/third_party/WebKit/LayoutTests/platform/linux/tables/mozilla/bugs/bug1188-expected.png
Binary files differ
diff --git a/third_party/WebKit/LayoutTests/platform/linux/tables/mozilla/bugs/bug1302-expected.png b/third_party/WebKit/LayoutTests/platform/linux/tables/mozilla/bugs/bug1302-expected.png
index 4e9d08d82..88863e18c 100644
--- a/third_party/WebKit/LayoutTests/platform/linux/tables/mozilla/bugs/bug1302-expected.png
+++ b/third_party/WebKit/LayoutTests/platform/linux/tables/mozilla/bugs/bug1302-expected.png
Binary files differ
diff --git a/third_party/WebKit/LayoutTests/platform/linux/tables/mozilla/bugs/bug13105-expected.png b/third_party/WebKit/LayoutTests/platform/linux/tables/mozilla/bugs/bug13105-expected.png
index f029203..cf5546c 100644
--- a/third_party/WebKit/LayoutTests/platform/linux/tables/mozilla/bugs/bug13105-expected.png
+++ b/third_party/WebKit/LayoutTests/platform/linux/tables/mozilla/bugs/bug13105-expected.png
Binary files differ
diff --git a/third_party/WebKit/LayoutTests/platform/linux/tables/mozilla/bugs/bug13484-expected.png b/third_party/WebKit/LayoutTests/platform/linux/tables/mozilla/bugs/bug13484-expected.png
index 3f0e65b..2ba54c7a 100644
--- a/third_party/WebKit/LayoutTests/platform/linux/tables/mozilla/bugs/bug13484-expected.png
+++ b/third_party/WebKit/LayoutTests/platform/linux/tables/mozilla/bugs/bug13484-expected.png
Binary files differ
diff --git a/third_party/WebKit/LayoutTests/platform/linux/tables/mozilla/bugs/bug139524-2-expected.png b/third_party/WebKit/LayoutTests/platform/linux/tables/mozilla/bugs/bug139524-2-expected.png
index 1d6e6f5..ca14218 100644
--- a/third_party/WebKit/LayoutTests/platform/linux/tables/mozilla/bugs/bug139524-2-expected.png
+++ b/third_party/WebKit/LayoutTests/platform/linux/tables/mozilla/bugs/bug139524-2-expected.png
Binary files differ
diff --git a/third_party/WebKit/LayoutTests/platform/linux/tables/mozilla/bugs/bug1802-expected.png b/third_party/WebKit/LayoutTests/platform/linux/tables/mozilla/bugs/bug1802-expected.png
index dceefed..48bdcd4 100644
--- a/third_party/WebKit/LayoutTests/platform/linux/tables/mozilla/bugs/bug1802-expected.png
+++ b/third_party/WebKit/LayoutTests/platform/linux/tables/mozilla/bugs/bug1802-expected.png
Binary files differ
diff --git a/third_party/WebKit/LayoutTests/platform/linux/tables/mozilla/bugs/bug1802s-expected.png b/third_party/WebKit/LayoutTests/platform/linux/tables/mozilla/bugs/bug1802s-expected.png
index dceefed..48bdcd4 100644
--- a/third_party/WebKit/LayoutTests/platform/linux/tables/mozilla/bugs/bug1802s-expected.png
+++ b/third_party/WebKit/LayoutTests/platform/linux/tables/mozilla/bugs/bug1802s-expected.png
Binary files differ
diff --git a/third_party/WebKit/LayoutTests/platform/linux/tables/mozilla/bugs/bug1828-expected.png b/third_party/WebKit/LayoutTests/platform/linux/tables/mozilla/bugs/bug1828-expected.png
index c8225d5..4cd6869c 100644
--- a/third_party/WebKit/LayoutTests/platform/linux/tables/mozilla/bugs/bug1828-expected.png
+++ b/third_party/WebKit/LayoutTests/platform/linux/tables/mozilla/bugs/bug1828-expected.png
Binary files differ
diff --git a/third_party/WebKit/LayoutTests/platform/linux/tables/mozilla/bugs/bug20579-expected.png b/third_party/WebKit/LayoutTests/platform/linux/tables/mozilla/bugs/bug20579-expected.png
index 11c41a5..25b1362 100644
--- a/third_party/WebKit/LayoutTests/platform/linux/tables/mozilla/bugs/bug20579-expected.png
+++ b/third_party/WebKit/LayoutTests/platform/linux/tables/mozilla/bugs/bug20579-expected.png
Binary files differ
diff --git a/third_party/WebKit/LayoutTests/platform/linux/tables/mozilla/bugs/bug22019-expected.png b/third_party/WebKit/LayoutTests/platform/linux/tables/mozilla/bugs/bug22019-expected.png
index 3bbe01c..88634f44 100644
--- a/third_party/WebKit/LayoutTests/platform/linux/tables/mozilla/bugs/bug22019-expected.png
+++ b/third_party/WebKit/LayoutTests/platform/linux/tables/mozilla/bugs/bug22019-expected.png
Binary files differ
diff --git a/third_party/WebKit/LayoutTests/platform/linux/tables/mozilla/bugs/bug23235-expected.png b/third_party/WebKit/LayoutTests/platform/linux/tables/mozilla/bugs/bug23235-expected.png
index ce6d158f..24a444c 100644
--- a/third_party/WebKit/LayoutTests/platform/linux/tables/mozilla/bugs/bug23235-expected.png
+++ b/third_party/WebKit/LayoutTests/platform/linux/tables/mozilla/bugs/bug23235-expected.png
Binary files differ
diff --git a/third_party/WebKit/LayoutTests/platform/linux/tables/mozilla/bugs/bug2479-3-expected.png b/third_party/WebKit/LayoutTests/platform/linux/tables/mozilla/bugs/bug2479-3-expected.png
index 95e4721..aecdbbd 100644
--- a/third_party/WebKit/LayoutTests/platform/linux/tables/mozilla/bugs/bug2479-3-expected.png
+++ b/third_party/WebKit/LayoutTests/platform/linux/tables/mozilla/bugs/bug2479-3-expected.png
Binary files differ
diff --git a/third_party/WebKit/LayoutTests/platform/linux/tables/mozilla/bugs/bug2947-expected.png b/third_party/WebKit/LayoutTests/platform/linux/tables/mozilla/bugs/bug2947-expected.png
index e37293ff..e7eb07af 100644
--- a/third_party/WebKit/LayoutTests/platform/linux/tables/mozilla/bugs/bug2947-expected.png
+++ b/third_party/WebKit/LayoutTests/platform/linux/tables/mozilla/bugs/bug2947-expected.png
Binary files differ
diff --git a/third_party/WebKit/LayoutTests/platform/linux/tables/mozilla/bugs/bug30692-expected.png b/third_party/WebKit/LayoutTests/platform/linux/tables/mozilla/bugs/bug30692-expected.png
index 4610ec34..79acf76 100644
--- a/third_party/WebKit/LayoutTests/platform/linux/tables/mozilla/bugs/bug30692-expected.png
+++ b/third_party/WebKit/LayoutTests/platform/linux/tables/mozilla/bugs/bug30692-expected.png
Binary files differ
diff --git a/third_party/WebKit/LayoutTests/platform/linux/tables/mozilla/bugs/bug32205-2-expected.png b/third_party/WebKit/LayoutTests/platform/linux/tables/mozilla/bugs/bug32205-2-expected.png
index 969932a..728f9ae 100644
--- a/third_party/WebKit/LayoutTests/platform/linux/tables/mozilla/bugs/bug32205-2-expected.png
+++ b/third_party/WebKit/LayoutTests/platform/linux/tables/mozilla/bugs/bug32205-2-expected.png
Binary files differ
diff --git a/third_party/WebKit/LayoutTests/platform/linux/tables/mozilla/bugs/bug32205-3-expected.png b/third_party/WebKit/LayoutTests/platform/linux/tables/mozilla/bugs/bug32205-3-expected.png
index 297ebd7..d348886 100644
--- a/third_party/WebKit/LayoutTests/platform/linux/tables/mozilla/bugs/bug32205-3-expected.png
+++ b/third_party/WebKit/LayoutTests/platform/linux/tables/mozilla/bugs/bug32205-3-expected.png
Binary files differ
diff --git a/third_party/WebKit/LayoutTests/platform/linux/tables/mozilla/bugs/bug5538-expected.png b/third_party/WebKit/LayoutTests/platform/linux/tables/mozilla/bugs/bug5538-expected.png
index 1e0ccb54..9479408cd 100644
--- a/third_party/WebKit/LayoutTests/platform/linux/tables/mozilla/bugs/bug5538-expected.png
+++ b/third_party/WebKit/LayoutTests/platform/linux/tables/mozilla/bugs/bug5538-expected.png
Binary files differ
diff --git a/third_party/WebKit/LayoutTests/platform/linux/tables/mozilla/bugs/bug5835-expected.png b/third_party/WebKit/LayoutTests/platform/linux/tables/mozilla/bugs/bug5835-expected.png
index c646448e..26152b70 100644
--- a/third_party/WebKit/LayoutTests/platform/linux/tables/mozilla/bugs/bug5835-expected.png
+++ b/third_party/WebKit/LayoutTests/platform/linux/tables/mozilla/bugs/bug5835-expected.png
Binary files differ
diff --git a/third_party/WebKit/LayoutTests/platform/linux/tables/mozilla/bugs/bug5838-expected.png b/third_party/WebKit/LayoutTests/platform/linux/tables/mozilla/bugs/bug5838-expected.png
index 101ec96..ad6399f2f 100644
--- a/third_party/WebKit/LayoutTests/platform/linux/tables/mozilla/bugs/bug5838-expected.png
+++ b/third_party/WebKit/LayoutTests/platform/linux/tables/mozilla/bugs/bug5838-expected.png
Binary files differ
diff --git a/third_party/WebKit/LayoutTests/platform/linux/tables/mozilla/bugs/bug60992-expected.png b/third_party/WebKit/LayoutTests/platform/linux/tables/mozilla/bugs/bug60992-expected.png
index dc3da131..72f8a87e 100644
--- a/third_party/WebKit/LayoutTests/platform/linux/tables/mozilla/bugs/bug60992-expected.png
+++ b/third_party/WebKit/LayoutTests/platform/linux/tables/mozilla/bugs/bug60992-expected.png
Binary files differ
diff --git a/third_party/WebKit/LayoutTests/platform/linux/tables/mozilla/bugs/bug6304-expected.png b/third_party/WebKit/LayoutTests/platform/linux/tables/mozilla/bugs/bug6304-expected.png
index 2595d15..1718426 100644
--- a/third_party/WebKit/LayoutTests/platform/linux/tables/mozilla/bugs/bug6304-expected.png
+++ b/third_party/WebKit/LayoutTests/platform/linux/tables/mozilla/bugs/bug6304-expected.png
Binary files differ
diff --git a/third_party/WebKit/LayoutTests/platform/linux/tables/mozilla/bugs/bug6404-expected.png b/third_party/WebKit/LayoutTests/platform/linux/tables/mozilla/bugs/bug6404-expected.png
index 20e97cc..d880b581 100644
--- a/third_party/WebKit/LayoutTests/platform/linux/tables/mozilla/bugs/bug6404-expected.png
+++ b/third_party/WebKit/LayoutTests/platform/linux/tables/mozilla/bugs/bug6404-expected.png
Binary files differ
diff --git a/third_party/WebKit/LayoutTests/platform/linux/tables/mozilla/bugs/bug7121-1-expected.png b/third_party/WebKit/LayoutTests/platform/linux/tables/mozilla/bugs/bug7121-1-expected.png
index fe3e3d1..cd06fec 100644
--- a/third_party/WebKit/LayoutTests/platform/linux/tables/mozilla/bugs/bug7121-1-expected.png
+++ b/third_party/WebKit/LayoutTests/platform/linux/tables/mozilla/bugs/bug7121-1-expected.png
Binary files differ
diff --git a/third_party/WebKit/LayoutTests/platform/linux/tables/mozilla/bugs/bug83786-expected.png b/third_party/WebKit/LayoutTests/platform/linux/tables/mozilla/bugs/bug83786-expected.png
index 51890d9b..fa30eb14 100644
--- a/third_party/WebKit/LayoutTests/platform/linux/tables/mozilla/bugs/bug83786-expected.png
+++ b/third_party/WebKit/LayoutTests/platform/linux/tables/mozilla/bugs/bug83786-expected.png
Binary files differ
diff --git a/third_party/WebKit/LayoutTests/platform/linux/tables/mozilla/bugs/bug88035-1-expected.png b/third_party/WebKit/LayoutTests/platform/linux/tables/mozilla/bugs/bug88035-1-expected.png
index 7e3e840..f9f6934 100644
--- a/third_party/WebKit/LayoutTests/platform/linux/tables/mozilla/bugs/bug88035-1-expected.png
+++ b/third_party/WebKit/LayoutTests/platform/linux/tables/mozilla/bugs/bug88035-1-expected.png
Binary files differ
diff --git a/third_party/WebKit/LayoutTests/platform/linux/tables/mozilla/bugs/bug88035-2-expected.png b/third_party/WebKit/LayoutTests/platform/linux/tables/mozilla/bugs/bug88035-2-expected.png
index 0d1f953..5d7b948 100644
--- a/third_party/WebKit/LayoutTests/platform/linux/tables/mozilla/bugs/bug88035-2-expected.png
+++ b/third_party/WebKit/LayoutTests/platform/linux/tables/mozilla/bugs/bug88035-2-expected.png
Binary files differ
diff --git a/third_party/WebKit/LayoutTests/platform/linux/tables/mozilla/bugs/bug8950-expected.png b/third_party/WebKit/LayoutTests/platform/linux/tables/mozilla/bugs/bug8950-expected.png
index fde2aef..3687f40 100644
--- a/third_party/WebKit/LayoutTests/platform/linux/tables/mozilla/bugs/bug8950-expected.png
+++ b/third_party/WebKit/LayoutTests/platform/linux/tables/mozilla/bugs/bug8950-expected.png
Binary files differ
diff --git a/third_party/WebKit/LayoutTests/platform/linux/tables/mozilla/other/wa_table_thtd_rowspan-expected.png b/third_party/WebKit/LayoutTests/platform/linux/tables/mozilla/other/wa_table_thtd_rowspan-expected.png
index f27ca3e..28960e6 100644
--- a/third_party/WebKit/LayoutTests/platform/linux/tables/mozilla/other/wa_table_thtd_rowspan-expected.png
+++ b/third_party/WebKit/LayoutTests/platform/linux/tables/mozilla/other/wa_table_thtd_rowspan-expected.png
Binary files differ
diff --git a/third_party/WebKit/LayoutTests/platform/linux/tables/mozilla_expected_failures/bugs/bug1055-2-expected.png b/third_party/WebKit/LayoutTests/platform/linux/tables/mozilla_expected_failures/bugs/bug1055-2-expected.png
index b1d4f81..1c432351 100644
--- a/third_party/WebKit/LayoutTests/platform/linux/tables/mozilla_expected_failures/bugs/bug1055-2-expected.png
+++ b/third_party/WebKit/LayoutTests/platform/linux/tables/mozilla_expected_failures/bugs/bug1055-2-expected.png
Binary files differ
diff --git a/third_party/WebKit/LayoutTests/platform/linux/tables/mozilla_expected_failures/bugs/bug1128-expected.png b/third_party/WebKit/LayoutTests/platform/linux/tables/mozilla_expected_failures/bugs/bug1128-expected.png
index 28375190..89ddc733 100644
--- a/third_party/WebKit/LayoutTests/platform/linux/tables/mozilla_expected_failures/bugs/bug1128-expected.png
+++ b/third_party/WebKit/LayoutTests/platform/linux/tables/mozilla_expected_failures/bugs/bug1128-expected.png
Binary files differ
diff --git a/third_party/WebKit/LayoutTests/platform/linux/tables/mozilla_expected_failures/bugs/bug21518-expected.png b/third_party/WebKit/LayoutTests/platform/linux/tables/mozilla_expected_failures/bugs/bug21518-expected.png
index d4ebebea..f7af8bd 100644
--- a/third_party/WebKit/LayoutTests/platform/linux/tables/mozilla_expected_failures/bugs/bug21518-expected.png
+++ b/third_party/WebKit/LayoutTests/platform/linux/tables/mozilla_expected_failures/bugs/bug21518-expected.png
Binary files differ
diff --git a/third_party/WebKit/LayoutTests/platform/linux/tables/mozilla_expected_failures/bugs/bug22122-expected.png b/third_party/WebKit/LayoutTests/platform/linux/tables/mozilla_expected_failures/bugs/bug22122-expected.png
index 2dba916f..141388a8 100644
--- a/third_party/WebKit/LayoutTests/platform/linux/tables/mozilla_expected_failures/bugs/bug22122-expected.png
+++ b/third_party/WebKit/LayoutTests/platform/linux/tables/mozilla_expected_failures/bugs/bug22122-expected.png
Binary files differ
diff --git a/third_party/WebKit/LayoutTests/platform/linux/tables/mozilla_expected_failures/bugs/bug32205-1-expected.png b/third_party/WebKit/LayoutTests/platform/linux/tables/mozilla_expected_failures/bugs/bug32205-1-expected.png
index 3df2841..e87bbfd 100644
--- a/third_party/WebKit/LayoutTests/platform/linux/tables/mozilla_expected_failures/bugs/bug32205-1-expected.png
+++ b/third_party/WebKit/LayoutTests/platform/linux/tables/mozilla_expected_failures/bugs/bug32205-1-expected.png
Binary files differ
diff --git a/third_party/WebKit/LayoutTests/platform/linux/tables/mozilla_expected_failures/bugs/bug8499-expected.png b/third_party/WebKit/LayoutTests/platform/linux/tables/mozilla_expected_failures/bugs/bug8499-expected.png
index e1523bc1..57297098 100644
--- a/third_party/WebKit/LayoutTests/platform/linux/tables/mozilla_expected_failures/bugs/bug8499-expected.png
+++ b/third_party/WebKit/LayoutTests/platform/linux/tables/mozilla_expected_failures/bugs/bug8499-expected.png
Binary files differ
diff --git a/third_party/WebKit/LayoutTests/platform/linux/tables/mozilla_expected_failures/marvin/backgr_fixed-bg-expected.png b/third_party/WebKit/LayoutTests/platform/linux/tables/mozilla_expected_failures/marvin/backgr_fixed-bg-expected.png
index ac52ca3..d6babf1 100644
--- a/third_party/WebKit/LayoutTests/platform/linux/tables/mozilla_expected_failures/marvin/backgr_fixed-bg-expected.png
+++ b/third_party/WebKit/LayoutTests/platform/linux/tables/mozilla_expected_failures/marvin/backgr_fixed-bg-expected.png
Binary files differ
diff --git a/third_party/WebKit/LayoutTests/platform/linux/virtual/exotic-color-space/images/color-profile-munsell-adobe-to-srgb-expected.png b/third_party/WebKit/LayoutTests/platform/linux/virtual/exotic-color-space/images/color-profile-munsell-adobe-to-srgb-expected.png
index b91cd46..c5c3efb7 100644
--- a/third_party/WebKit/LayoutTests/platform/linux/virtual/exotic-color-space/images/color-profile-munsell-adobe-to-srgb-expected.png
+++ b/third_party/WebKit/LayoutTests/platform/linux/virtual/exotic-color-space/images/color-profile-munsell-adobe-to-srgb-expected.png
Binary files differ
diff --git a/third_party/WebKit/LayoutTests/platform/linux/virtual/exotic-color-space/images/color-profile-munsell-srgb-to-srgb-expected.png b/third_party/WebKit/LayoutTests/platform/linux/virtual/exotic-color-space/images/color-profile-munsell-srgb-to-srgb-expected.png
index cf8ed87a..6f42dc9 100644
--- a/third_party/WebKit/LayoutTests/platform/linux/virtual/exotic-color-space/images/color-profile-munsell-srgb-to-srgb-expected.png
+++ b/third_party/WebKit/LayoutTests/platform/linux/virtual/exotic-color-space/images/color-profile-munsell-srgb-to-srgb-expected.png
Binary files differ
diff --git a/third_party/WebKit/LayoutTests/platform/linux/virtual/exotic-color-space/images/imagemap-circle-focus-ring-expected.png b/third_party/WebKit/LayoutTests/platform/linux/virtual/exotic-color-space/images/imagemap-circle-focus-ring-expected.png
index e662d7b7..d5a6a16 100644
--- a/third_party/WebKit/LayoutTests/platform/linux/virtual/exotic-color-space/images/imagemap-circle-focus-ring-expected.png
+++ b/third_party/WebKit/LayoutTests/platform/linux/virtual/exotic-color-space/images/imagemap-circle-focus-ring-expected.png
Binary files differ
diff --git a/third_party/WebKit/LayoutTests/platform/linux/virtual/exotic-color-space/images/imagemap-focus-ring-expected.png b/third_party/WebKit/LayoutTests/platform/linux/virtual/exotic-color-space/images/imagemap-focus-ring-expected.png
index 3a18bc3..804ea1b 100644
--- a/third_party/WebKit/LayoutTests/platform/linux/virtual/exotic-color-space/images/imagemap-focus-ring-expected.png
+++ b/third_party/WebKit/LayoutTests/platform/linux/virtual/exotic-color-space/images/imagemap-focus-ring-expected.png
Binary files differ
diff --git a/third_party/WebKit/LayoutTests/platform/linux/virtual/exotic-color-space/images/imagemap-focus-ring-outline-color-expected.png b/third_party/WebKit/LayoutTests/platform/linux/virtual/exotic-color-space/images/imagemap-focus-ring-outline-color-expected.png
index c41f263..d392de6a 100644
--- a/third_party/WebKit/LayoutTests/platform/linux/virtual/exotic-color-space/images/imagemap-focus-ring-outline-color-expected.png
+++ b/third_party/WebKit/LayoutTests/platform/linux/virtual/exotic-color-space/images/imagemap-focus-ring-outline-color-expected.png
Binary files differ
diff --git a/third_party/WebKit/LayoutTests/platform/linux/virtual/exotic-color-space/images/imagemap-focus-ring-outline-color-explicitly-inherited-from-map-expected.png b/third_party/WebKit/LayoutTests/platform/linux/virtual/exotic-color-space/images/imagemap-focus-ring-outline-color-explicitly-inherited-from-map-expected.png
index 58619fe..579e241 100644
--- a/third_party/WebKit/LayoutTests/platform/linux/virtual/exotic-color-space/images/imagemap-focus-ring-outline-color-explicitly-inherited-from-map-expected.png
+++ b/third_party/WebKit/LayoutTests/platform/linux/virtual/exotic-color-space/images/imagemap-focus-ring-outline-color-explicitly-inherited-from-map-expected.png
Binary files differ
diff --git a/third_party/WebKit/LayoutTests/platform/linux/virtual/exotic-color-space/images/imagemap-focus-ring-outline-color-not-inherited-from-map-expected.png b/third_party/WebKit/LayoutTests/platform/linux/virtual/exotic-color-space/images/imagemap-focus-ring-outline-color-not-inherited-from-map-expected.png
index 9a71d1d..e479ae1 100644
--- a/third_party/WebKit/LayoutTests/platform/linux/virtual/exotic-color-space/images/imagemap-focus-ring-outline-color-not-inherited-from-map-expected.png
+++ b/third_party/WebKit/LayoutTests/platform/linux/virtual/exotic-color-space/images/imagemap-focus-ring-outline-color-not-inherited-from-map-expected.png
Binary files differ
diff --git a/third_party/WebKit/LayoutTests/platform/linux/virtual/exotic-color-space/images/imagemap-focus-ring-zero-outline-width-expected.png b/third_party/WebKit/LayoutTests/platform/linux/virtual/exotic-color-space/images/imagemap-focus-ring-zero-outline-width-expected.png
index f465da6..a199de2 100644
--- a/third_party/WebKit/LayoutTests/platform/linux/virtual/exotic-color-space/images/imagemap-focus-ring-zero-outline-width-expected.png
+++ b/third_party/WebKit/LayoutTests/platform/linux/virtual/exotic-color-space/images/imagemap-focus-ring-zero-outline-width-expected.png
Binary files differ
diff --git a/third_party/WebKit/LayoutTests/platform/linux/virtual/exotic-color-space/images/imagemap-focus-ring-zoom-expected.png b/third_party/WebKit/LayoutTests/platform/linux/virtual/exotic-color-space/images/imagemap-focus-ring-zoom-expected.png
index c314ece1..53a609a0 100644
--- a/third_party/WebKit/LayoutTests/platform/linux/virtual/exotic-color-space/images/imagemap-focus-ring-zoom-expected.png
+++ b/third_party/WebKit/LayoutTests/platform/linux/virtual/exotic-color-space/images/imagemap-focus-ring-zoom-expected.png
Binary files differ
diff --git a/third_party/WebKit/LayoutTests/platform/linux/virtual/exotic-color-space/images/imagemap-overflowing-circle-focus-ring-expected.png b/third_party/WebKit/LayoutTests/platform/linux/virtual/exotic-color-space/images/imagemap-overflowing-circle-focus-ring-expected.png
index 80874f0a..5880f18 100644
--- a/third_party/WebKit/LayoutTests/platform/linux/virtual/exotic-color-space/images/imagemap-overflowing-circle-focus-ring-expected.png
+++ b/third_party/WebKit/LayoutTests/platform/linux/virtual/exotic-color-space/images/imagemap-overflowing-circle-focus-ring-expected.png
Binary files differ
diff --git a/third_party/WebKit/LayoutTests/platform/linux/virtual/exotic-color-space/images/imagemap-overflowing-polygon-focus-ring-expected.png b/third_party/WebKit/LayoutTests/platform/linux/virtual/exotic-color-space/images/imagemap-overflowing-polygon-focus-ring-expected.png
index da1d078..d42a2dbc 100644
--- a/third_party/WebKit/LayoutTests/platform/linux/virtual/exotic-color-space/images/imagemap-overflowing-polygon-focus-ring-expected.png
+++ b/third_party/WebKit/LayoutTests/platform/linux/virtual/exotic-color-space/images/imagemap-overflowing-polygon-focus-ring-expected.png
Binary files differ
diff --git a/third_party/WebKit/LayoutTests/platform/linux/virtual/exotic-color-space/images/imagemap-polygon-focus-ring-expected.png b/third_party/WebKit/LayoutTests/platform/linux/virtual/exotic-color-space/images/imagemap-polygon-focus-ring-expected.png
index b61d6db..f3a0d48f 100644
--- a/third_party/WebKit/LayoutTests/platform/linux/virtual/exotic-color-space/images/imagemap-polygon-focus-ring-expected.png
+++ b/third_party/WebKit/LayoutTests/platform/linux/virtual/exotic-color-space/images/imagemap-polygon-focus-ring-expected.png
Binary files differ
diff --git a/third_party/WebKit/LayoutTests/platform/linux/virtual/gpu-rasterization/images/color-profile-munsell-adobe-to-srgb-expected.png b/third_party/WebKit/LayoutTests/platform/linux/virtual/gpu-rasterization/images/color-profile-munsell-adobe-to-srgb-expected.png
index b3bf324..5d6ebd9 100644
--- a/third_party/WebKit/LayoutTests/platform/linux/virtual/gpu-rasterization/images/color-profile-munsell-adobe-to-srgb-expected.png
+++ b/third_party/WebKit/LayoutTests/platform/linux/virtual/gpu-rasterization/images/color-profile-munsell-adobe-to-srgb-expected.png
Binary files differ
diff --git a/third_party/WebKit/LayoutTests/platform/linux/virtual/gpu-rasterization/images/color-profile-munsell-srgb-to-srgb-expected.png b/third_party/WebKit/LayoutTests/platform/linux/virtual/gpu-rasterization/images/color-profile-munsell-srgb-to-srgb-expected.png
index d9c1967..f82f529 100644
--- a/third_party/WebKit/LayoutTests/platform/linux/virtual/gpu-rasterization/images/color-profile-munsell-srgb-to-srgb-expected.png
+++ b/third_party/WebKit/LayoutTests/platform/linux/virtual/gpu-rasterization/images/color-profile-munsell-srgb-to-srgb-expected.png
Binary files differ
diff --git a/third_party/WebKit/LayoutTests/platform/linux/virtual/gpu-rasterization/images/imagemap-circle-focus-ring-expected.png b/third_party/WebKit/LayoutTests/platform/linux/virtual/gpu-rasterization/images/imagemap-circle-focus-ring-expected.png
index 32dbadd..9947e82 100644
--- a/third_party/WebKit/LayoutTests/platform/linux/virtual/gpu-rasterization/images/imagemap-circle-focus-ring-expected.png
+++ b/third_party/WebKit/LayoutTests/platform/linux/virtual/gpu-rasterization/images/imagemap-circle-focus-ring-expected.png
Binary files differ
diff --git a/third_party/WebKit/LayoutTests/platform/linux/virtual/gpu-rasterization/images/imagemap-focus-ring-expected.png b/third_party/WebKit/LayoutTests/platform/linux/virtual/gpu-rasterization/images/imagemap-focus-ring-expected.png
index 81c35cf..120c622 100644
--- a/third_party/WebKit/LayoutTests/platform/linux/virtual/gpu-rasterization/images/imagemap-focus-ring-expected.png
+++ b/third_party/WebKit/LayoutTests/platform/linux/virtual/gpu-rasterization/images/imagemap-focus-ring-expected.png
Binary files differ
diff --git a/third_party/WebKit/LayoutTests/platform/linux/virtual/gpu-rasterization/images/imagemap-focus-ring-outline-color-expected.png b/third_party/WebKit/LayoutTests/platform/linux/virtual/gpu-rasterization/images/imagemap-focus-ring-outline-color-expected.png
index 6bd6bb9d..54b9fca 100644
--- a/third_party/WebKit/LayoutTests/platform/linux/virtual/gpu-rasterization/images/imagemap-focus-ring-outline-color-expected.png
+++ b/third_party/WebKit/LayoutTests/platform/linux/virtual/gpu-rasterization/images/imagemap-focus-ring-outline-color-expected.png
Binary files differ
diff --git a/third_party/WebKit/LayoutTests/platform/linux/virtual/gpu-rasterization/images/imagemap-focus-ring-outline-color-explicitly-inherited-from-map-expected.png b/third_party/WebKit/LayoutTests/platform/linux/virtual/gpu-rasterization/images/imagemap-focus-ring-outline-color-explicitly-inherited-from-map-expected.png
index 239636df4..2ebf6b2 100644
--- a/third_party/WebKit/LayoutTests/platform/linux/virtual/gpu-rasterization/images/imagemap-focus-ring-outline-color-explicitly-inherited-from-map-expected.png
+++ b/third_party/WebKit/LayoutTests/platform/linux/virtual/gpu-rasterization/images/imagemap-focus-ring-outline-color-explicitly-inherited-from-map-expected.png
Binary files differ
diff --git a/third_party/WebKit/LayoutTests/platform/linux/virtual/gpu-rasterization/images/imagemap-focus-ring-outline-color-not-inherited-from-map-expected.png b/third_party/WebKit/LayoutTests/platform/linux/virtual/gpu-rasterization/images/imagemap-focus-ring-outline-color-not-inherited-from-map-expected.png
index fe409d3..1751c4b 100644
--- a/third_party/WebKit/LayoutTests/platform/linux/virtual/gpu-rasterization/images/imagemap-focus-ring-outline-color-not-inherited-from-map-expected.png
+++ b/third_party/WebKit/LayoutTests/platform/linux/virtual/gpu-rasterization/images/imagemap-focus-ring-outline-color-not-inherited-from-map-expected.png
Binary files differ
diff --git a/third_party/WebKit/LayoutTests/platform/linux/virtual/gpu-rasterization/images/imagemap-focus-ring-zero-outline-width-expected.png b/third_party/WebKit/LayoutTests/platform/linux/virtual/gpu-rasterization/images/imagemap-focus-ring-zero-outline-width-expected.png
index d0b28f8..51ccf93 100644
--- a/third_party/WebKit/LayoutTests/platform/linux/virtual/gpu-rasterization/images/imagemap-focus-ring-zero-outline-width-expected.png
+++ b/third_party/WebKit/LayoutTests/platform/linux/virtual/gpu-rasterization/images/imagemap-focus-ring-zero-outline-width-expected.png
Binary files differ
diff --git a/third_party/WebKit/LayoutTests/platform/linux/virtual/gpu-rasterization/images/imagemap-focus-ring-zoom-expected.png b/third_party/WebKit/LayoutTests/platform/linux/virtual/gpu-rasterization/images/imagemap-focus-ring-zoom-expected.png
index cc4a581..d4d0a98 100644
--- a/third_party/WebKit/LayoutTests/platform/linux/virtual/gpu-rasterization/images/imagemap-focus-ring-zoom-expected.png
+++ b/third_party/WebKit/LayoutTests/platform/linux/virtual/gpu-rasterization/images/imagemap-focus-ring-zoom-expected.png
Binary files differ
diff --git a/third_party/WebKit/LayoutTests/platform/linux/virtual/gpu-rasterization/images/imagemap-overflowing-circle-focus-ring-expected.png b/third_party/WebKit/LayoutTests/platform/linux/virtual/gpu-rasterization/images/imagemap-overflowing-circle-focus-ring-expected.png
index c881b2d..c6223975 100644
--- a/third_party/WebKit/LayoutTests/platform/linux/virtual/gpu-rasterization/images/imagemap-overflowing-circle-focus-ring-expected.png
+++ b/third_party/WebKit/LayoutTests/platform/linux/virtual/gpu-rasterization/images/imagemap-overflowing-circle-focus-ring-expected.png
Binary files differ
diff --git a/third_party/WebKit/LayoutTests/platform/linux/virtual/gpu-rasterization/images/imagemap-overflowing-polygon-focus-ring-expected.png b/third_party/WebKit/LayoutTests/platform/linux/virtual/gpu-rasterization/images/imagemap-overflowing-polygon-focus-ring-expected.png
index 4dafe60c..ed41a17 100644
--- a/third_party/WebKit/LayoutTests/platform/linux/virtual/gpu-rasterization/images/imagemap-overflowing-polygon-focus-ring-expected.png
+++ b/third_party/WebKit/LayoutTests/platform/linux/virtual/gpu-rasterization/images/imagemap-overflowing-polygon-focus-ring-expected.png
Binary files differ
diff --git a/third_party/WebKit/LayoutTests/platform/linux/virtual/gpu-rasterization/images/imagemap-polygon-focus-ring-expected.png b/third_party/WebKit/LayoutTests/platform/linux/virtual/gpu-rasterization/images/imagemap-polygon-focus-ring-expected.png
index d6df29b7..232540fc 100644
--- a/third_party/WebKit/LayoutTests/platform/linux/virtual/gpu-rasterization/images/imagemap-polygon-focus-ring-expected.png
+++ b/third_party/WebKit/LayoutTests/platform/linux/virtual/gpu-rasterization/images/imagemap-polygon-focus-ring-expected.png
Binary files differ
diff --git a/third_party/WebKit/LayoutTests/platform/linux/virtual/layout_ng/fast/block/basic/019-expected.png b/third_party/WebKit/LayoutTests/platform/linux/virtual/layout_ng/fast/block/basic/019-expected.png
new file mode 100644
index 0000000..ec5f39d
--- /dev/null
+++ b/third_party/WebKit/LayoutTests/platform/linux/virtual/layout_ng/fast/block/basic/019-expected.png
Binary files differ
diff --git a/third_party/WebKit/LayoutTests/platform/linux/virtual/layout_ng/fast/block/basic/adding-near-anonymous-block-expected.png b/third_party/WebKit/LayoutTests/platform/linux/virtual/layout_ng/fast/block/basic/adding-near-anonymous-block-expected.png
new file mode 100644
index 0000000..bfa1bc1d
--- /dev/null
+++ b/third_party/WebKit/LayoutTests/platform/linux/virtual/layout_ng/fast/block/basic/adding-near-anonymous-block-expected.png
Binary files differ
diff --git a/third_party/WebKit/LayoutTests/platform/linux/virtual/layout_ng/fast/block/basic/text-indent-rtl-expected.png b/third_party/WebKit/LayoutTests/platform/linux/virtual/layout_ng/fast/block/basic/text-indent-rtl-expected.png
new file mode 100644
index 0000000..ea7d635f
--- /dev/null
+++ b/third_party/WebKit/LayoutTests/platform/linux/virtual/layout_ng/fast/block/basic/text-indent-rtl-expected.png
Binary files differ
diff --git a/third_party/WebKit/LayoutTests/platform/linux/virtual/layout_ng/fast/block/basic/truncation-rtl-expected.png b/third_party/WebKit/LayoutTests/platform/linux/virtual/layout_ng/fast/block/basic/truncation-rtl-expected.png
new file mode 100644
index 0000000..08de8a9
--- /dev/null
+++ b/third_party/WebKit/LayoutTests/platform/linux/virtual/layout_ng/fast/block/basic/truncation-rtl-expected.png
Binary files differ
diff --git a/third_party/WebKit/LayoutTests/platform/linux/virtual/layout_ng/fast/block/basic/white-space-pre-wraps-expected.png b/third_party/WebKit/LayoutTests/platform/linux/virtual/layout_ng/fast/block/basic/white-space-pre-wraps-expected.png
new file mode 100644
index 0000000..4cc8f847
--- /dev/null
+++ b/third_party/WebKit/LayoutTests/platform/linux/virtual/layout_ng/fast/block/basic/white-space-pre-wraps-expected.png
Binary files differ
diff --git a/third_party/WebKit/LayoutTests/platform/linux/virtual/layout_ng/fast/block/float/add-inline-between-floats-with-preceding-anonymous-box-expected.png b/third_party/WebKit/LayoutTests/platform/linux/virtual/layout_ng/fast/block/float/add-inline-between-floats-with-preceding-anonymous-box-expected.png
new file mode 100644
index 0000000..12f2ab2e
--- /dev/null
+++ b/third_party/WebKit/LayoutTests/platform/linux/virtual/layout_ng/fast/block/float/add-inline-between-floats-with-preceding-anonymous-box-expected.png
Binary files differ
diff --git a/third_party/WebKit/LayoutTests/platform/linux/virtual/layout_ng/fast/block/float/add-inline-to-block-flow-with-block-children-that-do-not-need-anonymous-boxes-expected.png b/third_party/WebKit/LayoutTests/platform/linux/virtual/layout_ng/fast/block/float/add-inline-to-block-flow-with-block-children-that-do-not-need-anonymous-boxes-expected.png
new file mode 100644
index 0000000..4646ec6
--- /dev/null
+++ b/third_party/WebKit/LayoutTests/platform/linux/virtual/layout_ng/fast/block/float/add-inline-to-block-flow-with-block-children-that-do-not-need-anonymous-boxes-expected.png
Binary files differ
diff --git a/third_party/WebKit/LayoutTests/platform/linux/virtual/layout_ng/fast/block/float/intruding-painted-twice-expected.png b/third_party/WebKit/LayoutTests/platform/linux/virtual/layout_ng/fast/block/float/intruding-painted-twice-expected.png
new file mode 100644
index 0000000..7ee2a49
--- /dev/null
+++ b/third_party/WebKit/LayoutTests/platform/linux/virtual/layout_ng/fast/block/float/intruding-painted-twice-expected.png
Binary files differ
diff --git a/third_party/WebKit/LayoutTests/platform/linux/virtual/layout_ng/fast/block/float/table-relayout-expected.png b/third_party/WebKit/LayoutTests/platform/linux/virtual/layout_ng/fast/block/float/table-relayout-expected.png
new file mode 100644
index 0000000..e2038ab
--- /dev/null
+++ b/third_party/WebKit/LayoutTests/platform/linux/virtual/layout_ng/fast/block/float/table-relayout-expected.png
Binary files differ
diff --git a/third_party/WebKit/LayoutTests/platform/linux/virtual/layout_ng/fast/block/float/vertical-move-relayout-expected.png b/third_party/WebKit/LayoutTests/platform/linux/virtual/layout_ng/fast/block/float/vertical-move-relayout-expected.png
new file mode 100644
index 0000000..33f13c13
--- /dev/null
+++ b/third_party/WebKit/LayoutTests/platform/linux/virtual/layout_ng/fast/block/float/vertical-move-relayout-expected.png
Binary files differ
diff --git a/third_party/WebKit/LayoutTests/platform/linux/virtual/mojo-loading/css1/basic/comments-expected.png b/third_party/WebKit/LayoutTests/platform/linux/virtual/mojo-loading/css1/basic/comments-expected.png
index 23e7fa2..a90477f 100644
--- a/third_party/WebKit/LayoutTests/platform/linux/virtual/mojo-loading/css1/basic/comments-expected.png
+++ b/third_party/WebKit/LayoutTests/platform/linux/virtual/mojo-loading/css1/basic/comments-expected.png
Binary files differ
diff --git a/third_party/WebKit/LayoutTests/platform/linux/virtual/mojo-loading/css1/basic/comments-expected.txt b/third_party/WebKit/LayoutTests/platform/linux/virtual/mojo-loading/css1/basic/comments-expected.txt
index 1a9619c..37d2e51 100644
--- a/third_party/WebKit/LayoutTests/platform/linux/virtual/mojo-loading/css1/basic/comments-expected.txt
+++ b/third_party/WebKit/LayoutTests/platform/linux/virtual/mojo-loading/css1/basic/comments-expected.txt
@@ -7,33 +7,33 @@
         LayoutText {#text} at (0,0) size 355x19
           text run at (0,0) width 355: "The style declarations which apply to the text below are:"
       LayoutBlockFlow {PRE} at (0,36) size 769x240
-        LayoutText {#text} at (0,0) size 334x240
-          text run at (0,0) width 230: "/* This is a CSS1 comment. */"
-          text run at (230,0) width 0: " "
-          text run at (0,16) width 334: ".one {color: green;} /* Another comment */"
-          text run at (334,16) width 0: " "
-          text run at (0,32) width 287: "/* The following should not be used:"
-          text run at (287,32) width 0: " "
-          text run at (0,48) width 167: ".two {color: red;} */"
-          text run at (167,48) width 0: " "
-          text run at (0,64) width 318: ".three {color: green; /* color: red; */}"
-          text run at (318,64) width 0: " "
-          text run at (0,80) width 22: "/**"
-          text run at (22,80) width 0: " "
-          text run at (0,96) width 175: ".four {color: red;} */"
-          text run at (175,96) width 0: " "
+        LayoutText {#text} at (0,0) size 336x240
+          text run at (0,0) width 232: "/* This is a CSS1 comment. */"
+          text run at (232,0) width 0: " "
+          text run at (0,16) width 336: ".one {color: green;} /* Another comment */"
+          text run at (336,16) width 0: " "
+          text run at (0,32) width 288: "/* The following should not be used:"
+          text run at (288,32) width 0: " "
+          text run at (0,48) width 168: ".two {color: red;} */"
+          text run at (168,48) width 0: " "
+          text run at (0,64) width 320: ".three {color: green; /* color: red; */}"
+          text run at (320,64) width 0: " "
+          text run at (0,80) width 24: "/**"
+          text run at (24,80) width 0: " "
+          text run at (0,96) width 176: ".four {color: red;} */"
+          text run at (176,96) width 0: " "
           text run at (0,112) width 168: ".five {color: green;}"
           text run at (168,112) width 0: " "
-          text run at (0,128) width 30: "/**/"
-          text run at (30,128) width 0: " "
+          text run at (0,128) width 32: "/**/"
+          text run at (32,128) width 0: " "
           text run at (0,144) width 160: ".six {color: green;}"
           text run at (160,144) width 0: " "
-          text run at (0,160) width 79: "/*********/"
-          text run at (79,160) width 0: " "
+          text run at (0,160) width 88: "/*********/"
+          text run at (88,160) width 0: " "
           text run at (0,176) width 176: ".seven {color: green;}"
           text run at (176,176) width 0: " "
-          text run at (0,192) width 125: "/* a comment **/"
-          text run at (125,192) width 0: " "
+          text run at (0,192) width 128: "/* a comment **/"
+          text run at (128,192) width 0: " "
           text run at (0,208) width 176: ".eight {color: green;}"
           text run at (176,208) width 0: " "
           text run at (0,224) width 0: " "
diff --git a/third_party/WebKit/LayoutTests/platform/linux/virtual/mojo-loading/css1/basic/containment-expected.png b/third_party/WebKit/LayoutTests/platform/linux/virtual/mojo-loading/css1/basic/containment-expected.png
index 94d55899..3175599 100644
--- a/third_party/WebKit/LayoutTests/platform/linux/virtual/mojo-loading/css1/basic/containment-expected.png
+++ b/third_party/WebKit/LayoutTests/platform/linux/virtual/mojo-loading/css1/basic/containment-expected.png
Binary files differ
diff --git a/third_party/WebKit/LayoutTests/platform/linux/virtual/mojo-loading/css1/basic/contextual_selectors-expected.png b/third_party/WebKit/LayoutTests/platform/linux/virtual/mojo-loading/css1/basic/contextual_selectors-expected.png
index 6112d6d..97690e2 100644
--- a/third_party/WebKit/LayoutTests/platform/linux/virtual/mojo-loading/css1/basic/contextual_selectors-expected.png
+++ b/third_party/WebKit/LayoutTests/platform/linux/virtual/mojo-loading/css1/basic/contextual_selectors-expected.png
Binary files differ
diff --git a/third_party/WebKit/LayoutTests/platform/linux/virtual/mojo-loading/css1/basic/grouping-expected.png b/third_party/WebKit/LayoutTests/platform/linux/virtual/mojo-loading/css1/basic/grouping-expected.png
index 6fa52bc5..13d7815 100644
--- a/third_party/WebKit/LayoutTests/platform/linux/virtual/mojo-loading/css1/basic/grouping-expected.png
+++ b/third_party/WebKit/LayoutTests/platform/linux/virtual/mojo-loading/css1/basic/grouping-expected.png
Binary files differ
diff --git a/third_party/WebKit/LayoutTests/platform/linux/virtual/mojo-loading/css1/basic/id_as_selector-expected.png b/third_party/WebKit/LayoutTests/platform/linux/virtual/mojo-loading/css1/basic/id_as_selector-expected.png
index 9a547898..967b12a 100644
--- a/third_party/WebKit/LayoutTests/platform/linux/virtual/mojo-loading/css1/basic/id_as_selector-expected.png
+++ b/third_party/WebKit/LayoutTests/platform/linux/virtual/mojo-loading/css1/basic/id_as_selector-expected.png
Binary files differ
diff --git a/third_party/WebKit/LayoutTests/platform/linux/virtual/mojo-loading/css1/basic/inheritance-expected.png b/third_party/WebKit/LayoutTests/platform/linux/virtual/mojo-loading/css1/basic/inheritance-expected.png
index 8afc076b..36fce52 100644
--- a/third_party/WebKit/LayoutTests/platform/linux/virtual/mojo-loading/css1/basic/inheritance-expected.png
+++ b/third_party/WebKit/LayoutTests/platform/linux/virtual/mojo-loading/css1/basic/inheritance-expected.png
Binary files differ
diff --git a/third_party/WebKit/LayoutTests/platform/linux/virtual/mojo-loading/css1/box_properties/border-expected.png b/third_party/WebKit/LayoutTests/platform/linux/virtual/mojo-loading/css1/box_properties/border-expected.png
index 662f8b08..72a9bb5 100644
--- a/third_party/WebKit/LayoutTests/platform/linux/virtual/mojo-loading/css1/box_properties/border-expected.png
+++ b/third_party/WebKit/LayoutTests/platform/linux/virtual/mojo-loading/css1/box_properties/border-expected.png
Binary files differ
diff --git a/third_party/WebKit/LayoutTests/platform/linux/virtual/mojo-loading/css1/box_properties/border_bottom-expected.png b/third_party/WebKit/LayoutTests/platform/linux/virtual/mojo-loading/css1/box_properties/border_bottom-expected.png
index fd606fa..d27a587 100644
--- a/third_party/WebKit/LayoutTests/platform/linux/virtual/mojo-loading/css1/box_properties/border_bottom-expected.png
+++ b/third_party/WebKit/LayoutTests/platform/linux/virtual/mojo-loading/css1/box_properties/border_bottom-expected.png
Binary files differ
diff --git a/third_party/WebKit/LayoutTests/platform/linux/virtual/mojo-loading/css1/box_properties/border_bottom_inline-expected.png b/third_party/WebKit/LayoutTests/platform/linux/virtual/mojo-loading/css1/box_properties/border_bottom_inline-expected.png
index 135de6e..3bc2598 100644
--- a/third_party/WebKit/LayoutTests/platform/linux/virtual/mojo-loading/css1/box_properties/border_bottom_inline-expected.png
+++ b/third_party/WebKit/LayoutTests/platform/linux/virtual/mojo-loading/css1/box_properties/border_bottom_inline-expected.png
Binary files differ
diff --git a/third_party/WebKit/LayoutTests/platform/linux/virtual/mojo-loading/css1/box_properties/border_bottom_width-expected.png b/third_party/WebKit/LayoutTests/platform/linux/virtual/mojo-loading/css1/box_properties/border_bottom_width-expected.png
index 3682aeb6..26248fd0 100644
--- a/third_party/WebKit/LayoutTests/platform/linux/virtual/mojo-loading/css1/box_properties/border_bottom_width-expected.png
+++ b/third_party/WebKit/LayoutTests/platform/linux/virtual/mojo-loading/css1/box_properties/border_bottom_width-expected.png
Binary files differ
diff --git a/third_party/WebKit/LayoutTests/platform/linux/virtual/mojo-loading/css1/box_properties/border_bottom_width_inline-expected.png b/third_party/WebKit/LayoutTests/platform/linux/virtual/mojo-loading/css1/box_properties/border_bottom_width_inline-expected.png
index 3ad65031..4e61d83e 100644
--- a/third_party/WebKit/LayoutTests/platform/linux/virtual/mojo-loading/css1/box_properties/border_bottom_width_inline-expected.png
+++ b/third_party/WebKit/LayoutTests/platform/linux/virtual/mojo-loading/css1/box_properties/border_bottom_width_inline-expected.png
Binary files differ
diff --git a/third_party/WebKit/LayoutTests/platform/linux/virtual/mojo-loading/css1/box_properties/border_color-expected.png b/third_party/WebKit/LayoutTests/platform/linux/virtual/mojo-loading/css1/box_properties/border_color-expected.png
index 34585c46..bdfef32a1 100644
--- a/third_party/WebKit/LayoutTests/platform/linux/virtual/mojo-loading/css1/box_properties/border_color-expected.png
+++ b/third_party/WebKit/LayoutTests/platform/linux/virtual/mojo-loading/css1/box_properties/border_color-expected.png
Binary files differ
diff --git a/third_party/WebKit/LayoutTests/platform/linux/virtual/mojo-loading/css1/box_properties/border_color_inline-expected.png b/third_party/WebKit/LayoutTests/platform/linux/virtual/mojo-loading/css1/box_properties/border_color_inline-expected.png
index 939bdfc7..c1275a3 100644
--- a/third_party/WebKit/LayoutTests/platform/linux/virtual/mojo-loading/css1/box_properties/border_color_inline-expected.png
+++ b/third_party/WebKit/LayoutTests/platform/linux/virtual/mojo-loading/css1/box_properties/border_color_inline-expected.png
Binary files differ
diff --git a/third_party/WebKit/LayoutTests/platform/linux/virtual/mojo-loading/css1/box_properties/border_inline-expected.png b/third_party/WebKit/LayoutTests/platform/linux/virtual/mojo-loading/css1/box_properties/border_inline-expected.png
index cd8a856..69627cc 100644
--- a/third_party/WebKit/LayoutTests/platform/linux/virtual/mojo-loading/css1/box_properties/border_inline-expected.png
+++ b/third_party/WebKit/LayoutTests/platform/linux/virtual/mojo-loading/css1/box_properties/border_inline-expected.png
Binary files differ
diff --git a/third_party/WebKit/LayoutTests/platform/linux/virtual/mojo-loading/css1/box_properties/border_left-expected.png b/third_party/WebKit/LayoutTests/platform/linux/virtual/mojo-loading/css1/box_properties/border_left-expected.png
index 801d4af..eca0a7f 100644
--- a/third_party/WebKit/LayoutTests/platform/linux/virtual/mojo-loading/css1/box_properties/border_left-expected.png
+++ b/third_party/WebKit/LayoutTests/platform/linux/virtual/mojo-loading/css1/box_properties/border_left-expected.png
Binary files differ
diff --git a/third_party/WebKit/LayoutTests/platform/linux/virtual/mojo-loading/css1/box_properties/border_left_inline-expected.png b/third_party/WebKit/LayoutTests/platform/linux/virtual/mojo-loading/css1/box_properties/border_left_inline-expected.png
index be4f28885..a229c84 100644
--- a/third_party/WebKit/LayoutTests/platform/linux/virtual/mojo-loading/css1/box_properties/border_left_inline-expected.png
+++ b/third_party/WebKit/LayoutTests/platform/linux/virtual/mojo-loading/css1/box_properties/border_left_inline-expected.png
Binary files differ
diff --git a/third_party/WebKit/LayoutTests/platform/linux/virtual/mojo-loading/css1/box_properties/border_left_width-expected.png b/third_party/WebKit/LayoutTests/platform/linux/virtual/mojo-loading/css1/box_properties/border_left_width-expected.png
index e891fbb..0b1197a 100644
--- a/third_party/WebKit/LayoutTests/platform/linux/virtual/mojo-loading/css1/box_properties/border_left_width-expected.png
+++ b/third_party/WebKit/LayoutTests/platform/linux/virtual/mojo-loading/css1/box_properties/border_left_width-expected.png
Binary files differ
diff --git a/third_party/WebKit/LayoutTests/platform/linux/virtual/mojo-loading/css1/box_properties/border_left_width_inline-expected.png b/third_party/WebKit/LayoutTests/platform/linux/virtual/mojo-loading/css1/box_properties/border_left_width_inline-expected.png
index 5b355e1..29c5264c 100644
--- a/third_party/WebKit/LayoutTests/platform/linux/virtual/mojo-loading/css1/box_properties/border_left_width_inline-expected.png
+++ b/third_party/WebKit/LayoutTests/platform/linux/virtual/mojo-loading/css1/box_properties/border_left_width_inline-expected.png
Binary files differ
diff --git a/third_party/WebKit/LayoutTests/platform/linux/virtual/mojo-loading/css1/box_properties/border_right-expected.png b/third_party/WebKit/LayoutTests/platform/linux/virtual/mojo-loading/css1/box_properties/border_right-expected.png
index 411890a..ba4205aa 100644
--- a/third_party/WebKit/LayoutTests/platform/linux/virtual/mojo-loading/css1/box_properties/border_right-expected.png
+++ b/third_party/WebKit/LayoutTests/platform/linux/virtual/mojo-loading/css1/box_properties/border_right-expected.png
Binary files differ
diff --git a/third_party/WebKit/LayoutTests/platform/linux/virtual/mojo-loading/css1/box_properties/border_right_inline-expected.png b/third_party/WebKit/LayoutTests/platform/linux/virtual/mojo-loading/css1/box_properties/border_right_inline-expected.png
index 0adb5f86..ce1af30d6 100644
--- a/third_party/WebKit/LayoutTests/platform/linux/virtual/mojo-loading/css1/box_properties/border_right_inline-expected.png
+++ b/third_party/WebKit/LayoutTests/platform/linux/virtual/mojo-loading/css1/box_properties/border_right_inline-expected.png
Binary files differ
diff --git a/third_party/WebKit/LayoutTests/platform/linux/virtual/mojo-loading/css1/box_properties/border_right_width-expected.png b/third_party/WebKit/LayoutTests/platform/linux/virtual/mojo-loading/css1/box_properties/border_right_width-expected.png
index 556a3db..18fc7139 100644
--- a/third_party/WebKit/LayoutTests/platform/linux/virtual/mojo-loading/css1/box_properties/border_right_width-expected.png
+++ b/third_party/WebKit/LayoutTests/platform/linux/virtual/mojo-loading/css1/box_properties/border_right_width-expected.png
Binary files differ
diff --git a/third_party/WebKit/LayoutTests/platform/linux/virtual/mojo-loading/css1/box_properties/border_right_width_inline-expected.png b/third_party/WebKit/LayoutTests/platform/linux/virtual/mojo-loading/css1/box_properties/border_right_width_inline-expected.png
index 3b983872..5a74601ad 100644
--- a/third_party/WebKit/LayoutTests/platform/linux/virtual/mojo-loading/css1/box_properties/border_right_width_inline-expected.png
+++ b/third_party/WebKit/LayoutTests/platform/linux/virtual/mojo-loading/css1/box_properties/border_right_width_inline-expected.png
Binary files differ
diff --git a/third_party/WebKit/LayoutTests/platform/linux/virtual/mojo-loading/css1/box_properties/border_style-expected.png b/third_party/WebKit/LayoutTests/platform/linux/virtual/mojo-loading/css1/box_properties/border_style-expected.png
index 5af001f..c58b397 100644
--- a/third_party/WebKit/LayoutTests/platform/linux/virtual/mojo-loading/css1/box_properties/border_style-expected.png
+++ b/third_party/WebKit/LayoutTests/platform/linux/virtual/mojo-loading/css1/box_properties/border_style-expected.png
Binary files differ
diff --git a/third_party/WebKit/LayoutTests/platform/linux/virtual/mojo-loading/css1/box_properties/border_style_inline-expected.png b/third_party/WebKit/LayoutTests/platform/linux/virtual/mojo-loading/css1/box_properties/border_style_inline-expected.png
index a6816bd0..a9daed61 100644
--- a/third_party/WebKit/LayoutTests/platform/linux/virtual/mojo-loading/css1/box_properties/border_style_inline-expected.png
+++ b/third_party/WebKit/LayoutTests/platform/linux/virtual/mojo-loading/css1/box_properties/border_style_inline-expected.png
Binary files differ
diff --git a/third_party/WebKit/LayoutTests/platform/linux/virtual/mojo-loading/css1/box_properties/border_top-expected.png b/third_party/WebKit/LayoutTests/platform/linux/virtual/mojo-loading/css1/box_properties/border_top-expected.png
index 6f92c67..f06c5ff 100644
--- a/third_party/WebKit/LayoutTests/platform/linux/virtual/mojo-loading/css1/box_properties/border_top-expected.png
+++ b/third_party/WebKit/LayoutTests/platform/linux/virtual/mojo-loading/css1/box_properties/border_top-expected.png
Binary files differ
diff --git a/third_party/WebKit/LayoutTests/platform/linux/virtual/mojo-loading/css1/box_properties/border_top_inline-expected.png b/third_party/WebKit/LayoutTests/platform/linux/virtual/mojo-loading/css1/box_properties/border_top_inline-expected.png
index 49cfc71..2324fb74 100644
--- a/third_party/WebKit/LayoutTests/platform/linux/virtual/mojo-loading/css1/box_properties/border_top_inline-expected.png
+++ b/third_party/WebKit/LayoutTests/platform/linux/virtual/mojo-loading/css1/box_properties/border_top_inline-expected.png
Binary files differ
diff --git a/third_party/WebKit/LayoutTests/platform/linux/virtual/mojo-loading/css1/box_properties/border_top_width-expected.png b/third_party/WebKit/LayoutTests/platform/linux/virtual/mojo-loading/css1/box_properties/border_top_width-expected.png
index 8a3c921..b263abe4 100644
--- a/third_party/WebKit/LayoutTests/platform/linux/virtual/mojo-loading/css1/box_properties/border_top_width-expected.png
+++ b/third_party/WebKit/LayoutTests/platform/linux/virtual/mojo-loading/css1/box_properties/border_top_width-expected.png
Binary files differ
diff --git a/third_party/WebKit/LayoutTests/platform/linux/virtual/mojo-loading/css1/box_properties/border_top_width_inline-expected.png b/third_party/WebKit/LayoutTests/platform/linux/virtual/mojo-loading/css1/box_properties/border_top_width_inline-expected.png
index 58f925f5..6e896ab 100644
--- a/third_party/WebKit/LayoutTests/platform/linux/virtual/mojo-loading/css1/box_properties/border_top_width_inline-expected.png
+++ b/third_party/WebKit/LayoutTests/platform/linux/virtual/mojo-loading/css1/box_properties/border_top_width_inline-expected.png
Binary files differ
diff --git a/third_party/WebKit/LayoutTests/platform/linux/virtual/mojo-loading/css1/box_properties/border_width-expected.png b/third_party/WebKit/LayoutTests/platform/linux/virtual/mojo-loading/css1/box_properties/border_width-expected.png
index 39084ba..05713d6 100644
--- a/third_party/WebKit/LayoutTests/platform/linux/virtual/mojo-loading/css1/box_properties/border_width-expected.png
+++ b/third_party/WebKit/LayoutTests/platform/linux/virtual/mojo-loading/css1/box_properties/border_width-expected.png
Binary files differ
diff --git a/third_party/WebKit/LayoutTests/platform/linux/virtual/mojo-loading/css1/box_properties/border_width_inline-expected.png b/third_party/WebKit/LayoutTests/platform/linux/virtual/mojo-loading/css1/box_properties/border_width_inline-expected.png
index 12761ab..f040266 100644
--- a/third_party/WebKit/LayoutTests/platform/linux/virtual/mojo-loading/css1/box_properties/border_width_inline-expected.png
+++ b/third_party/WebKit/LayoutTests/platform/linux/virtual/mojo-loading/css1/box_properties/border_width_inline-expected.png
Binary files differ
diff --git a/third_party/WebKit/LayoutTests/platform/linux/virtual/mojo-loading/css1/box_properties/clear-expected.png b/third_party/WebKit/LayoutTests/platform/linux/virtual/mojo-loading/css1/box_properties/clear-expected.png
index 4e76195..2fa89e0 100644
--- a/third_party/WebKit/LayoutTests/platform/linux/virtual/mojo-loading/css1/box_properties/clear-expected.png
+++ b/third_party/WebKit/LayoutTests/platform/linux/virtual/mojo-loading/css1/box_properties/clear-expected.png
Binary files differ
diff --git a/third_party/WebKit/LayoutTests/platform/linux/virtual/mojo-loading/css1/box_properties/clear_float-expected.png b/third_party/WebKit/LayoutTests/platform/linux/virtual/mojo-loading/css1/box_properties/clear_float-expected.png
index 17ed55a..9a2e9e2 100644
--- a/third_party/WebKit/LayoutTests/platform/linux/virtual/mojo-loading/css1/box_properties/clear_float-expected.png
+++ b/third_party/WebKit/LayoutTests/platform/linux/virtual/mojo-loading/css1/box_properties/clear_float-expected.png
Binary files differ
diff --git a/third_party/WebKit/LayoutTests/platform/linux/virtual/mojo-loading/css1/box_properties/float-expected.png b/third_party/WebKit/LayoutTests/platform/linux/virtual/mojo-loading/css1/box_properties/float-expected.png
index f0fc73e..145777c 100644
--- a/third_party/WebKit/LayoutTests/platform/linux/virtual/mojo-loading/css1/box_properties/float-expected.png
+++ b/third_party/WebKit/LayoutTests/platform/linux/virtual/mojo-loading/css1/box_properties/float-expected.png
Binary files differ
diff --git a/third_party/WebKit/LayoutTests/platform/linux/virtual/mojo-loading/css1/box_properties/float_elements_in_series-expected.png b/third_party/WebKit/LayoutTests/platform/linux/virtual/mojo-loading/css1/box_properties/float_elements_in_series-expected.png
index df19646..f0c1277 100644
--- a/third_party/WebKit/LayoutTests/platform/linux/virtual/mojo-loading/css1/box_properties/float_elements_in_series-expected.png
+++ b/third_party/WebKit/LayoutTests/platform/linux/virtual/mojo-loading/css1/box_properties/float_elements_in_series-expected.png
Binary files differ
diff --git a/third_party/WebKit/LayoutTests/platform/linux/virtual/mojo-loading/css1/box_properties/float_margin-expected.png b/third_party/WebKit/LayoutTests/platform/linux/virtual/mojo-loading/css1/box_properties/float_margin-expected.png
index 79c41cb5..74ce629 100644
--- a/third_party/WebKit/LayoutTests/platform/linux/virtual/mojo-loading/css1/box_properties/float_margin-expected.png
+++ b/third_party/WebKit/LayoutTests/platform/linux/virtual/mojo-loading/css1/box_properties/float_margin-expected.png
Binary files differ
diff --git a/third_party/WebKit/LayoutTests/platform/linux/virtual/mojo-loading/css1/box_properties/height-expected.png b/third_party/WebKit/LayoutTests/platform/linux/virtual/mojo-loading/css1/box_properties/height-expected.png
index 27f585d..5e1929e 100644
--- a/third_party/WebKit/LayoutTests/platform/linux/virtual/mojo-loading/css1/box_properties/height-expected.png
+++ b/third_party/WebKit/LayoutTests/platform/linux/virtual/mojo-loading/css1/box_properties/height-expected.png
Binary files differ
diff --git a/third_party/WebKit/LayoutTests/platform/linux/virtual/mojo-loading/css1/box_properties/margin-expected.png b/third_party/WebKit/LayoutTests/platform/linux/virtual/mojo-loading/css1/box_properties/margin-expected.png
index 37e79e0..cd498f5 100644
--- a/third_party/WebKit/LayoutTests/platform/linux/virtual/mojo-loading/css1/box_properties/margin-expected.png
+++ b/third_party/WebKit/LayoutTests/platform/linux/virtual/mojo-loading/css1/box_properties/margin-expected.png
Binary files differ
diff --git a/third_party/WebKit/LayoutTests/platform/linux/virtual/mojo-loading/css1/box_properties/margin_bottom-expected.png b/third_party/WebKit/LayoutTests/platform/linux/virtual/mojo-loading/css1/box_properties/margin_bottom-expected.png
index 6b1b5df..143704ee 100644
--- a/third_party/WebKit/LayoutTests/platform/linux/virtual/mojo-loading/css1/box_properties/margin_bottom-expected.png
+++ b/third_party/WebKit/LayoutTests/platform/linux/virtual/mojo-loading/css1/box_properties/margin_bottom-expected.png
Binary files differ
diff --git a/third_party/WebKit/LayoutTests/platform/linux/virtual/mojo-loading/css1/box_properties/margin_bottom_inline-expected.png b/third_party/WebKit/LayoutTests/platform/linux/virtual/mojo-loading/css1/box_properties/margin_bottom_inline-expected.png
index 37865481..9442667 100644
--- a/third_party/WebKit/LayoutTests/platform/linux/virtual/mojo-loading/css1/box_properties/margin_bottom_inline-expected.png
+++ b/third_party/WebKit/LayoutTests/platform/linux/virtual/mojo-loading/css1/box_properties/margin_bottom_inline-expected.png
Binary files differ
diff --git a/third_party/WebKit/LayoutTests/platform/linux/virtual/mojo-loading/css1/box_properties/margin_inline-expected.png b/third_party/WebKit/LayoutTests/platform/linux/virtual/mojo-loading/css1/box_properties/margin_inline-expected.png
index 84a91b5..8859390 100644
--- a/third_party/WebKit/LayoutTests/platform/linux/virtual/mojo-loading/css1/box_properties/margin_inline-expected.png
+++ b/third_party/WebKit/LayoutTests/platform/linux/virtual/mojo-loading/css1/box_properties/margin_inline-expected.png
Binary files differ
diff --git a/third_party/WebKit/LayoutTests/platform/linux/virtual/mojo-loading/css1/box_properties/margin_left-expected.png b/third_party/WebKit/LayoutTests/platform/linux/virtual/mojo-loading/css1/box_properties/margin_left-expected.png
index e6c414e..a154bf04 100644
--- a/third_party/WebKit/LayoutTests/platform/linux/virtual/mojo-loading/css1/box_properties/margin_left-expected.png
+++ b/third_party/WebKit/LayoutTests/platform/linux/virtual/mojo-loading/css1/box_properties/margin_left-expected.png
Binary files differ
diff --git a/third_party/WebKit/LayoutTests/platform/linux/virtual/mojo-loading/css1/box_properties/margin_left_inline-expected.png b/third_party/WebKit/LayoutTests/platform/linux/virtual/mojo-loading/css1/box_properties/margin_left_inline-expected.png
index fcdca9b..b075e90 100644
--- a/third_party/WebKit/LayoutTests/platform/linux/virtual/mojo-loading/css1/box_properties/margin_left_inline-expected.png
+++ b/third_party/WebKit/LayoutTests/platform/linux/virtual/mojo-loading/css1/box_properties/margin_left_inline-expected.png
Binary files differ
diff --git a/third_party/WebKit/LayoutTests/platform/linux/virtual/mojo-loading/css1/box_properties/margin_right-expected.png b/third_party/WebKit/LayoutTests/platform/linux/virtual/mojo-loading/css1/box_properties/margin_right-expected.png
index 2127a2e..8d65f88f 100644
--- a/third_party/WebKit/LayoutTests/platform/linux/virtual/mojo-loading/css1/box_properties/margin_right-expected.png
+++ b/third_party/WebKit/LayoutTests/platform/linux/virtual/mojo-loading/css1/box_properties/margin_right-expected.png
Binary files differ
diff --git a/third_party/WebKit/LayoutTests/platform/linux/virtual/mojo-loading/css1/box_properties/margin_right_inline-expected.png b/third_party/WebKit/LayoutTests/platform/linux/virtual/mojo-loading/css1/box_properties/margin_right_inline-expected.png
index 169fe1f..df781c4c 100644
--- a/third_party/WebKit/LayoutTests/platform/linux/virtual/mojo-loading/css1/box_properties/margin_right_inline-expected.png
+++ b/third_party/WebKit/LayoutTests/platform/linux/virtual/mojo-loading/css1/box_properties/margin_right_inline-expected.png
Binary files differ
diff --git a/third_party/WebKit/LayoutTests/platform/linux/virtual/mojo-loading/css1/box_properties/margin_top-expected.png b/third_party/WebKit/LayoutTests/platform/linux/virtual/mojo-loading/css1/box_properties/margin_top-expected.png
index bd492b89..9025be9 100644
--- a/third_party/WebKit/LayoutTests/platform/linux/virtual/mojo-loading/css1/box_properties/margin_top-expected.png
+++ b/third_party/WebKit/LayoutTests/platform/linux/virtual/mojo-loading/css1/box_properties/margin_top-expected.png
Binary files differ
diff --git a/third_party/WebKit/LayoutTests/platform/linux/virtual/mojo-loading/css1/box_properties/margin_top_inline-expected.png b/third_party/WebKit/LayoutTests/platform/linux/virtual/mojo-loading/css1/box_properties/margin_top_inline-expected.png
index 605907e..20c60324 100644
--- a/third_party/WebKit/LayoutTests/platform/linux/virtual/mojo-loading/css1/box_properties/margin_top_inline-expected.png
+++ b/third_party/WebKit/LayoutTests/platform/linux/virtual/mojo-loading/css1/box_properties/margin_top_inline-expected.png
Binary files differ
diff --git a/third_party/WebKit/LayoutTests/platform/linux/virtual/mojo-loading/css1/box_properties/padding-expected.png b/third_party/WebKit/LayoutTests/platform/linux/virtual/mojo-loading/css1/box_properties/padding-expected.png
index dda5abb..503ad58 100644
--- a/third_party/WebKit/LayoutTests/platform/linux/virtual/mojo-loading/css1/box_properties/padding-expected.png
+++ b/third_party/WebKit/LayoutTests/platform/linux/virtual/mojo-loading/css1/box_properties/padding-expected.png
Binary files differ
diff --git a/third_party/WebKit/LayoutTests/platform/linux/virtual/mojo-loading/css1/box_properties/padding_bottom-expected.png b/third_party/WebKit/LayoutTests/platform/linux/virtual/mojo-loading/css1/box_properties/padding_bottom-expected.png
index d2c47b3..f31c5e3 100644
--- a/third_party/WebKit/LayoutTests/platform/linux/virtual/mojo-loading/css1/box_properties/padding_bottom-expected.png
+++ b/third_party/WebKit/LayoutTests/platform/linux/virtual/mojo-loading/css1/box_properties/padding_bottom-expected.png
Binary files differ
diff --git a/third_party/WebKit/LayoutTests/platform/linux/virtual/mojo-loading/css1/box_properties/padding_bottom_inline-expected.png b/third_party/WebKit/LayoutTests/platform/linux/virtual/mojo-loading/css1/box_properties/padding_bottom_inline-expected.png
index ec7400f3..01823bf 100644
--- a/third_party/WebKit/LayoutTests/platform/linux/virtual/mojo-loading/css1/box_properties/padding_bottom_inline-expected.png
+++ b/third_party/WebKit/LayoutTests/platform/linux/virtual/mojo-loading/css1/box_properties/padding_bottom_inline-expected.png
Binary files differ
diff --git a/third_party/WebKit/LayoutTests/platform/linux/virtual/mojo-loading/css1/box_properties/padding_inline-expected.png b/third_party/WebKit/LayoutTests/platform/linux/virtual/mojo-loading/css1/box_properties/padding_inline-expected.png
index c9a0e64..4d33f7d 100644
--- a/third_party/WebKit/LayoutTests/platform/linux/virtual/mojo-loading/css1/box_properties/padding_inline-expected.png
+++ b/third_party/WebKit/LayoutTests/platform/linux/virtual/mojo-loading/css1/box_properties/padding_inline-expected.png
Binary files differ
diff --git a/third_party/WebKit/LayoutTests/platform/linux/virtual/mojo-loading/css1/box_properties/padding_left-expected.png b/third_party/WebKit/LayoutTests/platform/linux/virtual/mojo-loading/css1/box_properties/padding_left-expected.png
index d9c5350..d913fcf 100644
--- a/third_party/WebKit/LayoutTests/platform/linux/virtual/mojo-loading/css1/box_properties/padding_left-expected.png
+++ b/third_party/WebKit/LayoutTests/platform/linux/virtual/mojo-loading/css1/box_properties/padding_left-expected.png
Binary files differ
diff --git a/third_party/WebKit/LayoutTests/platform/linux/virtual/mojo-loading/css1/box_properties/padding_left_inline-expected.png b/third_party/WebKit/LayoutTests/platform/linux/virtual/mojo-loading/css1/box_properties/padding_left_inline-expected.png
index bd17bc7..e30e4e8 100644
--- a/third_party/WebKit/LayoutTests/platform/linux/virtual/mojo-loading/css1/box_properties/padding_left_inline-expected.png
+++ b/third_party/WebKit/LayoutTests/platform/linux/virtual/mojo-loading/css1/box_properties/padding_left_inline-expected.png
Binary files differ
diff --git a/third_party/WebKit/LayoutTests/platform/linux/virtual/mojo-loading/css1/box_properties/padding_right-expected.png b/third_party/WebKit/LayoutTests/platform/linux/virtual/mojo-loading/css1/box_properties/padding_right-expected.png
index dd7922b..9772efb3 100644
--- a/third_party/WebKit/LayoutTests/platform/linux/virtual/mojo-loading/css1/box_properties/padding_right-expected.png
+++ b/third_party/WebKit/LayoutTests/platform/linux/virtual/mojo-loading/css1/box_properties/padding_right-expected.png
Binary files differ
diff --git a/third_party/WebKit/LayoutTests/platform/linux/virtual/mojo-loading/css1/box_properties/padding_right_inline-expected.png b/third_party/WebKit/LayoutTests/platform/linux/virtual/mojo-loading/css1/box_properties/padding_right_inline-expected.png
index 64b1ebc..687ebfc 100644
--- a/third_party/WebKit/LayoutTests/platform/linux/virtual/mojo-loading/css1/box_properties/padding_right_inline-expected.png
+++ b/third_party/WebKit/LayoutTests/platform/linux/virtual/mojo-loading/css1/box_properties/padding_right_inline-expected.png
Binary files differ
diff --git a/third_party/WebKit/LayoutTests/platform/linux/virtual/mojo-loading/css1/box_properties/padding_top-expected.png b/third_party/WebKit/LayoutTests/platform/linux/virtual/mojo-loading/css1/box_properties/padding_top-expected.png
index 5dc6318..8a16987 100644
--- a/third_party/WebKit/LayoutTests/platform/linux/virtual/mojo-loading/css1/box_properties/padding_top-expected.png
+++ b/third_party/WebKit/LayoutTests/platform/linux/virtual/mojo-loading/css1/box_properties/padding_top-expected.png
Binary files differ
diff --git a/third_party/WebKit/LayoutTests/platform/linux/virtual/mojo-loading/css1/box_properties/padding_top_inline-expected.png b/third_party/WebKit/LayoutTests/platform/linux/virtual/mojo-loading/css1/box_properties/padding_top_inline-expected.png
index 958a292..7eaa7c7 100644
--- a/third_party/WebKit/LayoutTests/platform/linux/virtual/mojo-loading/css1/box_properties/padding_top_inline-expected.png
+++ b/third_party/WebKit/LayoutTests/platform/linux/virtual/mojo-loading/css1/box_properties/padding_top_inline-expected.png
Binary files differ
diff --git a/third_party/WebKit/LayoutTests/platform/linux/virtual/mojo-loading/css1/box_properties/width-expected.png b/third_party/WebKit/LayoutTests/platform/linux/virtual/mojo-loading/css1/box_properties/width-expected.png
index 093a8b9e..0cf4ab3 100644
--- a/third_party/WebKit/LayoutTests/platform/linux/virtual/mojo-loading/css1/box_properties/width-expected.png
+++ b/third_party/WebKit/LayoutTests/platform/linux/virtual/mojo-loading/css1/box_properties/width-expected.png
Binary files differ
diff --git a/third_party/WebKit/LayoutTests/platform/linux/virtual/mojo-loading/css1/cascade/cascade_order-expected.png b/third_party/WebKit/LayoutTests/platform/linux/virtual/mojo-loading/css1/cascade/cascade_order-expected.png
index dd5fab3..37baba9d 100644
--- a/third_party/WebKit/LayoutTests/platform/linux/virtual/mojo-loading/css1/cascade/cascade_order-expected.png
+++ b/third_party/WebKit/LayoutTests/platform/linux/virtual/mojo-loading/css1/cascade/cascade_order-expected.png
Binary files differ
diff --git a/third_party/WebKit/LayoutTests/platform/linux/virtual/mojo-loading/css1/cascade/important-expected.png b/third_party/WebKit/LayoutTests/platform/linux/virtual/mojo-loading/css1/cascade/important-expected.png
index 0c58c74..ddbf65eb 100644
--- a/third_party/WebKit/LayoutTests/platform/linux/virtual/mojo-loading/css1/cascade/important-expected.png
+++ b/third_party/WebKit/LayoutTests/platform/linux/virtual/mojo-loading/css1/cascade/important-expected.png
Binary files differ
diff --git a/third_party/WebKit/LayoutTests/platform/linux/virtual/mojo-loading/css1/classification/display-expected.png b/third_party/WebKit/LayoutTests/platform/linux/virtual/mojo-loading/css1/classification/display-expected.png
index be2308b..0735a99d 100644
--- a/third_party/WebKit/LayoutTests/platform/linux/virtual/mojo-loading/css1/classification/display-expected.png
+++ b/third_party/WebKit/LayoutTests/platform/linux/virtual/mojo-loading/css1/classification/display-expected.png
Binary files differ
diff --git a/third_party/WebKit/LayoutTests/platform/linux/virtual/mojo-loading/css1/classification/list_style-expected.png b/third_party/WebKit/LayoutTests/platform/linux/virtual/mojo-loading/css1/classification/list_style-expected.png
index 8af6f55..50397b4 100644
--- a/third_party/WebKit/LayoutTests/platform/linux/virtual/mojo-loading/css1/classification/list_style-expected.png
+++ b/third_party/WebKit/LayoutTests/platform/linux/virtual/mojo-loading/css1/classification/list_style-expected.png
Binary files differ
diff --git a/third_party/WebKit/LayoutTests/platform/linux/virtual/mojo-loading/css1/classification/list_style_image-expected.png b/third_party/WebKit/LayoutTests/platform/linux/virtual/mojo-loading/css1/classification/list_style_image-expected.png
index a64cb3185..fe5d4fd 100644
--- a/third_party/WebKit/LayoutTests/platform/linux/virtual/mojo-loading/css1/classification/list_style_image-expected.png
+++ b/third_party/WebKit/LayoutTests/platform/linux/virtual/mojo-loading/css1/classification/list_style_image-expected.png
Binary files differ
diff --git a/third_party/WebKit/LayoutTests/platform/linux/virtual/mojo-loading/css1/classification/list_style_position-expected.png b/third_party/WebKit/LayoutTests/platform/linux/virtual/mojo-loading/css1/classification/list_style_position-expected.png
index cf3bd14..44839a39 100644
--- a/third_party/WebKit/LayoutTests/platform/linux/virtual/mojo-loading/css1/classification/list_style_position-expected.png
+++ b/third_party/WebKit/LayoutTests/platform/linux/virtual/mojo-loading/css1/classification/list_style_position-expected.png
Binary files differ
diff --git a/third_party/WebKit/LayoutTests/platform/linux/virtual/mojo-loading/css1/classification/list_style_type-expected.png b/third_party/WebKit/LayoutTests/platform/linux/virtual/mojo-loading/css1/classification/list_style_type-expected.png
index 0b2ec471..2443af0 100644
--- a/third_party/WebKit/LayoutTests/platform/linux/virtual/mojo-loading/css1/classification/list_style_type-expected.png
+++ b/third_party/WebKit/LayoutTests/platform/linux/virtual/mojo-loading/css1/classification/list_style_type-expected.png
Binary files differ
diff --git a/third_party/WebKit/LayoutTests/platform/linux/virtual/mojo-loading/css1/classification/white_space-expected.png b/third_party/WebKit/LayoutTests/platform/linux/virtual/mojo-loading/css1/classification/white_space-expected.png
index cee3d70..b365602 100644
--- a/third_party/WebKit/LayoutTests/platform/linux/virtual/mojo-loading/css1/classification/white_space-expected.png
+++ b/third_party/WebKit/LayoutTests/platform/linux/virtual/mojo-loading/css1/classification/white_space-expected.png
Binary files differ
diff --git a/third_party/WebKit/LayoutTests/platform/linux/virtual/mojo-loading/css1/color_and_background/background-expected.png b/third_party/WebKit/LayoutTests/platform/linux/virtual/mojo-loading/css1/color_and_background/background-expected.png
index 6c1a350b..089897e 100644
--- a/third_party/WebKit/LayoutTests/platform/linux/virtual/mojo-loading/css1/color_and_background/background-expected.png
+++ b/third_party/WebKit/LayoutTests/platform/linux/virtual/mojo-loading/css1/color_and_background/background-expected.png
Binary files differ
diff --git a/third_party/WebKit/LayoutTests/platform/linux/virtual/mojo-loading/css1/color_and_background/background_attachment-expected.png b/third_party/WebKit/LayoutTests/platform/linux/virtual/mojo-loading/css1/color_and_background/background_attachment-expected.png
index 74f6c50..b660bb6 100644
--- a/third_party/WebKit/LayoutTests/platform/linux/virtual/mojo-loading/css1/color_and_background/background_attachment-expected.png
+++ b/third_party/WebKit/LayoutTests/platform/linux/virtual/mojo-loading/css1/color_and_background/background_attachment-expected.png
Binary files differ
diff --git a/third_party/WebKit/LayoutTests/platform/linux/virtual/mojo-loading/css1/color_and_background/background_color-expected.png b/third_party/WebKit/LayoutTests/platform/linux/virtual/mojo-loading/css1/color_and_background/background_color-expected.png
index 6782702..9637cf72 100644
--- a/third_party/WebKit/LayoutTests/platform/linux/virtual/mojo-loading/css1/color_and_background/background_color-expected.png
+++ b/third_party/WebKit/LayoutTests/platform/linux/virtual/mojo-loading/css1/color_and_background/background_color-expected.png
Binary files differ
diff --git a/third_party/WebKit/LayoutTests/platform/linux/virtual/mojo-loading/css1/color_and_background/background_image-expected.png b/third_party/WebKit/LayoutTests/platform/linux/virtual/mojo-loading/css1/color_and_background/background_image-expected.png
index 46b0989..2f8cdc8 100644
--- a/third_party/WebKit/LayoutTests/platform/linux/virtual/mojo-loading/css1/color_and_background/background_image-expected.png
+++ b/third_party/WebKit/LayoutTests/platform/linux/virtual/mojo-loading/css1/color_and_background/background_image-expected.png
Binary files differ
diff --git a/third_party/WebKit/LayoutTests/platform/linux/virtual/mojo-loading/css1/color_and_background/background_position-expected.png b/third_party/WebKit/LayoutTests/platform/linux/virtual/mojo-loading/css1/color_and_background/background_position-expected.png
new file mode 100644
index 0000000..df4cca7
--- /dev/null
+++ b/third_party/WebKit/LayoutTests/platform/linux/virtual/mojo-loading/css1/color_and_background/background_position-expected.png
Binary files differ
diff --git a/third_party/WebKit/LayoutTests/platform/linux/virtual/mojo-loading/css1/color_and_background/background_repeat-expected.png b/third_party/WebKit/LayoutTests/platform/linux/virtual/mojo-loading/css1/color_and_background/background_repeat-expected.png
index af1364cb3..6925281 100644
--- a/third_party/WebKit/LayoutTests/platform/linux/virtual/mojo-loading/css1/color_and_background/background_repeat-expected.png
+++ b/third_party/WebKit/LayoutTests/platform/linux/virtual/mojo-loading/css1/color_and_background/background_repeat-expected.png
Binary files differ
diff --git a/third_party/WebKit/LayoutTests/platform/linux/virtual/mojo-loading/css1/color_and_background/color-expected.png b/third_party/WebKit/LayoutTests/platform/linux/virtual/mojo-loading/css1/color_and_background/color-expected.png
index 53cba51..5dbe7d03 100644
--- a/third_party/WebKit/LayoutTests/platform/linux/virtual/mojo-loading/css1/color_and_background/color-expected.png
+++ b/third_party/WebKit/LayoutTests/platform/linux/virtual/mojo-loading/css1/color_and_background/color-expected.png
Binary files differ
diff --git a/third_party/WebKit/LayoutTests/platform/linux/virtual/mojo-loading/css1/conformance/forward_compatible_parsing-expected.png b/third_party/WebKit/LayoutTests/platform/linux/virtual/mojo-loading/css1/conformance/forward_compatible_parsing-expected.png
index 9f2d41e..5eebe27 100644
--- a/third_party/WebKit/LayoutTests/platform/linux/virtual/mojo-loading/css1/conformance/forward_compatible_parsing-expected.png
+++ b/third_party/WebKit/LayoutTests/platform/linux/virtual/mojo-loading/css1/conformance/forward_compatible_parsing-expected.png
Binary files differ
diff --git a/third_party/WebKit/LayoutTests/platform/linux/virtual/mojo-loading/css1/conformance/forward_compatible_parsing-expected.txt b/third_party/WebKit/LayoutTests/platform/linux/virtual/mojo-loading/css1/conformance/forward_compatible_parsing-expected.txt
index 66ce4051..4972027 100644
--- a/third_party/WebKit/LayoutTests/platform/linux/virtual/mojo-loading/css1/conformance/forward_compatible_parsing-expected.txt
+++ b/third_party/WebKit/LayoutTests/platform/linux/virtual/mojo-loading/css1/conformance/forward_compatible_parsing-expected.txt
@@ -92,12 +92,12 @@
           text run at (0,656) width 0: " "
           text run at (0,672) width 360: "P.twentya {rotation-code: \"}\"; color: blue;} "
           text run at (360,672) width 0: " "
-          text run at (0,688) width 390: "P.twentyb {rotation-code: \"\\\"}\\\"\"; color: green;}"
-          text run at (390,688) width 0: " "
+          text run at (0,688) width 392: "P.twentyb {rotation-code: \"\\\"}\\\"\"; color: green;}"
+          text run at (392,688) width 0: " "
           text run at (0,704) width 400: "P.twentyonea {rotation-code: '}'; color: purple;} "
           text run at (400,704) width 0: " "
-          text run at (0,720) width 414: "P.twentyoneb {rotation-code: '\\'}\\''; color: green;}"
-          text run at (414,720) width 0: " "
+          text run at (0,720) width 416: "P.twentyoneb {rotation-code: '\\'}\\''; color: green;}"
+          text run at (416,720) width 0: " "
           text run at (0,736) width 104: "P.twentytwo {"
           text run at (104,736) width 0: " "
           text run at (0,752) width 376: " type-display: @threedee {rotation-code: '}';};"
diff --git a/third_party/WebKit/LayoutTests/platform/linux/virtual/mojo-loading/css1/font_properties/font-expected.png b/third_party/WebKit/LayoutTests/platform/linux/virtual/mojo-loading/css1/font_properties/font-expected.png
index 6448fda9..2fedb21 100644
--- a/third_party/WebKit/LayoutTests/platform/linux/virtual/mojo-loading/css1/font_properties/font-expected.png
+++ b/third_party/WebKit/LayoutTests/platform/linux/virtual/mojo-loading/css1/font_properties/font-expected.png
Binary files differ
diff --git a/third_party/WebKit/LayoutTests/platform/linux/virtual/mojo-loading/css1/font_properties/font-expected.txt b/third_party/WebKit/LayoutTests/platform/linux/virtual/mojo-loading/css1/font_properties/font-expected.txt
index d28ccd4..b33bc94 100644
--- a/third_party/WebKit/LayoutTests/platform/linux/virtual/mojo-loading/css1/font_properties/font-expected.txt
+++ b/third_party/WebKit/LayoutTests/platform/linux/virtual/mojo-loading/css1/font_properties/font-expected.txt
@@ -8,8 +8,8 @@
           text run at (0,0) width 264: "The style declarations which apply to the text below are:"
       LayoutBlockFlow {PRE} at (0,28) size 769x180
         LayoutText {#text} at (0,0) size 399x180
-          text run at (0,0) width 162: "BODY {font-size: 12px;}"
-          text run at (162,0) width 0: " "
+          text run at (0,0) width 161: "BODY {font-size: 12px;}"
+          text run at (161,0) width 0: " "
           text run at (0,15) width 322: ".one {font: italic small-caps 13pt Helvetica;}"
           text run at (322,15) width 0: " "
           text run at (0,30) width 203: ".two {font: 150%/150% serif;}"
diff --git a/third_party/WebKit/LayoutTests/platform/linux/virtual/mojo-loading/css1/font_properties/font_family-expected.png b/third_party/WebKit/LayoutTests/platform/linux/virtual/mojo-loading/css1/font_properties/font_family-expected.png
index 440a9ee..9c2375bd 100644
--- a/third_party/WebKit/LayoutTests/platform/linux/virtual/mojo-loading/css1/font_properties/font_family-expected.png
+++ b/third_party/WebKit/LayoutTests/platform/linux/virtual/mojo-loading/css1/font_properties/font_family-expected.png
Binary files differ
diff --git a/third_party/WebKit/LayoutTests/platform/linux/virtual/mojo-loading/css1/font_properties/font_size-expected.png b/third_party/WebKit/LayoutTests/platform/linux/virtual/mojo-loading/css1/font_properties/font_size-expected.png
index 66b91c9..77bb07f 100644
--- a/third_party/WebKit/LayoutTests/platform/linux/virtual/mojo-loading/css1/font_properties/font_size-expected.png
+++ b/third_party/WebKit/LayoutTests/platform/linux/virtual/mojo-loading/css1/font_properties/font_size-expected.png
Binary files differ
diff --git a/third_party/WebKit/LayoutTests/platform/linux/virtual/mojo-loading/css1/font_properties/font_style-expected.png b/third_party/WebKit/LayoutTests/platform/linux/virtual/mojo-loading/css1/font_properties/font_style-expected.png
index a1daaf4..33e7506 100644
--- a/third_party/WebKit/LayoutTests/platform/linux/virtual/mojo-loading/css1/font_properties/font_style-expected.png
+++ b/third_party/WebKit/LayoutTests/platform/linux/virtual/mojo-loading/css1/font_properties/font_style-expected.png
Binary files differ
diff --git a/third_party/WebKit/LayoutTests/platform/linux/virtual/mojo-loading/css1/font_properties/font_variant-expected.png b/third_party/WebKit/LayoutTests/platform/linux/virtual/mojo-loading/css1/font_properties/font_variant-expected.png
index feb15da7..c45818c4 100644
--- a/third_party/WebKit/LayoutTests/platform/linux/virtual/mojo-loading/css1/font_properties/font_variant-expected.png
+++ b/third_party/WebKit/LayoutTests/platform/linux/virtual/mojo-loading/css1/font_properties/font_variant-expected.png
Binary files differ
diff --git a/third_party/WebKit/LayoutTests/platform/linux/virtual/mojo-loading/css1/font_properties/font_weight-expected.png b/third_party/WebKit/LayoutTests/platform/linux/virtual/mojo-loading/css1/font_properties/font_weight-expected.png
index 5dee9b5e..227a2b5 100644
--- a/third_party/WebKit/LayoutTests/platform/linux/virtual/mojo-loading/css1/font_properties/font_weight-expected.png
+++ b/third_party/WebKit/LayoutTests/platform/linux/virtual/mojo-loading/css1/font_properties/font_weight-expected.png
Binary files differ
diff --git a/third_party/WebKit/LayoutTests/platform/linux/virtual/mojo-loading/css1/formatting_model/canvas-expected.png b/third_party/WebKit/LayoutTests/platform/linux/virtual/mojo-loading/css1/formatting_model/canvas-expected.png
new file mode 100644
index 0000000..a02bac0
--- /dev/null
+++ b/third_party/WebKit/LayoutTests/platform/linux/virtual/mojo-loading/css1/formatting_model/canvas-expected.png
Binary files differ
diff --git a/third_party/WebKit/LayoutTests/platform/linux/virtual/mojo-loading/css1/formatting_model/floating_elements-expected.png b/third_party/WebKit/LayoutTests/platform/linux/virtual/mojo-loading/css1/formatting_model/floating_elements-expected.png
index ca1bef1..a7eeb697 100644
--- a/third_party/WebKit/LayoutTests/platform/linux/virtual/mojo-loading/css1/formatting_model/floating_elements-expected.png
+++ b/third_party/WebKit/LayoutTests/platform/linux/virtual/mojo-loading/css1/formatting_model/floating_elements-expected.png
Binary files differ
diff --git a/third_party/WebKit/LayoutTests/platform/linux/virtual/mojo-loading/css1/formatting_model/height_of_lines-expected.png b/third_party/WebKit/LayoutTests/platform/linux/virtual/mojo-loading/css1/formatting_model/height_of_lines-expected.png
index 89f146c..320b7fcd 100644
--- a/third_party/WebKit/LayoutTests/platform/linux/virtual/mojo-loading/css1/formatting_model/height_of_lines-expected.png
+++ b/third_party/WebKit/LayoutTests/platform/linux/virtual/mojo-loading/css1/formatting_model/height_of_lines-expected.png
Binary files differ
diff --git a/third_party/WebKit/LayoutTests/platform/linux/virtual/mojo-loading/css1/formatting_model/inline_elements-expected.png b/third_party/WebKit/LayoutTests/platform/linux/virtual/mojo-loading/css1/formatting_model/inline_elements-expected.png
index b4f0984b..9ee24fb7 100644
--- a/third_party/WebKit/LayoutTests/platform/linux/virtual/mojo-loading/css1/formatting_model/inline_elements-expected.png
+++ b/third_party/WebKit/LayoutTests/platform/linux/virtual/mojo-loading/css1/formatting_model/inline_elements-expected.png
Binary files differ
diff --git a/third_party/WebKit/LayoutTests/platform/linux/virtual/mojo-loading/css1/formatting_model/replaced_elements-expected.png b/third_party/WebKit/LayoutTests/platform/linux/virtual/mojo-loading/css1/formatting_model/replaced_elements-expected.png
index 4a07bd70..c2dfaa2 100644
--- a/third_party/WebKit/LayoutTests/platform/linux/virtual/mojo-loading/css1/formatting_model/replaced_elements-expected.png
+++ b/third_party/WebKit/LayoutTests/platform/linux/virtual/mojo-loading/css1/formatting_model/replaced_elements-expected.png
Binary files differ
diff --git a/third_party/WebKit/LayoutTests/platform/linux/virtual/mojo-loading/css1/formatting_model/vertical_formatting-expected.png b/third_party/WebKit/LayoutTests/platform/linux/virtual/mojo-loading/css1/formatting_model/vertical_formatting-expected.png
index 3157dee5..7a7b891 100644
--- a/third_party/WebKit/LayoutTests/platform/linux/virtual/mojo-loading/css1/formatting_model/vertical_formatting-expected.png
+++ b/third_party/WebKit/LayoutTests/platform/linux/virtual/mojo-loading/css1/formatting_model/vertical_formatting-expected.png
Binary files differ
diff --git a/third_party/WebKit/LayoutTests/platform/linux/virtual/mojo-loading/css1/pseudo/anchor-expected.png b/third_party/WebKit/LayoutTests/platform/linux/virtual/mojo-loading/css1/pseudo/anchor-expected.png
index fc66848f..b4e611b 100644
--- a/third_party/WebKit/LayoutTests/platform/linux/virtual/mojo-loading/css1/pseudo/anchor-expected.png
+++ b/third_party/WebKit/LayoutTests/platform/linux/virtual/mojo-loading/css1/pseudo/anchor-expected.png
Binary files differ
diff --git a/third_party/WebKit/LayoutTests/platform/linux/virtual/mojo-loading/css1/pseudo/firstletter-expected.png b/third_party/WebKit/LayoutTests/platform/linux/virtual/mojo-loading/css1/pseudo/firstletter-expected.png
index 9efadaaf..508325c6 100644
--- a/third_party/WebKit/LayoutTests/platform/linux/virtual/mojo-loading/css1/pseudo/firstletter-expected.png
+++ b/third_party/WebKit/LayoutTests/platform/linux/virtual/mojo-loading/css1/pseudo/firstletter-expected.png
Binary files differ
diff --git a/third_party/WebKit/LayoutTests/platform/linux/virtual/mojo-loading/css1/pseudo/firstline-expected.png b/third_party/WebKit/LayoutTests/platform/linux/virtual/mojo-loading/css1/pseudo/firstline-expected.png
index cbb0334..8fb0e49 100644
--- a/third_party/WebKit/LayoutTests/platform/linux/virtual/mojo-loading/css1/pseudo/firstline-expected.png
+++ b/third_party/WebKit/LayoutTests/platform/linux/virtual/mojo-loading/css1/pseudo/firstline-expected.png
Binary files differ
diff --git a/third_party/WebKit/LayoutTests/platform/linux/virtual/mojo-loading/css1/pseudo/multiple_pseudo_elements-expected.png b/third_party/WebKit/LayoutTests/platform/linux/virtual/mojo-loading/css1/pseudo/multiple_pseudo_elements-expected.png
index 8bcc5127..2113b53 100644
--- a/third_party/WebKit/LayoutTests/platform/linux/virtual/mojo-loading/css1/pseudo/multiple_pseudo_elements-expected.png
+++ b/third_party/WebKit/LayoutTests/platform/linux/virtual/mojo-loading/css1/pseudo/multiple_pseudo_elements-expected.png
Binary files differ
diff --git a/third_party/WebKit/LayoutTests/platform/linux/virtual/mojo-loading/css1/pseudo/pseudo_elements_in_selectors-expected.png b/third_party/WebKit/LayoutTests/platform/linux/virtual/mojo-loading/css1/pseudo/pseudo_elements_in_selectors-expected.png
index 8eb7716a..33e24d83 100644
--- a/third_party/WebKit/LayoutTests/platform/linux/virtual/mojo-loading/css1/pseudo/pseudo_elements_in_selectors-expected.png
+++ b/third_party/WebKit/LayoutTests/platform/linux/virtual/mojo-loading/css1/pseudo/pseudo_elements_in_selectors-expected.png
Binary files differ
diff --git a/third_party/WebKit/LayoutTests/platform/linux/virtual/mojo-loading/css1/text_properties/letter_spacing-expected.png b/third_party/WebKit/LayoutTests/platform/linux/virtual/mojo-loading/css1/text_properties/letter_spacing-expected.png
index 576b99d..3656028 100644
--- a/third_party/WebKit/LayoutTests/platform/linux/virtual/mojo-loading/css1/text_properties/letter_spacing-expected.png
+++ b/third_party/WebKit/LayoutTests/platform/linux/virtual/mojo-loading/css1/text_properties/letter_spacing-expected.png
Binary files differ
diff --git a/third_party/WebKit/LayoutTests/platform/linux/virtual/mojo-loading/css1/text_properties/line_height-expected.png b/third_party/WebKit/LayoutTests/platform/linux/virtual/mojo-loading/css1/text_properties/line_height-expected.png
index 4539f37..7fa6c3d3 100644
--- a/third_party/WebKit/LayoutTests/platform/linux/virtual/mojo-loading/css1/text_properties/line_height-expected.png
+++ b/third_party/WebKit/LayoutTests/platform/linux/virtual/mojo-loading/css1/text_properties/line_height-expected.png
Binary files differ
diff --git a/third_party/WebKit/LayoutTests/platform/linux/virtual/mojo-loading/css1/text_properties/text_align-expected.png b/third_party/WebKit/LayoutTests/platform/linux/virtual/mojo-loading/css1/text_properties/text_align-expected.png
index 435c1c4..f3c86e42 100644
--- a/third_party/WebKit/LayoutTests/platform/linux/virtual/mojo-loading/css1/text_properties/text_align-expected.png
+++ b/third_party/WebKit/LayoutTests/platform/linux/virtual/mojo-loading/css1/text_properties/text_align-expected.png
Binary files differ
diff --git a/third_party/WebKit/LayoutTests/platform/linux/virtual/mojo-loading/css1/text_properties/text_decoration-expected.png b/third_party/WebKit/LayoutTests/platform/linux/virtual/mojo-loading/css1/text_properties/text_decoration-expected.png
index 7fd474f..cf6624d 100644
--- a/third_party/WebKit/LayoutTests/platform/linux/virtual/mojo-loading/css1/text_properties/text_decoration-expected.png
+++ b/third_party/WebKit/LayoutTests/platform/linux/virtual/mojo-loading/css1/text_properties/text_decoration-expected.png
Binary files differ
diff --git a/third_party/WebKit/LayoutTests/platform/linux/virtual/mojo-loading/css1/text_properties/text_indent-expected.png b/third_party/WebKit/LayoutTests/platform/linux/virtual/mojo-loading/css1/text_properties/text_indent-expected.png
index af717e6..bac5342 100644
--- a/third_party/WebKit/LayoutTests/platform/linux/virtual/mojo-loading/css1/text_properties/text_indent-expected.png
+++ b/third_party/WebKit/LayoutTests/platform/linux/virtual/mojo-loading/css1/text_properties/text_indent-expected.png
Binary files differ
diff --git a/third_party/WebKit/LayoutTests/platform/linux/virtual/mojo-loading/css1/text_properties/text_transform-expected.png b/third_party/WebKit/LayoutTests/platform/linux/virtual/mojo-loading/css1/text_properties/text_transform-expected.png
index fb73520..4074ca7e 100644
--- a/third_party/WebKit/LayoutTests/platform/linux/virtual/mojo-loading/css1/text_properties/text_transform-expected.png
+++ b/third_party/WebKit/LayoutTests/platform/linux/virtual/mojo-loading/css1/text_properties/text_transform-expected.png
Binary files differ
diff --git a/third_party/WebKit/LayoutTests/platform/linux/virtual/mojo-loading/css1/text_properties/vertical_align-expected.png b/third_party/WebKit/LayoutTests/platform/linux/virtual/mojo-loading/css1/text_properties/vertical_align-expected.png
index 8e08d880..8b69dd9 100644
--- a/third_party/WebKit/LayoutTests/platform/linux/virtual/mojo-loading/css1/text_properties/vertical_align-expected.png
+++ b/third_party/WebKit/LayoutTests/platform/linux/virtual/mojo-loading/css1/text_properties/vertical_align-expected.png
Binary files differ
diff --git a/third_party/WebKit/LayoutTests/platform/linux/virtual/mojo-loading/css1/text_properties/word_spacing-expected.png b/third_party/WebKit/LayoutTests/platform/linux/virtual/mojo-loading/css1/text_properties/word_spacing-expected.png
index 140efd6..badd717a 100644
--- a/third_party/WebKit/LayoutTests/platform/linux/virtual/mojo-loading/css1/text_properties/word_spacing-expected.png
+++ b/third_party/WebKit/LayoutTests/platform/linux/virtual/mojo-loading/css1/text_properties/word_spacing-expected.png
Binary files differ
diff --git a/third_party/WebKit/LayoutTests/platform/linux/virtual/mojo-loading/css1/units/color_units-expected.png b/third_party/WebKit/LayoutTests/platform/linux/virtual/mojo-loading/css1/units/color_units-expected.png
index e768313..f4bae11 100644
--- a/third_party/WebKit/LayoutTests/platform/linux/virtual/mojo-loading/css1/units/color_units-expected.png
+++ b/third_party/WebKit/LayoutTests/platform/linux/virtual/mojo-loading/css1/units/color_units-expected.png
Binary files differ
diff --git a/third_party/WebKit/LayoutTests/platform/linux/virtual/mojo-loading/css1/units/length_units-expected.png b/third_party/WebKit/LayoutTests/platform/linux/virtual/mojo-loading/css1/units/length_units-expected.png
index 92bab55..88cfcd4 100644
--- a/third_party/WebKit/LayoutTests/platform/linux/virtual/mojo-loading/css1/units/length_units-expected.png
+++ b/third_party/WebKit/LayoutTests/platform/linux/virtual/mojo-loading/css1/units/length_units-expected.png
Binary files differ
diff --git a/third_party/WebKit/LayoutTests/platform/linux/virtual/mojo-loading/css1/units/percentage_units-expected.png b/third_party/WebKit/LayoutTests/platform/linux/virtual/mojo-loading/css1/units/percentage_units-expected.png
index c77e636..05f2895 100644
--- a/third_party/WebKit/LayoutTests/platform/linux/virtual/mojo-loading/css1/units/percentage_units-expected.png
+++ b/third_party/WebKit/LayoutTests/platform/linux/virtual/mojo-loading/css1/units/percentage_units-expected.png
Binary files differ
diff --git a/third_party/WebKit/LayoutTests/platform/linux/virtual/mojo-loading/css1/units/urls-expected.png b/third_party/WebKit/LayoutTests/platform/linux/virtual/mojo-loading/css1/units/urls-expected.png
new file mode 100644
index 0000000..6c22c11
--- /dev/null
+++ b/third_party/WebKit/LayoutTests/platform/linux/virtual/mojo-loading/css1/units/urls-expected.png
Binary files differ
diff --git a/third_party/WebKit/LayoutTests/platform/linux/virtual/mojo-loading/fast/table/018-expected.png b/third_party/WebKit/LayoutTests/platform/linux/virtual/mojo-loading/fast/table/018-expected.png
new file mode 100644
index 0000000..f280ad41
--- /dev/null
+++ b/third_party/WebKit/LayoutTests/platform/linux/virtual/mojo-loading/fast/table/018-expected.png
Binary files differ
diff --git a/third_party/WebKit/LayoutTests/platform/linux/virtual/mojo-loading/fast/table/100-percent-cell-width-expected.png b/third_party/WebKit/LayoutTests/platform/linux/virtual/mojo-loading/fast/table/100-percent-cell-width-expected.png
new file mode 100644
index 0000000..cfee0433
--- /dev/null
+++ b/third_party/WebKit/LayoutTests/platform/linux/virtual/mojo-loading/fast/table/100-percent-cell-width-expected.png
Binary files differ
diff --git a/third_party/WebKit/LayoutTests/platform/linux/virtual/mojo-loading/fast/table/backgr_border-table-cell-collapsed-border-expected.png b/third_party/WebKit/LayoutTests/platform/linux/virtual/mojo-loading/fast/table/backgr_border-table-cell-collapsed-border-expected.png
index 1806f1b..af186ec 100644
--- a/third_party/WebKit/LayoutTests/platform/linux/virtual/mojo-loading/fast/table/backgr_border-table-cell-collapsed-border-expected.png
+++ b/third_party/WebKit/LayoutTests/platform/linux/virtual/mojo-loading/fast/table/backgr_border-table-cell-collapsed-border-expected.png
Binary files differ
diff --git a/third_party/WebKit/LayoutTests/platform/linux/virtual/mojo-loading/fast/table/backgr_border-table-cell-expected.png b/third_party/WebKit/LayoutTests/platform/linux/virtual/mojo-loading/fast/table/backgr_border-table-cell-expected.png
index 35651b1..a6ef896 100644
--- a/third_party/WebKit/LayoutTests/platform/linux/virtual/mojo-loading/fast/table/backgr_border-table-cell-expected.png
+++ b/third_party/WebKit/LayoutTests/platform/linux/virtual/mojo-loading/fast/table/backgr_border-table-cell-expected.png
Binary files differ
diff --git a/third_party/WebKit/LayoutTests/platform/linux/virtual/mojo-loading/fast/table/backgr_border-table-collapsed-border-expected.png b/third_party/WebKit/LayoutTests/platform/linux/virtual/mojo-loading/fast/table/backgr_border-table-collapsed-border-expected.png
index aa3a021..e80a8b61 100644
--- a/third_party/WebKit/LayoutTests/platform/linux/virtual/mojo-loading/fast/table/backgr_border-table-collapsed-border-expected.png
+++ b/third_party/WebKit/LayoutTests/platform/linux/virtual/mojo-loading/fast/table/backgr_border-table-collapsed-border-expected.png
Binary files differ
diff --git a/third_party/WebKit/LayoutTests/platform/linux/virtual/mojo-loading/fast/table/backgr_border-table-column-collapsed-border-expected.png b/third_party/WebKit/LayoutTests/platform/linux/virtual/mojo-loading/fast/table/backgr_border-table-column-collapsed-border-expected.png
index 198e231..6034610 100644
--- a/third_party/WebKit/LayoutTests/platform/linux/virtual/mojo-loading/fast/table/backgr_border-table-column-collapsed-border-expected.png
+++ b/third_party/WebKit/LayoutTests/platform/linux/virtual/mojo-loading/fast/table/backgr_border-table-column-collapsed-border-expected.png
Binary files differ
diff --git a/third_party/WebKit/LayoutTests/platform/linux/virtual/mojo-loading/fast/table/backgr_border-table-column-group-collapsed-border-expected.png b/third_party/WebKit/LayoutTests/platform/linux/virtual/mojo-loading/fast/table/backgr_border-table-column-group-collapsed-border-expected.png
index be1ef0ba..c9e89fb3 100644
--- a/third_party/WebKit/LayoutTests/platform/linux/virtual/mojo-loading/fast/table/backgr_border-table-column-group-collapsed-border-expected.png
+++ b/third_party/WebKit/LayoutTests/platform/linux/virtual/mojo-loading/fast/table/backgr_border-table-column-group-collapsed-border-expected.png
Binary files differ
diff --git a/third_party/WebKit/LayoutTests/platform/linux/virtual/mojo-loading/fast/table/backgr_border-table-column-group-expected.png b/third_party/WebKit/LayoutTests/platform/linux/virtual/mojo-loading/fast/table/backgr_border-table-column-group-expected.png
index a6ad508..05883dc 100644
--- a/third_party/WebKit/LayoutTests/platform/linux/virtual/mojo-loading/fast/table/backgr_border-table-column-group-expected.png
+++ b/third_party/WebKit/LayoutTests/platform/linux/virtual/mojo-loading/fast/table/backgr_border-table-column-group-expected.png
Binary files differ
diff --git a/third_party/WebKit/LayoutTests/platform/linux/virtual/mojo-loading/fast/table/backgr_border-table-quirks-collapsed-border-expected.png b/third_party/WebKit/LayoutTests/platform/linux/virtual/mojo-loading/fast/table/backgr_border-table-quirks-collapsed-border-expected.png
index 82438177..92b122b 100644
--- a/third_party/WebKit/LayoutTests/platform/linux/virtual/mojo-loading/fast/table/backgr_border-table-quirks-collapsed-border-expected.png
+++ b/third_party/WebKit/LayoutTests/platform/linux/virtual/mojo-loading/fast/table/backgr_border-table-quirks-collapsed-border-expected.png
Binary files differ
diff --git a/third_party/WebKit/LayoutTests/platform/linux/virtual/mojo-loading/fast/table/backgr_border-table-quirks-expected.png b/third_party/WebKit/LayoutTests/platform/linux/virtual/mojo-loading/fast/table/backgr_border-table-quirks-expected.png
new file mode 100644
index 0000000..3aea3ba
--- /dev/null
+++ b/third_party/WebKit/LayoutTests/platform/linux/virtual/mojo-loading/fast/table/backgr_border-table-quirks-expected.png
Binary files differ
diff --git a/third_party/WebKit/LayoutTests/platform/linux/virtual/mojo-loading/fast/table/backgr_border-table-row-collapsed-border-expected.png b/third_party/WebKit/LayoutTests/platform/linux/virtual/mojo-loading/fast/table/backgr_border-table-row-collapsed-border-expected.png
index 6ba967c..3cb3102 100644
--- a/third_party/WebKit/LayoutTests/platform/linux/virtual/mojo-loading/fast/table/backgr_border-table-row-collapsed-border-expected.png
+++ b/third_party/WebKit/LayoutTests/platform/linux/virtual/mojo-loading/fast/table/backgr_border-table-row-collapsed-border-expected.png
Binary files differ
diff --git a/third_party/WebKit/LayoutTests/platform/linux/virtual/mojo-loading/fast/table/backgr_border-table-row-expected.png b/third_party/WebKit/LayoutTests/platform/linux/virtual/mojo-loading/fast/table/backgr_border-table-row-expected.png
new file mode 100644
index 0000000..8aa6930
--- /dev/null
+++ b/third_party/WebKit/LayoutTests/platform/linux/virtual/mojo-loading/fast/table/backgr_border-table-row-expected.png
Binary files differ
diff --git a/third_party/WebKit/LayoutTests/platform/linux/virtual/mojo-loading/fast/table/backgr_border-table-row-group-collapsed-border-expected.png b/third_party/WebKit/LayoutTests/platform/linux/virtual/mojo-loading/fast/table/backgr_border-table-row-group-collapsed-border-expected.png
index 6a41c65..847d83be 100644
--- a/third_party/WebKit/LayoutTests/platform/linux/virtual/mojo-loading/fast/table/backgr_border-table-row-group-collapsed-border-expected.png
+++ b/third_party/WebKit/LayoutTests/platform/linux/virtual/mojo-loading/fast/table/backgr_border-table-row-group-collapsed-border-expected.png
Binary files differ
diff --git a/third_party/WebKit/LayoutTests/platform/linux/virtual/mojo-loading/fast/table/backgr_border-table-row-group-expected.png b/third_party/WebKit/LayoutTests/platform/linux/virtual/mojo-loading/fast/table/backgr_border-table-row-group-expected.png
index 4bd187d..6e4e7c9 100644
--- a/third_party/WebKit/LayoutTests/platform/linux/virtual/mojo-loading/fast/table/backgr_border-table-row-group-expected.png
+++ b/third_party/WebKit/LayoutTests/platform/linux/virtual/mojo-loading/fast/table/backgr_border-table-row-group-expected.png
Binary files differ
diff --git a/third_party/WebKit/LayoutTests/platform/linux/virtual/mojo-loading/fast/table/backgr_layers-hide-collapsed-border-expected.png b/third_party/WebKit/LayoutTests/platform/linux/virtual/mojo-loading/fast/table/backgr_layers-hide-collapsed-border-expected.png
index dcea118..1a2a9ba 100644
--- a/third_party/WebKit/LayoutTests/platform/linux/virtual/mojo-loading/fast/table/backgr_layers-hide-collapsed-border-expected.png
+++ b/third_party/WebKit/LayoutTests/platform/linux/virtual/mojo-loading/fast/table/backgr_layers-hide-collapsed-border-expected.png
Binary files differ
diff --git a/third_party/WebKit/LayoutTests/platform/linux/virtual/mojo-loading/fast/table/backgr_layers-hide-expected.png b/third_party/WebKit/LayoutTests/platform/linux/virtual/mojo-loading/fast/table/backgr_layers-hide-expected.png
index ccf013c6..449a74d 100644
--- a/third_party/WebKit/LayoutTests/platform/linux/virtual/mojo-loading/fast/table/backgr_layers-hide-expected.png
+++ b/third_party/WebKit/LayoutTests/platform/linux/virtual/mojo-loading/fast/table/backgr_layers-hide-expected.png
Binary files differ
diff --git a/third_party/WebKit/LayoutTests/platform/linux/virtual/mojo-loading/fast/table/backgr_layers-opacity-collapsed-border-expected.png b/third_party/WebKit/LayoutTests/platform/linux/virtual/mojo-loading/fast/table/backgr_layers-opacity-collapsed-border-expected.png
new file mode 100644
index 0000000..933de89
--- /dev/null
+++ b/third_party/WebKit/LayoutTests/platform/linux/virtual/mojo-loading/fast/table/backgr_layers-opacity-collapsed-border-expected.png
Binary files differ
diff --git a/third_party/WebKit/LayoutTests/platform/linux/virtual/mojo-loading/fast/table/backgr_layers-opacity-expected.png b/third_party/WebKit/LayoutTests/platform/linux/virtual/mojo-loading/fast/table/backgr_layers-opacity-expected.png
new file mode 100644
index 0000000..933de89
--- /dev/null
+++ b/third_party/WebKit/LayoutTests/platform/linux/virtual/mojo-loading/fast/table/backgr_layers-opacity-expected.png
Binary files differ
diff --git a/third_party/WebKit/LayoutTests/platform/linux/virtual/mojo-loading/fast/table/backgr_layers-show-collapsed-border-expected.png b/third_party/WebKit/LayoutTests/platform/linux/virtual/mojo-loading/fast/table/backgr_layers-show-collapsed-border-expected.png
index 06fd3954..59728f5 100644
--- a/third_party/WebKit/LayoutTests/platform/linux/virtual/mojo-loading/fast/table/backgr_layers-show-collapsed-border-expected.png
+++ b/third_party/WebKit/LayoutTests/platform/linux/virtual/mojo-loading/fast/table/backgr_layers-show-collapsed-border-expected.png
Binary files differ
diff --git a/third_party/WebKit/LayoutTests/platform/linux/virtual/mojo-loading/fast/table/backgr_layers-show-expected.png b/third_party/WebKit/LayoutTests/platform/linux/virtual/mojo-loading/fast/table/backgr_layers-show-expected.png
index 475491f..6fd0aba 100644
--- a/third_party/WebKit/LayoutTests/platform/linux/virtual/mojo-loading/fast/table/backgr_layers-show-expected.png
+++ b/third_party/WebKit/LayoutTests/platform/linux/virtual/mojo-loading/fast/table/backgr_layers-show-expected.png
Binary files differ
diff --git a/third_party/WebKit/LayoutTests/platform/linux/virtual/mojo-loading/fast/table/backgr_position-table-cell-collapsed-border-expected.png b/third_party/WebKit/LayoutTests/platform/linux/virtual/mojo-loading/fast/table/backgr_position-table-cell-collapsed-border-expected.png
index 2acb75ece..5e2d15b 100644
--- a/third_party/WebKit/LayoutTests/platform/linux/virtual/mojo-loading/fast/table/backgr_position-table-cell-collapsed-border-expected.png
+++ b/third_party/WebKit/LayoutTests/platform/linux/virtual/mojo-loading/fast/table/backgr_position-table-cell-collapsed-border-expected.png
Binary files differ
diff --git a/third_party/WebKit/LayoutTests/platform/linux/virtual/mojo-loading/fast/table/backgr_position-table-cell-expected.png b/third_party/WebKit/LayoutTests/platform/linux/virtual/mojo-loading/fast/table/backgr_position-table-cell-expected.png
new file mode 100644
index 0000000..28ea718
--- /dev/null
+++ b/third_party/WebKit/LayoutTests/platform/linux/virtual/mojo-loading/fast/table/backgr_position-table-cell-expected.png
Binary files differ
diff --git a/third_party/WebKit/LayoutTests/platform/linux/virtual/mojo-loading/fast/table/backgr_position-table-collapsed-border-expected.png b/third_party/WebKit/LayoutTests/platform/linux/virtual/mojo-loading/fast/table/backgr_position-table-collapsed-border-expected.png
index f887128..97733b76 100644
--- a/third_party/WebKit/LayoutTests/platform/linux/virtual/mojo-loading/fast/table/backgr_position-table-collapsed-border-expected.png
+++ b/third_party/WebKit/LayoutTests/platform/linux/virtual/mojo-loading/fast/table/backgr_position-table-collapsed-border-expected.png
Binary files differ
diff --git a/third_party/WebKit/LayoutTests/platform/linux/virtual/mojo-loading/fast/table/backgr_position-table-column-collapsed-border-expected.png b/third_party/WebKit/LayoutTests/platform/linux/virtual/mojo-loading/fast/table/backgr_position-table-column-collapsed-border-expected.png
index 1f9f904a..25e14eb 100644
--- a/third_party/WebKit/LayoutTests/platform/linux/virtual/mojo-loading/fast/table/backgr_position-table-column-collapsed-border-expected.png
+++ b/third_party/WebKit/LayoutTests/platform/linux/virtual/mojo-loading/fast/table/backgr_position-table-column-collapsed-border-expected.png
Binary files differ
diff --git a/third_party/WebKit/LayoutTests/platform/linux/virtual/mojo-loading/fast/table/backgr_position-table-column-expected.png b/third_party/WebKit/LayoutTests/platform/linux/virtual/mojo-loading/fast/table/backgr_position-table-column-expected.png
new file mode 100644
index 0000000..19426891
--- /dev/null
+++ b/third_party/WebKit/LayoutTests/platform/linux/virtual/mojo-loading/fast/table/backgr_position-table-column-expected.png
Binary files differ
diff --git a/third_party/WebKit/LayoutTests/platform/linux/virtual/mojo-loading/fast/table/backgr_position-table-column-group-collapsed-border-expected.png b/third_party/WebKit/LayoutTests/platform/linux/virtual/mojo-loading/fast/table/backgr_position-table-column-group-collapsed-border-expected.png
index 3e97fca8..a27b14f 100644
--- a/third_party/WebKit/LayoutTests/platform/linux/virtual/mojo-loading/fast/table/backgr_position-table-column-group-collapsed-border-expected.png
+++ b/third_party/WebKit/LayoutTests/platform/linux/virtual/mojo-loading/fast/table/backgr_position-table-column-group-collapsed-border-expected.png
Binary files differ
diff --git a/third_party/WebKit/LayoutTests/platform/linux/virtual/mojo-loading/fast/table/backgr_position-table-column-group-expected.png b/third_party/WebKit/LayoutTests/platform/linux/virtual/mojo-loading/fast/table/backgr_position-table-column-group-expected.png
index dd6bf6fd..8c39206 100644
--- a/third_party/WebKit/LayoutTests/platform/linux/virtual/mojo-loading/fast/table/backgr_position-table-column-group-expected.png
+++ b/third_party/WebKit/LayoutTests/platform/linux/virtual/mojo-loading/fast/table/backgr_position-table-column-group-expected.png
Binary files differ
diff --git a/third_party/WebKit/LayoutTests/platform/linux/virtual/mojo-loading/fast/table/backgr_position-table-expected.png b/third_party/WebKit/LayoutTests/platform/linux/virtual/mojo-loading/fast/table/backgr_position-table-expected.png
index 31d690b..4008f02 100644
--- a/third_party/WebKit/LayoutTests/platform/linux/virtual/mojo-loading/fast/table/backgr_position-table-expected.png
+++ b/third_party/WebKit/LayoutTests/platform/linux/virtual/mojo-loading/fast/table/backgr_position-table-expected.png
Binary files differ
diff --git a/third_party/WebKit/LayoutTests/platform/linux/virtual/mojo-loading/fast/table/backgr_position-table-row-collapsed-border-expected.png b/third_party/WebKit/LayoutTests/platform/linux/virtual/mojo-loading/fast/table/backgr_position-table-row-collapsed-border-expected.png
index 50414aa..0e3a429 100644
--- a/third_party/WebKit/LayoutTests/platform/linux/virtual/mojo-loading/fast/table/backgr_position-table-row-collapsed-border-expected.png
+++ b/third_party/WebKit/LayoutTests/platform/linux/virtual/mojo-loading/fast/table/backgr_position-table-row-collapsed-border-expected.png
Binary files differ
diff --git a/third_party/WebKit/LayoutTests/platform/linux/virtual/mojo-loading/fast/table/backgr_position-table-row-expected.png b/third_party/WebKit/LayoutTests/platform/linux/virtual/mojo-loading/fast/table/backgr_position-table-row-expected.png
new file mode 100644
index 0000000..76b2ce61
--- /dev/null
+++ b/third_party/WebKit/LayoutTests/platform/linux/virtual/mojo-loading/fast/table/backgr_position-table-row-expected.png
Binary files differ
diff --git a/third_party/WebKit/LayoutTests/platform/linux/virtual/mojo-loading/fast/table/backgr_position-table-row-group-collapsed-border-expected.png b/third_party/WebKit/LayoutTests/platform/linux/virtual/mojo-loading/fast/table/backgr_position-table-row-group-collapsed-border-expected.png
index 93a4e38..839b902 100644
--- a/third_party/WebKit/LayoutTests/platform/linux/virtual/mojo-loading/fast/table/backgr_position-table-row-group-collapsed-border-expected.png
+++ b/third_party/WebKit/LayoutTests/platform/linux/virtual/mojo-loading/fast/table/backgr_position-table-row-group-collapsed-border-expected.png
Binary files differ
diff --git a/third_party/WebKit/LayoutTests/platform/linux/virtual/mojo-loading/fast/table/backgr_position-table-row-group-expected.png b/third_party/WebKit/LayoutTests/platform/linux/virtual/mojo-loading/fast/table/backgr_position-table-row-group-expected.png
index 72d561a..61e56fc 100644
--- a/third_party/WebKit/LayoutTests/platform/linux/virtual/mojo-loading/fast/table/backgr_position-table-row-group-expected.png
+++ b/third_party/WebKit/LayoutTests/platform/linux/virtual/mojo-loading/fast/table/backgr_position-table-row-group-expected.png
Binary files differ
diff --git a/third_party/WebKit/LayoutTests/platform/linux/virtual/mojo-loading/fast/table/backgr_simple-table-cell-collapsed-border-expected.png b/third_party/WebKit/LayoutTests/platform/linux/virtual/mojo-loading/fast/table/backgr_simple-table-cell-collapsed-border-expected.png
index 2546b77..0dedaae 100644
--- a/third_party/WebKit/LayoutTests/platform/linux/virtual/mojo-loading/fast/table/backgr_simple-table-cell-collapsed-border-expected.png
+++ b/third_party/WebKit/LayoutTests/platform/linux/virtual/mojo-loading/fast/table/backgr_simple-table-cell-collapsed-border-expected.png
Binary files differ
diff --git a/third_party/WebKit/LayoutTests/platform/linux/virtual/mojo-loading/fast/table/backgr_simple-table-cell-expected.png b/third_party/WebKit/LayoutTests/platform/linux/virtual/mojo-loading/fast/table/backgr_simple-table-cell-expected.png
index 15a91c49..4996351 100644
--- a/third_party/WebKit/LayoutTests/platform/linux/virtual/mojo-loading/fast/table/backgr_simple-table-cell-expected.png
+++ b/third_party/WebKit/LayoutTests/platform/linux/virtual/mojo-loading/fast/table/backgr_simple-table-cell-expected.png
Binary files differ
diff --git a/third_party/WebKit/LayoutTests/platform/linux/virtual/mojo-loading/fast/table/backgr_simple-table-collapsed-border-expected.png b/third_party/WebKit/LayoutTests/platform/linux/virtual/mojo-loading/fast/table/backgr_simple-table-collapsed-border-expected.png
index 95393712..59e0ff4 100644
--- a/third_party/WebKit/LayoutTests/platform/linux/virtual/mojo-loading/fast/table/backgr_simple-table-collapsed-border-expected.png
+++ b/third_party/WebKit/LayoutTests/platform/linux/virtual/mojo-loading/fast/table/backgr_simple-table-collapsed-border-expected.png
Binary files differ
diff --git a/third_party/WebKit/LayoutTests/platform/linux/virtual/mojo-loading/fast/table/backgr_simple-table-column-collapsed-border-expected.png b/third_party/WebKit/LayoutTests/platform/linux/virtual/mojo-loading/fast/table/backgr_simple-table-column-collapsed-border-expected.png
index e760402..2c9ea75e 100644
--- a/third_party/WebKit/LayoutTests/platform/linux/virtual/mojo-loading/fast/table/backgr_simple-table-column-collapsed-border-expected.png
+++ b/third_party/WebKit/LayoutTests/platform/linux/virtual/mojo-loading/fast/table/backgr_simple-table-column-collapsed-border-expected.png
Binary files differ
diff --git a/third_party/WebKit/LayoutTests/platform/linux/virtual/mojo-loading/fast/table/backgr_simple-table-column-expected.png b/third_party/WebKit/LayoutTests/platform/linux/virtual/mojo-loading/fast/table/backgr_simple-table-column-expected.png
index 55bb5e3..36d4c0e4 100644
--- a/third_party/WebKit/LayoutTests/platform/linux/virtual/mojo-loading/fast/table/backgr_simple-table-column-expected.png
+++ b/third_party/WebKit/LayoutTests/platform/linux/virtual/mojo-loading/fast/table/backgr_simple-table-column-expected.png
Binary files differ
diff --git a/third_party/WebKit/LayoutTests/platform/linux/virtual/mojo-loading/fast/table/backgr_simple-table-column-group-collapsed-border-expected.png b/third_party/WebKit/LayoutTests/platform/linux/virtual/mojo-loading/fast/table/backgr_simple-table-column-group-collapsed-border-expected.png
index 12ab046e..eb15b87 100644
--- a/third_party/WebKit/LayoutTests/platform/linux/virtual/mojo-loading/fast/table/backgr_simple-table-column-group-collapsed-border-expected.png
+++ b/third_party/WebKit/LayoutTests/platform/linux/virtual/mojo-loading/fast/table/backgr_simple-table-column-group-collapsed-border-expected.png
Binary files differ
diff --git a/third_party/WebKit/LayoutTests/platform/linux/virtual/mojo-loading/fast/table/backgr_simple-table-column-group-expected.png b/third_party/WebKit/LayoutTests/platform/linux/virtual/mojo-loading/fast/table/backgr_simple-table-column-group-expected.png
index f79ae8ade..43c8a66 100644
--- a/third_party/WebKit/LayoutTests/platform/linux/virtual/mojo-loading/fast/table/backgr_simple-table-column-group-expected.png
+++ b/third_party/WebKit/LayoutTests/platform/linux/virtual/mojo-loading/fast/table/backgr_simple-table-column-group-expected.png
Binary files differ
diff --git a/third_party/WebKit/LayoutTests/platform/linux/virtual/mojo-loading/fast/table/backgr_simple-table-expected.png b/third_party/WebKit/LayoutTests/platform/linux/virtual/mojo-loading/fast/table/backgr_simple-table-expected.png
index cd74901..d6976ec 100644
--- a/third_party/WebKit/LayoutTests/platform/linux/virtual/mojo-loading/fast/table/backgr_simple-table-expected.png
+++ b/third_party/WebKit/LayoutTests/platform/linux/virtual/mojo-loading/fast/table/backgr_simple-table-expected.png
Binary files differ
diff --git a/third_party/WebKit/LayoutTests/platform/linux/virtual/mojo-loading/fast/table/backgr_simple-table-row-collapsed-border-expected.png b/third_party/WebKit/LayoutTests/platform/linux/virtual/mojo-loading/fast/table/backgr_simple-table-row-collapsed-border-expected.png
index b1d2d18..bd65d9e7c 100644
--- a/third_party/WebKit/LayoutTests/platform/linux/virtual/mojo-loading/fast/table/backgr_simple-table-row-collapsed-border-expected.png
+++ b/third_party/WebKit/LayoutTests/platform/linux/virtual/mojo-loading/fast/table/backgr_simple-table-row-collapsed-border-expected.png
Binary files differ
diff --git a/third_party/WebKit/LayoutTests/platform/linux/virtual/mojo-loading/fast/table/backgr_simple-table-row-expected.png b/third_party/WebKit/LayoutTests/platform/linux/virtual/mojo-loading/fast/table/backgr_simple-table-row-expected.png
index 9911e6b..ba52d1b 100644
--- a/third_party/WebKit/LayoutTests/platform/linux/virtual/mojo-loading/fast/table/backgr_simple-table-row-expected.png
+++ b/third_party/WebKit/LayoutTests/platform/linux/virtual/mojo-loading/fast/table/backgr_simple-table-row-expected.png
Binary files differ
diff --git a/third_party/WebKit/LayoutTests/platform/linux/virtual/mojo-loading/fast/table/backgr_simple-table-row-group-collapsed-border-expected.png b/third_party/WebKit/LayoutTests/platform/linux/virtual/mojo-loading/fast/table/backgr_simple-table-row-group-collapsed-border-expected.png
index ffdf3a1..a7f6465f 100644
--- a/third_party/WebKit/LayoutTests/platform/linux/virtual/mojo-loading/fast/table/backgr_simple-table-row-group-collapsed-border-expected.png
+++ b/third_party/WebKit/LayoutTests/platform/linux/virtual/mojo-loading/fast/table/backgr_simple-table-row-group-collapsed-border-expected.png
Binary files differ
diff --git a/third_party/WebKit/LayoutTests/platform/linux/virtual/mojo-loading/fast/table/backgr_simple-table-row-group-expected.png b/third_party/WebKit/LayoutTests/platform/linux/virtual/mojo-loading/fast/table/backgr_simple-table-row-group-expected.png
index 3263ca0d..a4a2b744 100644
--- a/third_party/WebKit/LayoutTests/platform/linux/virtual/mojo-loading/fast/table/backgr_simple-table-row-group-expected.png
+++ b/third_party/WebKit/LayoutTests/platform/linux/virtual/mojo-loading/fast/table/backgr_simple-table-row-group-expected.png
Binary files differ
diff --git a/third_party/WebKit/LayoutTests/platform/linux/virtual/mojo-loading/fast/table/border-collapsing/003-expected.png b/third_party/WebKit/LayoutTests/platform/linux/virtual/mojo-loading/fast/table/border-collapsing/003-expected.png
new file mode 100644
index 0000000..6a82258
--- /dev/null
+++ b/third_party/WebKit/LayoutTests/platform/linux/virtual/mojo-loading/fast/table/border-collapsing/003-expected.png
Binary files differ
diff --git a/third_party/WebKit/LayoutTests/platform/linux/virtual/mojo-loading/fast/table/border-collapsing/003-vertical-expected.png b/third_party/WebKit/LayoutTests/platform/linux/virtual/mojo-loading/fast/table/border-collapsing/003-vertical-expected.png
index 09f3eac0..09c54a1 100644
--- a/third_party/WebKit/LayoutTests/platform/linux/virtual/mojo-loading/fast/table/border-collapsing/003-vertical-expected.png
+++ b/third_party/WebKit/LayoutTests/platform/linux/virtual/mojo-loading/fast/table/border-collapsing/003-vertical-expected.png
Binary files differ
diff --git a/third_party/WebKit/LayoutTests/platform/linux/virtual/mojo-loading/fast/table/border-collapsing/004-expected.png b/third_party/WebKit/LayoutTests/platform/linux/virtual/mojo-loading/fast/table/border-collapsing/004-expected.png
new file mode 100644
index 0000000..61687c48
--- /dev/null
+++ b/third_party/WebKit/LayoutTests/platform/linux/virtual/mojo-loading/fast/table/border-collapsing/004-expected.png
Binary files differ
diff --git a/third_party/WebKit/LayoutTests/platform/linux/virtual/mojo-loading/fast/table/border-collapsing/004-vertical-expected.png b/third_party/WebKit/LayoutTests/platform/linux/virtual/mojo-loading/fast/table/border-collapsing/004-vertical-expected.png
new file mode 100644
index 0000000..57bfbad
--- /dev/null
+++ b/third_party/WebKit/LayoutTests/platform/linux/virtual/mojo-loading/fast/table/border-collapsing/004-vertical-expected.png
Binary files differ
diff --git a/third_party/WebKit/LayoutTests/platform/linux/virtual/mojo-loading/fast/table/border-collapsing/border-collapsing-head-foot-expected.png b/third_party/WebKit/LayoutTests/platform/linux/virtual/mojo-loading/fast/table/border-collapsing/border-collapsing-head-foot-expected.png
new file mode 100644
index 0000000..e938da1
--- /dev/null
+++ b/third_party/WebKit/LayoutTests/platform/linux/virtual/mojo-loading/fast/table/border-collapsing/border-collapsing-head-foot-expected.png
Binary files differ
diff --git a/third_party/WebKit/LayoutTests/platform/linux/virtual/mojo-loading/fast/table/border-collapsing/border-collapsing-head-foot-vertical-expected.png b/third_party/WebKit/LayoutTests/platform/linux/virtual/mojo-loading/fast/table/border-collapsing/border-collapsing-head-foot-vertical-expected.png
index b90ce0e23d..5dd4791 100644
--- a/third_party/WebKit/LayoutTests/platform/linux/virtual/mojo-loading/fast/table/border-collapsing/border-collapsing-head-foot-vertical-expected.png
+++ b/third_party/WebKit/LayoutTests/platform/linux/virtual/mojo-loading/fast/table/border-collapsing/border-collapsing-head-foot-vertical-expected.png
Binary files differ
diff --git a/third_party/WebKit/LayoutTests/platform/linux/virtual/mojo-loading/fast/table/border-collapsing/rtl-border-collapsing-expected.png b/third_party/WebKit/LayoutTests/platform/linux/virtual/mojo-loading/fast/table/border-collapsing/rtl-border-collapsing-expected.png
new file mode 100644
index 0000000..1543be4c
--- /dev/null
+++ b/third_party/WebKit/LayoutTests/platform/linux/virtual/mojo-loading/fast/table/border-collapsing/rtl-border-collapsing-expected.png
Binary files differ
diff --git a/third_party/WebKit/LayoutTests/platform/linux/virtual/mojo-loading/fast/table/border-collapsing/rtl-border-collapsing-vertical-expected.png b/third_party/WebKit/LayoutTests/platform/linux/virtual/mojo-loading/fast/table/border-collapsing/rtl-border-collapsing-vertical-expected.png
new file mode 100644
index 0000000..a545d36
--- /dev/null
+++ b/third_party/WebKit/LayoutTests/platform/linux/virtual/mojo-loading/fast/table/border-collapsing/rtl-border-collapsing-vertical-expected.png
Binary files differ
diff --git a/third_party/WebKit/LayoutTests/platform/linux/virtual/mojo-loading/fast/table/cell-absolute-child-expected.png b/third_party/WebKit/LayoutTests/platform/linux/virtual/mojo-loading/fast/table/cell-absolute-child-expected.png
new file mode 100644
index 0000000..56a79b0
--- /dev/null
+++ b/third_party/WebKit/LayoutTests/platform/linux/virtual/mojo-loading/fast/table/cell-absolute-child-expected.png
Binary files differ
diff --git a/third_party/WebKit/LayoutTests/platform/linux/virtual/mojo-loading/fast/table/click-near-anonymous-table-expected.png b/third_party/WebKit/LayoutTests/platform/linux/virtual/mojo-loading/fast/table/click-near-anonymous-table-expected.png
new file mode 100644
index 0000000..f415106
--- /dev/null
+++ b/third_party/WebKit/LayoutTests/platform/linux/virtual/mojo-loading/fast/table/click-near-anonymous-table-expected.png
Binary files differ
diff --git a/third_party/WebKit/LayoutTests/platform/linux/virtual/mojo-loading/fast/table/edge-offsets-expected.png b/third_party/WebKit/LayoutTests/platform/linux/virtual/mojo-loading/fast/table/edge-offsets-expected.png
new file mode 100644
index 0000000..6aaa10c
--- /dev/null
+++ b/third_party/WebKit/LayoutTests/platform/linux/virtual/mojo-loading/fast/table/edge-offsets-expected.png
Binary files differ
diff --git a/third_party/WebKit/LayoutTests/platform/linux/virtual/mojo-loading/fast/table/frame-and-rules-expected.png b/third_party/WebKit/LayoutTests/platform/linux/virtual/mojo-loading/fast/table/frame-and-rules-expected.png
new file mode 100644
index 0000000..de5f502f
--- /dev/null
+++ b/third_party/WebKit/LayoutTests/platform/linux/virtual/mojo-loading/fast/table/frame-and-rules-expected.png
Binary files differ
diff --git a/third_party/WebKit/LayoutTests/platform/linux/virtual/mojo-loading/fast/table/generated-caption-expected.png b/third_party/WebKit/LayoutTests/platform/linux/virtual/mojo-loading/fast/table/generated-caption-expected.png
new file mode 100644
index 0000000..f9761f1
--- /dev/null
+++ b/third_party/WebKit/LayoutTests/platform/linux/virtual/mojo-loading/fast/table/generated-caption-expected.png
Binary files differ
diff --git a/third_party/WebKit/LayoutTests/platform/linux/virtual/mojo-loading/fast/table/row-height-recalc-expected.png b/third_party/WebKit/LayoutTests/platform/linux/virtual/mojo-loading/fast/table/row-height-recalc-expected.png
new file mode 100644
index 0000000..87b017c
--- /dev/null
+++ b/third_party/WebKit/LayoutTests/platform/linux/virtual/mojo-loading/fast/table/row-height-recalc-expected.png
Binary files differ
diff --git a/third_party/WebKit/LayoutTests/platform/linux/virtual/mojo-loading/fast/table/rtl-cell-display-none-assert-expected.png b/third_party/WebKit/LayoutTests/platform/linux/virtual/mojo-loading/fast/table/rtl-cell-display-none-assert-expected.png
new file mode 100644
index 0000000..3b1538f
--- /dev/null
+++ b/third_party/WebKit/LayoutTests/platform/linux/virtual/mojo-loading/fast/table/rtl-cell-display-none-assert-expected.png
Binary files differ
diff --git a/third_party/WebKit/LayoutTests/platform/linux/virtual/mojo-loading/fast/table/stale-grid-crash-expected.png b/third_party/WebKit/LayoutTests/platform/linux/virtual/mojo-loading/fast/table/stale-grid-crash-expected.png
new file mode 100644
index 0000000..8b51f53
--- /dev/null
+++ b/third_party/WebKit/LayoutTests/platform/linux/virtual/mojo-loading/fast/table/stale-grid-crash-expected.png
Binary files differ
diff --git a/third_party/WebKit/LayoutTests/platform/linux/virtual/mojo-loading/fast/table/text-field-baseline-expected.png b/third_party/WebKit/LayoutTests/platform/linux/virtual/mojo-loading/fast/table/text-field-baseline-expected.png
new file mode 100644
index 0000000..e372709
--- /dev/null
+++ b/third_party/WebKit/LayoutTests/platform/linux/virtual/mojo-loading/fast/table/text-field-baseline-expected.png
Binary files differ
diff --git a/third_party/WebKit/LayoutTests/platform/win/fast/text/sub-pixel/text-scaling-ltr-expected.txt b/third_party/WebKit/LayoutTests/platform/win/fast/text/sub-pixel/text-scaling-ltr-expected.txt
index baad1c26..1a6af3ad 100644
--- a/third_party/WebKit/LayoutTests/platform/win/fast/text/sub-pixel/text-scaling-ltr-expected.txt
+++ b/third_party/WebKit/LayoutTests/platform/win/fast/text/sub-pixel/text-scaling-ltr-expected.txt
@@ -5,3 +5,4 @@
 Font Size Scaling (LTR, Latin)
 Size of the text should scale smoothly. Reported width should be within 0.02px of that of the highlighted reference row.
 
+
diff --git a/third_party/WebKit/LayoutTests/platform/win/fast/text/sub-pixel/text-scaling-rtl-expected.txt b/third_party/WebKit/LayoutTests/platform/win/fast/text/sub-pixel/text-scaling-rtl-expected.txt
index 906d1ed..616e423 100644
--- a/third_party/WebKit/LayoutTests/platform/win/fast/text/sub-pixel/text-scaling-rtl-expected.txt
+++ b/third_party/WebKit/LayoutTests/platform/win/fast/text/sub-pixel/text-scaling-rtl-expected.txt
@@ -5,3 +5,4 @@
 Font Size Scaling (RTL, Arabic)
 Size of the text should scale smoothly. Reported width should be within 0.02px of that of the highlighted reference row.
 
+
diff --git a/third_party/WebKit/LayoutTests/platform/win/fast/text/sub-pixel/text-scaling-vertical-expected.txt b/third_party/WebKit/LayoutTests/platform/win/fast/text/sub-pixel/text-scaling-vertical-expected.txt
index f3dc2272..908d157 100644
--- a/third_party/WebKit/LayoutTests/platform/win/fast/text/sub-pixel/text-scaling-vertical-expected.txt
+++ b/third_party/WebKit/LayoutTests/platform/win/fast/text/sub-pixel/text-scaling-vertical-expected.txt
@@ -5,3 +5,4 @@
 Font Size Scaling (vertical-rl, Latin)
 Size of the text should scale smoothly. Reported height (logical width) should be within 0.02px of that of the highlighted reference row.
 
+
diff --git a/third_party/WebKit/LayoutTests/scrollbars/scrollbar-large-overflow-rectangle-expected.txt b/third_party/WebKit/LayoutTests/scrollbars/scrollbar-large-overflow-rectangle-expected.txt
index f91edcf..367ffbd8 100644
--- a/third_party/WebKit/LayoutTests/scrollbars/scrollbar-large-overflow-rectangle-expected.txt
+++ b/third_party/WebKit/LayoutTests/scrollbars/scrollbar-large-overflow-rectangle-expected.txt
@@ -1,3 +1,5 @@
 This page should be scrollable
+
 PASS
 
+
diff --git a/third_party/WebKit/Source/core/dom/events/MediaElementEventQueue.cpp b/third_party/WebKit/Source/core/dom/events/MediaElementEventQueue.cpp
index a17d317c..706968a4 100644
--- a/third_party/WebKit/Source/core/dom/events/MediaElementEventQueue.cpp
+++ b/third_party/WebKit/Source/core/dom/events/MediaElementEventQueue.cpp
@@ -32,14 +32,16 @@
 
 namespace blink {
 
-MediaElementEventQueue* MediaElementEventQueue::Create(EventTarget* owner) {
-  return new MediaElementEventQueue(owner);
+MediaElementEventQueue* MediaElementEventQueue::Create(
+    EventTarget* owner,
+    ExecutionContext* context) {
+  return new MediaElementEventQueue(owner, context);
 }
 
-MediaElementEventQueue::MediaElementEventQueue(EventTarget* owner)
+MediaElementEventQueue::MediaElementEventQueue(EventTarget* owner,
+                                               ExecutionContext* context)
     : owner_(owner),
-      timer_(TaskRunnerHelper::Get(TaskType::kMediaElementEvent,
-                                   owner->GetExecutionContext()),
+      timer_(TaskRunnerHelper::Get(TaskType::kMediaElementEvent, context),
              this,
              &MediaElementEventQueue::TimerFired),
       is_closed_(false) {}
diff --git a/third_party/WebKit/Source/core/dom/events/MediaElementEventQueue.h b/third_party/WebKit/Source/core/dom/events/MediaElementEventQueue.h
index 6ffdae6..b49a8bd 100644
--- a/third_party/WebKit/Source/core/dom/events/MediaElementEventQueue.h
+++ b/third_party/WebKit/Source/core/dom/events/MediaElementEventQueue.h
@@ -40,7 +40,7 @@
 // "media element event" task type according to the spec.
 class CORE_EXPORT MediaElementEventQueue final : public EventQueue {
  public:
-  static MediaElementEventQueue* Create(EventTarget*);
+  static MediaElementEventQueue* Create(EventTarget*, ExecutionContext*);
   ~MediaElementEventQueue() override;
 
   // EventQueue
@@ -53,7 +53,7 @@
   bool HasPendingEvents() const;
 
  private:
-  explicit MediaElementEventQueue(EventTarget*);
+  MediaElementEventQueue(EventTarget*, ExecutionContext*);
   void TimerFired(TimerBase*);
 
   Member<EventTarget> owner_;
diff --git a/third_party/WebKit/Source/core/editing/SelectionController.cpp b/third_party/WebKit/Source/core/editing/SelectionController.cpp
index 5bb88cc..39ada6fc 100644
--- a/third_party/WebKit/Source/core/editing/SelectionController.cpp
+++ b/third_party/WebKit/Source/core/editing/SelectionController.cpp
@@ -396,7 +396,10 @@
     return false;
   }
 
-  if (has_editable_style && event.Event().FromTouch()) {
+  // SelectionControllerTest_SetCaretAtHitTestResultWithDisconnectedPosition
+  // makes the IsValidFor() check fail.
+  if (has_editable_style && event.Event().FromTouch() &&
+      position_to_use.IsValidFor(*frame_->GetDocument())) {
     frame_->GetTextSuggestionController().HandlePotentialMisspelledWordTap(
         position_to_use.GetPosition());
   }
diff --git a/third_party/WebKit/Source/core/editing/SelectionControllerTest.cpp b/third_party/WebKit/Source/core/editing/SelectionControllerTest.cpp
index 91ee6ad..cca3ffc 100644
--- a/third_party/WebKit/Source/core/editing/SelectionControllerTest.cpp
+++ b/third_party/WebKit/Source/core/editing/SelectionControllerTest.cpp
@@ -136,4 +136,46 @@
   EXPECT_TRUE(Selection().GetSelectionInDOMTree().IsNone());
 }
 
+// For http://crbug.com/759971
+TEST_F(SelectionControllerTest,
+       SetCaretAtHitTestResultWithDisconnectedPosition) {
+  GetDocument().GetSettings()->SetScriptEnabled(true);
+  Element* script = GetDocument().createElement("script");
+  script->setInnerHTML(
+      "document.designMode = 'on';"
+      "const selection = window.getSelection();"
+      "const html = document.getElementsByTagName('html')[0];"
+      "selection.collapse(html);"
+      "const range = selection.getRangeAt(0);"
+
+      "function selectstart() {"
+      "  const body = document.getElementsByTagName('body')[0];"
+      "  range.surroundContents(body);"
+      "  range.deleteContents();"
+      "}"
+      "document.addEventListener('selectstart', selectstart);");
+  GetDocument().body()->AppendChild(script);
+  GetDocument().View()->UpdateAllLifecyclePhases();
+
+  // Simulate a tap somewhere in the document
+  blink::WebMouseEvent mouse_event(
+      blink::WebInputEvent::kMouseDown,
+      blink::WebInputEvent::kIsCompatibilityEventForTouch,
+      blink::WebInputEvent::kTimeStampForTesting);
+  // Frame scale defaults to 0, which would cause a divide-by-zero problem.
+  mouse_event.SetFrameScale(1);
+  GetFrame().GetEventHandler().GetSelectionController().HandleMousePressEvent(
+      MouseEventWithHitTestResults(
+          mouse_event,
+          GetFrame().GetEventHandler().HitTestResultAtPoint(IntPoint(0, 0))));
+
+  // The original bug was that this test would cause
+  // TextSuggestionController::HandlePotentialMisspelledWordTap() to crash. So
+  // the primary thing this test cases tests is that we can get here without
+  // crashing.
+
+  // Verify no selection was set.
+  EXPECT_TRUE(Selection().GetSelectionInDOMTree().IsNone());
+}
+
 }  // namespace blink
diff --git a/third_party/WebKit/Source/core/editing/iterators/TextIterator.cpp b/third_party/WebKit/Source/core/editing/iterators/TextIterator.cpp
index 28864328..83fb0e2 100644
--- a/third_party/WebKit/Source/core/editing/iterators/TextIterator.cpp
+++ b/third_party/WebKit/Source/core/editing/iterators/TextIterator.cpp
@@ -652,10 +652,13 @@
 
   // NOTE: We only do this for a select set of nodes, and fwiw WinIE appears
   // not to do this at all
+
+  if (node->HasTagName(pTag))
+    return true;
+
   if (node->HasTagName(h1Tag) || node->HasTagName(h2Tag) ||
       node->HasTagName(h3Tag) || node->HasTagName(h4Tag) ||
-      node->HasTagName(h5Tag) || node->HasTagName(h6Tag) ||
-      node->HasTagName(pTag)) {
+      node->HasTagName(h5Tag) || node->HasTagName(h6Tag)) {
     const ComputedStyle* style = r->Style();
     if (style) {
       int bottom_margin = ToLayoutBox(r)->CollapsedMarginAfter().ToInt();
diff --git a/third_party/WebKit/Source/core/html/HTMLMediaElement.cpp b/third_party/WebKit/Source/core/html/HTMLMediaElement.cpp
index 76a3653..400ffc9 100644
--- a/third_party/WebKit/Source/core/html/HTMLMediaElement.cpp
+++ b/third_party/WebKit/Source/core/html/HTMLMediaElement.cpp
@@ -458,7 +458,7 @@
           this,
           &HTMLMediaElement::CheckViewportIntersectionTimerFired),
       played_time_ranges_(),
-      async_event_queue_(MediaElementEventQueue::Create(this)),
+      async_event_queue_(MediaElementEventQueue::Create(this, &document)),
       playback_rate_(1.0f),
       default_playback_rate_(1.0f),
       network_state_(kNetworkEmpty),
diff --git a/third_party/WebKit/Source/core/html/track/TextTrackList.cpp b/third_party/WebKit/Source/core/html/track/TextTrackList.cpp
index 866c431..9fa8bbe 100644
--- a/third_party/WebKit/Source/core/html/track/TextTrackList.cpp
+++ b/third_party/WebKit/Source/core/html/track/TextTrackList.cpp
@@ -36,7 +36,9 @@
 namespace blink {
 
 TextTrackList::TextTrackList(HTMLMediaElement* owner)
-    : owner_(owner), async_event_queue_(MediaElementEventQueue::Create(this)) {}
+    : owner_(owner),
+      async_event_queue_(
+          MediaElementEventQueue::Create(this, &owner_->GetDocument())) {}
 
 TextTrackList::~TextTrackList() {}
 
diff --git a/third_party/WebKit/Source/core/intersection_observer/IntersectionObserver.idl b/third_party/WebKit/Source/core/intersection_observer/IntersectionObserver.idl
index 6ab336e..31773be 100644
--- a/third_party/WebKit/Source/core/intersection_observer/IntersectionObserver.idl
+++ b/third_party/WebKit/Source/core/intersection_observer/IntersectionObserver.idl
@@ -13,7 +13,6 @@
     ConstructorCallWith=ScriptState,
     MeasureAs=IntersectionObserver_Constructor,
     RaisesException=Constructor,
-    RuntimeEnabled=IntersectionObserver,
     DependentLifetime
 ] interface IntersectionObserver {
     readonly attribute Element? root;
diff --git a/third_party/WebKit/Source/core/intersection_observer/IntersectionObserverEntry.idl b/third_party/WebKit/Source/core/intersection_observer/IntersectionObserverEntry.idl
index fea1aed..fb26cf2 100644
--- a/third_party/WebKit/Source/core/intersection_observer/IntersectionObserverEntry.idl
+++ b/third_party/WebKit/Source/core/intersection_observer/IntersectionObserverEntry.idl
@@ -4,9 +4,7 @@
 
 // https://wicg.github.io/IntersectionObserver/#intersection-observer-entry
 
-[
-    RuntimeEnabled=IntersectionObserver
-] interface IntersectionObserverEntry {
+interface IntersectionObserverEntry {
     readonly attribute DOMHighResTimeStamp time;
     // TODO(szager): |rootBounds| should not be nullable.
     readonly attribute DOMRectReadOnly? rootBounds;
diff --git a/third_party/WebKit/Source/core/layout/line/InlineFlowBox.cpp b/third_party/WebKit/Source/core/layout/line/InlineFlowBox.cpp
index 08e67a2..65e70f9 100644
--- a/third_party/WebKit/Source/core/layout/line/InlineFlowBox.cpp
+++ b/third_party/WebKit/Source/core/layout/line/InlineFlowBox.cpp
@@ -1281,6 +1281,8 @@
             flow->LogicalVisualOverflowRect(line_top, line_bottom));
       LayoutRect child_layout_overflow =
           flow->LogicalLayoutOverflowRect(line_top, line_bottom);
+      child_layout_overflow.Unite(
+          LogicalFrameRectIncludingLineHeight(line_top, line_bottom));
       child_layout_overflow.Move(
           flow->BoxModelObject().RelativePositionLogicalOffset());
       logical_layout_overflow.Unite(child_layout_overflow);
diff --git a/third_party/WebKit/Source/core/layout/ng/inline/ng_line_breaker.cc b/third_party/WebKit/Source/core/layout/ng/inline/ng_line_breaker.cc
index 3f6b41e4..fd9cd5a 100644
--- a/third_party/WebKit/Source/core/layout/ng/inline/ng_line_breaker.cc
+++ b/third_party/WebKit/Source/core/layout/ng/inline/ng_line_breaker.cc
@@ -692,6 +692,7 @@
       // must not be at the end.
       LayoutUnit item_available_width =
           std::min(-next_width_to_rewind, item_result->inline_size - 1);
+      SetCurrentStyle(*item.Style());
       BreakText(item_result, item, item_available_width);
       if (item_result->inline_size <= item_available_width) {
         DCHECK(item_result->end_offset < item.EndOffset() ||
@@ -718,6 +719,7 @@
     // that depend on old available width, but it's not trivial to rewind all
     // the states. For the simplicity, rewind to the beginning of the line.
     Rewind(line_info, 0);
+    SetCurrentStyle(line_info->LineStyle());
     line_.position = line_info->TextIndent();
     BreakLine(line_info);
     return;
diff --git a/third_party/WebKit/Source/modules/accessibility/AXInlineTextBox.cpp b/third_party/WebKit/Source/modules/accessibility/AXInlineTextBox.cpp
index 068a1d7..2ee5ef7 100644
--- a/third_party/WebKit/Source/modules/accessibility/AXInlineTextBox.cpp
+++ b/third_party/WebKit/Source/modules/accessibility/AXInlineTextBox.cpp
@@ -162,6 +162,13 @@
   return AXObject::GetTextDirection();
 }
 
+Node* AXInlineTextBox::GetNode() const {
+  if (!inline_text_box_)
+    return nullptr;
+
+  return inline_text_box_->GetNode();
+}
+
 AXObject* AXInlineTextBox::NextOnLine() const {
   RefPtr<AbstractInlineTextBox> next_on_line = inline_text_box_->NextOnLine();
   if (next_on_line)
diff --git a/third_party/WebKit/Source/modules/accessibility/AXInlineTextBox.h b/third_party/WebKit/Source/modules/accessibility/AXInlineTextBox.h
index 923cbcf..3be42f70 100644
--- a/third_party/WebKit/Source/modules/accessibility/AXInlineTextBox.h
+++ b/third_party/WebKit/Source/modules/accessibility/AXInlineTextBox.h
@@ -64,7 +64,7 @@
                          SkMatrix44& out_container_transform) const override;
   AXObject* ComputeParent() const override;
   AccessibilityTextDirection GetTextDirection() const override;
-  Node* GetNode() const override { return inline_text_box_->GetNode(); }
+  Node* GetNode() const override;
   AXObject* NextOnLine() const override;
   AXObject* PreviousOnLine() const override;
 
diff --git a/third_party/WebKit/Source/modules/encryptedmedia/MediaKeySession.cpp b/third_party/WebKit/Source/modules/encryptedmedia/MediaKeySession.cpp
index 49094ce2..6ca95167 100644
--- a/third_party/WebKit/Source/modules/encryptedmedia/MediaKeySession.cpp
+++ b/third_party/WebKit/Source/modules/encryptedmedia/MediaKeySession.cpp
@@ -344,7 +344,9 @@
                                  MediaKeys* media_keys,
                                  WebEncryptedMediaSessionType session_type)
     : ContextLifecycleObserver(ExecutionContext::From(script_state)),
-      async_event_queue_(MediaElementEventQueue::Create(this)),
+      async_event_queue_(
+          MediaElementEventQueue::Create(this,
+                                         ExecutionContext::From(script_state))),
       media_keys_(media_keys),
       session_type_(session_type),
       expiration_(std::numeric_limits<double>::quiet_NaN()),
diff --git a/third_party/WebKit/Source/modules/mediasource/MediaSource.cpp b/third_party/WebKit/Source/modules/mediasource/MediaSource.cpp
index c54d3fad..a325386 100644
--- a/third_party/WebKit/Source/modules/mediasource/MediaSource.cpp
+++ b/third_party/WebKit/Source/modules/mediasource/MediaSource.cpp
@@ -112,7 +112,7 @@
 MediaSource::MediaSource(ExecutionContext* context)
     : ContextLifecycleObserver(context),
       ready_state_(ClosedKeyword()),
-      async_event_queue_(MediaElementEventQueue::Create(this)),
+      async_event_queue_(MediaElementEventQueue::Create(this, context)),
       attached_element_(nullptr),
       source_buffers_(SourceBufferList::Create(GetExecutionContext(),
                                                async_event_queue_.Get())),
diff --git a/third_party/WebKit/Source/platform/RuntimeEnabledFeatures.json5 b/third_party/WebKit/Source/platform/RuntimeEnabledFeatures.json5
index fd5f304..d730c29 100644
--- a/third_party/WebKit/Source/platform/RuntimeEnabledFeatures.json5
+++ b/third_party/WebKit/Source/platform/RuntimeEnabledFeatures.json5
@@ -534,10 +534,6 @@
       status: "experimental",
     },
     {
-      name: "IntersectionObserver",
-      status: "stable",
-    },
-    {
       name: "JSImageDecode",
       status: "test",
     },
diff --git a/third_party/freetype/README.chromium b/third_party/freetype/README.chromium
index 01234c0..aad0fa0 100644
--- a/third_party/freetype/README.chromium
+++ b/third_party/freetype/README.chromium
@@ -1,7 +1,7 @@
 Name: FreeType
 URL: http://www.freetype.org/
-Version: VER-2-8-78
-Revision: 7e50824288fac5a36c2938fdb3e1c949ea53f982
+Version: VER-2-8-88
+Revision: f2e121ab11d1c9deb460d844d94f1d9fe6074f35
 License: Custom license "inspired by the BSD, Artistic, and IJG (Independent
          JPEG Group) licenses"
 License File: src/docs/FTL.TXT
diff --git a/third_party/freetype/include/freetype-custom-config/ftoption.h b/third_party/freetype/include/freetype-custom-config/ftoption.h
index 8fbfa28..34f64d9 100644
--- a/third_party/freetype/include/freetype-custom-config/ftoption.h
+++ b/third_party/freetype/include/freetype-custom-config/ftoption.h
@@ -107,20 +107,17 @@
 
   /*************************************************************************/
   /*                                                                       */
-  /* Uncomment the line below if you want to activate sub-pixel rendering  */
-  /* (a.k.a. LCD rendering, or ClearType) in this build of the library.    */
+  /* Uncomment the line below if you want to activate LCD rendering        */
+  /* technology similar to ClearType in this build of the library.  This   */
+  /* technology triples the resolution in the direction color subpixels.   */
+  /* To mitigate color fringes inherent to this technology, you also need  */
+  /* to explicitly set up LCD filtering.                                   */
   /*                                                                       */
   /* Note that this feature is covered by several Microsoft patents        */
   /* and should not be activated in any default build of the library.      */
-  /*                                                                       */
-  /* This macro has no impact on the FreeType API, only on its             */
-  /* _implementation_.  For example, using FT_RENDER_MODE_LCD when calling */
-  /* FT_Render_Glyph still generates a bitmap that is 3 times wider than   */
-  /* the original size in case this macro isn't defined; however, each     */
-  /* triplet of subpixels has R=G=B.                                       */
-  /*                                                                       */
-  /* This is done to allow FreeType clients to run unmodified, forcing     */
-  /* them to display normal gray-level anti-aliased glyphs.                */
+  /* When this macro is not defined, FreeType offers alternative LCD       */
+  /* rendering technology that produces excellent output without LCD       */
+  /* filtering.                                                            */
   /*                                                                       */
 #define FT_CONFIG_OPTION_SUBPIXEL_RENDERING
 
diff --git a/third_party/libvpx/README.chromium b/third_party/libvpx/README.chromium
index 6093bfc..cd8a43d 100644
--- a/third_party/libvpx/README.chromium
+++ b/third_party/libvpx/README.chromium
@@ -5,9 +5,9 @@
 License File: source/libvpx/LICENSE
 Security Critical: yes
 
-Date: Wednesday August 23 2017
+Date: Friday September 08 2017
 Branch: master
-Commit: 30c261b1ebe8f06d687cac5b3b442d51a7839d00
+Commit: 9a2dd7e67ed20a7389db618f1a8a25d5b3a3c89c
 
 Description:
 Contains the sources used to compile libvpx binaries used by Google Chrome and
diff --git a/third_party/libvpx/libvpx_srcs.gni b/third_party/libvpx/libvpx_srcs.gni
index 4ac157ee..e71332a 100644
--- a/third_party/libvpx/libvpx_srcs.gni
+++ b/third_party/libvpx/libvpx_srcs.gni
@@ -353,6 +353,7 @@
   "//third_party/libvpx/source/libvpx/vpx_scale/vpx_scale_rtcd.c",
   "//third_party/libvpx/source/libvpx/vpx_scale/yv12config.h",
   "//third_party/libvpx/source/libvpx/vpx_util/endian_inl.h",
+  "//third_party/libvpx/source/libvpx/vpx_util/vpx_atomics.h",
   "//third_party/libvpx/source/libvpx/vpx_util/vpx_thread.c",
   "//third_party/libvpx/source/libvpx/vpx_util/vpx_thread.h",
   "//third_party/libvpx/source/libvpx/vpx_util/vpx_write_yuv_frame.c",
@@ -423,6 +424,7 @@
   "//third_party/libvpx/source/libvpx/vpx_dsp/x86/highbd_idct32x32_add_sse2.c",
   "//third_party/libvpx/source/libvpx/vpx_dsp/x86/highbd_idct4x4_add_sse2.c",
   "//third_party/libvpx/source/libvpx/vpx_dsp/x86/highbd_idct8x8_add_sse2.c",
+  "//third_party/libvpx/source/libvpx/vpx_dsp/x86/highbd_intrapred_intrin_sse2.c",
   "//third_party/libvpx/source/libvpx/vpx_dsp/x86/highbd_loopfilter_sse2.c",
   "//third_party/libvpx/source/libvpx/vpx_dsp/x86/highbd_quantize_intrin_sse2.c",
   "//third_party/libvpx/source/libvpx/vpx_dsp/x86/highbd_variance_sse2.c",
@@ -812,6 +814,7 @@
   "//third_party/libvpx/source/libvpx/vpx_scale/vpx_scale_rtcd.c",
   "//third_party/libvpx/source/libvpx/vpx_scale/yv12config.h",
   "//third_party/libvpx/source/libvpx/vpx_util/endian_inl.h",
+  "//third_party/libvpx/source/libvpx/vpx_util/vpx_atomics.h",
   "//third_party/libvpx/source/libvpx/vpx_util/vpx_thread.c",
   "//third_party/libvpx/source/libvpx/vpx_util/vpx_thread.h",
   "//third_party/libvpx/source/libvpx/vpx_util/vpx_write_yuv_frame.c",
@@ -852,7 +855,6 @@
   "//third_party/libvpx/source/libvpx/vpx_dsp/x86/intrapred_ssse3.asm",
   "//third_party/libvpx/source/libvpx/vpx_dsp/x86/inv_wht_sse2.asm",
   "//third_party/libvpx/source/libvpx/vpx_dsp/x86/quantize_avx_x86_64.asm",
-  "//third_party/libvpx/source/libvpx/vpx_dsp/x86/quantize_ssse3_x86_64.asm",
   "//third_party/libvpx/source/libvpx/vpx_dsp/x86/sad4d_sse2.asm",
   "//third_party/libvpx/source/libvpx/vpx_dsp/x86/sad_sse2.asm",
   "//third_party/libvpx/source/libvpx/vpx_dsp/x86/sad_sse3.asm",
@@ -889,6 +891,7 @@
   "//third_party/libvpx/source/libvpx/vpx_dsp/x86/highbd_idct32x32_add_sse2.c",
   "//third_party/libvpx/source/libvpx/vpx_dsp/x86/highbd_idct4x4_add_sse2.c",
   "//third_party/libvpx/source/libvpx/vpx_dsp/x86/highbd_idct8x8_add_sse2.c",
+  "//third_party/libvpx/source/libvpx/vpx_dsp/x86/highbd_intrapred_intrin_sse2.c",
   "//third_party/libvpx/source/libvpx/vpx_dsp/x86/highbd_loopfilter_sse2.c",
   "//third_party/libvpx/source/libvpx/vpx_dsp/x86/highbd_quantize_intrin_sse2.c",
   "//third_party/libvpx/source/libvpx/vpx_dsp/x86/highbd_variance_sse2.c",
@@ -1261,6 +1264,7 @@
   "//third_party/libvpx/source/libvpx/vpx_scale/vpx_scale_rtcd.c",
   "//third_party/libvpx/source/libvpx/vpx_scale/yv12config.h",
   "//third_party/libvpx/source/libvpx/vpx_util/endian_inl.h",
+  "//third_party/libvpx/source/libvpx/vpx_util/vpx_atomics.h",
   "//third_party/libvpx/source/libvpx/vpx_util/vpx_thread.c",
   "//third_party/libvpx/source/libvpx/vpx_util/vpx_thread.h",
   "//third_party/libvpx/source/libvpx/vpx_util/vpx_write_yuv_frame.c",
@@ -1475,6 +1479,7 @@
   "//third_party/libvpx/source/libvpx/vp9/encoder/arm/neon/vp9_dct_neon.c",
   "//third_party/libvpx/source/libvpx/vp9/encoder/arm/neon/vp9_denoiser_neon.c",
   "//third_party/libvpx/source/libvpx/vp9/encoder/arm/neon/vp9_error_neon.c",
+  "//third_party/libvpx/source/libvpx/vp9/encoder/arm/neon/vp9_frame_scale_neon.c",
   "//third_party/libvpx/source/libvpx/vp9/encoder/arm/neon/vp9_quantize_neon.c",
   "//third_party/libvpx/source/libvpx/vp9/encoder/vp9_alt_ref_aq.c",
   "//third_party/libvpx/source/libvpx/vp9/encoder/vp9_alt_ref_aq.h",
@@ -1596,6 +1601,7 @@
   "//third_party/libvpx/source/libvpx/vpx_dsp/arm/sum_neon.h",
   "//third_party/libvpx/source/libvpx/vpx_dsp/arm/transpose_neon.h",
   "//third_party/libvpx/source/libvpx/vpx_dsp/arm/variance_neon.c",
+  "//third_party/libvpx/source/libvpx/vpx_dsp/arm/vpx_convolve8_neon.h",
   "//third_party/libvpx/source/libvpx/vpx_dsp/arm/vpx_convolve_neon.c",
   "//third_party/libvpx/source/libvpx/vpx_dsp/avg.c",
   "//third_party/libvpx/source/libvpx/vpx_dsp/bitreader.c",
@@ -1655,6 +1661,7 @@
   "//third_party/libvpx/source/libvpx/vpx_scale/vpx_scale_rtcd.c",
   "//third_party/libvpx/source/libvpx/vpx_scale/yv12config.h",
   "//third_party/libvpx/source/libvpx/vpx_util/endian_inl.h",
+  "//third_party/libvpx/source/libvpx/vpx_util/vpx_atomics.h",
   "//third_party/libvpx/source/libvpx/vpx_util/vpx_thread.c",
   "//third_party/libvpx/source/libvpx/vpx_util/vpx_thread.h",
   "//third_party/libvpx/source/libvpx/vpx_util/vpx_write_yuv_frame.c",
@@ -1954,6 +1961,7 @@
   "//third_party/libvpx/source/libvpx/vpx_dsp/arm/mem_neon.h",
   "//third_party/libvpx/source/libvpx/vpx_dsp/arm/sum_neon.h",
   "//third_party/libvpx/source/libvpx/vpx_dsp/arm/transpose_neon.h",
+  "//third_party/libvpx/source/libvpx/vpx_dsp/arm/vpx_convolve8_neon.h",
   "//third_party/libvpx/source/libvpx/vpx_dsp/avg.c",
   "//third_party/libvpx/source/libvpx/vpx_dsp/bitreader.c",
   "//third_party/libvpx/source/libvpx/vpx_dsp/bitreader.h",
@@ -2012,6 +2020,7 @@
   "//third_party/libvpx/source/libvpx/vpx_scale/vpx_scale_rtcd.c",
   "//third_party/libvpx/source/libvpx/vpx_scale/yv12config.h",
   "//third_party/libvpx/source/libvpx/vpx_util/endian_inl.h",
+  "//third_party/libvpx/source/libvpx/vpx_util/vpx_atomics.h",
   "//third_party/libvpx/source/libvpx/vpx_util/vpx_thread.c",
   "//third_party/libvpx/source/libvpx/vpx_util/vpx_thread.h",
   "//third_party/libvpx/source/libvpx/vpx_util/vpx_write_yuv_frame.c",
@@ -2056,6 +2065,7 @@
   "//third_party/libvpx/source/libvpx/vp9/encoder/arm/neon/vp9_dct_neon.c",
   "//third_party/libvpx/source/libvpx/vp9/encoder/arm/neon/vp9_denoiser_neon.c",
   "//third_party/libvpx/source/libvpx/vp9/encoder/arm/neon/vp9_error_neon.c",
+  "//third_party/libvpx/source/libvpx/vp9/encoder/arm/neon/vp9_frame_scale_neon.c",
   "//third_party/libvpx/source/libvpx/vp9/encoder/arm/neon/vp9_quantize_neon.c",
   "//third_party/libvpx/source/libvpx/vpx_dsp/arm/avg_neon.c",
   "//third_party/libvpx/source/libvpx/vpx_dsp/arm/avg_pred_neon.c",
@@ -2291,6 +2301,7 @@
   "//third_party/libvpx/source/libvpx/vp9/encoder/arm/neon/vp9_dct_neon.c",
   "//third_party/libvpx/source/libvpx/vp9/encoder/arm/neon/vp9_denoiser_neon.c",
   "//third_party/libvpx/source/libvpx/vp9/encoder/arm/neon/vp9_error_neon.c",
+  "//third_party/libvpx/source/libvpx/vp9/encoder/arm/neon/vp9_frame_scale_neon.c",
   "//third_party/libvpx/source/libvpx/vp9/encoder/arm/neon/vp9_quantize_neon.c",
   "//third_party/libvpx/source/libvpx/vp9/encoder/vp9_alt_ref_aq.c",
   "//third_party/libvpx/source/libvpx/vp9/encoder/vp9_alt_ref_aq.h",
@@ -2416,6 +2427,7 @@
   "//third_party/libvpx/source/libvpx/vpx_dsp/arm/transpose_neon.h",
   "//third_party/libvpx/source/libvpx/vpx_dsp/arm/variance_neon.c",
   "//third_party/libvpx/source/libvpx/vpx_dsp/arm/vpx_convolve8_neon.c",
+  "//third_party/libvpx/source/libvpx/vpx_dsp/arm/vpx_convolve8_neon.h",
   "//third_party/libvpx/source/libvpx/vpx_dsp/arm/vpx_convolve_avg_neon.c",
   "//third_party/libvpx/source/libvpx/vpx_dsp/arm/vpx_convolve_copy_neon.c",
   "//third_party/libvpx/source/libvpx/vpx_dsp/arm/vpx_convolve_neon.c",
@@ -2477,6 +2489,7 @@
   "//third_party/libvpx/source/libvpx/vpx_scale/vpx_scale_rtcd.c",
   "//third_party/libvpx/source/libvpx/vpx_scale/yv12config.h",
   "//third_party/libvpx/source/libvpx/vpx_util/endian_inl.h",
+  "//third_party/libvpx/source/libvpx/vpx_util/vpx_atomics.h",
   "//third_party/libvpx/source/libvpx/vpx_util/vpx_thread.c",
   "//third_party/libvpx/source/libvpx/vpx_util/vpx_thread.h",
   "//third_party/libvpx/source/libvpx/vpx_util/vpx_write_yuv_frame.c",
@@ -2815,6 +2828,7 @@
   "//third_party/libvpx/source/libvpx/vpx_scale/vpx_scale_rtcd.c",
   "//third_party/libvpx/source/libvpx/vpx_scale/yv12config.h",
   "//third_party/libvpx/source/libvpx/vpx_util/endian_inl.h",
+  "//third_party/libvpx/source/libvpx/vpx_util/vpx_atomics.h",
   "//third_party/libvpx/source/libvpx/vpx_util/vpx_thread.c",
   "//third_party/libvpx/source/libvpx/vpx_util/vpx_thread.h",
   "//third_party/libvpx/source/libvpx/vpx_util/vpx_write_yuv_frame.c",
@@ -3152,6 +3166,7 @@
   "//third_party/libvpx/source/libvpx/vpx_scale/vpx_scale_rtcd.c",
   "//third_party/libvpx/source/libvpx/vpx_scale/yv12config.h",
   "//third_party/libvpx/source/libvpx/vpx_util/endian_inl.h",
+  "//third_party/libvpx/source/libvpx/vpx_util/vpx_atomics.h",
   "//third_party/libvpx/source/libvpx/vpx_util/vpx_thread.c",
   "//third_party/libvpx/source/libvpx/vpx_util/vpx_thread.h",
   "//third_party/libvpx/source/libvpx/vpx_util/vpx_write_yuv_frame.c",
@@ -3489,6 +3504,7 @@
   "//third_party/libvpx/source/libvpx/vpx_scale/vpx_scale_rtcd.c",
   "//third_party/libvpx/source/libvpx/vpx_scale/yv12config.h",
   "//third_party/libvpx/source/libvpx/vpx_util/endian_inl.h",
+  "//third_party/libvpx/source/libvpx/vpx_util/vpx_atomics.h",
   "//third_party/libvpx/source/libvpx/vpx_util/vpx_thread.c",
   "//third_party/libvpx/source/libvpx/vpx_util/vpx_thread.h",
   "//third_party/libvpx/source/libvpx/vpx_util/vpx_write_yuv_frame.c",
diff --git a/third_party/libvpx/source/config/ios/arm-neon/vp9_rtcd.h b/third_party/libvpx/source/config/ios/arm-neon/vp9_rtcd.h
index 8cd3c19..bd078e4c 100644
--- a/third_party/libvpx/source/config/ios/arm-neon/vp9_rtcd.h
+++ b/third_party/libvpx/source/config/ios/arm-neon/vp9_rtcd.h
@@ -216,7 +216,11 @@
                                   struct yv12_buffer_config* dst,
                                   INTERP_FILTER filter_type,
                                   int phase_scaler);
-#define vp9_scale_and_extend_frame vp9_scale_and_extend_frame_c
+void vp9_scale_and_extend_frame_neon(const struct yv12_buffer_config* src,
+                                     struct yv12_buffer_config* dst,
+                                     INTERP_FILTER filter_type,
+                                     int phase_scaler);
+#define vp9_scale_and_extend_frame vp9_scale_and_extend_frame_neon
 
 void vp9_rtcd(void);
 
diff --git a/third_party/libvpx/source/config/ios/arm-neon/vpx_dsp_rtcd.h b/third_party/libvpx/source/config/ios/arm-neon/vpx_dsp_rtcd.h
index 5f54484..092dd0d 100644
--- a/third_party/libvpx/source/config/ios/arm-neon/vpx_dsp_rtcd.h
+++ b/third_party/libvpx/source/config/ios/arm-neon/vpx_dsp_rtcd.h
@@ -13,6 +13,7 @@
 
 #include "vpx/vpx_integer.h"
 #include "vpx_dsp/vpx_dsp_common.h"
+#include "vpx_dsp/vpx_filter.h"
 
 #ifdef __cplusplus
 extern "C" {
@@ -44,9 +45,10 @@
                      ptrdiff_t src_stride,
                      uint8_t* dst,
                      ptrdiff_t dst_stride,
-                     const int16_t* filter_x,
+                     const InterpKernel* filter,
+                     int x0_q4,
                      int x_step_q4,
-                     const int16_t* filter_y,
+                     int y0_q4,
                      int y_step_q4,
                      int w,
                      int h);
@@ -54,9 +56,10 @@
                         ptrdiff_t src_stride,
                         uint8_t* dst,
                         ptrdiff_t dst_stride,
-                        const int16_t* filter_x,
+                        const InterpKernel* filter,
+                        int x0_q4,
                         int x_step_q4,
-                        const int16_t* filter_y,
+                        int y0_q4,
                         int y_step_q4,
                         int w,
                         int h);
@@ -66,9 +69,10 @@
                          ptrdiff_t src_stride,
                          uint8_t* dst,
                          ptrdiff_t dst_stride,
-                         const int16_t* filter_x,
+                         const InterpKernel* filter,
+                         int x0_q4,
                          int x_step_q4,
-                         const int16_t* filter_y,
+                         int y0_q4,
                          int y_step_q4,
                          int w,
                          int h);
@@ -76,9 +80,10 @@
                             ptrdiff_t src_stride,
                             uint8_t* dst,
                             ptrdiff_t dst_stride,
-                            const int16_t* filter_x,
+                            const InterpKernel* filter,
+                            int x0_q4,
                             int x_step_q4,
-                            const int16_t* filter_y,
+                            int y0_q4,
                             int y_step_q4,
                             int w,
                             int h);
@@ -88,9 +93,10 @@
                                ptrdiff_t src_stride,
                                uint8_t* dst,
                                ptrdiff_t dst_stride,
-                               const int16_t* filter_x,
+                               const InterpKernel* filter,
+                               int x0_q4,
                                int x_step_q4,
-                               const int16_t* filter_y,
+                               int y0_q4,
                                int y_step_q4,
                                int w,
                                int h);
@@ -98,9 +104,10 @@
                                   ptrdiff_t src_stride,
                                   uint8_t* dst,
                                   ptrdiff_t dst_stride,
-                                  const int16_t* filter_x,
+                                  const InterpKernel* filter,
+                                  int x0_q4,
                                   int x_step_q4,
-                                  const int16_t* filter_y,
+                                  int y0_q4,
                                   int y_step_q4,
                                   int w,
                                   int h);
@@ -110,9 +117,10 @@
                               ptrdiff_t src_stride,
                               uint8_t* dst,
                               ptrdiff_t dst_stride,
-                              const int16_t* filter_x,
+                              const InterpKernel* filter,
+                              int x0_q4,
                               int x_step_q4,
-                              const int16_t* filter_y,
+                              int y0_q4,
                               int y_step_q4,
                               int w,
                               int h);
@@ -120,9 +128,10 @@
                                  ptrdiff_t src_stride,
                                  uint8_t* dst,
                                  ptrdiff_t dst_stride,
-                                 const int16_t* filter_x,
+                                 const InterpKernel* filter,
+                                 int x0_q4,
                                  int x_step_q4,
-                                 const int16_t* filter_y,
+                                 int y0_q4,
                                  int y_step_q4,
                                  int w,
                                  int h);
@@ -132,9 +141,10 @@
                            ptrdiff_t src_stride,
                            uint8_t* dst,
                            ptrdiff_t dst_stride,
-                           const int16_t* filter_x,
+                           const InterpKernel* filter,
+                           int x0_q4,
                            int x_step_q4,
-                           const int16_t* filter_y,
+                           int y0_q4,
                            int y_step_q4,
                            int w,
                            int h);
@@ -142,9 +152,10 @@
                               ptrdiff_t src_stride,
                               uint8_t* dst,
                               ptrdiff_t dst_stride,
-                              const int16_t* filter_x,
+                              const InterpKernel* filter,
+                              int x0_q4,
                               int x_step_q4,
-                              const int16_t* filter_y,
+                              int y0_q4,
                               int y_step_q4,
                               int w,
                               int h);
@@ -154,9 +165,10 @@
                           ptrdiff_t src_stride,
                           uint8_t* dst,
                           ptrdiff_t dst_stride,
-                          const int16_t* filter_x,
+                          const InterpKernel* filter,
+                          int x0_q4,
                           int x_step_q4,
-                          const int16_t* filter_y,
+                          int y0_q4,
                           int y_step_q4,
                           int w,
                           int h);
@@ -164,9 +176,10 @@
                              ptrdiff_t src_stride,
                              uint8_t* dst,
                              ptrdiff_t dst_stride,
-                             const int16_t* filter_x,
+                             const InterpKernel* filter,
+                             int x0_q4,
                              int x_step_q4,
-                             const int16_t* filter_y,
+                             int y0_q4,
                              int y_step_q4,
                              int w,
                              int h);
@@ -176,9 +189,10 @@
                         ptrdiff_t src_stride,
                         uint8_t* dst,
                         ptrdiff_t dst_stride,
-                        const int16_t* filter_x,
+                        const InterpKernel* filter,
+                        int x0_q4,
                         int x_step_q4,
-                        const int16_t* filter_y,
+                        int y0_q4,
                         int y_step_q4,
                         int w,
                         int h);
@@ -186,9 +200,10 @@
                            ptrdiff_t src_stride,
                            uint8_t* dst,
                            ptrdiff_t dst_stride,
-                           const int16_t* filter_x,
+                           const InterpKernel* filter,
+                           int x0_q4,
                            int x_step_q4,
-                           const int16_t* filter_y,
+                           int y0_q4,
                            int y_step_q4,
                            int w,
                            int h);
@@ -198,9 +213,10 @@
                          ptrdiff_t src_stride,
                          uint8_t* dst,
                          ptrdiff_t dst_stride,
-                         const int16_t* filter_x,
+                         const InterpKernel* filter,
+                         int x0_q4,
                          int x_step_q4,
-                         const int16_t* filter_y,
+                         int y0_q4,
                          int y_step_q4,
                          int w,
                          int h);
@@ -208,9 +224,10 @@
                             ptrdiff_t src_stride,
                             uint8_t* dst,
                             ptrdiff_t dst_stride,
-                            const int16_t* filter_x,
+                            const InterpKernel* filter,
+                            int x0_q4,
                             int x_step_q4,
-                            const int16_t* filter_y,
+                            int y0_q4,
                             int y_step_q4,
                             int w,
                             int h);
@@ -1646,9 +1663,10 @@
                      ptrdiff_t src_stride,
                      uint8_t* dst,
                      ptrdiff_t dst_stride,
-                     const int16_t* filter_x,
+                     const InterpKernel* filter,
+                     int x0_q4,
                      int x_step_q4,
-                     const int16_t* filter_y,
+                     int y0_q4,
                      int y_step_q4,
                      int w,
                      int h);
@@ -1658,9 +1676,10 @@
                          ptrdiff_t src_stride,
                          uint8_t* dst,
                          ptrdiff_t dst_stride,
-                         const int16_t* filter_x,
+                         const InterpKernel* filter,
+                         int x0_q4,
                          int x_step_q4,
-                         const int16_t* filter_y,
+                         int y0_q4,
                          int y_step_q4,
                          int w,
                          int h);
@@ -1670,9 +1689,10 @@
                             ptrdiff_t src_stride,
                             uint8_t* dst,
                             ptrdiff_t dst_stride,
-                            const int16_t* filter_x,
+                            const InterpKernel* filter,
+                            int x0_q4,
                             int x_step_q4,
-                            const int16_t* filter_y,
+                            int y0_q4,
                             int y_step_q4,
                             int w,
                             int h);
@@ -1682,9 +1702,10 @@
                            ptrdiff_t src_stride,
                            uint8_t* dst,
                            ptrdiff_t dst_stride,
-                           const int16_t* filter_x,
+                           const InterpKernel* filter,
+                           int x0_q4,
                            int x_step_q4,
-                           const int16_t* filter_y,
+                           int y0_q4,
                            int y_step_q4,
                            int w,
                            int h);
@@ -1694,9 +1715,10 @@
                         ptrdiff_t src_stride,
                         uint8_t* dst,
                         ptrdiff_t dst_stride,
-                        const int16_t* filter_x,
+                        const InterpKernel* filter,
+                        int x0_q4,
                         int x_step_q4,
-                        const int16_t* filter_y,
+                        int y0_q4,
                         int y_step_q4,
                         int w,
                         int h);
@@ -1706,9 +1728,10 @@
                        ptrdiff_t src_stride,
                        uint8_t* dst,
                        ptrdiff_t dst_stride,
-                       const int16_t* filter_x,
+                       const InterpKernel* filter,
+                       int x0_q4,
                        int x_step_q4,
-                       const int16_t* filter_y,
+                       int y0_q4,
                        int y_step_q4,
                        int w,
                        int h);
diff --git a/third_party/libvpx/source/config/ios/arm64/vp9_rtcd.h b/third_party/libvpx/source/config/ios/arm64/vp9_rtcd.h
index 8cd3c19..bd078e4c 100644
--- a/third_party/libvpx/source/config/ios/arm64/vp9_rtcd.h
+++ b/third_party/libvpx/source/config/ios/arm64/vp9_rtcd.h
@@ -216,7 +216,11 @@
                                   struct yv12_buffer_config* dst,
                                   INTERP_FILTER filter_type,
                                   int phase_scaler);
-#define vp9_scale_and_extend_frame vp9_scale_and_extend_frame_c
+void vp9_scale_and_extend_frame_neon(const struct yv12_buffer_config* src,
+                                     struct yv12_buffer_config* dst,
+                                     INTERP_FILTER filter_type,
+                                     int phase_scaler);
+#define vp9_scale_and_extend_frame vp9_scale_and_extend_frame_neon
 
 void vp9_rtcd(void);
 
diff --git a/third_party/libvpx/source/config/ios/arm64/vpx_dsp_rtcd.h b/third_party/libvpx/source/config/ios/arm64/vpx_dsp_rtcd.h
index 5f54484..092dd0d 100644
--- a/third_party/libvpx/source/config/ios/arm64/vpx_dsp_rtcd.h
+++ b/third_party/libvpx/source/config/ios/arm64/vpx_dsp_rtcd.h
@@ -13,6 +13,7 @@
 
 #include "vpx/vpx_integer.h"
 #include "vpx_dsp/vpx_dsp_common.h"
+#include "vpx_dsp/vpx_filter.h"
 
 #ifdef __cplusplus
 extern "C" {
@@ -44,9 +45,10 @@
                      ptrdiff_t src_stride,
                      uint8_t* dst,
                      ptrdiff_t dst_stride,
-                     const int16_t* filter_x,
+                     const InterpKernel* filter,
+                     int x0_q4,
                      int x_step_q4,
-                     const int16_t* filter_y,
+                     int y0_q4,
                      int y_step_q4,
                      int w,
                      int h);
@@ -54,9 +56,10 @@
                         ptrdiff_t src_stride,
                         uint8_t* dst,
                         ptrdiff_t dst_stride,
-                        const int16_t* filter_x,
+                        const InterpKernel* filter,
+                        int x0_q4,
                         int x_step_q4,
-                        const int16_t* filter_y,
+                        int y0_q4,
                         int y_step_q4,
                         int w,
                         int h);
@@ -66,9 +69,10 @@
                          ptrdiff_t src_stride,
                          uint8_t* dst,
                          ptrdiff_t dst_stride,
-                         const int16_t* filter_x,
+                         const InterpKernel* filter,
+                         int x0_q4,
                          int x_step_q4,
-                         const int16_t* filter_y,
+                         int y0_q4,
                          int y_step_q4,
                          int w,
                          int h);
@@ -76,9 +80,10 @@
                             ptrdiff_t src_stride,
                             uint8_t* dst,
                             ptrdiff_t dst_stride,
-                            const int16_t* filter_x,
+                            const InterpKernel* filter,
+                            int x0_q4,
                             int x_step_q4,
-                            const int16_t* filter_y,
+                            int y0_q4,
                             int y_step_q4,
                             int w,
                             int h);
@@ -88,9 +93,10 @@
                                ptrdiff_t src_stride,
                                uint8_t* dst,
                                ptrdiff_t dst_stride,
-                               const int16_t* filter_x,
+                               const InterpKernel* filter,
+                               int x0_q4,
                                int x_step_q4,
-                               const int16_t* filter_y,
+                               int y0_q4,
                                int y_step_q4,
                                int w,
                                int h);
@@ -98,9 +104,10 @@
                                   ptrdiff_t src_stride,
                                   uint8_t* dst,
                                   ptrdiff_t dst_stride,
-                                  const int16_t* filter_x,
+                                  const InterpKernel* filter,
+                                  int x0_q4,
                                   int x_step_q4,
-                                  const int16_t* filter_y,
+                                  int y0_q4,
                                   int y_step_q4,
                                   int w,
                                   int h);
@@ -110,9 +117,10 @@
                               ptrdiff_t src_stride,
                               uint8_t* dst,
                               ptrdiff_t dst_stride,
-                              const int16_t* filter_x,
+                              const InterpKernel* filter,
+                              int x0_q4,
                               int x_step_q4,
-                              const int16_t* filter_y,
+                              int y0_q4,
                               int y_step_q4,
                               int w,
                               int h);
@@ -120,9 +128,10 @@
                                  ptrdiff_t src_stride,
                                  uint8_t* dst,
                                  ptrdiff_t dst_stride,
-                                 const int16_t* filter_x,
+                                 const InterpKernel* filter,
+                                 int x0_q4,
                                  int x_step_q4,
-                                 const int16_t* filter_y,
+                                 int y0_q4,
                                  int y_step_q4,
                                  int w,
                                  int h);
@@ -132,9 +141,10 @@
                            ptrdiff_t src_stride,
                            uint8_t* dst,
                            ptrdiff_t dst_stride,
-                           const int16_t* filter_x,
+                           const InterpKernel* filter,
+                           int x0_q4,
                            int x_step_q4,
-                           const int16_t* filter_y,
+                           int y0_q4,
                            int y_step_q4,
                            int w,
                            int h);
@@ -142,9 +152,10 @@
                               ptrdiff_t src_stride,
                               uint8_t* dst,
                               ptrdiff_t dst_stride,
-                              const int16_t* filter_x,
+                              const InterpKernel* filter,
+                              int x0_q4,
                               int x_step_q4,
-                              const int16_t* filter_y,
+                              int y0_q4,
                               int y_step_q4,
                               int w,
                               int h);
@@ -154,9 +165,10 @@
                           ptrdiff_t src_stride,
                           uint8_t* dst,
                           ptrdiff_t dst_stride,
-                          const int16_t* filter_x,
+                          const InterpKernel* filter,
+                          int x0_q4,
                           int x_step_q4,
-                          const int16_t* filter_y,
+                          int y0_q4,
                           int y_step_q4,
                           int w,
                           int h);
@@ -164,9 +176,10 @@
                              ptrdiff_t src_stride,
                              uint8_t* dst,
                              ptrdiff_t dst_stride,
-                             const int16_t* filter_x,
+                             const InterpKernel* filter,
+                             int x0_q4,
                              int x_step_q4,
-                             const int16_t* filter_y,
+                             int y0_q4,
                              int y_step_q4,
                              int w,
                              int h);
@@ -176,9 +189,10 @@
                         ptrdiff_t src_stride,
                         uint8_t* dst,
                         ptrdiff_t dst_stride,
-                        const int16_t* filter_x,
+                        const InterpKernel* filter,
+                        int x0_q4,
                         int x_step_q4,
-                        const int16_t* filter_y,
+                        int y0_q4,
                         int y_step_q4,
                         int w,
                         int h);
@@ -186,9 +200,10 @@
                            ptrdiff_t src_stride,
                            uint8_t* dst,
                            ptrdiff_t dst_stride,
-                           const int16_t* filter_x,
+                           const InterpKernel* filter,
+                           int x0_q4,
                            int x_step_q4,
-                           const int16_t* filter_y,
+                           int y0_q4,
                            int y_step_q4,
                            int w,
                            int h);
@@ -198,9 +213,10 @@
                          ptrdiff_t src_stride,
                          uint8_t* dst,
                          ptrdiff_t dst_stride,
-                         const int16_t* filter_x,
+                         const InterpKernel* filter,
+                         int x0_q4,
                          int x_step_q4,
-                         const int16_t* filter_y,
+                         int y0_q4,
                          int y_step_q4,
                          int w,
                          int h);
@@ -208,9 +224,10 @@
                             ptrdiff_t src_stride,
                             uint8_t* dst,
                             ptrdiff_t dst_stride,
-                            const int16_t* filter_x,
+                            const InterpKernel* filter,
+                            int x0_q4,
                             int x_step_q4,
-                            const int16_t* filter_y,
+                            int y0_q4,
                             int y_step_q4,
                             int w,
                             int h);
@@ -1646,9 +1663,10 @@
                      ptrdiff_t src_stride,
                      uint8_t* dst,
                      ptrdiff_t dst_stride,
-                     const int16_t* filter_x,
+                     const InterpKernel* filter,
+                     int x0_q4,
                      int x_step_q4,
-                     const int16_t* filter_y,
+                     int y0_q4,
                      int y_step_q4,
                      int w,
                      int h);
@@ -1658,9 +1676,10 @@
                          ptrdiff_t src_stride,
                          uint8_t* dst,
                          ptrdiff_t dst_stride,
-                         const int16_t* filter_x,
+                         const InterpKernel* filter,
+                         int x0_q4,
                          int x_step_q4,
-                         const int16_t* filter_y,
+                         int y0_q4,
                          int y_step_q4,
                          int w,
                          int h);
@@ -1670,9 +1689,10 @@
                             ptrdiff_t src_stride,
                             uint8_t* dst,
                             ptrdiff_t dst_stride,
-                            const int16_t* filter_x,
+                            const InterpKernel* filter,
+                            int x0_q4,
                             int x_step_q4,
-                            const int16_t* filter_y,
+                            int y0_q4,
                             int y_step_q4,
                             int w,
                             int h);
@@ -1682,9 +1702,10 @@
                            ptrdiff_t src_stride,
                            uint8_t* dst,
                            ptrdiff_t dst_stride,
-                           const int16_t* filter_x,
+                           const InterpKernel* filter,
+                           int x0_q4,
                            int x_step_q4,
-                           const int16_t* filter_y,
+                           int y0_q4,
                            int y_step_q4,
                            int w,
                            int h);
@@ -1694,9 +1715,10 @@
                         ptrdiff_t src_stride,
                         uint8_t* dst,
                         ptrdiff_t dst_stride,
-                        const int16_t* filter_x,
+                        const InterpKernel* filter,
+                        int x0_q4,
                         int x_step_q4,
-                        const int16_t* filter_y,
+                        int y0_q4,
                         int y_step_q4,
                         int w,
                         int h);
@@ -1706,9 +1728,10 @@
                        ptrdiff_t src_stride,
                        uint8_t* dst,
                        ptrdiff_t dst_stride,
-                       const int16_t* filter_x,
+                       const InterpKernel* filter,
+                       int x0_q4,
                        int x_step_q4,
-                       const int16_t* filter_y,
+                       int y0_q4,
                        int y_step_q4,
                        int w,
                        int h);
diff --git a/third_party/libvpx/source/config/linux/arm-neon-cpu-detect/vp9_rtcd.h b/third_party/libvpx/source/config/linux/arm-neon-cpu-detect/vp9_rtcd.h
index 7a339e5..d16d9fd 100644
--- a/third_party/libvpx/source/config/linux/arm-neon-cpu-detect/vp9_rtcd.h
+++ b/third_party/libvpx/source/config/linux/arm-neon-cpu-detect/vp9_rtcd.h
@@ -264,7 +264,15 @@
                                   struct yv12_buffer_config* dst,
                                   INTERP_FILTER filter_type,
                                   int phase_scaler);
-#define vp9_scale_and_extend_frame vp9_scale_and_extend_frame_c
+void vp9_scale_and_extend_frame_neon(const struct yv12_buffer_config* src,
+                                     struct yv12_buffer_config* dst,
+                                     INTERP_FILTER filter_type,
+                                     int phase_scaler);
+RTCD_EXTERN void (*vp9_scale_and_extend_frame)(
+    const struct yv12_buffer_config* src,
+    struct yv12_buffer_config* dst,
+    INTERP_FILTER filter_type,
+    int phase_scaler);
 
 void vp9_rtcd(void);
 
@@ -298,6 +306,9 @@
   vp9_quantize_fp_32x32 = vp9_quantize_fp_32x32_c;
   if (flags & HAS_NEON)
     vp9_quantize_fp_32x32 = vp9_quantize_fp_32x32_neon;
+  vp9_scale_and_extend_frame = vp9_scale_and_extend_frame_c;
+  if (flags & HAS_NEON)
+    vp9_scale_and_extend_frame = vp9_scale_and_extend_frame_neon;
 }
 #endif
 
diff --git a/third_party/libvpx/source/config/linux/arm-neon-cpu-detect/vpx_dsp_rtcd.h b/third_party/libvpx/source/config/linux/arm-neon-cpu-detect/vpx_dsp_rtcd.h
index e395767..c88a44a 100644
--- a/third_party/libvpx/source/config/linux/arm-neon-cpu-detect/vpx_dsp_rtcd.h
+++ b/third_party/libvpx/source/config/linux/arm-neon-cpu-detect/vpx_dsp_rtcd.h
@@ -13,6 +13,7 @@
 
 #include "vpx/vpx_integer.h"
 #include "vpx_dsp/vpx_dsp_common.h"
+#include "vpx_dsp/vpx_filter.h"
 
 #ifdef __cplusplus
 extern "C" {
@@ -49,9 +50,10 @@
                      ptrdiff_t src_stride,
                      uint8_t* dst,
                      ptrdiff_t dst_stride,
-                     const int16_t* filter_x,
+                     const InterpKernel* filter,
+                     int x0_q4,
                      int x_step_q4,
-                     const int16_t* filter_y,
+                     int y0_q4,
                      int y_step_q4,
                      int w,
                      int h);
@@ -59,9 +61,10 @@
                         ptrdiff_t src_stride,
                         uint8_t* dst,
                         ptrdiff_t dst_stride,
-                        const int16_t* filter_x,
+                        const InterpKernel* filter,
+                        int x0_q4,
                         int x_step_q4,
-                        const int16_t* filter_y,
+                        int y0_q4,
                         int y_step_q4,
                         int w,
                         int h);
@@ -69,9 +72,10 @@
                                   ptrdiff_t src_stride,
                                   uint8_t* dst,
                                   ptrdiff_t dst_stride,
-                                  const int16_t* filter_x,
+                                  const InterpKernel* filter,
+                                  int x0_q4,
                                   int x_step_q4,
-                                  const int16_t* filter_y,
+                                  int y0_q4,
                                   int y_step_q4,
                                   int w,
                                   int h);
@@ -80,9 +84,10 @@
                          ptrdiff_t src_stride,
                          uint8_t* dst,
                          ptrdiff_t dst_stride,
-                         const int16_t* filter_x,
+                         const InterpKernel* filter,
+                         int x0_q4,
                          int x_step_q4,
-                         const int16_t* filter_y,
+                         int y0_q4,
                          int y_step_q4,
                          int w,
                          int h);
@@ -90,9 +95,10 @@
                             ptrdiff_t src_stride,
                             uint8_t* dst,
                             ptrdiff_t dst_stride,
-                            const int16_t* filter_x,
+                            const InterpKernel* filter,
+                            int x0_q4,
                             int x_step_q4,
-                            const int16_t* filter_y,
+                            int y0_q4,
                             int y_step_q4,
                             int w,
                             int h);
@@ -100,9 +106,10 @@
                                       ptrdiff_t src_stride,
                                       uint8_t* dst,
                                       ptrdiff_t dst_stride,
-                                      const int16_t* filter_x,
+                                      const InterpKernel* filter,
+                                      int x0_q4,
                                       int x_step_q4,
-                                      const int16_t* filter_y,
+                                      int y0_q4,
                                       int y_step_q4,
                                       int w,
                                       int h);
@@ -111,9 +118,10 @@
                                ptrdiff_t src_stride,
                                uint8_t* dst,
                                ptrdiff_t dst_stride,
-                               const int16_t* filter_x,
+                               const InterpKernel* filter,
+                               int x0_q4,
                                int x_step_q4,
-                               const int16_t* filter_y,
+                               int y0_q4,
                                int y_step_q4,
                                int w,
                                int h);
@@ -121,9 +129,10 @@
                                   ptrdiff_t src_stride,
                                   uint8_t* dst,
                                   ptrdiff_t dst_stride,
-                                  const int16_t* filter_x,
+                                  const InterpKernel* filter,
+                                  int x0_q4,
                                   int x_step_q4,
-                                  const int16_t* filter_y,
+                                  int y0_q4,
                                   int y_step_q4,
                                   int w,
                                   int h);
@@ -131,9 +140,10 @@
                                             ptrdiff_t src_stride,
                                             uint8_t* dst,
                                             ptrdiff_t dst_stride,
-                                            const int16_t* filter_x,
+                                            const InterpKernel* filter,
+                                            int x0_q4,
                                             int x_step_q4,
-                                            const int16_t* filter_y,
+                                            int y0_q4,
                                             int y_step_q4,
                                             int w,
                                             int h);
@@ -142,9 +152,10 @@
                               ptrdiff_t src_stride,
                               uint8_t* dst,
                               ptrdiff_t dst_stride,
-                              const int16_t* filter_x,
+                              const InterpKernel* filter,
+                              int x0_q4,
                               int x_step_q4,
-                              const int16_t* filter_y,
+                              int y0_q4,
                               int y_step_q4,
                               int w,
                               int h);
@@ -152,9 +163,10 @@
                                  ptrdiff_t src_stride,
                                  uint8_t* dst,
                                  ptrdiff_t dst_stride,
-                                 const int16_t* filter_x,
+                                 const InterpKernel* filter,
+                                 int x0_q4,
                                  int x_step_q4,
-                                 const int16_t* filter_y,
+                                 int y0_q4,
                                  int y_step_q4,
                                  int w,
                                  int h);
@@ -162,9 +174,10 @@
                                            ptrdiff_t src_stride,
                                            uint8_t* dst,
                                            ptrdiff_t dst_stride,
-                                           const int16_t* filter_x,
+                                           const InterpKernel* filter,
+                                           int x0_q4,
                                            int x_step_q4,
-                                           const int16_t* filter_y,
+                                           int y0_q4,
                                            int y_step_q4,
                                            int w,
                                            int h);
@@ -173,9 +186,10 @@
                            ptrdiff_t src_stride,
                            uint8_t* dst,
                            ptrdiff_t dst_stride,
-                           const int16_t* filter_x,
+                           const InterpKernel* filter,
+                           int x0_q4,
                            int x_step_q4,
-                           const int16_t* filter_y,
+                           int y0_q4,
                            int y_step_q4,
                            int w,
                            int h);
@@ -183,9 +197,10 @@
                               ptrdiff_t src_stride,
                               uint8_t* dst,
                               ptrdiff_t dst_stride,
-                              const int16_t* filter_x,
+                              const InterpKernel* filter,
+                              int x0_q4,
                               int x_step_q4,
-                              const int16_t* filter_y,
+                              int y0_q4,
                               int y_step_q4,
                               int w,
                               int h);
@@ -193,9 +208,10 @@
                                         ptrdiff_t src_stride,
                                         uint8_t* dst,
                                         ptrdiff_t dst_stride,
-                                        const int16_t* filter_x,
+                                        const InterpKernel* filter,
+                                        int x0_q4,
                                         int x_step_q4,
-                                        const int16_t* filter_y,
+                                        int y0_q4,
                                         int y_step_q4,
                                         int w,
                                         int h);
@@ -204,9 +220,10 @@
                           ptrdiff_t src_stride,
                           uint8_t* dst,
                           ptrdiff_t dst_stride,
-                          const int16_t* filter_x,
+                          const InterpKernel* filter,
+                          int x0_q4,
                           int x_step_q4,
-                          const int16_t* filter_y,
+                          int y0_q4,
                           int y_step_q4,
                           int w,
                           int h);
@@ -214,9 +231,10 @@
                              ptrdiff_t src_stride,
                              uint8_t* dst,
                              ptrdiff_t dst_stride,
-                             const int16_t* filter_x,
+                             const InterpKernel* filter,
+                             int x0_q4,
                              int x_step_q4,
-                             const int16_t* filter_y,
+                             int y0_q4,
                              int y_step_q4,
                              int w,
                              int h);
@@ -224,9 +242,10 @@
                                        ptrdiff_t src_stride,
                                        uint8_t* dst,
                                        ptrdiff_t dst_stride,
-                                       const int16_t* filter_x,
+                                       const InterpKernel* filter,
+                                       int x0_q4,
                                        int x_step_q4,
-                                       const int16_t* filter_y,
+                                       int y0_q4,
                                        int y_step_q4,
                                        int w,
                                        int h);
@@ -235,9 +254,10 @@
                         ptrdiff_t src_stride,
                         uint8_t* dst,
                         ptrdiff_t dst_stride,
-                        const int16_t* filter_x,
+                        const InterpKernel* filter,
+                        int x0_q4,
                         int x_step_q4,
-                        const int16_t* filter_y,
+                        int y0_q4,
                         int y_step_q4,
                         int w,
                         int h);
@@ -245,9 +265,10 @@
                            ptrdiff_t src_stride,
                            uint8_t* dst,
                            ptrdiff_t dst_stride,
-                           const int16_t* filter_x,
+                           const InterpKernel* filter,
+                           int x0_q4,
                            int x_step_q4,
-                           const int16_t* filter_y,
+                           int y0_q4,
                            int y_step_q4,
                            int w,
                            int h);
@@ -255,9 +276,10 @@
                                      ptrdiff_t src_stride,
                                      uint8_t* dst,
                                      ptrdiff_t dst_stride,
-                                     const int16_t* filter_x,
+                                     const InterpKernel* filter,
+                                     int x0_q4,
                                      int x_step_q4,
-                                     const int16_t* filter_y,
+                                     int y0_q4,
                                      int y_step_q4,
                                      int w,
                                      int h);
@@ -266,9 +288,10 @@
                          ptrdiff_t src_stride,
                          uint8_t* dst,
                          ptrdiff_t dst_stride,
-                         const int16_t* filter_x,
+                         const InterpKernel* filter,
+                         int x0_q4,
                          int x_step_q4,
-                         const int16_t* filter_y,
+                         int y0_q4,
                          int y_step_q4,
                          int w,
                          int h);
@@ -276,9 +299,10 @@
                             ptrdiff_t src_stride,
                             uint8_t* dst,
                             ptrdiff_t dst_stride,
-                            const int16_t* filter_x,
+                            const InterpKernel* filter,
+                            int x0_q4,
                             int x_step_q4,
-                            const int16_t* filter_y,
+                            int y0_q4,
                             int y_step_q4,
                             int w,
                             int h);
@@ -286,9 +310,10 @@
                                       ptrdiff_t src_stride,
                                       uint8_t* dst,
                                       ptrdiff_t dst_stride,
-                                      const int16_t* filter_x,
+                                      const InterpKernel* filter,
+                                      int x0_q4,
                                       int x_step_q4,
-                                      const int16_t* filter_y,
+                                      int y0_q4,
                                       int y_step_q4,
                                       int w,
                                       int h);
@@ -2120,9 +2145,10 @@
                      ptrdiff_t src_stride,
                      uint8_t* dst,
                      ptrdiff_t dst_stride,
-                     const int16_t* filter_x,
+                     const InterpKernel* filter,
+                     int x0_q4,
                      int x_step_q4,
-                     const int16_t* filter_y,
+                     int y0_q4,
                      int y_step_q4,
                      int w,
                      int h);
@@ -2132,9 +2158,10 @@
                          ptrdiff_t src_stride,
                          uint8_t* dst,
                          ptrdiff_t dst_stride,
-                         const int16_t* filter_x,
+                         const InterpKernel* filter,
+                         int x0_q4,
                          int x_step_q4,
-                         const int16_t* filter_y,
+                         int y0_q4,
                          int y_step_q4,
                          int w,
                          int h);
@@ -2144,9 +2171,10 @@
                             ptrdiff_t src_stride,
                             uint8_t* dst,
                             ptrdiff_t dst_stride,
-                            const int16_t* filter_x,
+                            const InterpKernel* filter,
+                            int x0_q4,
                             int x_step_q4,
-                            const int16_t* filter_y,
+                            int y0_q4,
                             int y_step_q4,
                             int w,
                             int h);
@@ -2156,9 +2184,10 @@
                            ptrdiff_t src_stride,
                            uint8_t* dst,
                            ptrdiff_t dst_stride,
-                           const int16_t* filter_x,
+                           const InterpKernel* filter,
+                           int x0_q4,
                            int x_step_q4,
-                           const int16_t* filter_y,
+                           int y0_q4,
                            int y_step_q4,
                            int w,
                            int h);
@@ -2168,9 +2197,10 @@
                         ptrdiff_t src_stride,
                         uint8_t* dst,
                         ptrdiff_t dst_stride,
-                        const int16_t* filter_x,
+                        const InterpKernel* filter,
+                        int x0_q4,
                         int x_step_q4,
-                        const int16_t* filter_y,
+                        int y0_q4,
                         int y_step_q4,
                         int w,
                         int h);
@@ -2180,9 +2210,10 @@
                        ptrdiff_t src_stride,
                        uint8_t* dst,
                        ptrdiff_t dst_stride,
-                       const int16_t* filter_x,
+                       const InterpKernel* filter,
+                       int x0_q4,
                        int x_step_q4,
-                       const int16_t* filter_y,
+                       int y0_q4,
                        int y_step_q4,
                        int w,
                        int h);
diff --git a/third_party/libvpx/source/config/linux/arm-neon/vp9_rtcd.h b/third_party/libvpx/source/config/linux/arm-neon/vp9_rtcd.h
index 8cd3c19..bd078e4c 100644
--- a/third_party/libvpx/source/config/linux/arm-neon/vp9_rtcd.h
+++ b/third_party/libvpx/source/config/linux/arm-neon/vp9_rtcd.h
@@ -216,7 +216,11 @@
                                   struct yv12_buffer_config* dst,
                                   INTERP_FILTER filter_type,
                                   int phase_scaler);
-#define vp9_scale_and_extend_frame vp9_scale_and_extend_frame_c
+void vp9_scale_and_extend_frame_neon(const struct yv12_buffer_config* src,
+                                     struct yv12_buffer_config* dst,
+                                     INTERP_FILTER filter_type,
+                                     int phase_scaler);
+#define vp9_scale_and_extend_frame vp9_scale_and_extend_frame_neon
 
 void vp9_rtcd(void);
 
diff --git a/third_party/libvpx/source/config/linux/arm-neon/vpx_dsp_rtcd.h b/third_party/libvpx/source/config/linux/arm-neon/vpx_dsp_rtcd.h
index 5f54484..092dd0d 100644
--- a/third_party/libvpx/source/config/linux/arm-neon/vpx_dsp_rtcd.h
+++ b/third_party/libvpx/source/config/linux/arm-neon/vpx_dsp_rtcd.h
@@ -13,6 +13,7 @@
 
 #include "vpx/vpx_integer.h"
 #include "vpx_dsp/vpx_dsp_common.h"
+#include "vpx_dsp/vpx_filter.h"
 
 #ifdef __cplusplus
 extern "C" {
@@ -44,9 +45,10 @@
                      ptrdiff_t src_stride,
                      uint8_t* dst,
                      ptrdiff_t dst_stride,
-                     const int16_t* filter_x,
+                     const InterpKernel* filter,
+                     int x0_q4,
                      int x_step_q4,
-                     const int16_t* filter_y,
+                     int y0_q4,
                      int y_step_q4,
                      int w,
                      int h);
@@ -54,9 +56,10 @@
                         ptrdiff_t src_stride,
                         uint8_t* dst,
                         ptrdiff_t dst_stride,
-                        const int16_t* filter_x,
+                        const InterpKernel* filter,
+                        int x0_q4,
                         int x_step_q4,
-                        const int16_t* filter_y,
+                        int y0_q4,
                         int y_step_q4,
                         int w,
                         int h);
@@ -66,9 +69,10 @@
                          ptrdiff_t src_stride,
                          uint8_t* dst,
                          ptrdiff_t dst_stride,
-                         const int16_t* filter_x,
+                         const InterpKernel* filter,
+                         int x0_q4,
                          int x_step_q4,
-                         const int16_t* filter_y,
+                         int y0_q4,
                          int y_step_q4,
                          int w,
                          int h);
@@ -76,9 +80,10 @@
                             ptrdiff_t src_stride,
                             uint8_t* dst,
                             ptrdiff_t dst_stride,
-                            const int16_t* filter_x,
+                            const InterpKernel* filter,
+                            int x0_q4,
                             int x_step_q4,
-                            const int16_t* filter_y,
+                            int y0_q4,
                             int y_step_q4,
                             int w,
                             int h);
@@ -88,9 +93,10 @@
                                ptrdiff_t src_stride,
                                uint8_t* dst,
                                ptrdiff_t dst_stride,
-                               const int16_t* filter_x,
+                               const InterpKernel* filter,
+                               int x0_q4,
                                int x_step_q4,
-                               const int16_t* filter_y,
+                               int y0_q4,
                                int y_step_q4,
                                int w,
                                int h);
@@ -98,9 +104,10 @@
                                   ptrdiff_t src_stride,
                                   uint8_t* dst,
                                   ptrdiff_t dst_stride,
-                                  const int16_t* filter_x,
+                                  const InterpKernel* filter,
+                                  int x0_q4,
                                   int x_step_q4,
-                                  const int16_t* filter_y,
+                                  int y0_q4,
                                   int y_step_q4,
                                   int w,
                                   int h);
@@ -110,9 +117,10 @@
                               ptrdiff_t src_stride,
                               uint8_t* dst,
                               ptrdiff_t dst_stride,
-                              const int16_t* filter_x,
+                              const InterpKernel* filter,
+                              int x0_q4,
                               int x_step_q4,
-                              const int16_t* filter_y,
+                              int y0_q4,
                               int y_step_q4,
                               int w,
                               int h);
@@ -120,9 +128,10 @@
                                  ptrdiff_t src_stride,
                                  uint8_t* dst,
                                  ptrdiff_t dst_stride,
-                                 const int16_t* filter_x,
+                                 const InterpKernel* filter,
+                                 int x0_q4,
                                  int x_step_q4,
-                                 const int16_t* filter_y,
+                                 int y0_q4,
                                  int y_step_q4,
                                  int w,
                                  int h);
@@ -132,9 +141,10 @@
                            ptrdiff_t src_stride,
                            uint8_t* dst,
                            ptrdiff_t dst_stride,
-                           const int16_t* filter_x,
+                           const InterpKernel* filter,
+                           int x0_q4,
                            int x_step_q4,
-                           const int16_t* filter_y,
+                           int y0_q4,
                            int y_step_q4,
                            int w,
                            int h);
@@ -142,9 +152,10 @@
                               ptrdiff_t src_stride,
                               uint8_t* dst,
                               ptrdiff_t dst_stride,
-                              const int16_t* filter_x,
+                              const InterpKernel* filter,
+                              int x0_q4,
                               int x_step_q4,
-                              const int16_t* filter_y,
+                              int y0_q4,
                               int y_step_q4,
                               int w,
                               int h);
@@ -154,9 +165,10 @@
                           ptrdiff_t src_stride,
                           uint8_t* dst,
                           ptrdiff_t dst_stride,
-                          const int16_t* filter_x,
+                          const InterpKernel* filter,
+                          int x0_q4,
                           int x_step_q4,
-                          const int16_t* filter_y,
+                          int y0_q4,
                           int y_step_q4,
                           int w,
                           int h);
@@ -164,9 +176,10 @@
                              ptrdiff_t src_stride,
                              uint8_t* dst,
                              ptrdiff_t dst_stride,
-                             const int16_t* filter_x,
+                             const InterpKernel* filter,
+                             int x0_q4,
                              int x_step_q4,
-                             const int16_t* filter_y,
+                             int y0_q4,
                              int y_step_q4,
                              int w,
                              int h);
@@ -176,9 +189,10 @@
                         ptrdiff_t src_stride,
                         uint8_t* dst,
                         ptrdiff_t dst_stride,
-                        const int16_t* filter_x,
+                        const InterpKernel* filter,
+                        int x0_q4,
                         int x_step_q4,
-                        const int16_t* filter_y,
+                        int y0_q4,
                         int y_step_q4,
                         int w,
                         int h);
@@ -186,9 +200,10 @@
                            ptrdiff_t src_stride,
                            uint8_t* dst,
                            ptrdiff_t dst_stride,
-                           const int16_t* filter_x,
+                           const InterpKernel* filter,
+                           int x0_q4,
                            int x_step_q4,
-                           const int16_t* filter_y,
+                           int y0_q4,
                            int y_step_q4,
                            int w,
                            int h);
@@ -198,9 +213,10 @@
                          ptrdiff_t src_stride,
                          uint8_t* dst,
                          ptrdiff_t dst_stride,
-                         const int16_t* filter_x,
+                         const InterpKernel* filter,
+                         int x0_q4,
                          int x_step_q4,
-                         const int16_t* filter_y,
+                         int y0_q4,
                          int y_step_q4,
                          int w,
                          int h);
@@ -208,9 +224,10 @@
                             ptrdiff_t src_stride,
                             uint8_t* dst,
                             ptrdiff_t dst_stride,
-                            const int16_t* filter_x,
+                            const InterpKernel* filter,
+                            int x0_q4,
                             int x_step_q4,
-                            const int16_t* filter_y,
+                            int y0_q4,
                             int y_step_q4,
                             int w,
                             int h);
@@ -1646,9 +1663,10 @@
                      ptrdiff_t src_stride,
                      uint8_t* dst,
                      ptrdiff_t dst_stride,
-                     const int16_t* filter_x,
+                     const InterpKernel* filter,
+                     int x0_q4,
                      int x_step_q4,
-                     const int16_t* filter_y,
+                     int y0_q4,
                      int y_step_q4,
                      int w,
                      int h);
@@ -1658,9 +1676,10 @@
                          ptrdiff_t src_stride,
                          uint8_t* dst,
                          ptrdiff_t dst_stride,
-                         const int16_t* filter_x,
+                         const InterpKernel* filter,
+                         int x0_q4,
                          int x_step_q4,
-                         const int16_t* filter_y,
+                         int y0_q4,
                          int y_step_q4,
                          int w,
                          int h);
@@ -1670,9 +1689,10 @@
                             ptrdiff_t src_stride,
                             uint8_t* dst,
                             ptrdiff_t dst_stride,
-                            const int16_t* filter_x,
+                            const InterpKernel* filter,
+                            int x0_q4,
                             int x_step_q4,
-                            const int16_t* filter_y,
+                            int y0_q4,
                             int y_step_q4,
                             int w,
                             int h);
@@ -1682,9 +1702,10 @@
                            ptrdiff_t src_stride,
                            uint8_t* dst,
                            ptrdiff_t dst_stride,
-                           const int16_t* filter_x,
+                           const InterpKernel* filter,
+                           int x0_q4,
                            int x_step_q4,
-                           const int16_t* filter_y,
+                           int y0_q4,
                            int y_step_q4,
                            int w,
                            int h);
@@ -1694,9 +1715,10 @@
                         ptrdiff_t src_stride,
                         uint8_t* dst,
                         ptrdiff_t dst_stride,
-                        const int16_t* filter_x,
+                        const InterpKernel* filter,
+                        int x0_q4,
                         int x_step_q4,
-                        const int16_t* filter_y,
+                        int y0_q4,
                         int y_step_q4,
                         int w,
                         int h);
@@ -1706,9 +1728,10 @@
                        ptrdiff_t src_stride,
                        uint8_t* dst,
                        ptrdiff_t dst_stride,
-                       const int16_t* filter_x,
+                       const InterpKernel* filter,
+                       int x0_q4,
                        int x_step_q4,
-                       const int16_t* filter_y,
+                       int y0_q4,
                        int y_step_q4,
                        int w,
                        int h);
diff --git a/third_party/libvpx/source/config/linux/arm/vpx_dsp_rtcd.h b/third_party/libvpx/source/config/linux/arm/vpx_dsp_rtcd.h
index 9d1cd0cc..8afa3b7 100644
--- a/third_party/libvpx/source/config/linux/arm/vpx_dsp_rtcd.h
+++ b/third_party/libvpx/source/config/linux/arm/vpx_dsp_rtcd.h
@@ -13,6 +13,7 @@
 
 #include "vpx/vpx_integer.h"
 #include "vpx_dsp/vpx_dsp_common.h"
+#include "vpx_dsp/vpx_filter.h"
 
 #ifdef __cplusplus
 extern "C" {
@@ -36,9 +37,10 @@
                      ptrdiff_t src_stride,
                      uint8_t* dst,
                      ptrdiff_t dst_stride,
-                     const int16_t* filter_x,
+                     const InterpKernel* filter,
+                     int x0_q4,
                      int x_step_q4,
-                     const int16_t* filter_y,
+                     int y0_q4,
                      int y_step_q4,
                      int w,
                      int h);
@@ -48,9 +50,10 @@
                          ptrdiff_t src_stride,
                          uint8_t* dst,
                          ptrdiff_t dst_stride,
-                         const int16_t* filter_x,
+                         const InterpKernel* filter,
+                         int x0_q4,
                          int x_step_q4,
-                         const int16_t* filter_y,
+                         int y0_q4,
                          int y_step_q4,
                          int w,
                          int h);
@@ -60,9 +63,10 @@
                                ptrdiff_t src_stride,
                                uint8_t* dst,
                                ptrdiff_t dst_stride,
-                               const int16_t* filter_x,
+                               const InterpKernel* filter,
+                               int x0_q4,
                                int x_step_q4,
-                               const int16_t* filter_y,
+                               int y0_q4,
                                int y_step_q4,
                                int w,
                                int h);
@@ -72,9 +76,10 @@
                               ptrdiff_t src_stride,
                               uint8_t* dst,
                               ptrdiff_t dst_stride,
-                              const int16_t* filter_x,
+                              const InterpKernel* filter,
+                              int x0_q4,
                               int x_step_q4,
-                              const int16_t* filter_y,
+                              int y0_q4,
                               int y_step_q4,
                               int w,
                               int h);
@@ -84,9 +89,10 @@
                            ptrdiff_t src_stride,
                            uint8_t* dst,
                            ptrdiff_t dst_stride,
-                           const int16_t* filter_x,
+                           const InterpKernel* filter,
+                           int x0_q4,
                            int x_step_q4,
-                           const int16_t* filter_y,
+                           int y0_q4,
                            int y_step_q4,
                            int w,
                            int h);
@@ -96,9 +102,10 @@
                           ptrdiff_t src_stride,
                           uint8_t* dst,
                           ptrdiff_t dst_stride,
-                          const int16_t* filter_x,
+                          const InterpKernel* filter,
+                          int x0_q4,
                           int x_step_q4,
-                          const int16_t* filter_y,
+                          int y0_q4,
                           int y_step_q4,
                           int w,
                           int h);
@@ -108,9 +115,10 @@
                         ptrdiff_t src_stride,
                         uint8_t* dst,
                         ptrdiff_t dst_stride,
-                        const int16_t* filter_x,
+                        const InterpKernel* filter,
+                        int x0_q4,
                         int x_step_q4,
-                        const int16_t* filter_y,
+                        int y0_q4,
                         int y_step_q4,
                         int w,
                         int h);
@@ -120,9 +128,10 @@
                          ptrdiff_t src_stride,
                          uint8_t* dst,
                          ptrdiff_t dst_stride,
-                         const int16_t* filter_x,
+                         const InterpKernel* filter,
+                         int x0_q4,
                          int x_step_q4,
-                         const int16_t* filter_y,
+                         int y0_q4,
                          int y_step_q4,
                          int w,
                          int h);
@@ -1064,9 +1073,10 @@
                      ptrdiff_t src_stride,
                      uint8_t* dst,
                      ptrdiff_t dst_stride,
-                     const int16_t* filter_x,
+                     const InterpKernel* filter,
+                     int x0_q4,
                      int x_step_q4,
-                     const int16_t* filter_y,
+                     int y0_q4,
                      int y_step_q4,
                      int w,
                      int h);
@@ -1076,9 +1086,10 @@
                          ptrdiff_t src_stride,
                          uint8_t* dst,
                          ptrdiff_t dst_stride,
-                         const int16_t* filter_x,
+                         const InterpKernel* filter,
+                         int x0_q4,
                          int x_step_q4,
-                         const int16_t* filter_y,
+                         int y0_q4,
                          int y_step_q4,
                          int w,
                          int h);
@@ -1088,9 +1099,10 @@
                             ptrdiff_t src_stride,
                             uint8_t* dst,
                             ptrdiff_t dst_stride,
-                            const int16_t* filter_x,
+                            const InterpKernel* filter,
+                            int x0_q4,
                             int x_step_q4,
-                            const int16_t* filter_y,
+                            int y0_q4,
                             int y_step_q4,
                             int w,
                             int h);
@@ -1100,9 +1112,10 @@
                            ptrdiff_t src_stride,
                            uint8_t* dst,
                            ptrdiff_t dst_stride,
-                           const int16_t* filter_x,
+                           const InterpKernel* filter,
+                           int x0_q4,
                            int x_step_q4,
-                           const int16_t* filter_y,
+                           int y0_q4,
                            int y_step_q4,
                            int w,
                            int h);
@@ -1112,9 +1125,10 @@
                         ptrdiff_t src_stride,
                         uint8_t* dst,
                         ptrdiff_t dst_stride,
-                        const int16_t* filter_x,
+                        const InterpKernel* filter,
+                        int x0_q4,
                         int x_step_q4,
-                        const int16_t* filter_y,
+                        int y0_q4,
                         int y_step_q4,
                         int w,
                         int h);
@@ -1124,9 +1138,10 @@
                        ptrdiff_t src_stride,
                        uint8_t* dst,
                        ptrdiff_t dst_stride,
-                       const int16_t* filter_x,
+                       const InterpKernel* filter,
+                       int x0_q4,
                        int x_step_q4,
-                       const int16_t* filter_y,
+                       int y0_q4,
                        int y_step_q4,
                        int w,
                        int h);
diff --git a/third_party/libvpx/source/config/linux/arm64/vp9_rtcd.h b/third_party/libvpx/source/config/linux/arm64/vp9_rtcd.h
index 8cd3c19..bd078e4c 100644
--- a/third_party/libvpx/source/config/linux/arm64/vp9_rtcd.h
+++ b/third_party/libvpx/source/config/linux/arm64/vp9_rtcd.h
@@ -216,7 +216,11 @@
                                   struct yv12_buffer_config* dst,
                                   INTERP_FILTER filter_type,
                                   int phase_scaler);
-#define vp9_scale_and_extend_frame vp9_scale_and_extend_frame_c
+void vp9_scale_and_extend_frame_neon(const struct yv12_buffer_config* src,
+                                     struct yv12_buffer_config* dst,
+                                     INTERP_FILTER filter_type,
+                                     int phase_scaler);
+#define vp9_scale_and_extend_frame vp9_scale_and_extend_frame_neon
 
 void vp9_rtcd(void);
 
diff --git a/third_party/libvpx/source/config/linux/arm64/vpx_dsp_rtcd.h b/third_party/libvpx/source/config/linux/arm64/vpx_dsp_rtcd.h
index 5f54484..092dd0d 100644
--- a/third_party/libvpx/source/config/linux/arm64/vpx_dsp_rtcd.h
+++ b/third_party/libvpx/source/config/linux/arm64/vpx_dsp_rtcd.h
@@ -13,6 +13,7 @@
 
 #include "vpx/vpx_integer.h"
 #include "vpx_dsp/vpx_dsp_common.h"
+#include "vpx_dsp/vpx_filter.h"
 
 #ifdef __cplusplus
 extern "C" {
@@ -44,9 +45,10 @@
                      ptrdiff_t src_stride,
                      uint8_t* dst,
                      ptrdiff_t dst_stride,
-                     const int16_t* filter_x,
+                     const InterpKernel* filter,
+                     int x0_q4,
                      int x_step_q4,
-                     const int16_t* filter_y,
+                     int y0_q4,
                      int y_step_q4,
                      int w,
                      int h);
@@ -54,9 +56,10 @@
                         ptrdiff_t src_stride,
                         uint8_t* dst,
                         ptrdiff_t dst_stride,
-                        const int16_t* filter_x,
+                        const InterpKernel* filter,
+                        int x0_q4,
                         int x_step_q4,
-                        const int16_t* filter_y,
+                        int y0_q4,
                         int y_step_q4,
                         int w,
                         int h);
@@ -66,9 +69,10 @@
                          ptrdiff_t src_stride,
                          uint8_t* dst,
                          ptrdiff_t dst_stride,
-                         const int16_t* filter_x,
+                         const InterpKernel* filter,
+                         int x0_q4,
                          int x_step_q4,
-                         const int16_t* filter_y,
+                         int y0_q4,
                          int y_step_q4,
                          int w,
                          int h);
@@ -76,9 +80,10 @@
                             ptrdiff_t src_stride,
                             uint8_t* dst,
                             ptrdiff_t dst_stride,
-                            const int16_t* filter_x,
+                            const InterpKernel* filter,
+                            int x0_q4,
                             int x_step_q4,
-                            const int16_t* filter_y,
+                            int y0_q4,
                             int y_step_q4,
                             int w,
                             int h);
@@ -88,9 +93,10 @@
                                ptrdiff_t src_stride,
                                uint8_t* dst,
                                ptrdiff_t dst_stride,
-                               const int16_t* filter_x,
+                               const InterpKernel* filter,
+                               int x0_q4,
                                int x_step_q4,
-                               const int16_t* filter_y,
+                               int y0_q4,
                                int y_step_q4,
                                int w,
                                int h);
@@ -98,9 +104,10 @@
                                   ptrdiff_t src_stride,
                                   uint8_t* dst,
                                   ptrdiff_t dst_stride,
-                                  const int16_t* filter_x,
+                                  const InterpKernel* filter,
+                                  int x0_q4,
                                   int x_step_q4,
-                                  const int16_t* filter_y,
+                                  int y0_q4,
                                   int y_step_q4,
                                   int w,
                                   int h);
@@ -110,9 +117,10 @@
                               ptrdiff_t src_stride,
                               uint8_t* dst,
                               ptrdiff_t dst_stride,
-                              const int16_t* filter_x,
+                              const InterpKernel* filter,
+                              int x0_q4,
                               int x_step_q4,
-                              const int16_t* filter_y,
+                              int y0_q4,
                               int y_step_q4,
                               int w,
                               int h);
@@ -120,9 +128,10 @@
                                  ptrdiff_t src_stride,
                                  uint8_t* dst,
                                  ptrdiff_t dst_stride,
-                                 const int16_t* filter_x,
+                                 const InterpKernel* filter,
+                                 int x0_q4,
                                  int x_step_q4,
-                                 const int16_t* filter_y,
+                                 int y0_q4,
                                  int y_step_q4,
                                  int w,
                                  int h);
@@ -132,9 +141,10 @@
                            ptrdiff_t src_stride,
                            uint8_t* dst,
                            ptrdiff_t dst_stride,
-                           const int16_t* filter_x,
+                           const InterpKernel* filter,
+                           int x0_q4,
                            int x_step_q4,
-                           const int16_t* filter_y,
+                           int y0_q4,
                            int y_step_q4,
                            int w,
                            int h);
@@ -142,9 +152,10 @@
                               ptrdiff_t src_stride,
                               uint8_t* dst,
                               ptrdiff_t dst_stride,
-                              const int16_t* filter_x,
+                              const InterpKernel* filter,
+                              int x0_q4,
                               int x_step_q4,
-                              const int16_t* filter_y,
+                              int y0_q4,
                               int y_step_q4,
                               int w,
                               int h);
@@ -154,9 +165,10 @@
                           ptrdiff_t src_stride,
                           uint8_t* dst,
                           ptrdiff_t dst_stride,
-                          const int16_t* filter_x,
+                          const InterpKernel* filter,
+                          int x0_q4,
                           int x_step_q4,
-                          const int16_t* filter_y,
+                          int y0_q4,
                           int y_step_q4,
                           int w,
                           int h);
@@ -164,9 +176,10 @@
                              ptrdiff_t src_stride,
                              uint8_t* dst,
                              ptrdiff_t dst_stride,
-                             const int16_t* filter_x,
+                             const InterpKernel* filter,
+                             int x0_q4,
                              int x_step_q4,
-                             const int16_t* filter_y,
+                             int y0_q4,
                              int y_step_q4,
                              int w,
                              int h);
@@ -176,9 +189,10 @@
                         ptrdiff_t src_stride,
                         uint8_t* dst,
                         ptrdiff_t dst_stride,
-                        const int16_t* filter_x,
+                        const InterpKernel* filter,
+                        int x0_q4,
                         int x_step_q4,
-                        const int16_t* filter_y,
+                        int y0_q4,
                         int y_step_q4,
                         int w,
                         int h);
@@ -186,9 +200,10 @@
                            ptrdiff_t src_stride,
                            uint8_t* dst,
                            ptrdiff_t dst_stride,
-                           const int16_t* filter_x,
+                           const InterpKernel* filter,
+                           int x0_q4,
                            int x_step_q4,
-                           const int16_t* filter_y,
+                           int y0_q4,
                            int y_step_q4,
                            int w,
                            int h);
@@ -198,9 +213,10 @@
                          ptrdiff_t src_stride,
                          uint8_t* dst,
                          ptrdiff_t dst_stride,
-                         const int16_t* filter_x,
+                         const InterpKernel* filter,
+                         int x0_q4,
                          int x_step_q4,
-                         const int16_t* filter_y,
+                         int y0_q4,
                          int y_step_q4,
                          int w,
                          int h);
@@ -208,9 +224,10 @@
                             ptrdiff_t src_stride,
                             uint8_t* dst,
                             ptrdiff_t dst_stride,
-                            const int16_t* filter_x,
+                            const InterpKernel* filter,
+                            int x0_q4,
                             int x_step_q4,
-                            const int16_t* filter_y,
+                            int y0_q4,
                             int y_step_q4,
                             int w,
                             int h);
@@ -1646,9 +1663,10 @@
                      ptrdiff_t src_stride,
                      uint8_t* dst,
                      ptrdiff_t dst_stride,
-                     const int16_t* filter_x,
+                     const InterpKernel* filter,
+                     int x0_q4,
                      int x_step_q4,
-                     const int16_t* filter_y,
+                     int y0_q4,
                      int y_step_q4,
                      int w,
                      int h);
@@ -1658,9 +1676,10 @@
                          ptrdiff_t src_stride,
                          uint8_t* dst,
                          ptrdiff_t dst_stride,
-                         const int16_t* filter_x,
+                         const InterpKernel* filter,
+                         int x0_q4,
                          int x_step_q4,
-                         const int16_t* filter_y,
+                         int y0_q4,
                          int y_step_q4,
                          int w,
                          int h);
@@ -1670,9 +1689,10 @@
                             ptrdiff_t src_stride,
                             uint8_t* dst,
                             ptrdiff_t dst_stride,
-                            const int16_t* filter_x,
+                            const InterpKernel* filter,
+                            int x0_q4,
                             int x_step_q4,
-                            const int16_t* filter_y,
+                            int y0_q4,
                             int y_step_q4,
                             int w,
                             int h);
@@ -1682,9 +1702,10 @@
                            ptrdiff_t src_stride,
                            uint8_t* dst,
                            ptrdiff_t dst_stride,
-                           const int16_t* filter_x,
+                           const InterpKernel* filter,
+                           int x0_q4,
                            int x_step_q4,
-                           const int16_t* filter_y,
+                           int y0_q4,
                            int y_step_q4,
                            int w,
                            int h);
@@ -1694,9 +1715,10 @@
                         ptrdiff_t src_stride,
                         uint8_t* dst,
                         ptrdiff_t dst_stride,
-                        const int16_t* filter_x,
+                        const InterpKernel* filter,
+                        int x0_q4,
                         int x_step_q4,
-                        const int16_t* filter_y,
+                        int y0_q4,
                         int y_step_q4,
                         int w,
                         int h);
@@ -1706,9 +1728,10 @@
                        ptrdiff_t src_stride,
                        uint8_t* dst,
                        ptrdiff_t dst_stride,
-                       const int16_t* filter_x,
+                       const InterpKernel* filter,
+                       int x0_q4,
                        int x_step_q4,
-                       const int16_t* filter_y,
+                       int y0_q4,
                        int y_step_q4,
                        int w,
                        int h);
diff --git a/third_party/libvpx/source/config/linux/generic/vpx_dsp_rtcd.h b/third_party/libvpx/source/config/linux/generic/vpx_dsp_rtcd.h
index 114b01b..3f20ed8 100644
--- a/third_party/libvpx/source/config/linux/generic/vpx_dsp_rtcd.h
+++ b/third_party/libvpx/source/config/linux/generic/vpx_dsp_rtcd.h
@@ -13,6 +13,7 @@
 
 #include "vpx/vpx_integer.h"
 #include "vpx_dsp/vpx_dsp_common.h"
+#include "vpx_dsp/vpx_filter.h"
 
 #ifdef __cplusplus
 extern "C" {
@@ -36,9 +37,10 @@
                      ptrdiff_t src_stride,
                      uint8_t* dst,
                      ptrdiff_t dst_stride,
-                     const int16_t* filter_x,
+                     const InterpKernel* filter,
+                     int x0_q4,
                      int x_step_q4,
-                     const int16_t* filter_y,
+                     int y0_q4,
                      int y_step_q4,
                      int w,
                      int h);
@@ -48,9 +50,10 @@
                          ptrdiff_t src_stride,
                          uint8_t* dst,
                          ptrdiff_t dst_stride,
-                         const int16_t* filter_x,
+                         const InterpKernel* filter,
+                         int x0_q4,
                          int x_step_q4,
-                         const int16_t* filter_y,
+                         int y0_q4,
                          int y_step_q4,
                          int w,
                          int h);
@@ -60,9 +63,10 @@
                                ptrdiff_t src_stride,
                                uint8_t* dst,
                                ptrdiff_t dst_stride,
-                               const int16_t* filter_x,
+                               const InterpKernel* filter,
+                               int x0_q4,
                                int x_step_q4,
-                               const int16_t* filter_y,
+                               int y0_q4,
                                int y_step_q4,
                                int w,
                                int h);
@@ -72,9 +76,10 @@
                               ptrdiff_t src_stride,
                               uint8_t* dst,
                               ptrdiff_t dst_stride,
-                              const int16_t* filter_x,
+                              const InterpKernel* filter,
+                              int x0_q4,
                               int x_step_q4,
-                              const int16_t* filter_y,
+                              int y0_q4,
                               int y_step_q4,
                               int w,
                               int h);
@@ -84,9 +89,10 @@
                            ptrdiff_t src_stride,
                            uint8_t* dst,
                            ptrdiff_t dst_stride,
-                           const int16_t* filter_x,
+                           const InterpKernel* filter,
+                           int x0_q4,
                            int x_step_q4,
-                           const int16_t* filter_y,
+                           int y0_q4,
                            int y_step_q4,
                            int w,
                            int h);
@@ -96,9 +102,10 @@
                           ptrdiff_t src_stride,
                           uint8_t* dst,
                           ptrdiff_t dst_stride,
-                          const int16_t* filter_x,
+                          const InterpKernel* filter,
+                          int x0_q4,
                           int x_step_q4,
-                          const int16_t* filter_y,
+                          int y0_q4,
                           int y_step_q4,
                           int w,
                           int h);
@@ -108,9 +115,10 @@
                         ptrdiff_t src_stride,
                         uint8_t* dst,
                         ptrdiff_t dst_stride,
-                        const int16_t* filter_x,
+                        const InterpKernel* filter,
+                        int x0_q4,
                         int x_step_q4,
-                        const int16_t* filter_y,
+                        int y0_q4,
                         int y_step_q4,
                         int w,
                         int h);
@@ -120,9 +128,10 @@
                          ptrdiff_t src_stride,
                          uint8_t* dst,
                          ptrdiff_t dst_stride,
-                         const int16_t* filter_x,
+                         const InterpKernel* filter,
+                         int x0_q4,
                          int x_step_q4,
-                         const int16_t* filter_y,
+                         int y0_q4,
                          int y_step_q4,
                          int w,
                          int h);
@@ -1724,9 +1733,10 @@
                             ptrdiff_t src_stride,
                             uint16_t* dst,
                             ptrdiff_t dst_stride,
-                            const int16_t* filter_x,
+                            const InterpKernel* filter,
+                            int x0_q4,
                             int x_step_q4,
-                            const int16_t* filter_y,
+                            int y0_q4,
                             int y_step_q4,
                             int w,
                             int h,
@@ -1737,9 +1747,10 @@
                                 ptrdiff_t src_stride,
                                 uint16_t* dst,
                                 ptrdiff_t dst_stride,
-                                const int16_t* filter_x,
+                                const InterpKernel* filter,
+                                int x0_q4,
                                 int x_step_q4,
-                                const int16_t* filter_y,
+                                int y0_q4,
                                 int y_step_q4,
                                 int w,
                                 int h,
@@ -1750,9 +1761,10 @@
                                       ptrdiff_t src_stride,
                                       uint16_t* dst,
                                       ptrdiff_t dst_stride,
-                                      const int16_t* filter_x,
+                                      const InterpKernel* filter,
+                                      int x0_q4,
                                       int x_step_q4,
-                                      const int16_t* filter_y,
+                                      int y0_q4,
                                       int y_step_q4,
                                       int w,
                                       int h,
@@ -1763,9 +1775,10 @@
                                      ptrdiff_t src_stride,
                                      uint16_t* dst,
                                      ptrdiff_t dst_stride,
-                                     const int16_t* filter_x,
+                                     const InterpKernel* filter,
+                                     int x0_q4,
                                      int x_step_q4,
-                                     const int16_t* filter_y,
+                                     int y0_q4,
                                      int y_step_q4,
                                      int w,
                                      int h,
@@ -1776,9 +1789,10 @@
                                   ptrdiff_t src_stride,
                                   uint16_t* dst,
                                   ptrdiff_t dst_stride,
-                                  const int16_t* filter_x,
+                                  const InterpKernel* filter,
+                                  int x0_q4,
                                   int x_step_q4,
-                                  const int16_t* filter_y,
+                                  int y0_q4,
                                   int y_step_q4,
                                   int w,
                                   int h,
@@ -1789,9 +1803,10 @@
                                  ptrdiff_t src_stride,
                                  uint16_t* dst,
                                  ptrdiff_t dst_stride,
-                                 const int16_t* filter_x,
+                                 const InterpKernel* filter,
+                                 int x0_q4,
                                  int x_step_q4,
-                                 const int16_t* filter_y,
+                                 int y0_q4,
                                  int y_step_q4,
                                  int w,
                                  int h,
@@ -1802,9 +1817,10 @@
                                ptrdiff_t src_stride,
                                uint16_t* dst,
                                ptrdiff_t dst_stride,
-                               const int16_t* filter_x,
+                               const InterpKernel* filter,
+                               int x0_q4,
                                int x_step_q4,
-                               const int16_t* filter_y,
+                               int y0_q4,
                                int y_step_q4,
                                int w,
                                int h,
@@ -1815,9 +1831,10 @@
                                 ptrdiff_t src_stride,
                                 uint16_t* dst,
                                 ptrdiff_t dst_stride,
-                                const int16_t* filter_x,
+                                const InterpKernel* filter,
+                                int x0_q4,
                                 int x_step_q4,
-                                const int16_t* filter_y,
+                                int y0_q4,
                                 int y_step_q4,
                                 int w,
                                 int h,
@@ -3323,9 +3340,10 @@
                      ptrdiff_t src_stride,
                      uint8_t* dst,
                      ptrdiff_t dst_stride,
-                     const int16_t* filter_x,
+                     const InterpKernel* filter,
+                     int x0_q4,
                      int x_step_q4,
-                     const int16_t* filter_y,
+                     int y0_q4,
                      int y_step_q4,
                      int w,
                      int h);
@@ -3335,9 +3353,10 @@
                          ptrdiff_t src_stride,
                          uint8_t* dst,
                          ptrdiff_t dst_stride,
-                         const int16_t* filter_x,
+                         const InterpKernel* filter,
+                         int x0_q4,
                          int x_step_q4,
-                         const int16_t* filter_y,
+                         int y0_q4,
                          int y_step_q4,
                          int w,
                          int h);
@@ -3347,9 +3366,10 @@
                             ptrdiff_t src_stride,
                             uint8_t* dst,
                             ptrdiff_t dst_stride,
-                            const int16_t* filter_x,
+                            const InterpKernel* filter,
+                            int x0_q4,
                             int x_step_q4,
-                            const int16_t* filter_y,
+                            int y0_q4,
                             int y_step_q4,
                             int w,
                             int h);
@@ -3359,9 +3379,10 @@
                            ptrdiff_t src_stride,
                            uint8_t* dst,
                            ptrdiff_t dst_stride,
-                           const int16_t* filter_x,
+                           const InterpKernel* filter,
+                           int x0_q4,
                            int x_step_q4,
-                           const int16_t* filter_y,
+                           int y0_q4,
                            int y_step_q4,
                            int w,
                            int h);
@@ -3371,9 +3392,10 @@
                         ptrdiff_t src_stride,
                         uint8_t* dst,
                         ptrdiff_t dst_stride,
-                        const int16_t* filter_x,
+                        const InterpKernel* filter,
+                        int x0_q4,
                         int x_step_q4,
-                        const int16_t* filter_y,
+                        int y0_q4,
                         int y_step_q4,
                         int w,
                         int h);
@@ -3383,9 +3405,10 @@
                        ptrdiff_t src_stride,
                        uint8_t* dst,
                        ptrdiff_t dst_stride,
-                       const int16_t* filter_x,
+                       const InterpKernel* filter,
+                       int x0_q4,
                        int x_step_q4,
-                       const int16_t* filter_y,
+                       int y0_q4,
                        int y_step_q4,
                        int w,
                        int h);
diff --git a/third_party/libvpx/source/config/linux/ia32/vpx_dsp_rtcd.h b/third_party/libvpx/source/config/linux/ia32/vpx_dsp_rtcd.h
index 10f0c335..66e7b01 100644
--- a/third_party/libvpx/source/config/linux/ia32/vpx_dsp_rtcd.h
+++ b/third_party/libvpx/source/config/linux/ia32/vpx_dsp_rtcd.h
@@ -13,6 +13,7 @@
 
 #include "vpx/vpx_integer.h"
 #include "vpx_dsp/vpx_dsp_common.h"
+#include "vpx_dsp/vpx_filter.h"
 
 #ifdef __cplusplus
 extern "C" {
@@ -49,9 +50,10 @@
                      ptrdiff_t src_stride,
                      uint8_t* dst,
                      ptrdiff_t dst_stride,
-                     const int16_t* filter_x,
+                     const InterpKernel* filter,
+                     int x0_q4,
                      int x_step_q4,
-                     const int16_t* filter_y,
+                     int y0_q4,
                      int y_step_q4,
                      int w,
                      int h);
@@ -59,9 +61,10 @@
                         ptrdiff_t src_stride,
                         uint8_t* dst,
                         ptrdiff_t dst_stride,
-                        const int16_t* filter_x,
+                        const InterpKernel* filter,
+                        int x0_q4,
                         int x_step_q4,
-                        const int16_t* filter_y,
+                        int y0_q4,
                         int y_step_q4,
                         int w,
                         int h);
@@ -69,9 +72,10 @@
                          ptrdiff_t src_stride,
                          uint8_t* dst,
                          ptrdiff_t dst_stride,
-                         const int16_t* filter_x,
+                         const InterpKernel* filter,
+                         int x0_q4,
                          int x_step_q4,
-                         const int16_t* filter_y,
+                         int y0_q4,
                          int y_step_q4,
                          int w,
                          int h);
@@ -79,9 +83,10 @@
                         ptrdiff_t src_stride,
                         uint8_t* dst,
                         ptrdiff_t dst_stride,
-                        const int16_t* filter_x,
+                        const InterpKernel* filter,
+                        int x0_q4,
                         int x_step_q4,
-                        const int16_t* filter_y,
+                        int y0_q4,
                         int y_step_q4,
                         int w,
                         int h);
@@ -89,9 +94,10 @@
                                   ptrdiff_t src_stride,
                                   uint8_t* dst,
                                   ptrdiff_t dst_stride,
-                                  const int16_t* filter_x,
+                                  const InterpKernel* filter,
+                                  int x0_q4,
                                   int x_step_q4,
-                                  const int16_t* filter_y,
+                                  int y0_q4,
                                   int y_step_q4,
                                   int w,
                                   int h);
@@ -100,9 +106,10 @@
                          ptrdiff_t src_stride,
                          uint8_t* dst,
                          ptrdiff_t dst_stride,
-                         const int16_t* filter_x,
+                         const InterpKernel* filter,
+                         int x0_q4,
                          int x_step_q4,
-                         const int16_t* filter_y,
+                         int y0_q4,
                          int y_step_q4,
                          int w,
                          int h);
@@ -110,9 +117,10 @@
                             ptrdiff_t src_stride,
                             uint8_t* dst,
                             ptrdiff_t dst_stride,
-                            const int16_t* filter_x,
+                            const InterpKernel* filter,
+                            int x0_q4,
                             int x_step_q4,
-                            const int16_t* filter_y,
+                            int y0_q4,
                             int y_step_q4,
                             int w,
                             int h);
@@ -120,9 +128,10 @@
                              ptrdiff_t src_stride,
                              uint8_t* dst,
                              ptrdiff_t dst_stride,
-                             const int16_t* filter_x,
+                             const InterpKernel* filter,
+                             int x0_q4,
                              int x_step_q4,
-                             const int16_t* filter_y,
+                             int y0_q4,
                              int y_step_q4,
                              int w,
                              int h);
@@ -130,9 +139,10 @@
                                       ptrdiff_t src_stride,
                                       uint8_t* dst,
                                       ptrdiff_t dst_stride,
-                                      const int16_t* filter_x,
+                                      const InterpKernel* filter,
+                                      int x0_q4,
                                       int x_step_q4,
-                                      const int16_t* filter_y,
+                                      int y0_q4,
                                       int y_step_q4,
                                       int w,
                                       int h);
@@ -141,9 +151,10 @@
                                ptrdiff_t src_stride,
                                uint8_t* dst,
                                ptrdiff_t dst_stride,
-                               const int16_t* filter_x,
+                               const InterpKernel* filter,
+                               int x0_q4,
                                int x_step_q4,
-                               const int16_t* filter_y,
+                               int y0_q4,
                                int y_step_q4,
                                int w,
                                int h);
@@ -151,9 +162,10 @@
                                   ptrdiff_t src_stride,
                                   uint8_t* dst,
                                   ptrdiff_t dst_stride,
-                                  const int16_t* filter_x,
+                                  const InterpKernel* filter,
+                                  int x0_q4,
                                   int x_step_q4,
-                                  const int16_t* filter_y,
+                                  int y0_q4,
                                   int y_step_q4,
                                   int w,
                                   int h);
@@ -161,9 +173,10 @@
                                    ptrdiff_t src_stride,
                                    uint8_t* dst,
                                    ptrdiff_t dst_stride,
-                                   const int16_t* filter_x,
+                                   const InterpKernel* filter,
+                                   int x0_q4,
                                    int x_step_q4,
-                                   const int16_t* filter_y,
+                                   int y0_q4,
                                    int y_step_q4,
                                    int w,
                                    int h);
@@ -171,9 +184,10 @@
                                             ptrdiff_t src_stride,
                                             uint8_t* dst,
                                             ptrdiff_t dst_stride,
-                                            const int16_t* filter_x,
+                                            const InterpKernel* filter,
+                                            int x0_q4,
                                             int x_step_q4,
-                                            const int16_t* filter_y,
+                                            int y0_q4,
                                             int y_step_q4,
                                             int w,
                                             int h);
@@ -182,9 +196,10 @@
                               ptrdiff_t src_stride,
                               uint8_t* dst,
                               ptrdiff_t dst_stride,
-                              const int16_t* filter_x,
+                              const InterpKernel* filter,
+                              int x0_q4,
                               int x_step_q4,
-                              const int16_t* filter_y,
+                              int y0_q4,
                               int y_step_q4,
                               int w,
                               int h);
@@ -192,9 +207,10 @@
                                  ptrdiff_t src_stride,
                                  uint8_t* dst,
                                  ptrdiff_t dst_stride,
-                                 const int16_t* filter_x,
+                                 const InterpKernel* filter,
+                                 int x0_q4,
                                  int x_step_q4,
-                                 const int16_t* filter_y,
+                                 int y0_q4,
                                  int y_step_q4,
                                  int w,
                                  int h);
@@ -202,9 +218,10 @@
                                   ptrdiff_t src_stride,
                                   uint8_t* dst,
                                   ptrdiff_t dst_stride,
-                                  const int16_t* filter_x,
+                                  const InterpKernel* filter,
+                                  int x0_q4,
                                   int x_step_q4,
-                                  const int16_t* filter_y,
+                                  int y0_q4,
                                   int y_step_q4,
                                   int w,
                                   int h);
@@ -212,9 +229,10 @@
                                            ptrdiff_t src_stride,
                                            uint8_t* dst,
                                            ptrdiff_t dst_stride,
-                                           const int16_t* filter_x,
+                                           const InterpKernel* filter,
+                                           int x0_q4,
                                            int x_step_q4,
-                                           const int16_t* filter_y,
+                                           int y0_q4,
                                            int y_step_q4,
                                            int w,
                                            int h);
@@ -223,9 +241,10 @@
                            ptrdiff_t src_stride,
                            uint8_t* dst,
                            ptrdiff_t dst_stride,
-                           const int16_t* filter_x,
+                           const InterpKernel* filter,
+                           int x0_q4,
                            int x_step_q4,
-                           const int16_t* filter_y,
+                           int y0_q4,
                            int y_step_q4,
                            int w,
                            int h);
@@ -233,9 +252,10 @@
                               ptrdiff_t src_stride,
                               uint8_t* dst,
                               ptrdiff_t dst_stride,
-                              const int16_t* filter_x,
+                              const InterpKernel* filter,
+                              int x0_q4,
                               int x_step_q4,
-                              const int16_t* filter_y,
+                              int y0_q4,
                               int y_step_q4,
                               int w,
                               int h);
@@ -243,9 +263,10 @@
                                ptrdiff_t src_stride,
                                uint8_t* dst,
                                ptrdiff_t dst_stride,
-                               const int16_t* filter_x,
+                               const InterpKernel* filter,
+                               int x0_q4,
                                int x_step_q4,
-                               const int16_t* filter_y,
+                               int y0_q4,
                                int y_step_q4,
                                int w,
                                int h);
@@ -253,9 +274,10 @@
                               ptrdiff_t src_stride,
                               uint8_t* dst,
                               ptrdiff_t dst_stride,
-                              const int16_t* filter_x,
+                              const InterpKernel* filter,
+                              int x0_q4,
                               int x_step_q4,
-                              const int16_t* filter_y,
+                              int y0_q4,
                               int y_step_q4,
                               int w,
                               int h);
@@ -263,9 +285,10 @@
                                         ptrdiff_t src_stride,
                                         uint8_t* dst,
                                         ptrdiff_t dst_stride,
-                                        const int16_t* filter_x,
+                                        const InterpKernel* filter,
+                                        int x0_q4,
                                         int x_step_q4,
-                                        const int16_t* filter_y,
+                                        int y0_q4,
                                         int y_step_q4,
                                         int w,
                                         int h);
@@ -274,9 +297,10 @@
                           ptrdiff_t src_stride,
                           uint8_t* dst,
                           ptrdiff_t dst_stride,
-                          const int16_t* filter_x,
+                          const InterpKernel* filter,
+                          int x0_q4,
                           int x_step_q4,
-                          const int16_t* filter_y,
+                          int y0_q4,
                           int y_step_q4,
                           int w,
                           int h);
@@ -284,9 +308,10 @@
                              ptrdiff_t src_stride,
                              uint8_t* dst,
                              ptrdiff_t dst_stride,
-                             const int16_t* filter_x,
+                             const InterpKernel* filter,
+                             int x0_q4,
                              int x_step_q4,
-                             const int16_t* filter_y,
+                             int y0_q4,
                              int y_step_q4,
                              int w,
                              int h);
@@ -294,9 +319,10 @@
                               ptrdiff_t src_stride,
                               uint8_t* dst,
                               ptrdiff_t dst_stride,
-                              const int16_t* filter_x,
+                              const InterpKernel* filter,
+                              int x0_q4,
                               int x_step_q4,
-                              const int16_t* filter_y,
+                              int y0_q4,
                               int y_step_q4,
                               int w,
                               int h);
@@ -304,9 +330,10 @@
                              ptrdiff_t src_stride,
                              uint8_t* dst,
                              ptrdiff_t dst_stride,
-                             const int16_t* filter_x,
+                             const InterpKernel* filter,
+                             int x0_q4,
                              int x_step_q4,
-                             const int16_t* filter_y,
+                             int y0_q4,
                              int y_step_q4,
                              int w,
                              int h);
@@ -314,9 +341,10 @@
                                        ptrdiff_t src_stride,
                                        uint8_t* dst,
                                        ptrdiff_t dst_stride,
-                                       const int16_t* filter_x,
+                                       const InterpKernel* filter,
+                                       int x0_q4,
                                        int x_step_q4,
-                                       const int16_t* filter_y,
+                                       int y0_q4,
                                        int y_step_q4,
                                        int w,
                                        int h);
@@ -325,9 +353,10 @@
                         ptrdiff_t src_stride,
                         uint8_t* dst,
                         ptrdiff_t dst_stride,
-                        const int16_t* filter_x,
+                        const InterpKernel* filter,
+                        int x0_q4,
                         int x_step_q4,
-                        const int16_t* filter_y,
+                        int y0_q4,
                         int y_step_q4,
                         int w,
                         int h);
@@ -335,9 +364,10 @@
                            ptrdiff_t src_stride,
                            uint8_t* dst,
                            ptrdiff_t dst_stride,
-                           const int16_t* filter_x,
+                           const InterpKernel* filter,
+                           int x0_q4,
                            int x_step_q4,
-                           const int16_t* filter_y,
+                           int y0_q4,
                            int y_step_q4,
                            int w,
                            int h);
@@ -345,9 +375,10 @@
                                      ptrdiff_t src_stride,
                                      uint8_t* dst,
                                      ptrdiff_t dst_stride,
-                                     const int16_t* filter_x,
+                                     const InterpKernel* filter,
+                                     int x0_q4,
                                      int x_step_q4,
-                                     const int16_t* filter_y,
+                                     int y0_q4,
                                      int y_step_q4,
                                      int w,
                                      int h);
@@ -356,9 +387,10 @@
                          ptrdiff_t src_stride,
                          uint8_t* dst,
                          ptrdiff_t dst_stride,
-                         const int16_t* filter_x,
+                         const InterpKernel* filter,
+                         int x0_q4,
                          int x_step_q4,
-                         const int16_t* filter_y,
+                         int y0_q4,
                          int y_step_q4,
                          int w,
                          int h);
@@ -366,9 +398,10 @@
                             ptrdiff_t src_stride,
                             uint8_t* dst,
                             ptrdiff_t dst_stride,
-                            const int16_t* filter_x,
+                            const InterpKernel* filter,
+                            int x0_q4,
                             int x_step_q4,
-                            const int16_t* filter_y,
+                            int y0_q4,
                             int y_step_q4,
                             int w,
                             int h);
@@ -376,9 +409,10 @@
                                       ptrdiff_t src_stride,
                                       uint8_t* dst,
                                       ptrdiff_t dst_stride,
-                                      const int16_t* filter_x,
+                                      const InterpKernel* filter,
+                                      int x0_q4,
                                       int x_step_q4,
-                                      const int16_t* filter_y,
+                                      int y0_q4,
                                       int y_step_q4,
                                       int w,
                                       int h);
@@ -3582,9 +3616,10 @@
                             ptrdiff_t src_stride,
                             uint16_t* dst,
                             ptrdiff_t dst_stride,
-                            const int16_t* filter_x,
+                            const InterpKernel* filter,
+                            int x0_q4,
                             int x_step_q4,
-                            const int16_t* filter_y,
+                            int y0_q4,
                             int y_step_q4,
                             int w,
                             int h,
@@ -3593,9 +3628,10 @@
                                ptrdiff_t src_stride,
                                uint16_t* dst,
                                ptrdiff_t dst_stride,
-                               const int16_t* filter_x,
+                               const InterpKernel* filter,
+                               int x0_q4,
                                int x_step_q4,
-                               const int16_t* filter_y,
+                               int y0_q4,
                                int y_step_q4,
                                int w,
                                int h,
@@ -3604,9 +3640,10 @@
                                          ptrdiff_t src_stride,
                                          uint16_t* dst,
                                          ptrdiff_t dst_stride,
-                                         const int16_t* filter_x,
+                                         const InterpKernel* filter,
+                                         int x0_q4,
                                          int x_step_q4,
-                                         const int16_t* filter_y,
+                                         int y0_q4,
                                          int y_step_q4,
                                          int w,
                                          int h,
@@ -3616,9 +3653,10 @@
                                 ptrdiff_t src_stride,
                                 uint16_t* dst,
                                 ptrdiff_t dst_stride,
-                                const int16_t* filter_x,
+                                const InterpKernel* filter,
+                                int x0_q4,
                                 int x_step_q4,
-                                const int16_t* filter_y,
+                                int y0_q4,
                                 int y_step_q4,
                                 int w,
                                 int h,
@@ -3627,9 +3665,10 @@
                                    ptrdiff_t src_stride,
                                    uint16_t* dst,
                                    ptrdiff_t dst_stride,
-                                   const int16_t* filter_x,
+                                   const InterpKernel* filter,
+                                   int x0_q4,
                                    int x_step_q4,
-                                   const int16_t* filter_y,
+                                   int y0_q4,
                                    int y_step_q4,
                                    int w,
                                    int h,
@@ -3638,9 +3677,10 @@
                                              ptrdiff_t src_stride,
                                              uint16_t* dst,
                                              ptrdiff_t dst_stride,
-                                             const int16_t* filter_x,
+                                             const InterpKernel* filter,
+                                             int x0_q4,
                                              int x_step_q4,
-                                             const int16_t* filter_y,
+                                             int y0_q4,
                                              int y_step_q4,
                                              int w,
                                              int h,
@@ -3650,9 +3690,10 @@
                                       ptrdiff_t src_stride,
                                       uint16_t* dst,
                                       ptrdiff_t dst_stride,
-                                      const int16_t* filter_x,
+                                      const InterpKernel* filter,
+                                      int x0_q4,
                                       int x_step_q4,
-                                      const int16_t* filter_y,
+                                      int y0_q4,
                                       int y_step_q4,
                                       int w,
                                       int h,
@@ -3661,9 +3702,10 @@
                                          ptrdiff_t src_stride,
                                          uint16_t* dst,
                                          ptrdiff_t dst_stride,
-                                         const int16_t* filter_x,
+                                         const InterpKernel* filter,
+                                         int x0_q4,
                                          int x_step_q4,
-                                         const int16_t* filter_y,
+                                         int y0_q4,
                                          int y_step_q4,
                                          int w,
                                          int h,
@@ -3672,9 +3714,10 @@
                                                    ptrdiff_t src_stride,
                                                    uint16_t* dst,
                                                    ptrdiff_t dst_stride,
-                                                   const int16_t* filter_x,
+                                                   const InterpKernel* filter,
+                                                   int x0_q4,
                                                    int x_step_q4,
-                                                   const int16_t* filter_y,
+                                                   int y0_q4,
                                                    int y_step_q4,
                                                    int w,
                                                    int h,
@@ -3684,9 +3727,10 @@
                                      ptrdiff_t src_stride,
                                      uint16_t* dst,
                                      ptrdiff_t dst_stride,
-                                     const int16_t* filter_x,
+                                     const InterpKernel* filter,
+                                     int x0_q4,
                                      int x_step_q4,
-                                     const int16_t* filter_y,
+                                     int y0_q4,
                                      int y_step_q4,
                                      int w,
                                      int h,
@@ -3695,9 +3739,10 @@
                                         ptrdiff_t src_stride,
                                         uint16_t* dst,
                                         ptrdiff_t dst_stride,
-                                        const int16_t* filter_x,
+                                        const InterpKernel* filter,
+                                        int x0_q4,
                                         int x_step_q4,
-                                        const int16_t* filter_y,
+                                        int y0_q4,
                                         int y_step_q4,
                                         int w,
                                         int h,
@@ -3706,9 +3751,10 @@
                                                   ptrdiff_t src_stride,
                                                   uint16_t* dst,
                                                   ptrdiff_t dst_stride,
-                                                  const int16_t* filter_x,
+                                                  const InterpKernel* filter,
+                                                  int x0_q4,
                                                   int x_step_q4,
-                                                  const int16_t* filter_y,
+                                                  int y0_q4,
                                                   int y_step_q4,
                                                   int w,
                                                   int h,
@@ -3718,9 +3764,10 @@
                                   ptrdiff_t src_stride,
                                   uint16_t* dst,
                                   ptrdiff_t dst_stride,
-                                  const int16_t* filter_x,
+                                  const InterpKernel* filter,
+                                  int x0_q4,
                                   int x_step_q4,
-                                  const int16_t* filter_y,
+                                  int y0_q4,
                                   int y_step_q4,
                                   int w,
                                   int h,
@@ -3729,9 +3776,10 @@
                                      ptrdiff_t src_stride,
                                      uint16_t* dst,
                                      ptrdiff_t dst_stride,
-                                     const int16_t* filter_x,
+                                     const InterpKernel* filter,
+                                     int x0_q4,
                                      int x_step_q4,
-                                     const int16_t* filter_y,
+                                     int y0_q4,
                                      int y_step_q4,
                                      int w,
                                      int h,
@@ -3740,9 +3788,10 @@
                                                ptrdiff_t src_stride,
                                                uint16_t* dst,
                                                ptrdiff_t dst_stride,
-                                               const int16_t* filter_x,
+                                               const InterpKernel* filter,
+                                               int x0_q4,
                                                int x_step_q4,
-                                               const int16_t* filter_y,
+                                               int y0_q4,
                                                int y_step_q4,
                                                int w,
                                                int h,
@@ -3752,9 +3801,10 @@
                                  ptrdiff_t src_stride,
                                  uint16_t* dst,
                                  ptrdiff_t dst_stride,
-                                 const int16_t* filter_x,
+                                 const InterpKernel* filter,
+                                 int x0_q4,
                                  int x_step_q4,
-                                 const int16_t* filter_y,
+                                 int y0_q4,
                                  int y_step_q4,
                                  int w,
                                  int h,
@@ -3763,9 +3813,10 @@
                                     ptrdiff_t src_stride,
                                     uint16_t* dst,
                                     ptrdiff_t dst_stride,
-                                    const int16_t* filter_x,
+                                    const InterpKernel* filter,
+                                    int x0_q4,
                                     int x_step_q4,
-                                    const int16_t* filter_y,
+                                    int y0_q4,
                                     int y_step_q4,
                                     int w,
                                     int h,
@@ -3774,9 +3825,10 @@
                                               ptrdiff_t src_stride,
                                               uint16_t* dst,
                                               ptrdiff_t dst_stride,
-                                              const int16_t* filter_x,
+                                              const InterpKernel* filter,
+                                              int x0_q4,
                                               int x_step_q4,
-                                              const int16_t* filter_y,
+                                              int y0_q4,
                                               int y_step_q4,
                                               int w,
                                               int h,
@@ -3786,9 +3838,10 @@
                                ptrdiff_t src_stride,
                                uint16_t* dst,
                                ptrdiff_t dst_stride,
-                               const int16_t* filter_x,
+                               const InterpKernel* filter,
+                               int x0_q4,
                                int x_step_q4,
-                               const int16_t* filter_y,
+                               int y0_q4,
                                int y_step_q4,
                                int w,
                                int h,
@@ -3797,9 +3850,10 @@
                                   ptrdiff_t src_stride,
                                   uint16_t* dst,
                                   ptrdiff_t dst_stride,
-                                  const int16_t* filter_x,
+                                  const InterpKernel* filter,
+                                  int x0_q4,
                                   int x_step_q4,
-                                  const int16_t* filter_y,
+                                  int y0_q4,
                                   int y_step_q4,
                                   int w,
                                   int h,
@@ -3808,9 +3862,10 @@
                                   ptrdiff_t src_stride,
                                   uint16_t* dst,
                                   ptrdiff_t dst_stride,
-                                  const int16_t* filter_x,
+                                  const InterpKernel* filter,
+                                  int x0_q4,
                                   int x_step_q4,
-                                  const int16_t* filter_y,
+                                  int y0_q4,
                                   int y_step_q4,
                                   int w,
                                   int h,
@@ -3819,9 +3874,10 @@
                                             ptrdiff_t src_stride,
                                             uint16_t* dst,
                                             ptrdiff_t dst_stride,
-                                            const int16_t* filter_x,
+                                            const InterpKernel* filter,
+                                            int x0_q4,
                                             int x_step_q4,
-                                            const int16_t* filter_y,
+                                            int y0_q4,
                                             int y_step_q4,
                                             int w,
                                             int h,
@@ -3831,9 +3887,10 @@
                                 ptrdiff_t src_stride,
                                 uint16_t* dst,
                                 ptrdiff_t dst_stride,
-                                const int16_t* filter_x,
+                                const InterpKernel* filter,
+                                int x0_q4,
                                 int x_step_q4,
-                                const int16_t* filter_y,
+                                int y0_q4,
                                 int y_step_q4,
                                 int w,
                                 int h,
@@ -3842,9 +3899,10 @@
                                    ptrdiff_t src_stride,
                                    uint16_t* dst,
                                    ptrdiff_t dst_stride,
-                                   const int16_t* filter_x,
+                                   const InterpKernel* filter,
+                                   int x0_q4,
                                    int x_step_q4,
-                                   const int16_t* filter_y,
+                                   int y0_q4,
                                    int y_step_q4,
                                    int w,
                                    int h,
@@ -3853,9 +3911,10 @@
                                    ptrdiff_t src_stride,
                                    uint16_t* dst,
                                    ptrdiff_t dst_stride,
-                                   const int16_t* filter_x,
+                                   const InterpKernel* filter,
+                                   int x0_q4,
                                    int x_step_q4,
-                                   const int16_t* filter_y,
+                                   int y0_q4,
                                    int y_step_q4,
                                    int w,
                                    int h,
@@ -3864,9 +3923,10 @@
                                              ptrdiff_t src_stride,
                                              uint16_t* dst,
                                              ptrdiff_t dst_stride,
-                                             const int16_t* filter_x,
+                                             const InterpKernel* filter,
+                                             int x0_q4,
                                              int x_step_q4,
-                                             const int16_t* filter_y,
+                                             int y0_q4,
                                              int y_step_q4,
                                              int w,
                                              int h,
@@ -4045,56 +4105,128 @@
                                          const uint16_t* above,
                                          const uint16_t* left,
                                          int bd);
-#define vpx_highbd_dc_128_predictor_16x16 vpx_highbd_dc_128_predictor_16x16_c
+void vpx_highbd_dc_128_predictor_16x16_sse2(uint16_t* dst,
+                                            ptrdiff_t y_stride,
+                                            const uint16_t* above,
+                                            const uint16_t* left,
+                                            int bd);
+RTCD_EXTERN void (*vpx_highbd_dc_128_predictor_16x16)(uint16_t* dst,
+                                                      ptrdiff_t y_stride,
+                                                      const uint16_t* above,
+                                                      const uint16_t* left,
+                                                      int bd);
 
 void vpx_highbd_dc_128_predictor_32x32_c(uint16_t* dst,
                                          ptrdiff_t y_stride,
                                          const uint16_t* above,
                                          const uint16_t* left,
                                          int bd);
-#define vpx_highbd_dc_128_predictor_32x32 vpx_highbd_dc_128_predictor_32x32_c
+void vpx_highbd_dc_128_predictor_32x32_sse2(uint16_t* dst,
+                                            ptrdiff_t y_stride,
+                                            const uint16_t* above,
+                                            const uint16_t* left,
+                                            int bd);
+RTCD_EXTERN void (*vpx_highbd_dc_128_predictor_32x32)(uint16_t* dst,
+                                                      ptrdiff_t y_stride,
+                                                      const uint16_t* above,
+                                                      const uint16_t* left,
+                                                      int bd);
 
 void vpx_highbd_dc_128_predictor_4x4_c(uint16_t* dst,
                                        ptrdiff_t y_stride,
                                        const uint16_t* above,
                                        const uint16_t* left,
                                        int bd);
-#define vpx_highbd_dc_128_predictor_4x4 vpx_highbd_dc_128_predictor_4x4_c
+void vpx_highbd_dc_128_predictor_4x4_sse2(uint16_t* dst,
+                                          ptrdiff_t y_stride,
+                                          const uint16_t* above,
+                                          const uint16_t* left,
+                                          int bd);
+RTCD_EXTERN void (*vpx_highbd_dc_128_predictor_4x4)(uint16_t* dst,
+                                                    ptrdiff_t y_stride,
+                                                    const uint16_t* above,
+                                                    const uint16_t* left,
+                                                    int bd);
 
 void vpx_highbd_dc_128_predictor_8x8_c(uint16_t* dst,
                                        ptrdiff_t y_stride,
                                        const uint16_t* above,
                                        const uint16_t* left,
                                        int bd);
-#define vpx_highbd_dc_128_predictor_8x8 vpx_highbd_dc_128_predictor_8x8_c
+void vpx_highbd_dc_128_predictor_8x8_sse2(uint16_t* dst,
+                                          ptrdiff_t y_stride,
+                                          const uint16_t* above,
+                                          const uint16_t* left,
+                                          int bd);
+RTCD_EXTERN void (*vpx_highbd_dc_128_predictor_8x8)(uint16_t* dst,
+                                                    ptrdiff_t y_stride,
+                                                    const uint16_t* above,
+                                                    const uint16_t* left,
+                                                    int bd);
 
 void vpx_highbd_dc_left_predictor_16x16_c(uint16_t* dst,
                                           ptrdiff_t y_stride,
                                           const uint16_t* above,
                                           const uint16_t* left,
                                           int bd);
-#define vpx_highbd_dc_left_predictor_16x16 vpx_highbd_dc_left_predictor_16x16_c
+void vpx_highbd_dc_left_predictor_16x16_sse2(uint16_t* dst,
+                                             ptrdiff_t y_stride,
+                                             const uint16_t* above,
+                                             const uint16_t* left,
+                                             int bd);
+RTCD_EXTERN void (*vpx_highbd_dc_left_predictor_16x16)(uint16_t* dst,
+                                                       ptrdiff_t y_stride,
+                                                       const uint16_t* above,
+                                                       const uint16_t* left,
+                                                       int bd);
 
 void vpx_highbd_dc_left_predictor_32x32_c(uint16_t* dst,
                                           ptrdiff_t y_stride,
                                           const uint16_t* above,
                                           const uint16_t* left,
                                           int bd);
-#define vpx_highbd_dc_left_predictor_32x32 vpx_highbd_dc_left_predictor_32x32_c
+void vpx_highbd_dc_left_predictor_32x32_sse2(uint16_t* dst,
+                                             ptrdiff_t y_stride,
+                                             const uint16_t* above,
+                                             const uint16_t* left,
+                                             int bd);
+RTCD_EXTERN void (*vpx_highbd_dc_left_predictor_32x32)(uint16_t* dst,
+                                                       ptrdiff_t y_stride,
+                                                       const uint16_t* above,
+                                                       const uint16_t* left,
+                                                       int bd);
 
 void vpx_highbd_dc_left_predictor_4x4_c(uint16_t* dst,
                                         ptrdiff_t y_stride,
                                         const uint16_t* above,
                                         const uint16_t* left,
                                         int bd);
-#define vpx_highbd_dc_left_predictor_4x4 vpx_highbd_dc_left_predictor_4x4_c
+void vpx_highbd_dc_left_predictor_4x4_sse2(uint16_t* dst,
+                                           ptrdiff_t y_stride,
+                                           const uint16_t* above,
+                                           const uint16_t* left,
+                                           int bd);
+RTCD_EXTERN void (*vpx_highbd_dc_left_predictor_4x4)(uint16_t* dst,
+                                                     ptrdiff_t y_stride,
+                                                     const uint16_t* above,
+                                                     const uint16_t* left,
+                                                     int bd);
 
 void vpx_highbd_dc_left_predictor_8x8_c(uint16_t* dst,
                                         ptrdiff_t y_stride,
                                         const uint16_t* above,
                                         const uint16_t* left,
                                         int bd);
-#define vpx_highbd_dc_left_predictor_8x8 vpx_highbd_dc_left_predictor_8x8_c
+void vpx_highbd_dc_left_predictor_8x8_sse2(uint16_t* dst,
+                                           ptrdiff_t y_stride,
+                                           const uint16_t* above,
+                                           const uint16_t* left,
+                                           int bd);
+RTCD_EXTERN void (*vpx_highbd_dc_left_predictor_8x8)(uint16_t* dst,
+                                                     ptrdiff_t y_stride,
+                                                     const uint16_t* above,
+                                                     const uint16_t* left,
+                                                     int bd);
 
 void vpx_highbd_dc_predictor_16x16_c(uint16_t* dst,
                                      ptrdiff_t y_stride,
@@ -4165,28 +4297,64 @@
                                          const uint16_t* above,
                                          const uint16_t* left,
                                          int bd);
-#define vpx_highbd_dc_top_predictor_16x16 vpx_highbd_dc_top_predictor_16x16_c
+void vpx_highbd_dc_top_predictor_16x16_sse2(uint16_t* dst,
+                                            ptrdiff_t y_stride,
+                                            const uint16_t* above,
+                                            const uint16_t* left,
+                                            int bd);
+RTCD_EXTERN void (*vpx_highbd_dc_top_predictor_16x16)(uint16_t* dst,
+                                                      ptrdiff_t y_stride,
+                                                      const uint16_t* above,
+                                                      const uint16_t* left,
+                                                      int bd);
 
 void vpx_highbd_dc_top_predictor_32x32_c(uint16_t* dst,
                                          ptrdiff_t y_stride,
                                          const uint16_t* above,
                                          const uint16_t* left,
                                          int bd);
-#define vpx_highbd_dc_top_predictor_32x32 vpx_highbd_dc_top_predictor_32x32_c
+void vpx_highbd_dc_top_predictor_32x32_sse2(uint16_t* dst,
+                                            ptrdiff_t y_stride,
+                                            const uint16_t* above,
+                                            const uint16_t* left,
+                                            int bd);
+RTCD_EXTERN void (*vpx_highbd_dc_top_predictor_32x32)(uint16_t* dst,
+                                                      ptrdiff_t y_stride,
+                                                      const uint16_t* above,
+                                                      const uint16_t* left,
+                                                      int bd);
 
 void vpx_highbd_dc_top_predictor_4x4_c(uint16_t* dst,
                                        ptrdiff_t y_stride,
                                        const uint16_t* above,
                                        const uint16_t* left,
                                        int bd);
-#define vpx_highbd_dc_top_predictor_4x4 vpx_highbd_dc_top_predictor_4x4_c
+void vpx_highbd_dc_top_predictor_4x4_sse2(uint16_t* dst,
+                                          ptrdiff_t y_stride,
+                                          const uint16_t* above,
+                                          const uint16_t* left,
+                                          int bd);
+RTCD_EXTERN void (*vpx_highbd_dc_top_predictor_4x4)(uint16_t* dst,
+                                                    ptrdiff_t y_stride,
+                                                    const uint16_t* above,
+                                                    const uint16_t* left,
+                                                    int bd);
 
 void vpx_highbd_dc_top_predictor_8x8_c(uint16_t* dst,
                                        ptrdiff_t y_stride,
                                        const uint16_t* above,
                                        const uint16_t* left,
                                        int bd);
-#define vpx_highbd_dc_top_predictor_8x8 vpx_highbd_dc_top_predictor_8x8_c
+void vpx_highbd_dc_top_predictor_8x8_sse2(uint16_t* dst,
+                                          ptrdiff_t y_stride,
+                                          const uint16_t* above,
+                                          const uint16_t* left,
+                                          int bd);
+RTCD_EXTERN void (*vpx_highbd_dc_top_predictor_8x8)(uint16_t* dst,
+                                                    ptrdiff_t y_stride,
+                                                    const uint16_t* above,
+                                                    const uint16_t* left,
+                                                    int bd);
 
 void vpx_highbd_fdct16x16_c(const int16_t* input,
                             tran_low_t* output,
@@ -4254,28 +4422,64 @@
                                     const uint16_t* above,
                                     const uint16_t* left,
                                     int bd);
-#define vpx_highbd_h_predictor_16x16 vpx_highbd_h_predictor_16x16_c
+void vpx_highbd_h_predictor_16x16_sse2(uint16_t* dst,
+                                       ptrdiff_t y_stride,
+                                       const uint16_t* above,
+                                       const uint16_t* left,
+                                       int bd);
+RTCD_EXTERN void (*vpx_highbd_h_predictor_16x16)(uint16_t* dst,
+                                                 ptrdiff_t y_stride,
+                                                 const uint16_t* above,
+                                                 const uint16_t* left,
+                                                 int bd);
 
 void vpx_highbd_h_predictor_32x32_c(uint16_t* dst,
                                     ptrdiff_t y_stride,
                                     const uint16_t* above,
                                     const uint16_t* left,
                                     int bd);
-#define vpx_highbd_h_predictor_32x32 vpx_highbd_h_predictor_32x32_c
+void vpx_highbd_h_predictor_32x32_sse2(uint16_t* dst,
+                                       ptrdiff_t y_stride,
+                                       const uint16_t* above,
+                                       const uint16_t* left,
+                                       int bd);
+RTCD_EXTERN void (*vpx_highbd_h_predictor_32x32)(uint16_t* dst,
+                                                 ptrdiff_t y_stride,
+                                                 const uint16_t* above,
+                                                 const uint16_t* left,
+                                                 int bd);
 
 void vpx_highbd_h_predictor_4x4_c(uint16_t* dst,
                                   ptrdiff_t y_stride,
                                   const uint16_t* above,
                                   const uint16_t* left,
                                   int bd);
-#define vpx_highbd_h_predictor_4x4 vpx_highbd_h_predictor_4x4_c
+void vpx_highbd_h_predictor_4x4_sse2(uint16_t* dst,
+                                     ptrdiff_t y_stride,
+                                     const uint16_t* above,
+                                     const uint16_t* left,
+                                     int bd);
+RTCD_EXTERN void (*vpx_highbd_h_predictor_4x4)(uint16_t* dst,
+                                               ptrdiff_t y_stride,
+                                               const uint16_t* above,
+                                               const uint16_t* left,
+                                               int bd);
 
 void vpx_highbd_h_predictor_8x8_c(uint16_t* dst,
                                   ptrdiff_t y_stride,
                                   const uint16_t* above,
                                   const uint16_t* left,
                                   int bd);
-#define vpx_highbd_h_predictor_8x8 vpx_highbd_h_predictor_8x8_c
+void vpx_highbd_h_predictor_8x8_sse2(uint16_t* dst,
+                                     ptrdiff_t y_stride,
+                                     const uint16_t* above,
+                                     const uint16_t* left,
+                                     int bd);
+RTCD_EXTERN void (*vpx_highbd_h_predictor_8x8)(uint16_t* dst,
+                                               ptrdiff_t y_stride,
+                                               const uint16_t* above,
+                                               const uint16_t* left,
+                                               int bd);
 
 void vpx_highbd_idct16x16_10_add_c(const tran_low_t* input,
                                    uint16_t* dest,
@@ -6162,7 +6366,32 @@
                             uint16_t* eob_ptr,
                             const int16_t* scan,
                             const int16_t* iscan);
-#define vpx_quantize_b_32x32 vpx_quantize_b_32x32_c
+void vpx_quantize_b_32x32_ssse3(const tran_low_t* coeff_ptr,
+                                intptr_t n_coeffs,
+                                int skip_block,
+                                const int16_t* zbin_ptr,
+                                const int16_t* round_ptr,
+                                const int16_t* quant_ptr,
+                                const int16_t* quant_shift_ptr,
+                                tran_low_t* qcoeff_ptr,
+                                tran_low_t* dqcoeff_ptr,
+                                const int16_t* dequant_ptr,
+                                uint16_t* eob_ptr,
+                                const int16_t* scan,
+                                const int16_t* iscan);
+RTCD_EXTERN void (*vpx_quantize_b_32x32)(const tran_low_t* coeff_ptr,
+                                         intptr_t n_coeffs,
+                                         int skip_block,
+                                         const int16_t* zbin_ptr,
+                                         const int16_t* round_ptr,
+                                         const int16_t* quant_ptr,
+                                         const int16_t* quant_shift_ptr,
+                                         tran_low_t* qcoeff_ptr,
+                                         tran_low_t* dqcoeff_ptr,
+                                         const int16_t* dequant_ptr,
+                                         uint16_t* eob_ptr,
+                                         const int16_t* scan,
+                                         const int16_t* iscan);
 
 unsigned int vpx_sad16x16_c(const uint8_t* src_ptr,
                             int src_stride,
@@ -6982,9 +7211,10 @@
                      ptrdiff_t src_stride,
                      uint8_t* dst,
                      ptrdiff_t dst_stride,
-                     const int16_t* filter_x,
+                     const InterpKernel* filter,
+                     int x0_q4,
                      int x_step_q4,
-                     const int16_t* filter_y,
+                     int y0_q4,
                      int y_step_q4,
                      int w,
                      int h);
@@ -6992,9 +7222,10 @@
                          ptrdiff_t src_stride,
                          uint8_t* dst,
                          ptrdiff_t dst_stride,
-                         const int16_t* filter_x,
+                         const InterpKernel* filter,
+                         int x0_q4,
                          int x_step_q4,
-                         const int16_t* filter_y,
+                         int y0_q4,
                          int y_step_q4,
                          int w,
                          int h);
@@ -7002,9 +7233,10 @@
                                   ptrdiff_t src_stride,
                                   uint8_t* dst,
                                   ptrdiff_t dst_stride,
-                                  const int16_t* filter_x,
+                                  const InterpKernel* filter,
+                                  int x0_q4,
                                   int x_step_q4,
-                                  const int16_t* filter_y,
+                                  int y0_q4,
                                   int y_step_q4,
                                   int w,
                                   int h);
@@ -7013,9 +7245,10 @@
                          ptrdiff_t src_stride,
                          uint8_t* dst,
                          ptrdiff_t dst_stride,
-                         const int16_t* filter_x,
+                         const InterpKernel* filter,
+                         int x0_q4,
                          int x_step_q4,
-                         const int16_t* filter_y,
+                         int y0_q4,
                          int y_step_q4,
                          int w,
                          int h);
@@ -7025,9 +7258,10 @@
                             ptrdiff_t src_stride,
                             uint8_t* dst,
                             ptrdiff_t dst_stride,
-                            const int16_t* filter_x,
+                            const InterpKernel* filter,
+                            int x0_q4,
                             int x_step_q4,
-                            const int16_t* filter_y,
+                            int y0_q4,
                             int y_step_q4,
                             int w,
                             int h);
@@ -7037,9 +7271,10 @@
                            ptrdiff_t src_stride,
                            uint8_t* dst,
                            ptrdiff_t dst_stride,
-                           const int16_t* filter_x,
+                           const InterpKernel* filter,
+                           int x0_q4,
                            int x_step_q4,
-                           const int16_t* filter_y,
+                           int y0_q4,
                            int y_step_q4,
                            int w,
                            int h);
@@ -7049,9 +7284,10 @@
                         ptrdiff_t src_stride,
                         uint8_t* dst,
                         ptrdiff_t dst_stride,
-                        const int16_t* filter_x,
+                        const InterpKernel* filter,
+                        int x0_q4,
                         int x_step_q4,
-                        const int16_t* filter_y,
+                        int y0_q4,
                         int y_step_q4,
                         int w,
                         int h);
@@ -7061,9 +7297,10 @@
                        ptrdiff_t src_stride,
                        uint8_t* dst,
                        ptrdiff_t dst_stride,
-                       const int16_t* filter_x,
+                       const InterpKernel* filter,
+                       int x0_q4,
                        int x_step_q4,
-                       const int16_t* filter_y,
+                       int y0_q4,
                        int y_step_q4,
                        int w,
                        int h);
@@ -8957,6 +9194,32 @@
     vpx_highbd_convolve_copy = vpx_highbd_convolve_copy_sse2;
   if (flags & HAS_AVX2)
     vpx_highbd_convolve_copy = vpx_highbd_convolve_copy_avx2;
+  vpx_highbd_dc_128_predictor_16x16 = vpx_highbd_dc_128_predictor_16x16_c;
+  if (flags & HAS_SSE2)
+    vpx_highbd_dc_128_predictor_16x16 = vpx_highbd_dc_128_predictor_16x16_sse2;
+  vpx_highbd_dc_128_predictor_32x32 = vpx_highbd_dc_128_predictor_32x32_c;
+  if (flags & HAS_SSE2)
+    vpx_highbd_dc_128_predictor_32x32 = vpx_highbd_dc_128_predictor_32x32_sse2;
+  vpx_highbd_dc_128_predictor_4x4 = vpx_highbd_dc_128_predictor_4x4_c;
+  if (flags & HAS_SSE2)
+    vpx_highbd_dc_128_predictor_4x4 = vpx_highbd_dc_128_predictor_4x4_sse2;
+  vpx_highbd_dc_128_predictor_8x8 = vpx_highbd_dc_128_predictor_8x8_c;
+  if (flags & HAS_SSE2)
+    vpx_highbd_dc_128_predictor_8x8 = vpx_highbd_dc_128_predictor_8x8_sse2;
+  vpx_highbd_dc_left_predictor_16x16 = vpx_highbd_dc_left_predictor_16x16_c;
+  if (flags & HAS_SSE2)
+    vpx_highbd_dc_left_predictor_16x16 =
+        vpx_highbd_dc_left_predictor_16x16_sse2;
+  vpx_highbd_dc_left_predictor_32x32 = vpx_highbd_dc_left_predictor_32x32_c;
+  if (flags & HAS_SSE2)
+    vpx_highbd_dc_left_predictor_32x32 =
+        vpx_highbd_dc_left_predictor_32x32_sse2;
+  vpx_highbd_dc_left_predictor_4x4 = vpx_highbd_dc_left_predictor_4x4_c;
+  if (flags & HAS_SSE2)
+    vpx_highbd_dc_left_predictor_4x4 = vpx_highbd_dc_left_predictor_4x4_sse2;
+  vpx_highbd_dc_left_predictor_8x8 = vpx_highbd_dc_left_predictor_8x8_c;
+  if (flags & HAS_SSE2)
+    vpx_highbd_dc_left_predictor_8x8 = vpx_highbd_dc_left_predictor_8x8_sse2;
   vpx_highbd_dc_predictor_16x16 = vpx_highbd_dc_predictor_16x16_c;
   if (flags & HAS_SSE2)
     vpx_highbd_dc_predictor_16x16 = vpx_highbd_dc_predictor_16x16_sse2;
@@ -8969,6 +9232,18 @@
   vpx_highbd_dc_predictor_8x8 = vpx_highbd_dc_predictor_8x8_c;
   if (flags & HAS_SSE2)
     vpx_highbd_dc_predictor_8x8 = vpx_highbd_dc_predictor_8x8_sse2;
+  vpx_highbd_dc_top_predictor_16x16 = vpx_highbd_dc_top_predictor_16x16_c;
+  if (flags & HAS_SSE2)
+    vpx_highbd_dc_top_predictor_16x16 = vpx_highbd_dc_top_predictor_16x16_sse2;
+  vpx_highbd_dc_top_predictor_32x32 = vpx_highbd_dc_top_predictor_32x32_c;
+  if (flags & HAS_SSE2)
+    vpx_highbd_dc_top_predictor_32x32 = vpx_highbd_dc_top_predictor_32x32_sse2;
+  vpx_highbd_dc_top_predictor_4x4 = vpx_highbd_dc_top_predictor_4x4_c;
+  if (flags & HAS_SSE2)
+    vpx_highbd_dc_top_predictor_4x4 = vpx_highbd_dc_top_predictor_4x4_sse2;
+  vpx_highbd_dc_top_predictor_8x8 = vpx_highbd_dc_top_predictor_8x8_c;
+  if (flags & HAS_SSE2)
+    vpx_highbd_dc_top_predictor_8x8 = vpx_highbd_dc_top_predictor_8x8_sse2;
   vpx_highbd_fdct16x16 = vpx_highbd_fdct16x16_c;
   if (flags & HAS_SSE2)
     vpx_highbd_fdct16x16 = vpx_highbd_fdct16x16_sse2;
@@ -8984,6 +9259,18 @@
   vpx_highbd_fdct8x8 = vpx_highbd_fdct8x8_c;
   if (flags & HAS_SSE2)
     vpx_highbd_fdct8x8 = vpx_highbd_fdct8x8_sse2;
+  vpx_highbd_h_predictor_16x16 = vpx_highbd_h_predictor_16x16_c;
+  if (flags & HAS_SSE2)
+    vpx_highbd_h_predictor_16x16 = vpx_highbd_h_predictor_16x16_sse2;
+  vpx_highbd_h_predictor_32x32 = vpx_highbd_h_predictor_32x32_c;
+  if (flags & HAS_SSE2)
+    vpx_highbd_h_predictor_32x32 = vpx_highbd_h_predictor_32x32_sse2;
+  vpx_highbd_h_predictor_4x4 = vpx_highbd_h_predictor_4x4_c;
+  if (flags & HAS_SSE2)
+    vpx_highbd_h_predictor_4x4 = vpx_highbd_h_predictor_4x4_sse2;
+  vpx_highbd_h_predictor_8x8 = vpx_highbd_h_predictor_8x8_c;
+  if (flags & HAS_SSE2)
+    vpx_highbd_h_predictor_8x8 = vpx_highbd_h_predictor_8x8_sse2;
   vpx_highbd_idct16x16_10_add = vpx_highbd_idct16x16_10_add_c;
   if (flags & HAS_SSE2)
     vpx_highbd_idct16x16_10_add = vpx_highbd_idct16x16_10_add_sse2;
@@ -9343,6 +9630,9 @@
     vpx_quantize_b = vpx_quantize_b_ssse3;
   if (flags & HAS_AVX)
     vpx_quantize_b = vpx_quantize_b_avx;
+  vpx_quantize_b_32x32 = vpx_quantize_b_32x32_c;
+  if (flags & HAS_SSSE3)
+    vpx_quantize_b_32x32 = vpx_quantize_b_32x32_ssse3;
   vpx_sad16x16 = vpx_sad16x16_c;
   if (flags & HAS_SSE2)
     vpx_sad16x16 = vpx_sad16x16_sse2;
diff --git a/third_party/libvpx/source/config/linux/mips64el/vpx_dsp_rtcd.h b/third_party/libvpx/source/config/linux/mips64el/vpx_dsp_rtcd.h
index 9fae69e..a08da50 100644
--- a/third_party/libvpx/source/config/linux/mips64el/vpx_dsp_rtcd.h
+++ b/third_party/libvpx/source/config/linux/mips64el/vpx_dsp_rtcd.h
@@ -13,6 +13,7 @@
 
 #include "vpx/vpx_integer.h"
 #include "vpx_dsp/vpx_dsp_common.h"
+#include "vpx_dsp/vpx_filter.h"
 
 #ifdef __cplusplus
 extern "C" {
@@ -36,9 +37,10 @@
                      ptrdiff_t src_stride,
                      uint8_t* dst,
                      ptrdiff_t dst_stride,
-                     const int16_t* filter_x,
+                     const InterpKernel* filter,
+                     int x0_q4,
                      int x_step_q4,
-                     const int16_t* filter_y,
+                     int y0_q4,
                      int y_step_q4,
                      int w,
                      int h);
@@ -48,9 +50,10 @@
                          ptrdiff_t src_stride,
                          uint8_t* dst,
                          ptrdiff_t dst_stride,
-                         const int16_t* filter_x,
+                         const InterpKernel* filter,
+                         int x0_q4,
                          int x_step_q4,
-                         const int16_t* filter_y,
+                         int y0_q4,
                          int y_step_q4,
                          int w,
                          int h);
@@ -60,9 +63,10 @@
                                ptrdiff_t src_stride,
                                uint8_t* dst,
                                ptrdiff_t dst_stride,
-                               const int16_t* filter_x,
+                               const InterpKernel* filter,
+                               int x0_q4,
                                int x_step_q4,
-                               const int16_t* filter_y,
+                               int y0_q4,
                                int y_step_q4,
                                int w,
                                int h);
@@ -72,9 +76,10 @@
                               ptrdiff_t src_stride,
                               uint8_t* dst,
                               ptrdiff_t dst_stride,
-                              const int16_t* filter_x,
+                              const InterpKernel* filter,
+                              int x0_q4,
                               int x_step_q4,
-                              const int16_t* filter_y,
+                              int y0_q4,
                               int y_step_q4,
                               int w,
                               int h);
@@ -84,9 +89,10 @@
                            ptrdiff_t src_stride,
                            uint8_t* dst,
                            ptrdiff_t dst_stride,
-                           const int16_t* filter_x,
+                           const InterpKernel* filter,
+                           int x0_q4,
                            int x_step_q4,
-                           const int16_t* filter_y,
+                           int y0_q4,
                            int y_step_q4,
                            int w,
                            int h);
@@ -96,9 +102,10 @@
                           ptrdiff_t src_stride,
                           uint8_t* dst,
                           ptrdiff_t dst_stride,
-                          const int16_t* filter_x,
+                          const InterpKernel* filter,
+                          int x0_q4,
                           int x_step_q4,
-                          const int16_t* filter_y,
+                          int y0_q4,
                           int y_step_q4,
                           int w,
                           int h);
@@ -108,9 +115,10 @@
                         ptrdiff_t src_stride,
                         uint8_t* dst,
                         ptrdiff_t dst_stride,
-                        const int16_t* filter_x,
+                        const InterpKernel* filter,
+                        int x0_q4,
                         int x_step_q4,
-                        const int16_t* filter_y,
+                        int y0_q4,
                         int y_step_q4,
                         int w,
                         int h);
@@ -120,9 +128,10 @@
                          ptrdiff_t src_stride,
                          uint8_t* dst,
                          ptrdiff_t dst_stride,
-                         const int16_t* filter_x,
+                         const InterpKernel* filter,
+                         int x0_q4,
                          int x_step_q4,
-                         const int16_t* filter_y,
+                         int y0_q4,
                          int y_step_q4,
                          int w,
                          int h);
@@ -1064,9 +1073,10 @@
                      ptrdiff_t src_stride,
                      uint8_t* dst,
                      ptrdiff_t dst_stride,
-                     const int16_t* filter_x,
+                     const InterpKernel* filter,
+                     int x0_q4,
                      int x_step_q4,
-                     const int16_t* filter_y,
+                     int y0_q4,
                      int y_step_q4,
                      int w,
                      int h);
@@ -1076,9 +1086,10 @@
                          ptrdiff_t src_stride,
                          uint8_t* dst,
                          ptrdiff_t dst_stride,
-                         const int16_t* filter_x,
+                         const InterpKernel* filter,
+                         int x0_q4,
                          int x_step_q4,
-                         const int16_t* filter_y,
+                         int y0_q4,
                          int y_step_q4,
                          int w,
                          int h);
@@ -1088,9 +1099,10 @@
                             ptrdiff_t src_stride,
                             uint8_t* dst,
                             ptrdiff_t dst_stride,
-                            const int16_t* filter_x,
+                            const InterpKernel* filter,
+                            int x0_q4,
                             int x_step_q4,
-                            const int16_t* filter_y,
+                            int y0_q4,
                             int y_step_q4,
                             int w,
                             int h);
@@ -1100,9 +1112,10 @@
                            ptrdiff_t src_stride,
                            uint8_t* dst,
                            ptrdiff_t dst_stride,
-                           const int16_t* filter_x,
+                           const InterpKernel* filter,
+                           int x0_q4,
                            int x_step_q4,
-                           const int16_t* filter_y,
+                           int y0_q4,
                            int y_step_q4,
                            int w,
                            int h);
@@ -1112,9 +1125,10 @@
                         ptrdiff_t src_stride,
                         uint8_t* dst,
                         ptrdiff_t dst_stride,
-                        const int16_t* filter_x,
+                        const InterpKernel* filter,
+                        int x0_q4,
                         int x_step_q4,
-                        const int16_t* filter_y,
+                        int y0_q4,
                         int y_step_q4,
                         int w,
                         int h);
@@ -1124,9 +1138,10 @@
                        ptrdiff_t src_stride,
                        uint8_t* dst,
                        ptrdiff_t dst_stride,
-                       const int16_t* filter_x,
+                       const InterpKernel* filter,
+                       int x0_q4,
                        int x_step_q4,
-                       const int16_t* filter_y,
+                       int y0_q4,
                        int y_step_q4,
                        int w,
                        int h);
diff --git a/third_party/libvpx/source/config/linux/mipsel/vpx_dsp_rtcd.h b/third_party/libvpx/source/config/linux/mipsel/vpx_dsp_rtcd.h
index 9fae69e..a08da50 100644
--- a/third_party/libvpx/source/config/linux/mipsel/vpx_dsp_rtcd.h
+++ b/third_party/libvpx/source/config/linux/mipsel/vpx_dsp_rtcd.h
@@ -13,6 +13,7 @@
 
 #include "vpx/vpx_integer.h"
 #include "vpx_dsp/vpx_dsp_common.h"
+#include "vpx_dsp/vpx_filter.h"
 
 #ifdef __cplusplus
 extern "C" {
@@ -36,9 +37,10 @@
                      ptrdiff_t src_stride,
                      uint8_t* dst,
                      ptrdiff_t dst_stride,
-                     const int16_t* filter_x,
+                     const InterpKernel* filter,
+                     int x0_q4,
                      int x_step_q4,
-                     const int16_t* filter_y,
+                     int y0_q4,
                      int y_step_q4,
                      int w,
                      int h);
@@ -48,9 +50,10 @@
                          ptrdiff_t src_stride,
                          uint8_t* dst,
                          ptrdiff_t dst_stride,
-                         const int16_t* filter_x,
+                         const InterpKernel* filter,
+                         int x0_q4,
                          int x_step_q4,
-                         const int16_t* filter_y,
+                         int y0_q4,
                          int y_step_q4,
                          int w,
                          int h);
@@ -60,9 +63,10 @@
                                ptrdiff_t src_stride,
                                uint8_t* dst,
                                ptrdiff_t dst_stride,
-                               const int16_t* filter_x,
+                               const InterpKernel* filter,
+                               int x0_q4,
                                int x_step_q4,
-                               const int16_t* filter_y,
+                               int y0_q4,
                                int y_step_q4,
                                int w,
                                int h);
@@ -72,9 +76,10 @@
                               ptrdiff_t src_stride,
                               uint8_t* dst,
                               ptrdiff_t dst_stride,
-                              const int16_t* filter_x,
+                              const InterpKernel* filter,
+                              int x0_q4,
                               int x_step_q4,
-                              const int16_t* filter_y,
+                              int y0_q4,
                               int y_step_q4,
                               int w,
                               int h);
@@ -84,9 +89,10 @@
                            ptrdiff_t src_stride,
                            uint8_t* dst,
                            ptrdiff_t dst_stride,
-                           const int16_t* filter_x,
+                           const InterpKernel* filter,
+                           int x0_q4,
                            int x_step_q4,
-                           const int16_t* filter_y,
+                           int y0_q4,
                            int y_step_q4,
                            int w,
                            int h);
@@ -96,9 +102,10 @@
                           ptrdiff_t src_stride,
                           uint8_t* dst,
                           ptrdiff_t dst_stride,
-                          const int16_t* filter_x,
+                          const InterpKernel* filter,
+                          int x0_q4,
                           int x_step_q4,
-                          const int16_t* filter_y,
+                          int y0_q4,
                           int y_step_q4,
                           int w,
                           int h);
@@ -108,9 +115,10 @@
                         ptrdiff_t src_stride,
                         uint8_t* dst,
                         ptrdiff_t dst_stride,
-                        const int16_t* filter_x,
+                        const InterpKernel* filter,
+                        int x0_q4,
                         int x_step_q4,
-                        const int16_t* filter_y,
+                        int y0_q4,
                         int y_step_q4,
                         int w,
                         int h);
@@ -120,9 +128,10 @@
                          ptrdiff_t src_stride,
                          uint8_t* dst,
                          ptrdiff_t dst_stride,
-                         const int16_t* filter_x,
+                         const InterpKernel* filter,
+                         int x0_q4,
                          int x_step_q4,
-                         const int16_t* filter_y,
+                         int y0_q4,
                          int y_step_q4,
                          int w,
                          int h);
@@ -1064,9 +1073,10 @@
                      ptrdiff_t src_stride,
                      uint8_t* dst,
                      ptrdiff_t dst_stride,
-                     const int16_t* filter_x,
+                     const InterpKernel* filter,
+                     int x0_q4,
                      int x_step_q4,
-                     const int16_t* filter_y,
+                     int y0_q4,
                      int y_step_q4,
                      int w,
                      int h);
@@ -1076,9 +1086,10 @@
                          ptrdiff_t src_stride,
                          uint8_t* dst,
                          ptrdiff_t dst_stride,
-                         const int16_t* filter_x,
+                         const InterpKernel* filter,
+                         int x0_q4,
                          int x_step_q4,
-                         const int16_t* filter_y,
+                         int y0_q4,
                          int y_step_q4,
                          int w,
                          int h);
@@ -1088,9 +1099,10 @@
                             ptrdiff_t src_stride,
                             uint8_t* dst,
                             ptrdiff_t dst_stride,
-                            const int16_t* filter_x,
+                            const InterpKernel* filter,
+                            int x0_q4,
                             int x_step_q4,
-                            const int16_t* filter_y,
+                            int y0_q4,
                             int y_step_q4,
                             int w,
                             int h);
@@ -1100,9 +1112,10 @@
                            ptrdiff_t src_stride,
                            uint8_t* dst,
                            ptrdiff_t dst_stride,
-                           const int16_t* filter_x,
+                           const InterpKernel* filter,
+                           int x0_q4,
                            int x_step_q4,
-                           const int16_t* filter_y,
+                           int y0_q4,
                            int y_step_q4,
                            int w,
                            int h);
@@ -1112,9 +1125,10 @@
                         ptrdiff_t src_stride,
                         uint8_t* dst,
                         ptrdiff_t dst_stride,
-                        const int16_t* filter_x,
+                        const InterpKernel* filter,
+                        int x0_q4,
                         int x_step_q4,
-                        const int16_t* filter_y,
+                        int y0_q4,
                         int y_step_q4,
                         int w,
                         int h);
@@ -1124,9 +1138,10 @@
                        ptrdiff_t src_stride,
                        uint8_t* dst,
                        ptrdiff_t dst_stride,
-                       const int16_t* filter_x,
+                       const InterpKernel* filter,
+                       int x0_q4,
                        int x_step_q4,
-                       const int16_t* filter_y,
+                       int y0_q4,
                        int y_step_q4,
                        int w,
                        int h);
diff --git a/third_party/libvpx/source/config/linux/x64/vpx_dsp_rtcd.h b/third_party/libvpx/source/config/linux/x64/vpx_dsp_rtcd.h
index 76174db..e3352ff2 100644
--- a/third_party/libvpx/source/config/linux/x64/vpx_dsp_rtcd.h
+++ b/third_party/libvpx/source/config/linux/x64/vpx_dsp_rtcd.h
@@ -13,6 +13,7 @@
 
 #include "vpx/vpx_integer.h"
 #include "vpx_dsp/vpx_dsp_common.h"
+#include "vpx_dsp/vpx_filter.h"
 
 #ifdef __cplusplus
 extern "C" {
@@ -44,9 +45,10 @@
                      ptrdiff_t src_stride,
                      uint8_t* dst,
                      ptrdiff_t dst_stride,
-                     const int16_t* filter_x,
+                     const InterpKernel* filter,
+                     int x0_q4,
                      int x_step_q4,
-                     const int16_t* filter_y,
+                     int y0_q4,
                      int y_step_q4,
                      int w,
                      int h);
@@ -54,9 +56,10 @@
                         ptrdiff_t src_stride,
                         uint8_t* dst,
                         ptrdiff_t dst_stride,
-                        const int16_t* filter_x,
+                        const InterpKernel* filter,
+                        int x0_q4,
                         int x_step_q4,
-                        const int16_t* filter_y,
+                        int y0_q4,
                         int y_step_q4,
                         int w,
                         int h);
@@ -64,9 +67,10 @@
                          ptrdiff_t src_stride,
                          uint8_t* dst,
                          ptrdiff_t dst_stride,
-                         const int16_t* filter_x,
+                         const InterpKernel* filter,
+                         int x0_q4,
                          int x_step_q4,
-                         const int16_t* filter_y,
+                         int y0_q4,
                          int y_step_q4,
                          int w,
                          int h);
@@ -74,9 +78,10 @@
                         ptrdiff_t src_stride,
                         uint8_t* dst,
                         ptrdiff_t dst_stride,
-                        const int16_t* filter_x,
+                        const InterpKernel* filter,
+                        int x0_q4,
                         int x_step_q4,
-                        const int16_t* filter_y,
+                        int y0_q4,
                         int y_step_q4,
                         int w,
                         int h);
@@ -84,9 +89,10 @@
                                   ptrdiff_t src_stride,
                                   uint8_t* dst,
                                   ptrdiff_t dst_stride,
-                                  const int16_t* filter_x,
+                                  const InterpKernel* filter,
+                                  int x0_q4,
                                   int x_step_q4,
-                                  const int16_t* filter_y,
+                                  int y0_q4,
                                   int y_step_q4,
                                   int w,
                                   int h);
@@ -95,9 +101,10 @@
                          ptrdiff_t src_stride,
                          uint8_t* dst,
                          ptrdiff_t dst_stride,
-                         const int16_t* filter_x,
+                         const InterpKernel* filter,
+                         int x0_q4,
                          int x_step_q4,
-                         const int16_t* filter_y,
+                         int y0_q4,
                          int y_step_q4,
                          int w,
                          int h);
@@ -105,9 +112,10 @@
                             ptrdiff_t src_stride,
                             uint8_t* dst,
                             ptrdiff_t dst_stride,
-                            const int16_t* filter_x,
+                            const InterpKernel* filter,
+                            int x0_q4,
                             int x_step_q4,
-                            const int16_t* filter_y,
+                            int y0_q4,
                             int y_step_q4,
                             int w,
                             int h);
@@ -115,9 +123,10 @@
                              ptrdiff_t src_stride,
                              uint8_t* dst,
                              ptrdiff_t dst_stride,
-                             const int16_t* filter_x,
+                             const InterpKernel* filter,
+                             int x0_q4,
                              int x_step_q4,
-                             const int16_t* filter_y,
+                             int y0_q4,
                              int y_step_q4,
                              int w,
                              int h);
@@ -125,9 +134,10 @@
                                       ptrdiff_t src_stride,
                                       uint8_t* dst,
                                       ptrdiff_t dst_stride,
-                                      const int16_t* filter_x,
+                                      const InterpKernel* filter,
+                                      int x0_q4,
                                       int x_step_q4,
-                                      const int16_t* filter_y,
+                                      int y0_q4,
                                       int y_step_q4,
                                       int w,
                                       int h);
@@ -136,9 +146,10 @@
                                ptrdiff_t src_stride,
                                uint8_t* dst,
                                ptrdiff_t dst_stride,
-                               const int16_t* filter_x,
+                               const InterpKernel* filter,
+                               int x0_q4,
                                int x_step_q4,
-                               const int16_t* filter_y,
+                               int y0_q4,
                                int y_step_q4,
                                int w,
                                int h);
@@ -146,9 +157,10 @@
                                   ptrdiff_t src_stride,
                                   uint8_t* dst,
                                   ptrdiff_t dst_stride,
-                                  const int16_t* filter_x,
+                                  const InterpKernel* filter,
+                                  int x0_q4,
                                   int x_step_q4,
-                                  const int16_t* filter_y,
+                                  int y0_q4,
                                   int y_step_q4,
                                   int w,
                                   int h);
@@ -156,9 +168,10 @@
                                    ptrdiff_t src_stride,
                                    uint8_t* dst,
                                    ptrdiff_t dst_stride,
-                                   const int16_t* filter_x,
+                                   const InterpKernel* filter,
+                                   int x0_q4,
                                    int x_step_q4,
-                                   const int16_t* filter_y,
+                                   int y0_q4,
                                    int y_step_q4,
                                    int w,
                                    int h);
@@ -166,9 +179,10 @@
                                             ptrdiff_t src_stride,
                                             uint8_t* dst,
                                             ptrdiff_t dst_stride,
-                                            const int16_t* filter_x,
+                                            const InterpKernel* filter,
+                                            int x0_q4,
                                             int x_step_q4,
-                                            const int16_t* filter_y,
+                                            int y0_q4,
                                             int y_step_q4,
                                             int w,
                                             int h);
@@ -177,9 +191,10 @@
                               ptrdiff_t src_stride,
                               uint8_t* dst,
                               ptrdiff_t dst_stride,
-                              const int16_t* filter_x,
+                              const InterpKernel* filter,
+                              int x0_q4,
                               int x_step_q4,
-                              const int16_t* filter_y,
+                              int y0_q4,
                               int y_step_q4,
                               int w,
                               int h);
@@ -187,9 +202,10 @@
                                  ptrdiff_t src_stride,
                                  uint8_t* dst,
                                  ptrdiff_t dst_stride,
-                                 const int16_t* filter_x,
+                                 const InterpKernel* filter,
+                                 int x0_q4,
                                  int x_step_q4,
-                                 const int16_t* filter_y,
+                                 int y0_q4,
                                  int y_step_q4,
                                  int w,
                                  int h);
@@ -197,9 +213,10 @@
                                   ptrdiff_t src_stride,
                                   uint8_t* dst,
                                   ptrdiff_t dst_stride,
-                                  const int16_t* filter_x,
+                                  const InterpKernel* filter,
+                                  int x0_q4,
                                   int x_step_q4,
-                                  const int16_t* filter_y,
+                                  int y0_q4,
                                   int y_step_q4,
                                   int w,
                                   int h);
@@ -207,9 +224,10 @@
                                            ptrdiff_t src_stride,
                                            uint8_t* dst,
                                            ptrdiff_t dst_stride,
-                                           const int16_t* filter_x,
+                                           const InterpKernel* filter,
+                                           int x0_q4,
                                            int x_step_q4,
-                                           const int16_t* filter_y,
+                                           int y0_q4,
                                            int y_step_q4,
                                            int w,
                                            int h);
@@ -218,9 +236,10 @@
                            ptrdiff_t src_stride,
                            uint8_t* dst,
                            ptrdiff_t dst_stride,
-                           const int16_t* filter_x,
+                           const InterpKernel* filter,
+                           int x0_q4,
                            int x_step_q4,
-                           const int16_t* filter_y,
+                           int y0_q4,
                            int y_step_q4,
                            int w,
                            int h);
@@ -228,9 +247,10 @@
                               ptrdiff_t src_stride,
                               uint8_t* dst,
                               ptrdiff_t dst_stride,
-                              const int16_t* filter_x,
+                              const InterpKernel* filter,
+                              int x0_q4,
                               int x_step_q4,
-                              const int16_t* filter_y,
+                              int y0_q4,
                               int y_step_q4,
                               int w,
                               int h);
@@ -238,9 +258,10 @@
                                ptrdiff_t src_stride,
                                uint8_t* dst,
                                ptrdiff_t dst_stride,
-                               const int16_t* filter_x,
+                               const InterpKernel* filter,
+                               int x0_q4,
                                int x_step_q4,
-                               const int16_t* filter_y,
+                               int y0_q4,
                                int y_step_q4,
                                int w,
                                int h);
@@ -248,9 +269,10 @@
                               ptrdiff_t src_stride,
                               uint8_t* dst,
                               ptrdiff_t dst_stride,
-                              const int16_t* filter_x,
+                              const InterpKernel* filter,
+                              int x0_q4,
                               int x_step_q4,
-                              const int16_t* filter_y,
+                              int y0_q4,
                               int y_step_q4,
                               int w,
                               int h);
@@ -258,9 +280,10 @@
                                         ptrdiff_t src_stride,
                                         uint8_t* dst,
                                         ptrdiff_t dst_stride,
-                                        const int16_t* filter_x,
+                                        const InterpKernel* filter,
+                                        int x0_q4,
                                         int x_step_q4,
-                                        const int16_t* filter_y,
+                                        int y0_q4,
                                         int y_step_q4,
                                         int w,
                                         int h);
@@ -269,9 +292,10 @@
                           ptrdiff_t src_stride,
                           uint8_t* dst,
                           ptrdiff_t dst_stride,
-                          const int16_t* filter_x,
+                          const InterpKernel* filter,
+                          int x0_q4,
                           int x_step_q4,
-                          const int16_t* filter_y,
+                          int y0_q4,
                           int y_step_q4,
                           int w,
                           int h);
@@ -279,9 +303,10 @@
                              ptrdiff_t src_stride,
                              uint8_t* dst,
                              ptrdiff_t dst_stride,
-                             const int16_t* filter_x,
+                             const InterpKernel* filter,
+                             int x0_q4,
                              int x_step_q4,
-                             const int16_t* filter_y,
+                             int y0_q4,
                              int y_step_q4,
                              int w,
                              int h);
@@ -289,9 +314,10 @@
                               ptrdiff_t src_stride,
                               uint8_t* dst,
                               ptrdiff_t dst_stride,
-                              const int16_t* filter_x,
+                              const InterpKernel* filter,
+                              int x0_q4,
                               int x_step_q4,
-                              const int16_t* filter_y,
+                              int y0_q4,
                               int y_step_q4,
                               int w,
                               int h);
@@ -299,9 +325,10 @@
                              ptrdiff_t src_stride,
                              uint8_t* dst,
                              ptrdiff_t dst_stride,
-                             const int16_t* filter_x,
+                             const InterpKernel* filter,
+                             int x0_q4,
                              int x_step_q4,
-                             const int16_t* filter_y,
+                             int y0_q4,
                              int y_step_q4,
                              int w,
                              int h);
@@ -309,9 +336,10 @@
                                        ptrdiff_t src_stride,
                                        uint8_t* dst,
                                        ptrdiff_t dst_stride,
-                                       const int16_t* filter_x,
+                                       const InterpKernel* filter,
+                                       int x0_q4,
                                        int x_step_q4,
-                                       const int16_t* filter_y,
+                                       int y0_q4,
                                        int y_step_q4,
                                        int w,
                                        int h);
@@ -320,9 +348,10 @@
                         ptrdiff_t src_stride,
                         uint8_t* dst,
                         ptrdiff_t dst_stride,
-                        const int16_t* filter_x,
+                        const InterpKernel* filter,
+                        int x0_q4,
                         int x_step_q4,
-                        const int16_t* filter_y,
+                        int y0_q4,
                         int y_step_q4,
                         int w,
                         int h);
@@ -330,9 +359,10 @@
                            ptrdiff_t src_stride,
                            uint8_t* dst,
                            ptrdiff_t dst_stride,
-                           const int16_t* filter_x,
+                           const InterpKernel* filter,
+                           int x0_q4,
                            int x_step_q4,
-                           const int16_t* filter_y,
+                           int y0_q4,
                            int y_step_q4,
                            int w,
                            int h);
@@ -342,9 +372,10 @@
                          ptrdiff_t src_stride,
                          uint8_t* dst,
                          ptrdiff_t dst_stride,
-                         const int16_t* filter_x,
+                         const InterpKernel* filter,
+                         int x0_q4,
                          int x_step_q4,
-                         const int16_t* filter_y,
+                         int y0_q4,
                          int y_step_q4,
                          int w,
                          int h);
@@ -352,9 +383,10 @@
                             ptrdiff_t src_stride,
                             uint8_t* dst,
                             ptrdiff_t dst_stride,
-                            const int16_t* filter_x,
+                            const InterpKernel* filter,
+                            int x0_q4,
                             int x_step_q4,
-                            const int16_t* filter_y,
+                            int y0_q4,
                             int y_step_q4,
                             int w,
                             int h);
@@ -2895,9 +2927,10 @@
                             ptrdiff_t src_stride,
                             uint16_t* dst,
                             ptrdiff_t dst_stride,
-                            const int16_t* filter_x,
+                            const InterpKernel* filter,
+                            int x0_q4,
                             int x_step_q4,
-                            const int16_t* filter_y,
+                            int y0_q4,
                             int y_step_q4,
                             int w,
                             int h,
@@ -2906,9 +2939,10 @@
                                ptrdiff_t src_stride,
                                uint16_t* dst,
                                ptrdiff_t dst_stride,
-                               const int16_t* filter_x,
+                               const InterpKernel* filter,
+                               int x0_q4,
                                int x_step_q4,
-                               const int16_t* filter_y,
+                               int y0_q4,
                                int y_step_q4,
                                int w,
                                int h,
@@ -2917,9 +2951,10 @@
                                ptrdiff_t src_stride,
                                uint16_t* dst,
                                ptrdiff_t dst_stride,
-                               const int16_t* filter_x,
+                               const InterpKernel* filter,
+                               int x0_q4,
                                int x_step_q4,
-                               const int16_t* filter_y,
+                               int y0_q4,
                                int y_step_q4,
                                int w,
                                int h,
@@ -2928,9 +2963,10 @@
                                          ptrdiff_t src_stride,
                                          uint16_t* dst,
                                          ptrdiff_t dst_stride,
-                                         const int16_t* filter_x,
+                                         const InterpKernel* filter,
+                                         int x0_q4,
                                          int x_step_q4,
-                                         const int16_t* filter_y,
+                                         int y0_q4,
                                          int y_step_q4,
                                          int w,
                                          int h,
@@ -2940,9 +2976,10 @@
                                 ptrdiff_t src_stride,
                                 uint16_t* dst,
                                 ptrdiff_t dst_stride,
-                                const int16_t* filter_x,
+                                const InterpKernel* filter,
+                                int x0_q4,
                                 int x_step_q4,
-                                const int16_t* filter_y,
+                                int y0_q4,
                                 int y_step_q4,
                                 int w,
                                 int h,
@@ -2951,9 +2988,10 @@
                                    ptrdiff_t src_stride,
                                    uint16_t* dst,
                                    ptrdiff_t dst_stride,
-                                   const int16_t* filter_x,
+                                   const InterpKernel* filter,
+                                   int x0_q4,
                                    int x_step_q4,
-                                   const int16_t* filter_y,
+                                   int y0_q4,
                                    int y_step_q4,
                                    int w,
                                    int h,
@@ -2962,9 +3000,10 @@
                                    ptrdiff_t src_stride,
                                    uint16_t* dst,
                                    ptrdiff_t dst_stride,
-                                   const int16_t* filter_x,
+                                   const InterpKernel* filter,
+                                   int x0_q4,
                                    int x_step_q4,
-                                   const int16_t* filter_y,
+                                   int y0_q4,
                                    int y_step_q4,
                                    int w,
                                    int h,
@@ -2973,9 +3012,10 @@
                                              ptrdiff_t src_stride,
                                              uint16_t* dst,
                                              ptrdiff_t dst_stride,
-                                             const int16_t* filter_x,
+                                             const InterpKernel* filter,
+                                             int x0_q4,
                                              int x_step_q4,
-                                             const int16_t* filter_y,
+                                             int y0_q4,
                                              int y_step_q4,
                                              int w,
                                              int h,
@@ -2985,9 +3025,10 @@
                                       ptrdiff_t src_stride,
                                       uint16_t* dst,
                                       ptrdiff_t dst_stride,
-                                      const int16_t* filter_x,
+                                      const InterpKernel* filter,
+                                      int x0_q4,
                                       int x_step_q4,
-                                      const int16_t* filter_y,
+                                      int y0_q4,
                                       int y_step_q4,
                                       int w,
                                       int h,
@@ -2996,9 +3037,10 @@
                                          ptrdiff_t src_stride,
                                          uint16_t* dst,
                                          ptrdiff_t dst_stride,
-                                         const int16_t* filter_x,
+                                         const InterpKernel* filter,
+                                         int x0_q4,
                                          int x_step_q4,
-                                         const int16_t* filter_y,
+                                         int y0_q4,
                                          int y_step_q4,
                                          int w,
                                          int h,
@@ -3007,9 +3049,10 @@
                                          ptrdiff_t src_stride,
                                          uint16_t* dst,
                                          ptrdiff_t dst_stride,
-                                         const int16_t* filter_x,
+                                         const InterpKernel* filter,
+                                         int x0_q4,
                                          int x_step_q4,
-                                         const int16_t* filter_y,
+                                         int y0_q4,
                                          int y_step_q4,
                                          int w,
                                          int h,
@@ -3018,9 +3061,10 @@
                                                    ptrdiff_t src_stride,
                                                    uint16_t* dst,
                                                    ptrdiff_t dst_stride,
-                                                   const int16_t* filter_x,
+                                                   const InterpKernel* filter,
+                                                   int x0_q4,
                                                    int x_step_q4,
-                                                   const int16_t* filter_y,
+                                                   int y0_q4,
                                                    int y_step_q4,
                                                    int w,
                                                    int h,
@@ -3030,9 +3074,10 @@
                                      ptrdiff_t src_stride,
                                      uint16_t* dst,
                                      ptrdiff_t dst_stride,
-                                     const int16_t* filter_x,
+                                     const InterpKernel* filter,
+                                     int x0_q4,
                                      int x_step_q4,
-                                     const int16_t* filter_y,
+                                     int y0_q4,
                                      int y_step_q4,
                                      int w,
                                      int h,
@@ -3041,9 +3086,10 @@
                                         ptrdiff_t src_stride,
                                         uint16_t* dst,
                                         ptrdiff_t dst_stride,
-                                        const int16_t* filter_x,
+                                        const InterpKernel* filter,
+                                        int x0_q4,
                                         int x_step_q4,
-                                        const int16_t* filter_y,
+                                        int y0_q4,
                                         int y_step_q4,
                                         int w,
                                         int h,
@@ -3052,9 +3098,10 @@
                                         ptrdiff_t src_stride,
                                         uint16_t* dst,
                                         ptrdiff_t dst_stride,
-                                        const int16_t* filter_x,
+                                        const InterpKernel* filter,
+                                        int x0_q4,
                                         int x_step_q4,
-                                        const int16_t* filter_y,
+                                        int y0_q4,
                                         int y_step_q4,
                                         int w,
                                         int h,
@@ -3063,9 +3110,10 @@
                                                   ptrdiff_t src_stride,
                                                   uint16_t* dst,
                                                   ptrdiff_t dst_stride,
-                                                  const int16_t* filter_x,
+                                                  const InterpKernel* filter,
+                                                  int x0_q4,
                                                   int x_step_q4,
-                                                  const int16_t* filter_y,
+                                                  int y0_q4,
                                                   int y_step_q4,
                                                   int w,
                                                   int h,
@@ -3075,9 +3123,10 @@
                                   ptrdiff_t src_stride,
                                   uint16_t* dst,
                                   ptrdiff_t dst_stride,
-                                  const int16_t* filter_x,
+                                  const InterpKernel* filter,
+                                  int x0_q4,
                                   int x_step_q4,
-                                  const int16_t* filter_y,
+                                  int y0_q4,
                                   int y_step_q4,
                                   int w,
                                   int h,
@@ -3086,9 +3135,10 @@
                                      ptrdiff_t src_stride,
                                      uint16_t* dst,
                                      ptrdiff_t dst_stride,
-                                     const int16_t* filter_x,
+                                     const InterpKernel* filter,
+                                     int x0_q4,
                                      int x_step_q4,
-                                     const int16_t* filter_y,
+                                     int y0_q4,
                                      int y_step_q4,
                                      int w,
                                      int h,
@@ -3097,9 +3147,10 @@
                                      ptrdiff_t src_stride,
                                      uint16_t* dst,
                                      ptrdiff_t dst_stride,
-                                     const int16_t* filter_x,
+                                     const InterpKernel* filter,
+                                     int x0_q4,
                                      int x_step_q4,
-                                     const int16_t* filter_y,
+                                     int y0_q4,
                                      int y_step_q4,
                                      int w,
                                      int h,
@@ -3108,9 +3159,10 @@
                                                ptrdiff_t src_stride,
                                                uint16_t* dst,
                                                ptrdiff_t dst_stride,
-                                               const int16_t* filter_x,
+                                               const InterpKernel* filter,
+                                               int x0_q4,
                                                int x_step_q4,
-                                               const int16_t* filter_y,
+                                               int y0_q4,
                                                int y_step_q4,
                                                int w,
                                                int h,
@@ -3120,9 +3172,10 @@
                                  ptrdiff_t src_stride,
                                  uint16_t* dst,
                                  ptrdiff_t dst_stride,
-                                 const int16_t* filter_x,
+                                 const InterpKernel* filter,
+                                 int x0_q4,
                                  int x_step_q4,
-                                 const int16_t* filter_y,
+                                 int y0_q4,
                                  int y_step_q4,
                                  int w,
                                  int h,
@@ -3131,9 +3184,10 @@
                                     ptrdiff_t src_stride,
                                     uint16_t* dst,
                                     ptrdiff_t dst_stride,
-                                    const int16_t* filter_x,
+                                    const InterpKernel* filter,
+                                    int x0_q4,
                                     int x_step_q4,
-                                    const int16_t* filter_y,
+                                    int y0_q4,
                                     int y_step_q4,
                                     int w,
                                     int h,
@@ -3142,9 +3196,10 @@
                                     ptrdiff_t src_stride,
                                     uint16_t* dst,
                                     ptrdiff_t dst_stride,
-                                    const int16_t* filter_x,
+                                    const InterpKernel* filter,
+                                    int x0_q4,
                                     int x_step_q4,
-                                    const int16_t* filter_y,
+                                    int y0_q4,
                                     int y_step_q4,
                                     int w,
                                     int h,
@@ -3153,9 +3208,10 @@
                                               ptrdiff_t src_stride,
                                               uint16_t* dst,
                                               ptrdiff_t dst_stride,
-                                              const int16_t* filter_x,
+                                              const InterpKernel* filter,
+                                              int x0_q4,
                                               int x_step_q4,
-                                              const int16_t* filter_y,
+                                              int y0_q4,
                                               int y_step_q4,
                                               int w,
                                               int h,
@@ -3165,9 +3221,10 @@
                                ptrdiff_t src_stride,
                                uint16_t* dst,
                                ptrdiff_t dst_stride,
-                               const int16_t* filter_x,
+                               const InterpKernel* filter,
+                               int x0_q4,
                                int x_step_q4,
-                               const int16_t* filter_y,
+                               int y0_q4,
                                int y_step_q4,
                                int w,
                                int h,
@@ -3176,9 +3233,10 @@
                                   ptrdiff_t src_stride,
                                   uint16_t* dst,
                                   ptrdiff_t dst_stride,
-                                  const int16_t* filter_x,
+                                  const InterpKernel* filter,
+                                  int x0_q4,
                                   int x_step_q4,
-                                  const int16_t* filter_y,
+                                  int y0_q4,
                                   int y_step_q4,
                                   int w,
                                   int h,
@@ -3187,9 +3245,10 @@
                                   ptrdiff_t src_stride,
                                   uint16_t* dst,
                                   ptrdiff_t dst_stride,
-                                  const int16_t* filter_x,
+                                  const InterpKernel* filter,
+                                  int x0_q4,
                                   int x_step_q4,
-                                  const int16_t* filter_y,
+                                  int y0_q4,
                                   int y_step_q4,
                                   int w,
                                   int h,
@@ -3198,9 +3257,10 @@
                                             ptrdiff_t src_stride,
                                             uint16_t* dst,
                                             ptrdiff_t dst_stride,
-                                            const int16_t* filter_x,
+                                            const InterpKernel* filter,
+                                            int x0_q4,
                                             int x_step_q4,
-                                            const int16_t* filter_y,
+                                            int y0_q4,
                                             int y_step_q4,
                                             int w,
                                             int h,
@@ -3210,9 +3270,10 @@
                                 ptrdiff_t src_stride,
                                 uint16_t* dst,
                                 ptrdiff_t dst_stride,
-                                const int16_t* filter_x,
+                                const InterpKernel* filter,
+                                int x0_q4,
                                 int x_step_q4,
-                                const int16_t* filter_y,
+                                int y0_q4,
                                 int y_step_q4,
                                 int w,
                                 int h,
@@ -3221,9 +3282,10 @@
                                    ptrdiff_t src_stride,
                                    uint16_t* dst,
                                    ptrdiff_t dst_stride,
-                                   const int16_t* filter_x,
+                                   const InterpKernel* filter,
+                                   int x0_q4,
                                    int x_step_q4,
-                                   const int16_t* filter_y,
+                                   int y0_q4,
                                    int y_step_q4,
                                    int w,
                                    int h,
@@ -3232,9 +3294,10 @@
                                    ptrdiff_t src_stride,
                                    uint16_t* dst,
                                    ptrdiff_t dst_stride,
-                                   const int16_t* filter_x,
+                                   const InterpKernel* filter,
+                                   int x0_q4,
                                    int x_step_q4,
-                                   const int16_t* filter_y,
+                                   int y0_q4,
                                    int y_step_q4,
                                    int w,
                                    int h,
@@ -3243,9 +3306,10 @@
                                              ptrdiff_t src_stride,
                                              uint16_t* dst,
                                              ptrdiff_t dst_stride,
-                                             const int16_t* filter_x,
+                                             const InterpKernel* filter,
+                                             int x0_q4,
                                              int x_step_q4,
-                                             const int16_t* filter_y,
+                                             int y0_q4,
                                              int y_step_q4,
                                              int w,
                                              int h,
@@ -3424,56 +3488,98 @@
                                          const uint16_t* above,
                                          const uint16_t* left,
                                          int bd);
-#define vpx_highbd_dc_128_predictor_16x16 vpx_highbd_dc_128_predictor_16x16_c
+void vpx_highbd_dc_128_predictor_16x16_sse2(uint16_t* dst,
+                                            ptrdiff_t y_stride,
+                                            const uint16_t* above,
+                                            const uint16_t* left,
+                                            int bd);
+#define vpx_highbd_dc_128_predictor_16x16 vpx_highbd_dc_128_predictor_16x16_sse2
 
 void vpx_highbd_dc_128_predictor_32x32_c(uint16_t* dst,
                                          ptrdiff_t y_stride,
                                          const uint16_t* above,
                                          const uint16_t* left,
                                          int bd);
-#define vpx_highbd_dc_128_predictor_32x32 vpx_highbd_dc_128_predictor_32x32_c
+void vpx_highbd_dc_128_predictor_32x32_sse2(uint16_t* dst,
+                                            ptrdiff_t y_stride,
+                                            const uint16_t* above,
+                                            const uint16_t* left,
+                                            int bd);
+#define vpx_highbd_dc_128_predictor_32x32 vpx_highbd_dc_128_predictor_32x32_sse2
 
 void vpx_highbd_dc_128_predictor_4x4_c(uint16_t* dst,
                                        ptrdiff_t y_stride,
                                        const uint16_t* above,
                                        const uint16_t* left,
                                        int bd);
-#define vpx_highbd_dc_128_predictor_4x4 vpx_highbd_dc_128_predictor_4x4_c
+void vpx_highbd_dc_128_predictor_4x4_sse2(uint16_t* dst,
+                                          ptrdiff_t y_stride,
+                                          const uint16_t* above,
+                                          const uint16_t* left,
+                                          int bd);
+#define vpx_highbd_dc_128_predictor_4x4 vpx_highbd_dc_128_predictor_4x4_sse2
 
 void vpx_highbd_dc_128_predictor_8x8_c(uint16_t* dst,
                                        ptrdiff_t y_stride,
                                        const uint16_t* above,
                                        const uint16_t* left,
                                        int bd);
-#define vpx_highbd_dc_128_predictor_8x8 vpx_highbd_dc_128_predictor_8x8_c
+void vpx_highbd_dc_128_predictor_8x8_sse2(uint16_t* dst,
+                                          ptrdiff_t y_stride,
+                                          const uint16_t* above,
+                                          const uint16_t* left,
+                                          int bd);
+#define vpx_highbd_dc_128_predictor_8x8 vpx_highbd_dc_128_predictor_8x8_sse2
 
 void vpx_highbd_dc_left_predictor_16x16_c(uint16_t* dst,
                                           ptrdiff_t y_stride,
                                           const uint16_t* above,
                                           const uint16_t* left,
                                           int bd);
-#define vpx_highbd_dc_left_predictor_16x16 vpx_highbd_dc_left_predictor_16x16_c
+void vpx_highbd_dc_left_predictor_16x16_sse2(uint16_t* dst,
+                                             ptrdiff_t y_stride,
+                                             const uint16_t* above,
+                                             const uint16_t* left,
+                                             int bd);
+#define vpx_highbd_dc_left_predictor_16x16 \
+  vpx_highbd_dc_left_predictor_16x16_sse2
 
 void vpx_highbd_dc_left_predictor_32x32_c(uint16_t* dst,
                                           ptrdiff_t y_stride,
                                           const uint16_t* above,
                                           const uint16_t* left,
                                           int bd);
-#define vpx_highbd_dc_left_predictor_32x32 vpx_highbd_dc_left_predictor_32x32_c
+void vpx_highbd_dc_left_predictor_32x32_sse2(uint16_t* dst,
+                                             ptrdiff_t y_stride,
+                                             const uint16_t* above,
+                                             const uint16_t* left,
+                                             int bd);
+#define vpx_highbd_dc_left_predictor_32x32 \
+  vpx_highbd_dc_left_predictor_32x32_sse2
 
 void vpx_highbd_dc_left_predictor_4x4_c(uint16_t* dst,
                                         ptrdiff_t y_stride,
                                         const uint16_t* above,
                                         const uint16_t* left,
                                         int bd);
-#define vpx_highbd_dc_left_predictor_4x4 vpx_highbd_dc_left_predictor_4x4_c
+void vpx_highbd_dc_left_predictor_4x4_sse2(uint16_t* dst,
+                                           ptrdiff_t y_stride,
+                                           const uint16_t* above,
+                                           const uint16_t* left,
+                                           int bd);
+#define vpx_highbd_dc_left_predictor_4x4 vpx_highbd_dc_left_predictor_4x4_sse2
 
 void vpx_highbd_dc_left_predictor_8x8_c(uint16_t* dst,
                                         ptrdiff_t y_stride,
                                         const uint16_t* above,
                                         const uint16_t* left,
                                         int bd);
-#define vpx_highbd_dc_left_predictor_8x8 vpx_highbd_dc_left_predictor_8x8_c
+void vpx_highbd_dc_left_predictor_8x8_sse2(uint16_t* dst,
+                                           ptrdiff_t y_stride,
+                                           const uint16_t* above,
+                                           const uint16_t* left,
+                                           int bd);
+#define vpx_highbd_dc_left_predictor_8x8 vpx_highbd_dc_left_predictor_8x8_sse2
 
 void vpx_highbd_dc_predictor_16x16_c(uint16_t* dst,
                                      ptrdiff_t y_stride,
@@ -3528,28 +3634,48 @@
                                          const uint16_t* above,
                                          const uint16_t* left,
                                          int bd);
-#define vpx_highbd_dc_top_predictor_16x16 vpx_highbd_dc_top_predictor_16x16_c
+void vpx_highbd_dc_top_predictor_16x16_sse2(uint16_t* dst,
+                                            ptrdiff_t y_stride,
+                                            const uint16_t* above,
+                                            const uint16_t* left,
+                                            int bd);
+#define vpx_highbd_dc_top_predictor_16x16 vpx_highbd_dc_top_predictor_16x16_sse2
 
 void vpx_highbd_dc_top_predictor_32x32_c(uint16_t* dst,
                                          ptrdiff_t y_stride,
                                          const uint16_t* above,
                                          const uint16_t* left,
                                          int bd);
-#define vpx_highbd_dc_top_predictor_32x32 vpx_highbd_dc_top_predictor_32x32_c
+void vpx_highbd_dc_top_predictor_32x32_sse2(uint16_t* dst,
+                                            ptrdiff_t y_stride,
+                                            const uint16_t* above,
+                                            const uint16_t* left,
+                                            int bd);
+#define vpx_highbd_dc_top_predictor_32x32 vpx_highbd_dc_top_predictor_32x32_sse2
 
 void vpx_highbd_dc_top_predictor_4x4_c(uint16_t* dst,
                                        ptrdiff_t y_stride,
                                        const uint16_t* above,
                                        const uint16_t* left,
                                        int bd);
-#define vpx_highbd_dc_top_predictor_4x4 vpx_highbd_dc_top_predictor_4x4_c
+void vpx_highbd_dc_top_predictor_4x4_sse2(uint16_t* dst,
+                                          ptrdiff_t y_stride,
+                                          const uint16_t* above,
+                                          const uint16_t* left,
+                                          int bd);
+#define vpx_highbd_dc_top_predictor_4x4 vpx_highbd_dc_top_predictor_4x4_sse2
 
 void vpx_highbd_dc_top_predictor_8x8_c(uint16_t* dst,
                                        ptrdiff_t y_stride,
                                        const uint16_t* above,
                                        const uint16_t* left,
                                        int bd);
-#define vpx_highbd_dc_top_predictor_8x8 vpx_highbd_dc_top_predictor_8x8_c
+void vpx_highbd_dc_top_predictor_8x8_sse2(uint16_t* dst,
+                                          ptrdiff_t y_stride,
+                                          const uint16_t* above,
+                                          const uint16_t* left,
+                                          int bd);
+#define vpx_highbd_dc_top_predictor_8x8 vpx_highbd_dc_top_predictor_8x8_sse2
 
 void vpx_highbd_fdct16x16_c(const int16_t* input,
                             tran_low_t* output,
@@ -3607,28 +3733,48 @@
                                     const uint16_t* above,
                                     const uint16_t* left,
                                     int bd);
-#define vpx_highbd_h_predictor_16x16 vpx_highbd_h_predictor_16x16_c
+void vpx_highbd_h_predictor_16x16_sse2(uint16_t* dst,
+                                       ptrdiff_t y_stride,
+                                       const uint16_t* above,
+                                       const uint16_t* left,
+                                       int bd);
+#define vpx_highbd_h_predictor_16x16 vpx_highbd_h_predictor_16x16_sse2
 
 void vpx_highbd_h_predictor_32x32_c(uint16_t* dst,
                                     ptrdiff_t y_stride,
                                     const uint16_t* above,
                                     const uint16_t* left,
                                     int bd);
-#define vpx_highbd_h_predictor_32x32 vpx_highbd_h_predictor_32x32_c
+void vpx_highbd_h_predictor_32x32_sse2(uint16_t* dst,
+                                       ptrdiff_t y_stride,
+                                       const uint16_t* above,
+                                       const uint16_t* left,
+                                       int bd);
+#define vpx_highbd_h_predictor_32x32 vpx_highbd_h_predictor_32x32_sse2
 
 void vpx_highbd_h_predictor_4x4_c(uint16_t* dst,
                                   ptrdiff_t y_stride,
                                   const uint16_t* above,
                                   const uint16_t* left,
                                   int bd);
-#define vpx_highbd_h_predictor_4x4 vpx_highbd_h_predictor_4x4_c
+void vpx_highbd_h_predictor_4x4_sse2(uint16_t* dst,
+                                     ptrdiff_t y_stride,
+                                     const uint16_t* above,
+                                     const uint16_t* left,
+                                     int bd);
+#define vpx_highbd_h_predictor_4x4 vpx_highbd_h_predictor_4x4_sse2
 
 void vpx_highbd_h_predictor_8x8_c(uint16_t* dst,
                                   ptrdiff_t y_stride,
                                   const uint16_t* above,
                                   const uint16_t* left,
                                   int bd);
-#define vpx_highbd_h_predictor_8x8 vpx_highbd_h_predictor_8x8_c
+void vpx_highbd_h_predictor_8x8_sse2(uint16_t* dst,
+                                     ptrdiff_t y_stride,
+                                     const uint16_t* above,
+                                     const uint16_t* left,
+                                     int bd);
+#define vpx_highbd_h_predictor_8x8 vpx_highbd_h_predictor_8x8_sse2
 
 void vpx_highbd_idct16x16_10_add_c(const tran_low_t* input,
                                    uint16_t* dest,
@@ -5891,9 +6037,10 @@
                      ptrdiff_t src_stride,
                      uint8_t* dst,
                      ptrdiff_t dst_stride,
-                     const int16_t* filter_x,
+                     const InterpKernel* filter,
+                     int x0_q4,
                      int x_step_q4,
-                     const int16_t* filter_y,
+                     int y0_q4,
                      int y_step_q4,
                      int w,
                      int h);
@@ -5901,9 +6048,10 @@
                          ptrdiff_t src_stride,
                          uint8_t* dst,
                          ptrdiff_t dst_stride,
-                         const int16_t* filter_x,
+                         const InterpKernel* filter,
+                         int x0_q4,
                          int x_step_q4,
-                         const int16_t* filter_y,
+                         int y0_q4,
                          int y_step_q4,
                          int w,
                          int h);
@@ -5911,9 +6059,10 @@
                                   ptrdiff_t src_stride,
                                   uint8_t* dst,
                                   ptrdiff_t dst_stride,
-                                  const int16_t* filter_x,
+                                  const InterpKernel* filter,
+                                  int x0_q4,
                                   int x_step_q4,
-                                  const int16_t* filter_y,
+                                  int y0_q4,
                                   int y_step_q4,
                                   int w,
                                   int h);
@@ -5922,9 +6071,10 @@
                          ptrdiff_t src_stride,
                          uint8_t* dst,
                          ptrdiff_t dst_stride,
-                         const int16_t* filter_x,
+                         const InterpKernel* filter,
+                         int x0_q4,
                          int x_step_q4,
-                         const int16_t* filter_y,
+                         int y0_q4,
                          int y_step_q4,
                          int w,
                          int h);
@@ -5934,9 +6084,10 @@
                             ptrdiff_t src_stride,
                             uint8_t* dst,
                             ptrdiff_t dst_stride,
-                            const int16_t* filter_x,
+                            const InterpKernel* filter,
+                            int x0_q4,
                             int x_step_q4,
-                            const int16_t* filter_y,
+                            int y0_q4,
                             int y_step_q4,
                             int w,
                             int h);
@@ -5946,9 +6097,10 @@
                            ptrdiff_t src_stride,
                            uint8_t* dst,
                            ptrdiff_t dst_stride,
-                           const int16_t* filter_x,
+                           const InterpKernel* filter,
+                           int x0_q4,
                            int x_step_q4,
-                           const int16_t* filter_y,
+                           int y0_q4,
                            int y_step_q4,
                            int w,
                            int h);
@@ -5958,9 +6110,10 @@
                         ptrdiff_t src_stride,
                         uint8_t* dst,
                         ptrdiff_t dst_stride,
-                        const int16_t* filter_x,
+                        const InterpKernel* filter,
+                        int x0_q4,
                         int x_step_q4,
-                        const int16_t* filter_y,
+                        int y0_q4,
                         int y_step_q4,
                         int w,
                         int h);
@@ -5970,9 +6123,10 @@
                        ptrdiff_t src_stride,
                        uint8_t* dst,
                        ptrdiff_t dst_stride,
-                       const int16_t* filter_x,
+                       const InterpKernel* filter,
+                       int x0_q4,
                        int x_step_q4,
-                       const int16_t* filter_y,
+                       int y0_q4,
                        int y_step_q4,
                        int w,
                        int h);
diff --git a/third_party/libvpx/source/config/mac/ia32/vpx_dsp_rtcd.h b/third_party/libvpx/source/config/mac/ia32/vpx_dsp_rtcd.h
index 10f0c335..66e7b01 100644
--- a/third_party/libvpx/source/config/mac/ia32/vpx_dsp_rtcd.h
+++ b/third_party/libvpx/source/config/mac/ia32/vpx_dsp_rtcd.h
@@ -13,6 +13,7 @@
 
 #include "vpx/vpx_integer.h"
 #include "vpx_dsp/vpx_dsp_common.h"
+#include "vpx_dsp/vpx_filter.h"
 
 #ifdef __cplusplus
 extern "C" {
@@ -49,9 +50,10 @@
                      ptrdiff_t src_stride,
                      uint8_t* dst,
                      ptrdiff_t dst_stride,
-                     const int16_t* filter_x,
+                     const InterpKernel* filter,
+                     int x0_q4,
                      int x_step_q4,
-                     const int16_t* filter_y,
+                     int y0_q4,
                      int y_step_q4,
                      int w,
                      int h);
@@ -59,9 +61,10 @@
                         ptrdiff_t src_stride,
                         uint8_t* dst,
                         ptrdiff_t dst_stride,
-                        const int16_t* filter_x,
+                        const InterpKernel* filter,
+                        int x0_q4,
                         int x_step_q4,
-                        const int16_t* filter_y,
+                        int y0_q4,
                         int y_step_q4,
                         int w,
                         int h);
@@ -69,9 +72,10 @@
                          ptrdiff_t src_stride,
                          uint8_t* dst,
                          ptrdiff_t dst_stride,
-                         const int16_t* filter_x,
+                         const InterpKernel* filter,
+                         int x0_q4,
                          int x_step_q4,
-                         const int16_t* filter_y,
+                         int y0_q4,
                          int y_step_q4,
                          int w,
                          int h);
@@ -79,9 +83,10 @@
                         ptrdiff_t src_stride,
                         uint8_t* dst,
                         ptrdiff_t dst_stride,
-                        const int16_t* filter_x,
+                        const InterpKernel* filter,
+                        int x0_q4,
                         int x_step_q4,
-                        const int16_t* filter_y,
+                        int y0_q4,
                         int y_step_q4,
                         int w,
                         int h);
@@ -89,9 +94,10 @@
                                   ptrdiff_t src_stride,
                                   uint8_t* dst,
                                   ptrdiff_t dst_stride,
-                                  const int16_t* filter_x,
+                                  const InterpKernel* filter,
+                                  int x0_q4,
                                   int x_step_q4,
-                                  const int16_t* filter_y,
+                                  int y0_q4,
                                   int y_step_q4,
                                   int w,
                                   int h);
@@ -100,9 +106,10 @@
                          ptrdiff_t src_stride,
                          uint8_t* dst,
                          ptrdiff_t dst_stride,
-                         const int16_t* filter_x,
+                         const InterpKernel* filter,
+                         int x0_q4,
                          int x_step_q4,
-                         const int16_t* filter_y,
+                         int y0_q4,
                          int y_step_q4,
                          int w,
                          int h);
@@ -110,9 +117,10 @@
                             ptrdiff_t src_stride,
                             uint8_t* dst,
                             ptrdiff_t dst_stride,
-                            const int16_t* filter_x,
+                            const InterpKernel* filter,
+                            int x0_q4,
                             int x_step_q4,
-                            const int16_t* filter_y,
+                            int y0_q4,
                             int y_step_q4,
                             int w,
                             int h);
@@ -120,9 +128,10 @@
                              ptrdiff_t src_stride,
                              uint8_t* dst,
                              ptrdiff_t dst_stride,
-                             const int16_t* filter_x,
+                             const InterpKernel* filter,
+                             int x0_q4,
                              int x_step_q4,
-                             const int16_t* filter_y,
+                             int y0_q4,
                              int y_step_q4,
                              int w,
                              int h);
@@ -130,9 +139,10 @@
                                       ptrdiff_t src_stride,
                                       uint8_t* dst,
                                       ptrdiff_t dst_stride,
-                                      const int16_t* filter_x,
+                                      const InterpKernel* filter,
+                                      int x0_q4,
                                       int x_step_q4,
-                                      const int16_t* filter_y,
+                                      int y0_q4,
                                       int y_step_q4,
                                       int w,
                                       int h);
@@ -141,9 +151,10 @@
                                ptrdiff_t src_stride,
                                uint8_t* dst,
                                ptrdiff_t dst_stride,
-                               const int16_t* filter_x,
+                               const InterpKernel* filter,
+                               int x0_q4,
                                int x_step_q4,
-                               const int16_t* filter_y,
+                               int y0_q4,
                                int y_step_q4,
                                int w,
                                int h);
@@ -151,9 +162,10 @@
                                   ptrdiff_t src_stride,
                                   uint8_t* dst,
                                   ptrdiff_t dst_stride,
-                                  const int16_t* filter_x,
+                                  const InterpKernel* filter,
+                                  int x0_q4,
                                   int x_step_q4,
-                                  const int16_t* filter_y,
+                                  int y0_q4,
                                   int y_step_q4,
                                   int w,
                                   int h);
@@ -161,9 +173,10 @@
                                    ptrdiff_t src_stride,
                                    uint8_t* dst,
                                    ptrdiff_t dst_stride,
-                                   const int16_t* filter_x,
+                                   const InterpKernel* filter,
+                                   int x0_q4,
                                    int x_step_q4,
-                                   const int16_t* filter_y,
+                                   int y0_q4,
                                    int y_step_q4,
                                    int w,
                                    int h);
@@ -171,9 +184,10 @@
                                             ptrdiff_t src_stride,
                                             uint8_t* dst,
                                             ptrdiff_t dst_stride,
-                                            const int16_t* filter_x,
+                                            const InterpKernel* filter,
+                                            int x0_q4,
                                             int x_step_q4,
-                                            const int16_t* filter_y,
+                                            int y0_q4,
                                             int y_step_q4,
                                             int w,
                                             int h);
@@ -182,9 +196,10 @@
                               ptrdiff_t src_stride,
                               uint8_t* dst,
                               ptrdiff_t dst_stride,
-                              const int16_t* filter_x,
+                              const InterpKernel* filter,
+                              int x0_q4,
                               int x_step_q4,
-                              const int16_t* filter_y,
+                              int y0_q4,
                               int y_step_q4,
                               int w,
                               int h);
@@ -192,9 +207,10 @@
                                  ptrdiff_t src_stride,
                                  uint8_t* dst,
                                  ptrdiff_t dst_stride,
-                                 const int16_t* filter_x,
+                                 const InterpKernel* filter,
+                                 int x0_q4,
                                  int x_step_q4,
-                                 const int16_t* filter_y,
+                                 int y0_q4,
                                  int y_step_q4,
                                  int w,
                                  int h);
@@ -202,9 +218,10 @@
                                   ptrdiff_t src_stride,
                                   uint8_t* dst,
                                   ptrdiff_t dst_stride,
-                                  const int16_t* filter_x,
+                                  const InterpKernel* filter,
+                                  int x0_q4,
                                   int x_step_q4,
-                                  const int16_t* filter_y,
+                                  int y0_q4,
                                   int y_step_q4,
                                   int w,
                                   int h);
@@ -212,9 +229,10 @@
                                            ptrdiff_t src_stride,
                                            uint8_t* dst,
                                            ptrdiff_t dst_stride,
-                                           const int16_t* filter_x,
+                                           const InterpKernel* filter,
+                                           int x0_q4,
                                            int x_step_q4,
-                                           const int16_t* filter_y,
+                                           int y0_q4,
                                            int y_step_q4,
                                            int w,
                                            int h);
@@ -223,9 +241,10 @@
                            ptrdiff_t src_stride,
                            uint8_t* dst,
                            ptrdiff_t dst_stride,
-                           const int16_t* filter_x,
+                           const InterpKernel* filter,
+                           int x0_q4,
                            int x_step_q4,
-                           const int16_t* filter_y,
+                           int y0_q4,
                            int y_step_q4,
                            int w,
                            int h);
@@ -233,9 +252,10 @@
                               ptrdiff_t src_stride,
                               uint8_t* dst,
                               ptrdiff_t dst_stride,
-                              const int16_t* filter_x,
+                              const InterpKernel* filter,
+                              int x0_q4,
                               int x_step_q4,
-                              const int16_t* filter_y,
+                              int y0_q4,
                               int y_step_q4,
                               int w,
                               int h);
@@ -243,9 +263,10 @@
                                ptrdiff_t src_stride,
                                uint8_t* dst,
                                ptrdiff_t dst_stride,
-                               const int16_t* filter_x,
+                               const InterpKernel* filter,
+                               int x0_q4,
                                int x_step_q4,
-                               const int16_t* filter_y,
+                               int y0_q4,
                                int y_step_q4,
                                int w,
                                int h);
@@ -253,9 +274,10 @@
                               ptrdiff_t src_stride,
                               uint8_t* dst,
                               ptrdiff_t dst_stride,
-                              const int16_t* filter_x,
+                              const InterpKernel* filter,
+                              int x0_q4,
                               int x_step_q4,
-                              const int16_t* filter_y,
+                              int y0_q4,
                               int y_step_q4,
                               int w,
                               int h);
@@ -263,9 +285,10 @@
                                         ptrdiff_t src_stride,
                                         uint8_t* dst,
                                         ptrdiff_t dst_stride,
-                                        const int16_t* filter_x,
+                                        const InterpKernel* filter,
+                                        int x0_q4,
                                         int x_step_q4,
-                                        const int16_t* filter_y,
+                                        int y0_q4,
                                         int y_step_q4,
                                         int w,
                                         int h);
@@ -274,9 +297,10 @@
                           ptrdiff_t src_stride,
                           uint8_t* dst,
                           ptrdiff_t dst_stride,
-                          const int16_t* filter_x,
+                          const InterpKernel* filter,
+                          int x0_q4,
                           int x_step_q4,
-                          const int16_t* filter_y,
+                          int y0_q4,
                           int y_step_q4,
                           int w,
                           int h);
@@ -284,9 +308,10 @@
                              ptrdiff_t src_stride,
                              uint8_t* dst,
                              ptrdiff_t dst_stride,
-                             const int16_t* filter_x,
+                             const InterpKernel* filter,
+                             int x0_q4,
                              int x_step_q4,
-                             const int16_t* filter_y,
+                             int y0_q4,
                              int y_step_q4,
                              int w,
                              int h);
@@ -294,9 +319,10 @@
                               ptrdiff_t src_stride,
                               uint8_t* dst,
                               ptrdiff_t dst_stride,
-                              const int16_t* filter_x,
+                              const InterpKernel* filter,
+                              int x0_q4,
                               int x_step_q4,
-                              const int16_t* filter_y,
+                              int y0_q4,
                               int y_step_q4,
                               int w,
                               int h);
@@ -304,9 +330,10 @@
                              ptrdiff_t src_stride,
                              uint8_t* dst,
                              ptrdiff_t dst_stride,
-                             const int16_t* filter_x,
+                             const InterpKernel* filter,
+                             int x0_q4,
                              int x_step_q4,
-                             const int16_t* filter_y,
+                             int y0_q4,
                              int y_step_q4,
                              int w,
                              int h);
@@ -314,9 +341,10 @@
                                        ptrdiff_t src_stride,
                                        uint8_t* dst,
                                        ptrdiff_t dst_stride,
-                                       const int16_t* filter_x,
+                                       const InterpKernel* filter,
+                                       int x0_q4,
                                        int x_step_q4,
-                                       const int16_t* filter_y,
+                                       int y0_q4,
                                        int y_step_q4,
                                        int w,
                                        int h);
@@ -325,9 +353,10 @@
                         ptrdiff_t src_stride,
                         uint8_t* dst,
                         ptrdiff_t dst_stride,
-                        const int16_t* filter_x,
+                        const InterpKernel* filter,
+                        int x0_q4,
                         int x_step_q4,
-                        const int16_t* filter_y,
+                        int y0_q4,
                         int y_step_q4,
                         int w,
                         int h);
@@ -335,9 +364,10 @@
                            ptrdiff_t src_stride,
                            uint8_t* dst,
                            ptrdiff_t dst_stride,
-                           const int16_t* filter_x,
+                           const InterpKernel* filter,
+                           int x0_q4,
                            int x_step_q4,
-                           const int16_t* filter_y,
+                           int y0_q4,
                            int y_step_q4,
                            int w,
                            int h);
@@ -345,9 +375,10 @@
                                      ptrdiff_t src_stride,
                                      uint8_t* dst,
                                      ptrdiff_t dst_stride,
-                                     const int16_t* filter_x,
+                                     const InterpKernel* filter,
+                                     int x0_q4,
                                      int x_step_q4,
-                                     const int16_t* filter_y,
+                                     int y0_q4,
                                      int y_step_q4,
                                      int w,
                                      int h);
@@ -356,9 +387,10 @@
                          ptrdiff_t src_stride,
                          uint8_t* dst,
                          ptrdiff_t dst_stride,
-                         const int16_t* filter_x,
+                         const InterpKernel* filter,
+                         int x0_q4,
                          int x_step_q4,
-                         const int16_t* filter_y,
+                         int y0_q4,
                          int y_step_q4,
                          int w,
                          int h);
@@ -366,9 +398,10 @@
                             ptrdiff_t src_stride,
                             uint8_t* dst,
                             ptrdiff_t dst_stride,
-                            const int16_t* filter_x,
+                            const InterpKernel* filter,
+                            int x0_q4,
                             int x_step_q4,
-                            const int16_t* filter_y,
+                            int y0_q4,
                             int y_step_q4,
                             int w,
                             int h);
@@ -376,9 +409,10 @@
                                       ptrdiff_t src_stride,
                                       uint8_t* dst,
                                       ptrdiff_t dst_stride,
-                                      const int16_t* filter_x,
+                                      const InterpKernel* filter,
+                                      int x0_q4,
                                       int x_step_q4,
-                                      const int16_t* filter_y,
+                                      int y0_q4,
                                       int y_step_q4,
                                       int w,
                                       int h);
@@ -3582,9 +3616,10 @@
                             ptrdiff_t src_stride,
                             uint16_t* dst,
                             ptrdiff_t dst_stride,
-                            const int16_t* filter_x,
+                            const InterpKernel* filter,
+                            int x0_q4,
                             int x_step_q4,
-                            const int16_t* filter_y,
+                            int y0_q4,
                             int y_step_q4,
                             int w,
                             int h,
@@ -3593,9 +3628,10 @@
                                ptrdiff_t src_stride,
                                uint16_t* dst,
                                ptrdiff_t dst_stride,
-                               const int16_t* filter_x,
+                               const InterpKernel* filter,
+                               int x0_q4,
                                int x_step_q4,
-                               const int16_t* filter_y,
+                               int y0_q4,
                                int y_step_q4,
                                int w,
                                int h,
@@ -3604,9 +3640,10 @@
                                          ptrdiff_t src_stride,
                                          uint16_t* dst,
                                          ptrdiff_t dst_stride,
-                                         const int16_t* filter_x,
+                                         const InterpKernel* filter,
+                                         int x0_q4,
                                          int x_step_q4,
-                                         const int16_t* filter_y,
+                                         int y0_q4,
                                          int y_step_q4,
                                          int w,
                                          int h,
@@ -3616,9 +3653,10 @@
                                 ptrdiff_t src_stride,
                                 uint16_t* dst,
                                 ptrdiff_t dst_stride,
-                                const int16_t* filter_x,
+                                const InterpKernel* filter,
+                                int x0_q4,
                                 int x_step_q4,
-                                const int16_t* filter_y,
+                                int y0_q4,
                                 int y_step_q4,
                                 int w,
                                 int h,
@@ -3627,9 +3665,10 @@
                                    ptrdiff_t src_stride,
                                    uint16_t* dst,
                                    ptrdiff_t dst_stride,
-                                   const int16_t* filter_x,
+                                   const InterpKernel* filter,
+                                   int x0_q4,
                                    int x_step_q4,
-                                   const int16_t* filter_y,
+                                   int y0_q4,
                                    int y_step_q4,
                                    int w,
                                    int h,
@@ -3638,9 +3677,10 @@
                                              ptrdiff_t src_stride,
                                              uint16_t* dst,
                                              ptrdiff_t dst_stride,
-                                             const int16_t* filter_x,
+                                             const InterpKernel* filter,
+                                             int x0_q4,
                                              int x_step_q4,
-                                             const int16_t* filter_y,
+                                             int y0_q4,
                                              int y_step_q4,
                                              int w,
                                              int h,
@@ -3650,9 +3690,10 @@
                                       ptrdiff_t src_stride,
                                       uint16_t* dst,
                                       ptrdiff_t dst_stride,
-                                      const int16_t* filter_x,
+                                      const InterpKernel* filter,
+                                      int x0_q4,
                                       int x_step_q4,
-                                      const int16_t* filter_y,
+                                      int y0_q4,
                                       int y_step_q4,
                                       int w,
                                       int h,
@@ -3661,9 +3702,10 @@
                                          ptrdiff_t src_stride,
                                          uint16_t* dst,
                                          ptrdiff_t dst_stride,
-                                         const int16_t* filter_x,
+                                         const InterpKernel* filter,
+                                         int x0_q4,
                                          int x_step_q4,
-                                         const int16_t* filter_y,
+                                         int y0_q4,
                                          int y_step_q4,
                                          int w,
                                          int h,
@@ -3672,9 +3714,10 @@
                                                    ptrdiff_t src_stride,
                                                    uint16_t* dst,
                                                    ptrdiff_t dst_stride,
-                                                   const int16_t* filter_x,
+                                                   const InterpKernel* filter,
+                                                   int x0_q4,
                                                    int x_step_q4,
-                                                   const int16_t* filter_y,
+                                                   int y0_q4,
                                                    int y_step_q4,
                                                    int w,
                                                    int h,
@@ -3684,9 +3727,10 @@
                                      ptrdiff_t src_stride,
                                      uint16_t* dst,
                                      ptrdiff_t dst_stride,
-                                     const int16_t* filter_x,
+                                     const InterpKernel* filter,
+                                     int x0_q4,
                                      int x_step_q4,
-                                     const int16_t* filter_y,
+                                     int y0_q4,
                                      int y_step_q4,
                                      int w,
                                      int h,
@@ -3695,9 +3739,10 @@
                                         ptrdiff_t src_stride,
                                         uint16_t* dst,
                                         ptrdiff_t dst_stride,
-                                        const int16_t* filter_x,
+                                        const InterpKernel* filter,
+                                        int x0_q4,
                                         int x_step_q4,
-                                        const int16_t* filter_y,
+                                        int y0_q4,
                                         int y_step_q4,
                                         int w,
                                         int h,
@@ -3706,9 +3751,10 @@
                                                   ptrdiff_t src_stride,
                                                   uint16_t* dst,
                                                   ptrdiff_t dst_stride,
-                                                  const int16_t* filter_x,
+                                                  const InterpKernel* filter,
+                                                  int x0_q4,
                                                   int x_step_q4,
-                                                  const int16_t* filter_y,
+                                                  int y0_q4,
                                                   int y_step_q4,
                                                   int w,
                                                   int h,
@@ -3718,9 +3764,10 @@
                                   ptrdiff_t src_stride,
                                   uint16_t* dst,
                                   ptrdiff_t dst_stride,
-                                  const int16_t* filter_x,
+                                  const InterpKernel* filter,
+                                  int x0_q4,
                                   int x_step_q4,
-                                  const int16_t* filter_y,
+                                  int y0_q4,
                                   int y_step_q4,
                                   int w,
                                   int h,
@@ -3729,9 +3776,10 @@
                                      ptrdiff_t src_stride,
                                      uint16_t* dst,
                                      ptrdiff_t dst_stride,
-                                     const int16_t* filter_x,
+                                     const InterpKernel* filter,
+                                     int x0_q4,
                                      int x_step_q4,
-                                     const int16_t* filter_y,
+                                     int y0_q4,
                                      int y_step_q4,
                                      int w,
                                      int h,
@@ -3740,9 +3788,10 @@
                                                ptrdiff_t src_stride,
                                                uint16_t* dst,
                                                ptrdiff_t dst_stride,
-                                               const int16_t* filter_x,
+                                               const InterpKernel* filter,
+                                               int x0_q4,
                                                int x_step_q4,
-                                               const int16_t* filter_y,
+                                               int y0_q4,
                                                int y_step_q4,
                                                int w,
                                                int h,
@@ -3752,9 +3801,10 @@
                                  ptrdiff_t src_stride,
                                  uint16_t* dst,
                                  ptrdiff_t dst_stride,
-                                 const int16_t* filter_x,
+                                 const InterpKernel* filter,
+                                 int x0_q4,
                                  int x_step_q4,
-                                 const int16_t* filter_y,
+                                 int y0_q4,
                                  int y_step_q4,
                                  int w,
                                  int h,
@@ -3763,9 +3813,10 @@
                                     ptrdiff_t src_stride,
                                     uint16_t* dst,
                                     ptrdiff_t dst_stride,
-                                    const int16_t* filter_x,
+                                    const InterpKernel* filter,
+                                    int x0_q4,
                                     int x_step_q4,
-                                    const int16_t* filter_y,
+                                    int y0_q4,
                                     int y_step_q4,
                                     int w,
                                     int h,
@@ -3774,9 +3825,10 @@
                                               ptrdiff_t src_stride,
                                               uint16_t* dst,
                                               ptrdiff_t dst_stride,
-                                              const int16_t* filter_x,
+                                              const InterpKernel* filter,
+                                              int x0_q4,
                                               int x_step_q4,
-                                              const int16_t* filter_y,
+                                              int y0_q4,
                                               int y_step_q4,
                                               int w,
                                               int h,
@@ -3786,9 +3838,10 @@
                                ptrdiff_t src_stride,
                                uint16_t* dst,
                                ptrdiff_t dst_stride,
-                               const int16_t* filter_x,
+                               const InterpKernel* filter,
+                               int x0_q4,
                                int x_step_q4,
-                               const int16_t* filter_y,
+                               int y0_q4,
                                int y_step_q4,
                                int w,
                                int h,
@@ -3797,9 +3850,10 @@
                                   ptrdiff_t src_stride,
                                   uint16_t* dst,
                                   ptrdiff_t dst_stride,
-                                  const int16_t* filter_x,
+                                  const InterpKernel* filter,
+                                  int x0_q4,
                                   int x_step_q4,
-                                  const int16_t* filter_y,
+                                  int y0_q4,
                                   int y_step_q4,
                                   int w,
                                   int h,
@@ -3808,9 +3862,10 @@
                                   ptrdiff_t src_stride,
                                   uint16_t* dst,
                                   ptrdiff_t dst_stride,
-                                  const int16_t* filter_x,
+                                  const InterpKernel* filter,
+                                  int x0_q4,
                                   int x_step_q4,
-                                  const int16_t* filter_y,
+                                  int y0_q4,
                                   int y_step_q4,
                                   int w,
                                   int h,
@@ -3819,9 +3874,10 @@
                                             ptrdiff_t src_stride,
                                             uint16_t* dst,
                                             ptrdiff_t dst_stride,
-                                            const int16_t* filter_x,
+                                            const InterpKernel* filter,
+                                            int x0_q4,
                                             int x_step_q4,
-                                            const int16_t* filter_y,
+                                            int y0_q4,
                                             int y_step_q4,
                                             int w,
                                             int h,
@@ -3831,9 +3887,10 @@
                                 ptrdiff_t src_stride,
                                 uint16_t* dst,
                                 ptrdiff_t dst_stride,
-                                const int16_t* filter_x,
+                                const InterpKernel* filter,
+                                int x0_q4,
                                 int x_step_q4,
-                                const int16_t* filter_y,
+                                int y0_q4,
                                 int y_step_q4,
                                 int w,
                                 int h,
@@ -3842,9 +3899,10 @@
                                    ptrdiff_t src_stride,
                                    uint16_t* dst,
                                    ptrdiff_t dst_stride,
-                                   const int16_t* filter_x,
+                                   const InterpKernel* filter,
+                                   int x0_q4,
                                    int x_step_q4,
-                                   const int16_t* filter_y,
+                                   int y0_q4,
                                    int y_step_q4,
                                    int w,
                                    int h,
@@ -3853,9 +3911,10 @@
                                    ptrdiff_t src_stride,
                                    uint16_t* dst,
                                    ptrdiff_t dst_stride,
-                                   const int16_t* filter_x,
+                                   const InterpKernel* filter,
+                                   int x0_q4,
                                    int x_step_q4,
-                                   const int16_t* filter_y,
+                                   int y0_q4,
                                    int y_step_q4,
                                    int w,
                                    int h,
@@ -3864,9 +3923,10 @@
                                              ptrdiff_t src_stride,
                                              uint16_t* dst,
                                              ptrdiff_t dst_stride,
-                                             const int16_t* filter_x,
+                                             const InterpKernel* filter,
+                                             int x0_q4,
                                              int x_step_q4,
-                                             const int16_t* filter_y,
+                                             int y0_q4,
                                              int y_step_q4,
                                              int w,
                                              int h,
@@ -4045,56 +4105,128 @@
                                          const uint16_t* above,
                                          const uint16_t* left,
                                          int bd);
-#define vpx_highbd_dc_128_predictor_16x16 vpx_highbd_dc_128_predictor_16x16_c
+void vpx_highbd_dc_128_predictor_16x16_sse2(uint16_t* dst,
+                                            ptrdiff_t y_stride,
+                                            const uint16_t* above,
+                                            const uint16_t* left,
+                                            int bd);
+RTCD_EXTERN void (*vpx_highbd_dc_128_predictor_16x16)(uint16_t* dst,
+                                                      ptrdiff_t y_stride,
+                                                      const uint16_t* above,
+                                                      const uint16_t* left,
+                                                      int bd);
 
 void vpx_highbd_dc_128_predictor_32x32_c(uint16_t* dst,
                                          ptrdiff_t y_stride,
                                          const uint16_t* above,
                                          const uint16_t* left,
                                          int bd);
-#define vpx_highbd_dc_128_predictor_32x32 vpx_highbd_dc_128_predictor_32x32_c
+void vpx_highbd_dc_128_predictor_32x32_sse2(uint16_t* dst,
+                                            ptrdiff_t y_stride,
+                                            const uint16_t* above,
+                                            const uint16_t* left,
+                                            int bd);
+RTCD_EXTERN void (*vpx_highbd_dc_128_predictor_32x32)(uint16_t* dst,
+                                                      ptrdiff_t y_stride,
+                                                      const uint16_t* above,
+                                                      const uint16_t* left,
+                                                      int bd);
 
 void vpx_highbd_dc_128_predictor_4x4_c(uint16_t* dst,
                                        ptrdiff_t y_stride,
                                        const uint16_t* above,
                                        const uint16_t* left,
                                        int bd);
-#define vpx_highbd_dc_128_predictor_4x4 vpx_highbd_dc_128_predictor_4x4_c
+void vpx_highbd_dc_128_predictor_4x4_sse2(uint16_t* dst,
+                                          ptrdiff_t y_stride,
+                                          const uint16_t* above,
+                                          const uint16_t* left,
+                                          int bd);
+RTCD_EXTERN void (*vpx_highbd_dc_128_predictor_4x4)(uint16_t* dst,
+                                                    ptrdiff_t y_stride,
+                                                    const uint16_t* above,
+                                                    const uint16_t* left,
+                                                    int bd);
 
 void vpx_highbd_dc_128_predictor_8x8_c(uint16_t* dst,
                                        ptrdiff_t y_stride,
                                        const uint16_t* above,
                                        const uint16_t* left,
                                        int bd);
-#define vpx_highbd_dc_128_predictor_8x8 vpx_highbd_dc_128_predictor_8x8_c
+void vpx_highbd_dc_128_predictor_8x8_sse2(uint16_t* dst,
+                                          ptrdiff_t y_stride,
+                                          const uint16_t* above,
+                                          const uint16_t* left,
+                                          int bd);
+RTCD_EXTERN void (*vpx_highbd_dc_128_predictor_8x8)(uint16_t* dst,
+                                                    ptrdiff_t y_stride,
+                                                    const uint16_t* above,
+                                                    const uint16_t* left,
+                                                    int bd);
 
 void vpx_highbd_dc_left_predictor_16x16_c(uint16_t* dst,
                                           ptrdiff_t y_stride,
                                           const uint16_t* above,
                                           const uint16_t* left,
                                           int bd);
-#define vpx_highbd_dc_left_predictor_16x16 vpx_highbd_dc_left_predictor_16x16_c
+void vpx_highbd_dc_left_predictor_16x16_sse2(uint16_t* dst,
+                                             ptrdiff_t y_stride,
+                                             const uint16_t* above,
+                                             const uint16_t* left,
+                                             int bd);
+RTCD_EXTERN void (*vpx_highbd_dc_left_predictor_16x16)(uint16_t* dst,
+                                                       ptrdiff_t y_stride,
+                                                       const uint16_t* above,
+                                                       const uint16_t* left,
+                                                       int bd);
 
 void vpx_highbd_dc_left_predictor_32x32_c(uint16_t* dst,
                                           ptrdiff_t y_stride,
                                           const uint16_t* above,
                                           const uint16_t* left,
                                           int bd);
-#define vpx_highbd_dc_left_predictor_32x32 vpx_highbd_dc_left_predictor_32x32_c
+void vpx_highbd_dc_left_predictor_32x32_sse2(uint16_t* dst,
+                                             ptrdiff_t y_stride,
+                                             const uint16_t* above,
+                                             const uint16_t* left,
+                                             int bd);
+RTCD_EXTERN void (*vpx_highbd_dc_left_predictor_32x32)(uint16_t* dst,
+                                                       ptrdiff_t y_stride,
+                                                       const uint16_t* above,
+                                                       const uint16_t* left,
+                                                       int bd);
 
 void vpx_highbd_dc_left_predictor_4x4_c(uint16_t* dst,
                                         ptrdiff_t y_stride,
                                         const uint16_t* above,
                                         const uint16_t* left,
                                         int bd);
-#define vpx_highbd_dc_left_predictor_4x4 vpx_highbd_dc_left_predictor_4x4_c
+void vpx_highbd_dc_left_predictor_4x4_sse2(uint16_t* dst,
+                                           ptrdiff_t y_stride,
+                                           const uint16_t* above,
+                                           const uint16_t* left,
+                                           int bd);
+RTCD_EXTERN void (*vpx_highbd_dc_left_predictor_4x4)(uint16_t* dst,
+                                                     ptrdiff_t y_stride,
+                                                     const uint16_t* above,
+                                                     const uint16_t* left,
+                                                     int bd);
 
 void vpx_highbd_dc_left_predictor_8x8_c(uint16_t* dst,
                                         ptrdiff_t y_stride,
                                         const uint16_t* above,
                                         const uint16_t* left,
                                         int bd);
-#define vpx_highbd_dc_left_predictor_8x8 vpx_highbd_dc_left_predictor_8x8_c
+void vpx_highbd_dc_left_predictor_8x8_sse2(uint16_t* dst,
+                                           ptrdiff_t y_stride,
+                                           const uint16_t* above,
+                                           const uint16_t* left,
+                                           int bd);
+RTCD_EXTERN void (*vpx_highbd_dc_left_predictor_8x8)(uint16_t* dst,
+                                                     ptrdiff_t y_stride,
+                                                     const uint16_t* above,
+                                                     const uint16_t* left,
+                                                     int bd);
 
 void vpx_highbd_dc_predictor_16x16_c(uint16_t* dst,
                                      ptrdiff_t y_stride,
@@ -4165,28 +4297,64 @@
                                          const uint16_t* above,
                                          const uint16_t* left,
                                          int bd);
-#define vpx_highbd_dc_top_predictor_16x16 vpx_highbd_dc_top_predictor_16x16_c
+void vpx_highbd_dc_top_predictor_16x16_sse2(uint16_t* dst,
+                                            ptrdiff_t y_stride,
+                                            const uint16_t* above,
+                                            const uint16_t* left,
+                                            int bd);
+RTCD_EXTERN void (*vpx_highbd_dc_top_predictor_16x16)(uint16_t* dst,
+                                                      ptrdiff_t y_stride,
+                                                      const uint16_t* above,
+                                                      const uint16_t* left,
+                                                      int bd);
 
 void vpx_highbd_dc_top_predictor_32x32_c(uint16_t* dst,
                                          ptrdiff_t y_stride,
                                          const uint16_t* above,
                                          const uint16_t* left,
                                          int bd);
-#define vpx_highbd_dc_top_predictor_32x32 vpx_highbd_dc_top_predictor_32x32_c
+void vpx_highbd_dc_top_predictor_32x32_sse2(uint16_t* dst,
+                                            ptrdiff_t y_stride,
+                                            const uint16_t* above,
+                                            const uint16_t* left,
+                                            int bd);
+RTCD_EXTERN void (*vpx_highbd_dc_top_predictor_32x32)(uint16_t* dst,
+                                                      ptrdiff_t y_stride,
+                                                      const uint16_t* above,
+                                                      const uint16_t* left,
+                                                      int bd);
 
 void vpx_highbd_dc_top_predictor_4x4_c(uint16_t* dst,
                                        ptrdiff_t y_stride,
                                        const uint16_t* above,
                                        const uint16_t* left,
                                        int bd);
-#define vpx_highbd_dc_top_predictor_4x4 vpx_highbd_dc_top_predictor_4x4_c
+void vpx_highbd_dc_top_predictor_4x4_sse2(uint16_t* dst,
+                                          ptrdiff_t y_stride,
+                                          const uint16_t* above,
+                                          const uint16_t* left,
+                                          int bd);
+RTCD_EXTERN void (*vpx_highbd_dc_top_predictor_4x4)(uint16_t* dst,
+                                                    ptrdiff_t y_stride,
+                                                    const uint16_t* above,
+                                                    const uint16_t* left,
+                                                    int bd);
 
 void vpx_highbd_dc_top_predictor_8x8_c(uint16_t* dst,
                                        ptrdiff_t y_stride,
                                        const uint16_t* above,
                                        const uint16_t* left,
                                        int bd);
-#define vpx_highbd_dc_top_predictor_8x8 vpx_highbd_dc_top_predictor_8x8_c
+void vpx_highbd_dc_top_predictor_8x8_sse2(uint16_t* dst,
+                                          ptrdiff_t y_stride,
+                                          const uint16_t* above,
+                                          const uint16_t* left,
+                                          int bd);
+RTCD_EXTERN void (*vpx_highbd_dc_top_predictor_8x8)(uint16_t* dst,
+                                                    ptrdiff_t y_stride,
+                                                    const uint16_t* above,
+                                                    const uint16_t* left,
+                                                    int bd);
 
 void vpx_highbd_fdct16x16_c(const int16_t* input,
                             tran_low_t* output,
@@ -4254,28 +4422,64 @@
                                     const uint16_t* above,
                                     const uint16_t* left,
                                     int bd);
-#define vpx_highbd_h_predictor_16x16 vpx_highbd_h_predictor_16x16_c
+void vpx_highbd_h_predictor_16x16_sse2(uint16_t* dst,
+                                       ptrdiff_t y_stride,
+                                       const uint16_t* above,
+                                       const uint16_t* left,
+                                       int bd);
+RTCD_EXTERN void (*vpx_highbd_h_predictor_16x16)(uint16_t* dst,
+                                                 ptrdiff_t y_stride,
+                                                 const uint16_t* above,
+                                                 const uint16_t* left,
+                                                 int bd);
 
 void vpx_highbd_h_predictor_32x32_c(uint16_t* dst,
                                     ptrdiff_t y_stride,
                                     const uint16_t* above,
                                     const uint16_t* left,
                                     int bd);
-#define vpx_highbd_h_predictor_32x32 vpx_highbd_h_predictor_32x32_c
+void vpx_highbd_h_predictor_32x32_sse2(uint16_t* dst,
+                                       ptrdiff_t y_stride,
+                                       const uint16_t* above,
+                                       const uint16_t* left,
+                                       int bd);
+RTCD_EXTERN void (*vpx_highbd_h_predictor_32x32)(uint16_t* dst,
+                                                 ptrdiff_t y_stride,
+                                                 const uint16_t* above,
+                                                 const uint16_t* left,
+                                                 int bd);
 
 void vpx_highbd_h_predictor_4x4_c(uint16_t* dst,
                                   ptrdiff_t y_stride,
                                   const uint16_t* above,
                                   const uint16_t* left,
                                   int bd);
-#define vpx_highbd_h_predictor_4x4 vpx_highbd_h_predictor_4x4_c
+void vpx_highbd_h_predictor_4x4_sse2(uint16_t* dst,
+                                     ptrdiff_t y_stride,
+                                     const uint16_t* above,
+                                     const uint16_t* left,
+                                     int bd);
+RTCD_EXTERN void (*vpx_highbd_h_predictor_4x4)(uint16_t* dst,
+                                               ptrdiff_t y_stride,
+                                               const uint16_t* above,
+                                               const uint16_t* left,
+                                               int bd);
 
 void vpx_highbd_h_predictor_8x8_c(uint16_t* dst,
                                   ptrdiff_t y_stride,
                                   const uint16_t* above,
                                   const uint16_t* left,
                                   int bd);
-#define vpx_highbd_h_predictor_8x8 vpx_highbd_h_predictor_8x8_c
+void vpx_highbd_h_predictor_8x8_sse2(uint16_t* dst,
+                                     ptrdiff_t y_stride,
+                                     const uint16_t* above,
+                                     const uint16_t* left,
+                                     int bd);
+RTCD_EXTERN void (*vpx_highbd_h_predictor_8x8)(uint16_t* dst,
+                                               ptrdiff_t y_stride,
+                                               const uint16_t* above,
+                                               const uint16_t* left,
+                                               int bd);
 
 void vpx_highbd_idct16x16_10_add_c(const tran_low_t* input,
                                    uint16_t* dest,
@@ -6162,7 +6366,32 @@
                             uint16_t* eob_ptr,
                             const int16_t* scan,
                             const int16_t* iscan);
-#define vpx_quantize_b_32x32 vpx_quantize_b_32x32_c
+void vpx_quantize_b_32x32_ssse3(const tran_low_t* coeff_ptr,
+                                intptr_t n_coeffs,
+                                int skip_block,
+                                const int16_t* zbin_ptr,
+                                const int16_t* round_ptr,
+                                const int16_t* quant_ptr,
+                                const int16_t* quant_shift_ptr,
+                                tran_low_t* qcoeff_ptr,
+                                tran_low_t* dqcoeff_ptr,
+                                const int16_t* dequant_ptr,
+                                uint16_t* eob_ptr,
+                                const int16_t* scan,
+                                const int16_t* iscan);
+RTCD_EXTERN void (*vpx_quantize_b_32x32)(const tran_low_t* coeff_ptr,
+                                         intptr_t n_coeffs,
+                                         int skip_block,
+                                         const int16_t* zbin_ptr,
+                                         const int16_t* round_ptr,
+                                         const int16_t* quant_ptr,
+                                         const int16_t* quant_shift_ptr,
+                                         tran_low_t* qcoeff_ptr,
+                                         tran_low_t* dqcoeff_ptr,
+                                         const int16_t* dequant_ptr,
+                                         uint16_t* eob_ptr,
+                                         const int16_t* scan,
+                                         const int16_t* iscan);
 
 unsigned int vpx_sad16x16_c(const uint8_t* src_ptr,
                             int src_stride,
@@ -6982,9 +7211,10 @@
                      ptrdiff_t src_stride,
                      uint8_t* dst,
                      ptrdiff_t dst_stride,
-                     const int16_t* filter_x,
+                     const InterpKernel* filter,
+                     int x0_q4,
                      int x_step_q4,
-                     const int16_t* filter_y,
+                     int y0_q4,
                      int y_step_q4,
                      int w,
                      int h);
@@ -6992,9 +7222,10 @@
                          ptrdiff_t src_stride,
                          uint8_t* dst,
                          ptrdiff_t dst_stride,
-                         const int16_t* filter_x,
+                         const InterpKernel* filter,
+                         int x0_q4,
                          int x_step_q4,
-                         const int16_t* filter_y,
+                         int y0_q4,
                          int y_step_q4,
                          int w,
                          int h);
@@ -7002,9 +7233,10 @@
                                   ptrdiff_t src_stride,
                                   uint8_t* dst,
                                   ptrdiff_t dst_stride,
-                                  const int16_t* filter_x,
+                                  const InterpKernel* filter,
+                                  int x0_q4,
                                   int x_step_q4,
-                                  const int16_t* filter_y,
+                                  int y0_q4,
                                   int y_step_q4,
                                   int w,
                                   int h);
@@ -7013,9 +7245,10 @@
                          ptrdiff_t src_stride,
                          uint8_t* dst,
                          ptrdiff_t dst_stride,
-                         const int16_t* filter_x,
+                         const InterpKernel* filter,
+                         int x0_q4,
                          int x_step_q4,
-                         const int16_t* filter_y,
+                         int y0_q4,
                          int y_step_q4,
                          int w,
                          int h);
@@ -7025,9 +7258,10 @@
                             ptrdiff_t src_stride,
                             uint8_t* dst,
                             ptrdiff_t dst_stride,
-                            const int16_t* filter_x,
+                            const InterpKernel* filter,
+                            int x0_q4,
                             int x_step_q4,
-                            const int16_t* filter_y,
+                            int y0_q4,
                             int y_step_q4,
                             int w,
                             int h);
@@ -7037,9 +7271,10 @@
                            ptrdiff_t src_stride,
                            uint8_t* dst,
                            ptrdiff_t dst_stride,
-                           const int16_t* filter_x,
+                           const InterpKernel* filter,
+                           int x0_q4,
                            int x_step_q4,
-                           const int16_t* filter_y,
+                           int y0_q4,
                            int y_step_q4,
                            int w,
                            int h);
@@ -7049,9 +7284,10 @@
                         ptrdiff_t src_stride,
                         uint8_t* dst,
                         ptrdiff_t dst_stride,
-                        const int16_t* filter_x,
+                        const InterpKernel* filter,
+                        int x0_q4,
                         int x_step_q4,
-                        const int16_t* filter_y,
+                        int y0_q4,
                         int y_step_q4,
                         int w,
                         int h);
@@ -7061,9 +7297,10 @@
                        ptrdiff_t src_stride,
                        uint8_t* dst,
                        ptrdiff_t dst_stride,
-                       const int16_t* filter_x,
+                       const InterpKernel* filter,
+                       int x0_q4,
                        int x_step_q4,
-                       const int16_t* filter_y,
+                       int y0_q4,
                        int y_step_q4,
                        int w,
                        int h);
@@ -8957,6 +9194,32 @@
     vpx_highbd_convolve_copy = vpx_highbd_convolve_copy_sse2;
   if (flags & HAS_AVX2)
     vpx_highbd_convolve_copy = vpx_highbd_convolve_copy_avx2;
+  vpx_highbd_dc_128_predictor_16x16 = vpx_highbd_dc_128_predictor_16x16_c;
+  if (flags & HAS_SSE2)
+    vpx_highbd_dc_128_predictor_16x16 = vpx_highbd_dc_128_predictor_16x16_sse2;
+  vpx_highbd_dc_128_predictor_32x32 = vpx_highbd_dc_128_predictor_32x32_c;
+  if (flags & HAS_SSE2)
+    vpx_highbd_dc_128_predictor_32x32 = vpx_highbd_dc_128_predictor_32x32_sse2;
+  vpx_highbd_dc_128_predictor_4x4 = vpx_highbd_dc_128_predictor_4x4_c;
+  if (flags & HAS_SSE2)
+    vpx_highbd_dc_128_predictor_4x4 = vpx_highbd_dc_128_predictor_4x4_sse2;
+  vpx_highbd_dc_128_predictor_8x8 = vpx_highbd_dc_128_predictor_8x8_c;
+  if (flags & HAS_SSE2)
+    vpx_highbd_dc_128_predictor_8x8 = vpx_highbd_dc_128_predictor_8x8_sse2;
+  vpx_highbd_dc_left_predictor_16x16 = vpx_highbd_dc_left_predictor_16x16_c;
+  if (flags & HAS_SSE2)
+    vpx_highbd_dc_left_predictor_16x16 =
+        vpx_highbd_dc_left_predictor_16x16_sse2;
+  vpx_highbd_dc_left_predictor_32x32 = vpx_highbd_dc_left_predictor_32x32_c;
+  if (flags & HAS_SSE2)
+    vpx_highbd_dc_left_predictor_32x32 =
+        vpx_highbd_dc_left_predictor_32x32_sse2;
+  vpx_highbd_dc_left_predictor_4x4 = vpx_highbd_dc_left_predictor_4x4_c;
+  if (flags & HAS_SSE2)
+    vpx_highbd_dc_left_predictor_4x4 = vpx_highbd_dc_left_predictor_4x4_sse2;
+  vpx_highbd_dc_left_predictor_8x8 = vpx_highbd_dc_left_predictor_8x8_c;
+  if (flags & HAS_SSE2)
+    vpx_highbd_dc_left_predictor_8x8 = vpx_highbd_dc_left_predictor_8x8_sse2;
   vpx_highbd_dc_predictor_16x16 = vpx_highbd_dc_predictor_16x16_c;
   if (flags & HAS_SSE2)
     vpx_highbd_dc_predictor_16x16 = vpx_highbd_dc_predictor_16x16_sse2;
@@ -8969,6 +9232,18 @@
   vpx_highbd_dc_predictor_8x8 = vpx_highbd_dc_predictor_8x8_c;
   if (flags & HAS_SSE2)
     vpx_highbd_dc_predictor_8x8 = vpx_highbd_dc_predictor_8x8_sse2;
+  vpx_highbd_dc_top_predictor_16x16 = vpx_highbd_dc_top_predictor_16x16_c;
+  if (flags & HAS_SSE2)
+    vpx_highbd_dc_top_predictor_16x16 = vpx_highbd_dc_top_predictor_16x16_sse2;
+  vpx_highbd_dc_top_predictor_32x32 = vpx_highbd_dc_top_predictor_32x32_c;
+  if (flags & HAS_SSE2)
+    vpx_highbd_dc_top_predictor_32x32 = vpx_highbd_dc_top_predictor_32x32_sse2;
+  vpx_highbd_dc_top_predictor_4x4 = vpx_highbd_dc_top_predictor_4x4_c;
+  if (flags & HAS_SSE2)
+    vpx_highbd_dc_top_predictor_4x4 = vpx_highbd_dc_top_predictor_4x4_sse2;
+  vpx_highbd_dc_top_predictor_8x8 = vpx_highbd_dc_top_predictor_8x8_c;
+  if (flags & HAS_SSE2)
+    vpx_highbd_dc_top_predictor_8x8 = vpx_highbd_dc_top_predictor_8x8_sse2;
   vpx_highbd_fdct16x16 = vpx_highbd_fdct16x16_c;
   if (flags & HAS_SSE2)
     vpx_highbd_fdct16x16 = vpx_highbd_fdct16x16_sse2;
@@ -8984,6 +9259,18 @@
   vpx_highbd_fdct8x8 = vpx_highbd_fdct8x8_c;
   if (flags & HAS_SSE2)
     vpx_highbd_fdct8x8 = vpx_highbd_fdct8x8_sse2;
+  vpx_highbd_h_predictor_16x16 = vpx_highbd_h_predictor_16x16_c;
+  if (flags & HAS_SSE2)
+    vpx_highbd_h_predictor_16x16 = vpx_highbd_h_predictor_16x16_sse2;
+  vpx_highbd_h_predictor_32x32 = vpx_highbd_h_predictor_32x32_c;
+  if (flags & HAS_SSE2)
+    vpx_highbd_h_predictor_32x32 = vpx_highbd_h_predictor_32x32_sse2;
+  vpx_highbd_h_predictor_4x4 = vpx_highbd_h_predictor_4x4_c;
+  if (flags & HAS_SSE2)
+    vpx_highbd_h_predictor_4x4 = vpx_highbd_h_predictor_4x4_sse2;
+  vpx_highbd_h_predictor_8x8 = vpx_highbd_h_predictor_8x8_c;
+  if (flags & HAS_SSE2)
+    vpx_highbd_h_predictor_8x8 = vpx_highbd_h_predictor_8x8_sse2;
   vpx_highbd_idct16x16_10_add = vpx_highbd_idct16x16_10_add_c;
   if (flags & HAS_SSE2)
     vpx_highbd_idct16x16_10_add = vpx_highbd_idct16x16_10_add_sse2;
@@ -9343,6 +9630,9 @@
     vpx_quantize_b = vpx_quantize_b_ssse3;
   if (flags & HAS_AVX)
     vpx_quantize_b = vpx_quantize_b_avx;
+  vpx_quantize_b_32x32 = vpx_quantize_b_32x32_c;
+  if (flags & HAS_SSSE3)
+    vpx_quantize_b_32x32 = vpx_quantize_b_32x32_ssse3;
   vpx_sad16x16 = vpx_sad16x16_c;
   if (flags & HAS_SSE2)
     vpx_sad16x16 = vpx_sad16x16_sse2;
diff --git a/third_party/libvpx/source/config/mac/x64/vpx_dsp_rtcd.h b/third_party/libvpx/source/config/mac/x64/vpx_dsp_rtcd.h
index 76174db..e3352ff2 100644
--- a/third_party/libvpx/source/config/mac/x64/vpx_dsp_rtcd.h
+++ b/third_party/libvpx/source/config/mac/x64/vpx_dsp_rtcd.h
@@ -13,6 +13,7 @@
 
 #include "vpx/vpx_integer.h"
 #include "vpx_dsp/vpx_dsp_common.h"
+#include "vpx_dsp/vpx_filter.h"
 
 #ifdef __cplusplus
 extern "C" {
@@ -44,9 +45,10 @@
                      ptrdiff_t src_stride,
                      uint8_t* dst,
                      ptrdiff_t dst_stride,
-                     const int16_t* filter_x,
+                     const InterpKernel* filter,
+                     int x0_q4,
                      int x_step_q4,
-                     const int16_t* filter_y,
+                     int y0_q4,
                      int y_step_q4,
                      int w,
                      int h);
@@ -54,9 +56,10 @@
                         ptrdiff_t src_stride,
                         uint8_t* dst,
                         ptrdiff_t dst_stride,
-                        const int16_t* filter_x,
+                        const InterpKernel* filter,
+                        int x0_q4,
                         int x_step_q4,
-                        const int16_t* filter_y,
+                        int y0_q4,
                         int y_step_q4,
                         int w,
                         int h);
@@ -64,9 +67,10 @@
                          ptrdiff_t src_stride,
                          uint8_t* dst,
                          ptrdiff_t dst_stride,
-                         const int16_t* filter_x,
+                         const InterpKernel* filter,
+                         int x0_q4,
                          int x_step_q4,
-                         const int16_t* filter_y,
+                         int y0_q4,
                          int y_step_q4,
                          int w,
                          int h);
@@ -74,9 +78,10 @@
                         ptrdiff_t src_stride,
                         uint8_t* dst,
                         ptrdiff_t dst_stride,
-                        const int16_t* filter_x,
+                        const InterpKernel* filter,
+                        int x0_q4,
                         int x_step_q4,
-                        const int16_t* filter_y,
+                        int y0_q4,
                         int y_step_q4,
                         int w,
                         int h);
@@ -84,9 +89,10 @@
                                   ptrdiff_t src_stride,
                                   uint8_t* dst,
                                   ptrdiff_t dst_stride,
-                                  const int16_t* filter_x,
+                                  const InterpKernel* filter,
+                                  int x0_q4,
                                   int x_step_q4,
-                                  const int16_t* filter_y,
+                                  int y0_q4,
                                   int y_step_q4,
                                   int w,
                                   int h);
@@ -95,9 +101,10 @@
                          ptrdiff_t src_stride,
                          uint8_t* dst,
                          ptrdiff_t dst_stride,
-                         const int16_t* filter_x,
+                         const InterpKernel* filter,
+                         int x0_q4,
                          int x_step_q4,
-                         const int16_t* filter_y,
+                         int y0_q4,
                          int y_step_q4,
                          int w,
                          int h);
@@ -105,9 +112,10 @@
                             ptrdiff_t src_stride,
                             uint8_t* dst,
                             ptrdiff_t dst_stride,
-                            const int16_t* filter_x,
+                            const InterpKernel* filter,
+                            int x0_q4,
                             int x_step_q4,
-                            const int16_t* filter_y,
+                            int y0_q4,
                             int y_step_q4,
                             int w,
                             int h);
@@ -115,9 +123,10 @@
                              ptrdiff_t src_stride,
                              uint8_t* dst,
                              ptrdiff_t dst_stride,
-                             const int16_t* filter_x,
+                             const InterpKernel* filter,
+                             int x0_q4,
                              int x_step_q4,
-                             const int16_t* filter_y,
+                             int y0_q4,
                              int y_step_q4,
                              int w,
                              int h);
@@ -125,9 +134,10 @@
                                       ptrdiff_t src_stride,
                                       uint8_t* dst,
                                       ptrdiff_t dst_stride,
-                                      const int16_t* filter_x,
+                                      const InterpKernel* filter,
+                                      int x0_q4,
                                       int x_step_q4,
-                                      const int16_t* filter_y,
+                                      int y0_q4,
                                       int y_step_q4,
                                       int w,
                                       int h);
@@ -136,9 +146,10 @@
                                ptrdiff_t src_stride,
                                uint8_t* dst,
                                ptrdiff_t dst_stride,
-                               const int16_t* filter_x,
+                               const InterpKernel* filter,
+                               int x0_q4,
                                int x_step_q4,
-                               const int16_t* filter_y,
+                               int y0_q4,
                                int y_step_q4,
                                int w,
                                int h);
@@ -146,9 +157,10 @@
                                   ptrdiff_t src_stride,
                                   uint8_t* dst,
                                   ptrdiff_t dst_stride,
-                                  const int16_t* filter_x,
+                                  const InterpKernel* filter,
+                                  int x0_q4,
                                   int x_step_q4,
-                                  const int16_t* filter_y,
+                                  int y0_q4,
                                   int y_step_q4,
                                   int w,
                                   int h);
@@ -156,9 +168,10 @@
                                    ptrdiff_t src_stride,
                                    uint8_t* dst,
                                    ptrdiff_t dst_stride,
-                                   const int16_t* filter_x,
+                                   const InterpKernel* filter,
+                                   int x0_q4,
                                    int x_step_q4,
-                                   const int16_t* filter_y,
+                                   int y0_q4,
                                    int y_step_q4,
                                    int w,
                                    int h);
@@ -166,9 +179,10 @@
                                             ptrdiff_t src_stride,
                                             uint8_t* dst,
                                             ptrdiff_t dst_stride,
-                                            const int16_t* filter_x,
+                                            const InterpKernel* filter,
+                                            int x0_q4,
                                             int x_step_q4,
-                                            const int16_t* filter_y,
+                                            int y0_q4,
                                             int y_step_q4,
                                             int w,
                                             int h);
@@ -177,9 +191,10 @@
                               ptrdiff_t src_stride,
                               uint8_t* dst,
                               ptrdiff_t dst_stride,
-                              const int16_t* filter_x,
+                              const InterpKernel* filter,
+                              int x0_q4,
                               int x_step_q4,
-                              const int16_t* filter_y,
+                              int y0_q4,
                               int y_step_q4,
                               int w,
                               int h);
@@ -187,9 +202,10 @@
                                  ptrdiff_t src_stride,
                                  uint8_t* dst,
                                  ptrdiff_t dst_stride,
-                                 const int16_t* filter_x,
+                                 const InterpKernel* filter,
+                                 int x0_q4,
                                  int x_step_q4,
-                                 const int16_t* filter_y,
+                                 int y0_q4,
                                  int y_step_q4,
                                  int w,
                                  int h);
@@ -197,9 +213,10 @@
                                   ptrdiff_t src_stride,
                                   uint8_t* dst,
                                   ptrdiff_t dst_stride,
-                                  const int16_t* filter_x,
+                                  const InterpKernel* filter,
+                                  int x0_q4,
                                   int x_step_q4,
-                                  const int16_t* filter_y,
+                                  int y0_q4,
                                   int y_step_q4,
                                   int w,
                                   int h);
@@ -207,9 +224,10 @@
                                            ptrdiff_t src_stride,
                                            uint8_t* dst,
                                            ptrdiff_t dst_stride,
-                                           const int16_t* filter_x,
+                                           const InterpKernel* filter,
+                                           int x0_q4,
                                            int x_step_q4,
-                                           const int16_t* filter_y,
+                                           int y0_q4,
                                            int y_step_q4,
                                            int w,
                                            int h);
@@ -218,9 +236,10 @@
                            ptrdiff_t src_stride,
                            uint8_t* dst,
                            ptrdiff_t dst_stride,
-                           const int16_t* filter_x,
+                           const InterpKernel* filter,
+                           int x0_q4,
                            int x_step_q4,
-                           const int16_t* filter_y,
+                           int y0_q4,
                            int y_step_q4,
                            int w,
                            int h);
@@ -228,9 +247,10 @@
                               ptrdiff_t src_stride,
                               uint8_t* dst,
                               ptrdiff_t dst_stride,
-                              const int16_t* filter_x,
+                              const InterpKernel* filter,
+                              int x0_q4,
                               int x_step_q4,
-                              const int16_t* filter_y,
+                              int y0_q4,
                               int y_step_q4,
                               int w,
                               int h);
@@ -238,9 +258,10 @@
                                ptrdiff_t src_stride,
                                uint8_t* dst,
                                ptrdiff_t dst_stride,
-                               const int16_t* filter_x,
+                               const InterpKernel* filter,
+                               int x0_q4,
                                int x_step_q4,
-                               const int16_t* filter_y,
+                               int y0_q4,
                                int y_step_q4,
                                int w,
                                int h);
@@ -248,9 +269,10 @@
                               ptrdiff_t src_stride,
                               uint8_t* dst,
                               ptrdiff_t dst_stride,
-                              const int16_t* filter_x,
+                              const InterpKernel* filter,
+                              int x0_q4,
                               int x_step_q4,
-                              const int16_t* filter_y,
+                              int y0_q4,
                               int y_step_q4,
                               int w,
                               int h);
@@ -258,9 +280,10 @@
                                         ptrdiff_t src_stride,
                                         uint8_t* dst,
                                         ptrdiff_t dst_stride,
-                                        const int16_t* filter_x,
+                                        const InterpKernel* filter,
+                                        int x0_q4,
                                         int x_step_q4,
-                                        const int16_t* filter_y,
+                                        int y0_q4,
                                         int y_step_q4,
                                         int w,
                                         int h);
@@ -269,9 +292,10 @@
                           ptrdiff_t src_stride,
                           uint8_t* dst,
                           ptrdiff_t dst_stride,
-                          const int16_t* filter_x,
+                          const InterpKernel* filter,
+                          int x0_q4,
                           int x_step_q4,
-                          const int16_t* filter_y,
+                          int y0_q4,
                           int y_step_q4,
                           int w,
                           int h);
@@ -279,9 +303,10 @@
                              ptrdiff_t src_stride,
                              uint8_t* dst,
                              ptrdiff_t dst_stride,
-                             const int16_t* filter_x,
+                             const InterpKernel* filter,
+                             int x0_q4,
                              int x_step_q4,
-                             const int16_t* filter_y,
+                             int y0_q4,
                              int y_step_q4,
                              int w,
                              int h);
@@ -289,9 +314,10 @@
                               ptrdiff_t src_stride,
                               uint8_t* dst,
                               ptrdiff_t dst_stride,
-                              const int16_t* filter_x,
+                              const InterpKernel* filter,
+                              int x0_q4,
                               int x_step_q4,
-                              const int16_t* filter_y,
+                              int y0_q4,
                               int y_step_q4,
                               int w,
                               int h);
@@ -299,9 +325,10 @@
                              ptrdiff_t src_stride,
                              uint8_t* dst,
                              ptrdiff_t dst_stride,
-                             const int16_t* filter_x,
+                             const InterpKernel* filter,
+                             int x0_q4,
                              int x_step_q4,
-                             const int16_t* filter_y,
+                             int y0_q4,
                              int y_step_q4,
                              int w,
                              int h);
@@ -309,9 +336,10 @@
                                        ptrdiff_t src_stride,
                                        uint8_t* dst,
                                        ptrdiff_t dst_stride,
-                                       const int16_t* filter_x,
+                                       const InterpKernel* filter,
+                                       int x0_q4,
                                        int x_step_q4,
-                                       const int16_t* filter_y,
+                                       int y0_q4,
                                        int y_step_q4,
                                        int w,
                                        int h);
@@ -320,9 +348,10 @@
                         ptrdiff_t src_stride,
                         uint8_t* dst,
                         ptrdiff_t dst_stride,
-                        const int16_t* filter_x,
+                        const InterpKernel* filter,
+                        int x0_q4,
                         int x_step_q4,
-                        const int16_t* filter_y,
+                        int y0_q4,
                         int y_step_q4,
                         int w,
                         int h);
@@ -330,9 +359,10 @@
                            ptrdiff_t src_stride,
                            uint8_t* dst,
                            ptrdiff_t dst_stride,
-                           const int16_t* filter_x,
+                           const InterpKernel* filter,
+                           int x0_q4,
                            int x_step_q4,
-                           const int16_t* filter_y,
+                           int y0_q4,
                            int y_step_q4,
                            int w,
                            int h);
@@ -342,9 +372,10 @@
                          ptrdiff_t src_stride,
                          uint8_t* dst,
                          ptrdiff_t dst_stride,
-                         const int16_t* filter_x,
+                         const InterpKernel* filter,
+                         int x0_q4,
                          int x_step_q4,
-                         const int16_t* filter_y,
+                         int y0_q4,
                          int y_step_q4,
                          int w,
                          int h);
@@ -352,9 +383,10 @@
                             ptrdiff_t src_stride,
                             uint8_t* dst,
                             ptrdiff_t dst_stride,
-                            const int16_t* filter_x,
+                            const InterpKernel* filter,
+                            int x0_q4,
                             int x_step_q4,
-                            const int16_t* filter_y,
+                            int y0_q4,
                             int y_step_q4,
                             int w,
                             int h);
@@ -2895,9 +2927,10 @@
                             ptrdiff_t src_stride,
                             uint16_t* dst,
                             ptrdiff_t dst_stride,
-                            const int16_t* filter_x,
+                            const InterpKernel* filter,
+                            int x0_q4,
                             int x_step_q4,
-                            const int16_t* filter_y,
+                            int y0_q4,
                             int y_step_q4,
                             int w,
                             int h,
@@ -2906,9 +2939,10 @@
                                ptrdiff_t src_stride,
                                uint16_t* dst,
                                ptrdiff_t dst_stride,
-                               const int16_t* filter_x,
+                               const InterpKernel* filter,
+                               int x0_q4,
                                int x_step_q4,
-                               const int16_t* filter_y,
+                               int y0_q4,
                                int y_step_q4,
                                int w,
                                int h,
@@ -2917,9 +2951,10 @@
                                ptrdiff_t src_stride,
                                uint16_t* dst,
                                ptrdiff_t dst_stride,
-                               const int16_t* filter_x,
+                               const InterpKernel* filter,
+                               int x0_q4,
                                int x_step_q4,
-                               const int16_t* filter_y,
+                               int y0_q4,
                                int y_step_q4,
                                int w,
                                int h,
@@ -2928,9 +2963,10 @@
                                          ptrdiff_t src_stride,
                                          uint16_t* dst,
                                          ptrdiff_t dst_stride,
-                                         const int16_t* filter_x,
+                                         const InterpKernel* filter,
+                                         int x0_q4,
                                          int x_step_q4,
-                                         const int16_t* filter_y,
+                                         int y0_q4,
                                          int y_step_q4,
                                          int w,
                                          int h,
@@ -2940,9 +2976,10 @@
                                 ptrdiff_t src_stride,
                                 uint16_t* dst,
                                 ptrdiff_t dst_stride,
-                                const int16_t* filter_x,
+                                const InterpKernel* filter,
+                                int x0_q4,
                                 int x_step_q4,
-                                const int16_t* filter_y,
+                                int y0_q4,
                                 int y_step_q4,
                                 int w,
                                 int h,
@@ -2951,9 +2988,10 @@
                                    ptrdiff_t src_stride,
                                    uint16_t* dst,
                                    ptrdiff_t dst_stride,
-                                   const int16_t* filter_x,
+                                   const InterpKernel* filter,
+                                   int x0_q4,
                                    int x_step_q4,
-                                   const int16_t* filter_y,
+                                   int y0_q4,
                                    int y_step_q4,
                                    int w,
                                    int h,
@@ -2962,9 +3000,10 @@
                                    ptrdiff_t src_stride,
                                    uint16_t* dst,
                                    ptrdiff_t dst_stride,
-                                   const int16_t* filter_x,
+                                   const InterpKernel* filter,
+                                   int x0_q4,
                                    int x_step_q4,
-                                   const int16_t* filter_y,
+                                   int y0_q4,
                                    int y_step_q4,
                                    int w,
                                    int h,
@@ -2973,9 +3012,10 @@
                                              ptrdiff_t src_stride,
                                              uint16_t* dst,
                                              ptrdiff_t dst_stride,
-                                             const int16_t* filter_x,
+                                             const InterpKernel* filter,
+                                             int x0_q4,
                                              int x_step_q4,
-                                             const int16_t* filter_y,
+                                             int y0_q4,
                                              int y_step_q4,
                                              int w,
                                              int h,
@@ -2985,9 +3025,10 @@
                                       ptrdiff_t src_stride,
                                       uint16_t* dst,
                                       ptrdiff_t dst_stride,
-                                      const int16_t* filter_x,
+                                      const InterpKernel* filter,
+                                      int x0_q4,
                                       int x_step_q4,
-                                      const int16_t* filter_y,
+                                      int y0_q4,
                                       int y_step_q4,
                                       int w,
                                       int h,
@@ -2996,9 +3037,10 @@
                                          ptrdiff_t src_stride,
                                          uint16_t* dst,
                                          ptrdiff_t dst_stride,
-                                         const int16_t* filter_x,
+                                         const InterpKernel* filter,
+                                         int x0_q4,
                                          int x_step_q4,
-                                         const int16_t* filter_y,
+                                         int y0_q4,
                                          int y_step_q4,
                                          int w,
                                          int h,
@@ -3007,9 +3049,10 @@
                                          ptrdiff_t src_stride,
                                          uint16_t* dst,
                                          ptrdiff_t dst_stride,
-                                         const int16_t* filter_x,
+                                         const InterpKernel* filter,
+                                         int x0_q4,
                                          int x_step_q4,
-                                         const int16_t* filter_y,
+                                         int y0_q4,
                                          int y_step_q4,
                                          int w,
                                          int h,
@@ -3018,9 +3061,10 @@
                                                    ptrdiff_t src_stride,
                                                    uint16_t* dst,
                                                    ptrdiff_t dst_stride,
-                                                   const int16_t* filter_x,
+                                                   const InterpKernel* filter,
+                                                   int x0_q4,
                                                    int x_step_q4,
-                                                   const int16_t* filter_y,
+                                                   int y0_q4,
                                                    int y_step_q4,
                                                    int w,
                                                    int h,
@@ -3030,9 +3074,10 @@
                                      ptrdiff_t src_stride,
                                      uint16_t* dst,
                                      ptrdiff_t dst_stride,
-                                     const int16_t* filter_x,
+                                     const InterpKernel* filter,
+                                     int x0_q4,
                                      int x_step_q4,
-                                     const int16_t* filter_y,
+                                     int y0_q4,
                                      int y_step_q4,
                                      int w,
                                      int h,
@@ -3041,9 +3086,10 @@
                                         ptrdiff_t src_stride,
                                         uint16_t* dst,
                                         ptrdiff_t dst_stride,
-                                        const int16_t* filter_x,
+                                        const InterpKernel* filter,
+                                        int x0_q4,
                                         int x_step_q4,
-                                        const int16_t* filter_y,
+                                        int y0_q4,
                                         int y_step_q4,
                                         int w,
                                         int h,
@@ -3052,9 +3098,10 @@
                                         ptrdiff_t src_stride,
                                         uint16_t* dst,
                                         ptrdiff_t dst_stride,
-                                        const int16_t* filter_x,
+                                        const InterpKernel* filter,
+                                        int x0_q4,
                                         int x_step_q4,
-                                        const int16_t* filter_y,
+                                        int y0_q4,
                                         int y_step_q4,
                                         int w,
                                         int h,
@@ -3063,9 +3110,10 @@
                                                   ptrdiff_t src_stride,
                                                   uint16_t* dst,
                                                   ptrdiff_t dst_stride,
-                                                  const int16_t* filter_x,
+                                                  const InterpKernel* filter,
+                                                  int x0_q4,
                                                   int x_step_q4,
-                                                  const int16_t* filter_y,
+                                                  int y0_q4,
                                                   int y_step_q4,
                                                   int w,
                                                   int h,
@@ -3075,9 +3123,10 @@
                                   ptrdiff_t src_stride,
                                   uint16_t* dst,
                                   ptrdiff_t dst_stride,
-                                  const int16_t* filter_x,
+                                  const InterpKernel* filter,
+                                  int x0_q4,
                                   int x_step_q4,
-                                  const int16_t* filter_y,
+                                  int y0_q4,
                                   int y_step_q4,
                                   int w,
                                   int h,
@@ -3086,9 +3135,10 @@
                                      ptrdiff_t src_stride,
                                      uint16_t* dst,
                                      ptrdiff_t dst_stride,
-                                     const int16_t* filter_x,
+                                     const InterpKernel* filter,
+                                     int x0_q4,
                                      int x_step_q4,
-                                     const int16_t* filter_y,
+                                     int y0_q4,
                                      int y_step_q4,
                                      int w,
                                      int h,
@@ -3097,9 +3147,10 @@
                                      ptrdiff_t src_stride,
                                      uint16_t* dst,
                                      ptrdiff_t dst_stride,
-                                     const int16_t* filter_x,
+                                     const InterpKernel* filter,
+                                     int x0_q4,
                                      int x_step_q4,
-                                     const int16_t* filter_y,
+                                     int y0_q4,
                                      int y_step_q4,
                                      int w,
                                      int h,
@@ -3108,9 +3159,10 @@
                                                ptrdiff_t src_stride,
                                                uint16_t* dst,
                                                ptrdiff_t dst_stride,
-                                               const int16_t* filter_x,
+                                               const InterpKernel* filter,
+                                               int x0_q4,
                                                int x_step_q4,
-                                               const int16_t* filter_y,
+                                               int y0_q4,
                                                int y_step_q4,
                                                int w,
                                                int h,
@@ -3120,9 +3172,10 @@
                                  ptrdiff_t src_stride,
                                  uint16_t* dst,
                                  ptrdiff_t dst_stride,
-                                 const int16_t* filter_x,
+                                 const InterpKernel* filter,
+                                 int x0_q4,
                                  int x_step_q4,
-                                 const int16_t* filter_y,
+                                 int y0_q4,
                                  int y_step_q4,
                                  int w,
                                  int h,
@@ -3131,9 +3184,10 @@
                                     ptrdiff_t src_stride,
                                     uint16_t* dst,
                                     ptrdiff_t dst_stride,
-                                    const int16_t* filter_x,
+                                    const InterpKernel* filter,
+                                    int x0_q4,
                                     int x_step_q4,
-                                    const int16_t* filter_y,
+                                    int y0_q4,
                                     int y_step_q4,
                                     int w,
                                     int h,
@@ -3142,9 +3196,10 @@
                                     ptrdiff_t src_stride,
                                     uint16_t* dst,
                                     ptrdiff_t dst_stride,
-                                    const int16_t* filter_x,
+                                    const InterpKernel* filter,
+                                    int x0_q4,
                                     int x_step_q4,
-                                    const int16_t* filter_y,
+                                    int y0_q4,
                                     int y_step_q4,
                                     int w,
                                     int h,
@@ -3153,9 +3208,10 @@
                                               ptrdiff_t src_stride,
                                               uint16_t* dst,
                                               ptrdiff_t dst_stride,
-                                              const int16_t* filter_x,
+                                              const InterpKernel* filter,
+                                              int x0_q4,
                                               int x_step_q4,
-                                              const int16_t* filter_y,
+                                              int y0_q4,
                                               int y_step_q4,
                                               int w,
                                               int h,
@@ -3165,9 +3221,10 @@
                                ptrdiff_t src_stride,
                                uint16_t* dst,
                                ptrdiff_t dst_stride,
-                               const int16_t* filter_x,
+                               const InterpKernel* filter,
+                               int x0_q4,
                                int x_step_q4,
-                               const int16_t* filter_y,
+                               int y0_q4,
                                int y_step_q4,
                                int w,
                                int h,
@@ -3176,9 +3233,10 @@
                                   ptrdiff_t src_stride,
                                   uint16_t* dst,
                                   ptrdiff_t dst_stride,
-                                  const int16_t* filter_x,
+                                  const InterpKernel* filter,
+                                  int x0_q4,
                                   int x_step_q4,
-                                  const int16_t* filter_y,
+                                  int y0_q4,
                                   int y_step_q4,
                                   int w,
                                   int h,
@@ -3187,9 +3245,10 @@
                                   ptrdiff_t src_stride,
                                   uint16_t* dst,
                                   ptrdiff_t dst_stride,
-                                  const int16_t* filter_x,
+                                  const InterpKernel* filter,
+                                  int x0_q4,
                                   int x_step_q4,
-                                  const int16_t* filter_y,
+                                  int y0_q4,
                                   int y_step_q4,
                                   int w,
                                   int h,
@@ -3198,9 +3257,10 @@
                                             ptrdiff_t src_stride,
                                             uint16_t* dst,
                                             ptrdiff_t dst_stride,
-                                            const int16_t* filter_x,
+                                            const InterpKernel* filter,
+                                            int x0_q4,
                                             int x_step_q4,
-                                            const int16_t* filter_y,
+                                            int y0_q4,
                                             int y_step_q4,
                                             int w,
                                             int h,
@@ -3210,9 +3270,10 @@
                                 ptrdiff_t src_stride,
                                 uint16_t* dst,
                                 ptrdiff_t dst_stride,
-                                const int16_t* filter_x,
+                                const InterpKernel* filter,
+                                int x0_q4,
                                 int x_step_q4,
-                                const int16_t* filter_y,
+                                int y0_q4,
                                 int y_step_q4,
                                 int w,
                                 int h,
@@ -3221,9 +3282,10 @@
                                    ptrdiff_t src_stride,
                                    uint16_t* dst,
                                    ptrdiff_t dst_stride,
-                                   const int16_t* filter_x,
+                                   const InterpKernel* filter,
+                                   int x0_q4,
                                    int x_step_q4,
-                                   const int16_t* filter_y,
+                                   int y0_q4,
                                    int y_step_q4,
                                    int w,
                                    int h,
@@ -3232,9 +3294,10 @@
                                    ptrdiff_t src_stride,
                                    uint16_t* dst,
                                    ptrdiff_t dst_stride,
-                                   const int16_t* filter_x,
+                                   const InterpKernel* filter,
+                                   int x0_q4,
                                    int x_step_q4,
-                                   const int16_t* filter_y,
+                                   int y0_q4,
                                    int y_step_q4,
                                    int w,
                                    int h,
@@ -3243,9 +3306,10 @@
                                              ptrdiff_t src_stride,
                                              uint16_t* dst,
                                              ptrdiff_t dst_stride,
-                                             const int16_t* filter_x,
+                                             const InterpKernel* filter,
+                                             int x0_q4,
                                              int x_step_q4,
-                                             const int16_t* filter_y,
+                                             int y0_q4,
                                              int y_step_q4,
                                              int w,
                                              int h,
@@ -3424,56 +3488,98 @@
                                          const uint16_t* above,
                                          const uint16_t* left,
                                          int bd);
-#define vpx_highbd_dc_128_predictor_16x16 vpx_highbd_dc_128_predictor_16x16_c
+void vpx_highbd_dc_128_predictor_16x16_sse2(uint16_t* dst,
+                                            ptrdiff_t y_stride,
+                                            const uint16_t* above,
+                                            const uint16_t* left,
+                                            int bd);
+#define vpx_highbd_dc_128_predictor_16x16 vpx_highbd_dc_128_predictor_16x16_sse2
 
 void vpx_highbd_dc_128_predictor_32x32_c(uint16_t* dst,
                                          ptrdiff_t y_stride,
                                          const uint16_t* above,
                                          const uint16_t* left,
                                          int bd);
-#define vpx_highbd_dc_128_predictor_32x32 vpx_highbd_dc_128_predictor_32x32_c
+void vpx_highbd_dc_128_predictor_32x32_sse2(uint16_t* dst,
+                                            ptrdiff_t y_stride,
+                                            const uint16_t* above,
+                                            const uint16_t* left,
+                                            int bd);
+#define vpx_highbd_dc_128_predictor_32x32 vpx_highbd_dc_128_predictor_32x32_sse2
 
 void vpx_highbd_dc_128_predictor_4x4_c(uint16_t* dst,
                                        ptrdiff_t y_stride,
                                        const uint16_t* above,
                                        const uint16_t* left,
                                        int bd);
-#define vpx_highbd_dc_128_predictor_4x4 vpx_highbd_dc_128_predictor_4x4_c
+void vpx_highbd_dc_128_predictor_4x4_sse2(uint16_t* dst,
+                                          ptrdiff_t y_stride,
+                                          const uint16_t* above,
+                                          const uint16_t* left,
+                                          int bd);
+#define vpx_highbd_dc_128_predictor_4x4 vpx_highbd_dc_128_predictor_4x4_sse2
 
 void vpx_highbd_dc_128_predictor_8x8_c(uint16_t* dst,
                                        ptrdiff_t y_stride,
                                        const uint16_t* above,
                                        const uint16_t* left,
                                        int bd);
-#define vpx_highbd_dc_128_predictor_8x8 vpx_highbd_dc_128_predictor_8x8_c
+void vpx_highbd_dc_128_predictor_8x8_sse2(uint16_t* dst,
+                                          ptrdiff_t y_stride,
+                                          const uint16_t* above,
+                                          const uint16_t* left,
+                                          int bd);
+#define vpx_highbd_dc_128_predictor_8x8 vpx_highbd_dc_128_predictor_8x8_sse2
 
 void vpx_highbd_dc_left_predictor_16x16_c(uint16_t* dst,
                                           ptrdiff_t y_stride,
                                           const uint16_t* above,
                                           const uint16_t* left,
                                           int bd);
-#define vpx_highbd_dc_left_predictor_16x16 vpx_highbd_dc_left_predictor_16x16_c
+void vpx_highbd_dc_left_predictor_16x16_sse2(uint16_t* dst,
+                                             ptrdiff_t y_stride,
+                                             const uint16_t* above,
+                                             const uint16_t* left,
+                                             int bd);
+#define vpx_highbd_dc_left_predictor_16x16 \
+  vpx_highbd_dc_left_predictor_16x16_sse2
 
 void vpx_highbd_dc_left_predictor_32x32_c(uint16_t* dst,
                                           ptrdiff_t y_stride,
                                           const uint16_t* above,
                                           const uint16_t* left,
                                           int bd);
-#define vpx_highbd_dc_left_predictor_32x32 vpx_highbd_dc_left_predictor_32x32_c
+void vpx_highbd_dc_left_predictor_32x32_sse2(uint16_t* dst,
+                                             ptrdiff_t y_stride,
+                                             const uint16_t* above,
+                                             const uint16_t* left,
+                                             int bd);
+#define vpx_highbd_dc_left_predictor_32x32 \
+  vpx_highbd_dc_left_predictor_32x32_sse2
 
 void vpx_highbd_dc_left_predictor_4x4_c(uint16_t* dst,
                                         ptrdiff_t y_stride,
                                         const uint16_t* above,
                                         const uint16_t* left,
                                         int bd);
-#define vpx_highbd_dc_left_predictor_4x4 vpx_highbd_dc_left_predictor_4x4_c
+void vpx_highbd_dc_left_predictor_4x4_sse2(uint16_t* dst,
+                                           ptrdiff_t y_stride,
+                                           const uint16_t* above,
+                                           const uint16_t* left,
+                                           int bd);
+#define vpx_highbd_dc_left_predictor_4x4 vpx_highbd_dc_left_predictor_4x4_sse2
 
 void vpx_highbd_dc_left_predictor_8x8_c(uint16_t* dst,
                                         ptrdiff_t y_stride,
                                         const uint16_t* above,
                                         const uint16_t* left,
                                         int bd);
-#define vpx_highbd_dc_left_predictor_8x8 vpx_highbd_dc_left_predictor_8x8_c
+void vpx_highbd_dc_left_predictor_8x8_sse2(uint16_t* dst,
+                                           ptrdiff_t y_stride,
+                                           const uint16_t* above,
+                                           const uint16_t* left,
+                                           int bd);
+#define vpx_highbd_dc_left_predictor_8x8 vpx_highbd_dc_left_predictor_8x8_sse2
 
 void vpx_highbd_dc_predictor_16x16_c(uint16_t* dst,
                                      ptrdiff_t y_stride,
@@ -3528,28 +3634,48 @@
                                          const uint16_t* above,
                                          const uint16_t* left,
                                          int bd);
-#define vpx_highbd_dc_top_predictor_16x16 vpx_highbd_dc_top_predictor_16x16_c
+void vpx_highbd_dc_top_predictor_16x16_sse2(uint16_t* dst,
+                                            ptrdiff_t y_stride,
+                                            const uint16_t* above,
+                                            const uint16_t* left,
+                                            int bd);
+#define vpx_highbd_dc_top_predictor_16x16 vpx_highbd_dc_top_predictor_16x16_sse2
 
 void vpx_highbd_dc_top_predictor_32x32_c(uint16_t* dst,
                                          ptrdiff_t y_stride,
                                          const uint16_t* above,
                                          const uint16_t* left,
                                          int bd);
-#define vpx_highbd_dc_top_predictor_32x32 vpx_highbd_dc_top_predictor_32x32_c
+void vpx_highbd_dc_top_predictor_32x32_sse2(uint16_t* dst,
+                                            ptrdiff_t y_stride,
+                                            const uint16_t* above,
+                                            const uint16_t* left,
+                                            int bd);
+#define vpx_highbd_dc_top_predictor_32x32 vpx_highbd_dc_top_predictor_32x32_sse2
 
 void vpx_highbd_dc_top_predictor_4x4_c(uint16_t* dst,
                                        ptrdiff_t y_stride,
                                        const uint16_t* above,
                                        const uint16_t* left,
                                        int bd);
-#define vpx_highbd_dc_top_predictor_4x4 vpx_highbd_dc_top_predictor_4x4_c
+void vpx_highbd_dc_top_predictor_4x4_sse2(uint16_t* dst,
+                                          ptrdiff_t y_stride,
+                                          const uint16_t* above,
+                                          const uint16_t* left,
+                                          int bd);
+#define vpx_highbd_dc_top_predictor_4x4 vpx_highbd_dc_top_predictor_4x4_sse2
 
 void vpx_highbd_dc_top_predictor_8x8_c(uint16_t* dst,
                                        ptrdiff_t y_stride,
                                        const uint16_t* above,
                                        const uint16_t* left,
                                        int bd);
-#define vpx_highbd_dc_top_predictor_8x8 vpx_highbd_dc_top_predictor_8x8_c
+void vpx_highbd_dc_top_predictor_8x8_sse2(uint16_t* dst,
+                                          ptrdiff_t y_stride,
+                                          const uint16_t* above,
+                                          const uint16_t* left,
+                                          int bd);
+#define vpx_highbd_dc_top_predictor_8x8 vpx_highbd_dc_top_predictor_8x8_sse2
 
 void vpx_highbd_fdct16x16_c(const int16_t* input,
                             tran_low_t* output,
@@ -3607,28 +3733,48 @@
                                     const uint16_t* above,
                                     const uint16_t* left,
                                     int bd);
-#define vpx_highbd_h_predictor_16x16 vpx_highbd_h_predictor_16x16_c
+void vpx_highbd_h_predictor_16x16_sse2(uint16_t* dst,
+                                       ptrdiff_t y_stride,
+                                       const uint16_t* above,
+                                       const uint16_t* left,
+                                       int bd);
+#define vpx_highbd_h_predictor_16x16 vpx_highbd_h_predictor_16x16_sse2
 
 void vpx_highbd_h_predictor_32x32_c(uint16_t* dst,
                                     ptrdiff_t y_stride,
                                     const uint16_t* above,
                                     const uint16_t* left,
                                     int bd);
-#define vpx_highbd_h_predictor_32x32 vpx_highbd_h_predictor_32x32_c
+void vpx_highbd_h_predictor_32x32_sse2(uint16_t* dst,
+                                       ptrdiff_t y_stride,
+                                       const uint16_t* above,
+                                       const uint16_t* left,
+                                       int bd);
+#define vpx_highbd_h_predictor_32x32 vpx_highbd_h_predictor_32x32_sse2
 
 void vpx_highbd_h_predictor_4x4_c(uint16_t* dst,
                                   ptrdiff_t y_stride,
                                   const uint16_t* above,
                                   const uint16_t* left,
                                   int bd);
-#define vpx_highbd_h_predictor_4x4 vpx_highbd_h_predictor_4x4_c
+void vpx_highbd_h_predictor_4x4_sse2(uint16_t* dst,
+                                     ptrdiff_t y_stride,
+                                     const uint16_t* above,
+                                     const uint16_t* left,
+                                     int bd);
+#define vpx_highbd_h_predictor_4x4 vpx_highbd_h_predictor_4x4_sse2
 
 void vpx_highbd_h_predictor_8x8_c(uint16_t* dst,
                                   ptrdiff_t y_stride,
                                   const uint16_t* above,
                                   const uint16_t* left,
                                   int bd);
-#define vpx_highbd_h_predictor_8x8 vpx_highbd_h_predictor_8x8_c
+void vpx_highbd_h_predictor_8x8_sse2(uint16_t* dst,
+                                     ptrdiff_t y_stride,
+                                     const uint16_t* above,
+                                     const uint16_t* left,
+                                     int bd);
+#define vpx_highbd_h_predictor_8x8 vpx_highbd_h_predictor_8x8_sse2
 
 void vpx_highbd_idct16x16_10_add_c(const tran_low_t* input,
                                    uint16_t* dest,
@@ -5891,9 +6037,10 @@
                      ptrdiff_t src_stride,
                      uint8_t* dst,
                      ptrdiff_t dst_stride,
-                     const int16_t* filter_x,
+                     const InterpKernel* filter,
+                     int x0_q4,
                      int x_step_q4,
-                     const int16_t* filter_y,
+                     int y0_q4,
                      int y_step_q4,
                      int w,
                      int h);
@@ -5901,9 +6048,10 @@
                          ptrdiff_t src_stride,
                          uint8_t* dst,
                          ptrdiff_t dst_stride,
-                         const int16_t* filter_x,
+                         const InterpKernel* filter,
+                         int x0_q4,
                          int x_step_q4,
-                         const int16_t* filter_y,
+                         int y0_q4,
                          int y_step_q4,
                          int w,
                          int h);
@@ -5911,9 +6059,10 @@
                                   ptrdiff_t src_stride,
                                   uint8_t* dst,
                                   ptrdiff_t dst_stride,
-                                  const int16_t* filter_x,
+                                  const InterpKernel* filter,
+                                  int x0_q4,
                                   int x_step_q4,
-                                  const int16_t* filter_y,
+                                  int y0_q4,
                                   int y_step_q4,
                                   int w,
                                   int h);
@@ -5922,9 +6071,10 @@
                          ptrdiff_t src_stride,
                          uint8_t* dst,
                          ptrdiff_t dst_stride,
-                         const int16_t* filter_x,
+                         const InterpKernel* filter,
+                         int x0_q4,
                          int x_step_q4,
-                         const int16_t* filter_y,
+                         int y0_q4,
                          int y_step_q4,
                          int w,
                          int h);
@@ -5934,9 +6084,10 @@
                             ptrdiff_t src_stride,
                             uint8_t* dst,
                             ptrdiff_t dst_stride,
-                            const int16_t* filter_x,
+                            const InterpKernel* filter,
+                            int x0_q4,
                             int x_step_q4,
-                            const int16_t* filter_y,
+                            int y0_q4,
                             int y_step_q4,
                             int w,
                             int h);
@@ -5946,9 +6097,10 @@
                            ptrdiff_t src_stride,
                            uint8_t* dst,
                            ptrdiff_t dst_stride,
-                           const int16_t* filter_x,
+                           const InterpKernel* filter,
+                           int x0_q4,
                            int x_step_q4,
-                           const int16_t* filter_y,
+                           int y0_q4,
                            int y_step_q4,
                            int w,
                            int h);
@@ -5958,9 +6110,10 @@
                         ptrdiff_t src_stride,
                         uint8_t* dst,
                         ptrdiff_t dst_stride,
-                        const int16_t* filter_x,
+                        const InterpKernel* filter,
+                        int x0_q4,
                         int x_step_q4,
-                        const int16_t* filter_y,
+                        int y0_q4,
                         int y_step_q4,
                         int w,
                         int h);
@@ -5970,9 +6123,10 @@
                        ptrdiff_t src_stride,
                        uint8_t* dst,
                        ptrdiff_t dst_stride,
-                       const int16_t* filter_x,
+                       const InterpKernel* filter,
+                       int x0_q4,
                        int x_step_q4,
-                       const int16_t* filter_y,
+                       int y0_q4,
                        int y_step_q4,
                        int w,
                        int h);
diff --git a/third_party/libvpx/source/config/nacl/vpx_dsp_rtcd.h b/third_party/libvpx/source/config/nacl/vpx_dsp_rtcd.h
index 114b01b..3f20ed8 100644
--- a/third_party/libvpx/source/config/nacl/vpx_dsp_rtcd.h
+++ b/third_party/libvpx/source/config/nacl/vpx_dsp_rtcd.h
@@ -13,6 +13,7 @@
 
 #include "vpx/vpx_integer.h"
 #include "vpx_dsp/vpx_dsp_common.h"
+#include "vpx_dsp/vpx_filter.h"
 
 #ifdef __cplusplus
 extern "C" {
@@ -36,9 +37,10 @@
                      ptrdiff_t src_stride,
                      uint8_t* dst,
                      ptrdiff_t dst_stride,
-                     const int16_t* filter_x,
+                     const InterpKernel* filter,
+                     int x0_q4,
                      int x_step_q4,
-                     const int16_t* filter_y,
+                     int y0_q4,
                      int y_step_q4,
                      int w,
                      int h);
@@ -48,9 +50,10 @@
                          ptrdiff_t src_stride,
                          uint8_t* dst,
                          ptrdiff_t dst_stride,
-                         const int16_t* filter_x,
+                         const InterpKernel* filter,
+                         int x0_q4,
                          int x_step_q4,
-                         const int16_t* filter_y,
+                         int y0_q4,
                          int y_step_q4,
                          int w,
                          int h);
@@ -60,9 +63,10 @@
                                ptrdiff_t src_stride,
                                uint8_t* dst,
                                ptrdiff_t dst_stride,
-                               const int16_t* filter_x,
+                               const InterpKernel* filter,
+                               int x0_q4,
                                int x_step_q4,
-                               const int16_t* filter_y,
+                               int y0_q4,
                                int y_step_q4,
                                int w,
                                int h);
@@ -72,9 +76,10 @@
                               ptrdiff_t src_stride,
                               uint8_t* dst,
                               ptrdiff_t dst_stride,
-                              const int16_t* filter_x,
+                              const InterpKernel* filter,
+                              int x0_q4,
                               int x_step_q4,
-                              const int16_t* filter_y,
+                              int y0_q4,
                               int y_step_q4,
                               int w,
                               int h);
@@ -84,9 +89,10 @@
                            ptrdiff_t src_stride,
                            uint8_t* dst,
                            ptrdiff_t dst_stride,
-                           const int16_t* filter_x,
+                           const InterpKernel* filter,
+                           int x0_q4,
                            int x_step_q4,
-                           const int16_t* filter_y,
+                           int y0_q4,
                            int y_step_q4,
                            int w,
                            int h);
@@ -96,9 +102,10 @@
                           ptrdiff_t src_stride,
                           uint8_t* dst,
                           ptrdiff_t dst_stride,
-                          const int16_t* filter_x,
+                          const InterpKernel* filter,
+                          int x0_q4,
                           int x_step_q4,
-                          const int16_t* filter_y,
+                          int y0_q4,
                           int y_step_q4,
                           int w,
                           int h);
@@ -108,9 +115,10 @@
                         ptrdiff_t src_stride,
                         uint8_t* dst,
                         ptrdiff_t dst_stride,
-                        const int16_t* filter_x,
+                        const InterpKernel* filter,
+                        int x0_q4,
                         int x_step_q4,
-                        const int16_t* filter_y,
+                        int y0_q4,
                         int y_step_q4,
                         int w,
                         int h);
@@ -120,9 +128,10 @@
                          ptrdiff_t src_stride,
                          uint8_t* dst,
                          ptrdiff_t dst_stride,
-                         const int16_t* filter_x,
+                         const InterpKernel* filter,
+                         int x0_q4,
                          int x_step_q4,
-                         const int16_t* filter_y,
+                         int y0_q4,
                          int y_step_q4,
                          int w,
                          int h);
@@ -1724,9 +1733,10 @@
                             ptrdiff_t src_stride,
                             uint16_t* dst,
                             ptrdiff_t dst_stride,
-                            const int16_t* filter_x,
+                            const InterpKernel* filter,
+                            int x0_q4,
                             int x_step_q4,
-                            const int16_t* filter_y,
+                            int y0_q4,
                             int y_step_q4,
                             int w,
                             int h,
@@ -1737,9 +1747,10 @@
                                 ptrdiff_t src_stride,
                                 uint16_t* dst,
                                 ptrdiff_t dst_stride,
-                                const int16_t* filter_x,
+                                const InterpKernel* filter,
+                                int x0_q4,
                                 int x_step_q4,
-                                const int16_t* filter_y,
+                                int y0_q4,
                                 int y_step_q4,
                                 int w,
                                 int h,
@@ -1750,9 +1761,10 @@
                                       ptrdiff_t src_stride,
                                       uint16_t* dst,
                                       ptrdiff_t dst_stride,
-                                      const int16_t* filter_x,
+                                      const InterpKernel* filter,
+                                      int x0_q4,
                                       int x_step_q4,
-                                      const int16_t* filter_y,
+                                      int y0_q4,
                                       int y_step_q4,
                                       int w,
                                       int h,
@@ -1763,9 +1775,10 @@
                                      ptrdiff_t src_stride,
                                      uint16_t* dst,
                                      ptrdiff_t dst_stride,
-                                     const int16_t* filter_x,
+                                     const InterpKernel* filter,
+                                     int x0_q4,
                                      int x_step_q4,
-                                     const int16_t* filter_y,
+                                     int y0_q4,
                                      int y_step_q4,
                                      int w,
                                      int h,
@@ -1776,9 +1789,10 @@
                                   ptrdiff_t src_stride,
                                   uint16_t* dst,
                                   ptrdiff_t dst_stride,
-                                  const int16_t* filter_x,
+                                  const InterpKernel* filter,
+                                  int x0_q4,
                                   int x_step_q4,
-                                  const int16_t* filter_y,
+                                  int y0_q4,
                                   int y_step_q4,
                                   int w,
                                   int h,
@@ -1789,9 +1803,10 @@
                                  ptrdiff_t src_stride,
                                  uint16_t* dst,
                                  ptrdiff_t dst_stride,
-                                 const int16_t* filter_x,
+                                 const InterpKernel* filter,
+                                 int x0_q4,
                                  int x_step_q4,
-                                 const int16_t* filter_y,
+                                 int y0_q4,
                                  int y_step_q4,
                                  int w,
                                  int h,
@@ -1802,9 +1817,10 @@
                                ptrdiff_t src_stride,
                                uint16_t* dst,
                                ptrdiff_t dst_stride,
-                               const int16_t* filter_x,
+                               const InterpKernel* filter,
+                               int x0_q4,
                                int x_step_q4,
-                               const int16_t* filter_y,
+                               int y0_q4,
                                int y_step_q4,
                                int w,
                                int h,
@@ -1815,9 +1831,10 @@
                                 ptrdiff_t src_stride,
                                 uint16_t* dst,
                                 ptrdiff_t dst_stride,
-                                const int16_t* filter_x,
+                                const InterpKernel* filter,
+                                int x0_q4,
                                 int x_step_q4,
-                                const int16_t* filter_y,
+                                int y0_q4,
                                 int y_step_q4,
                                 int w,
                                 int h,
@@ -3323,9 +3340,10 @@
                      ptrdiff_t src_stride,
                      uint8_t* dst,
                      ptrdiff_t dst_stride,
-                     const int16_t* filter_x,
+                     const InterpKernel* filter,
+                     int x0_q4,
                      int x_step_q4,
-                     const int16_t* filter_y,
+                     int y0_q4,
                      int y_step_q4,
                      int w,
                      int h);
@@ -3335,9 +3353,10 @@
                          ptrdiff_t src_stride,
                          uint8_t* dst,
                          ptrdiff_t dst_stride,
-                         const int16_t* filter_x,
+                         const InterpKernel* filter,
+                         int x0_q4,
                          int x_step_q4,
-                         const int16_t* filter_y,
+                         int y0_q4,
                          int y_step_q4,
                          int w,
                          int h);
@@ -3347,9 +3366,10 @@
                             ptrdiff_t src_stride,
                             uint8_t* dst,
                             ptrdiff_t dst_stride,
-                            const int16_t* filter_x,
+                            const InterpKernel* filter,
+                            int x0_q4,
                             int x_step_q4,
-                            const int16_t* filter_y,
+                            int y0_q4,
                             int y_step_q4,
                             int w,
                             int h);
@@ -3359,9 +3379,10 @@
                            ptrdiff_t src_stride,
                            uint8_t* dst,
                            ptrdiff_t dst_stride,
-                           const int16_t* filter_x,
+                           const InterpKernel* filter,
+                           int x0_q4,
                            int x_step_q4,
-                           const int16_t* filter_y,
+                           int y0_q4,
                            int y_step_q4,
                            int w,
                            int h);
@@ -3371,9 +3392,10 @@
                         ptrdiff_t src_stride,
                         uint8_t* dst,
                         ptrdiff_t dst_stride,
-                        const int16_t* filter_x,
+                        const InterpKernel* filter,
+                        int x0_q4,
                         int x_step_q4,
-                        const int16_t* filter_y,
+                        int y0_q4,
                         int y_step_q4,
                         int w,
                         int h);
@@ -3383,9 +3405,10 @@
                        ptrdiff_t src_stride,
                        uint8_t* dst,
                        ptrdiff_t dst_stride,
-                       const int16_t* filter_x,
+                       const InterpKernel* filter,
+                       int x0_q4,
                        int x_step_q4,
-                       const int16_t* filter_y,
+                       int y0_q4,
                        int y_step_q4,
                        int w,
                        int h);
diff --git a/third_party/libvpx/source/config/vpx_version.h b/third_party/libvpx/source/config/vpx_version.h
index 7b71ebe0..c6de475 100644
--- a/third_party/libvpx/source/config/vpx_version.h
+++ b/third_party/libvpx/source/config/vpx_version.h
@@ -1,7 +1,7 @@
 #define VERSION_MAJOR  1
 #define VERSION_MINOR  6
 #define VERSION_PATCH  1
-#define VERSION_EXTRA  "1117-g30c261b1e"
+#define VERSION_EXTRA  "1176-g9a2dd7e67"
 #define VERSION_PACKED ((VERSION_MAJOR<<16)|(VERSION_MINOR<<8)|(VERSION_PATCH))
-#define VERSION_STRING_NOSP "v1.6.1-1117-g30c261b1e"
-#define VERSION_STRING      " v1.6.1-1117-g30c261b1e"
+#define VERSION_STRING_NOSP "v1.6.1-1176-g9a2dd7e67"
+#define VERSION_STRING      " v1.6.1-1176-g9a2dd7e67"
diff --git a/third_party/libvpx/source/config/win/ia32/vpx_dsp_rtcd.h b/third_party/libvpx/source/config/win/ia32/vpx_dsp_rtcd.h
index 10f0c335..66e7b01 100644
--- a/third_party/libvpx/source/config/win/ia32/vpx_dsp_rtcd.h
+++ b/third_party/libvpx/source/config/win/ia32/vpx_dsp_rtcd.h
@@ -13,6 +13,7 @@
 
 #include "vpx/vpx_integer.h"
 #include "vpx_dsp/vpx_dsp_common.h"
+#include "vpx_dsp/vpx_filter.h"
 
 #ifdef __cplusplus
 extern "C" {
@@ -49,9 +50,10 @@
                      ptrdiff_t src_stride,
                      uint8_t* dst,
                      ptrdiff_t dst_stride,
-                     const int16_t* filter_x,
+                     const InterpKernel* filter,
+                     int x0_q4,
                      int x_step_q4,
-                     const int16_t* filter_y,
+                     int y0_q4,
                      int y_step_q4,
                      int w,
                      int h);
@@ -59,9 +61,10 @@
                         ptrdiff_t src_stride,
                         uint8_t* dst,
                         ptrdiff_t dst_stride,
-                        const int16_t* filter_x,
+                        const InterpKernel* filter,
+                        int x0_q4,
                         int x_step_q4,
-                        const int16_t* filter_y,
+                        int y0_q4,
                         int y_step_q4,
                         int w,
                         int h);
@@ -69,9 +72,10 @@
                          ptrdiff_t src_stride,
                          uint8_t* dst,
                          ptrdiff_t dst_stride,
-                         const int16_t* filter_x,
+                         const InterpKernel* filter,
+                         int x0_q4,
                          int x_step_q4,
-                         const int16_t* filter_y,
+                         int y0_q4,
                          int y_step_q4,
                          int w,
                          int h);
@@ -79,9 +83,10 @@
                         ptrdiff_t src_stride,
                         uint8_t* dst,
                         ptrdiff_t dst_stride,
-                        const int16_t* filter_x,
+                        const InterpKernel* filter,
+                        int x0_q4,
                         int x_step_q4,
-                        const int16_t* filter_y,
+                        int y0_q4,
                         int y_step_q4,
                         int w,
                         int h);
@@ -89,9 +94,10 @@
                                   ptrdiff_t src_stride,
                                   uint8_t* dst,
                                   ptrdiff_t dst_stride,
-                                  const int16_t* filter_x,
+                                  const InterpKernel* filter,
+                                  int x0_q4,
                                   int x_step_q4,
-                                  const int16_t* filter_y,
+                                  int y0_q4,
                                   int y_step_q4,
                                   int w,
                                   int h);
@@ -100,9 +106,10 @@
                          ptrdiff_t src_stride,
                          uint8_t* dst,
                          ptrdiff_t dst_stride,
-                         const int16_t* filter_x,
+                         const InterpKernel* filter,
+                         int x0_q4,
                          int x_step_q4,
-                         const int16_t* filter_y,
+                         int y0_q4,
                          int y_step_q4,
                          int w,
                          int h);
@@ -110,9 +117,10 @@
                             ptrdiff_t src_stride,
                             uint8_t* dst,
                             ptrdiff_t dst_stride,
-                            const int16_t* filter_x,
+                            const InterpKernel* filter,
+                            int x0_q4,
                             int x_step_q4,
-                            const int16_t* filter_y,
+                            int y0_q4,
                             int y_step_q4,
                             int w,
                             int h);
@@ -120,9 +128,10 @@
                              ptrdiff_t src_stride,
                              uint8_t* dst,
                              ptrdiff_t dst_stride,
-                             const int16_t* filter_x,
+                             const InterpKernel* filter,
+                             int x0_q4,
                              int x_step_q4,
-                             const int16_t* filter_y,
+                             int y0_q4,
                              int y_step_q4,
                              int w,
                              int h);
@@ -130,9 +139,10 @@
                                       ptrdiff_t src_stride,
                                       uint8_t* dst,
                                       ptrdiff_t dst_stride,
-                                      const int16_t* filter_x,
+                                      const InterpKernel* filter,
+                                      int x0_q4,
                                       int x_step_q4,
-                                      const int16_t* filter_y,
+                                      int y0_q4,
                                       int y_step_q4,
                                       int w,
                                       int h);
@@ -141,9 +151,10 @@
                                ptrdiff_t src_stride,
                                uint8_t* dst,
                                ptrdiff_t dst_stride,
-                               const int16_t* filter_x,
+                               const InterpKernel* filter,
+                               int x0_q4,
                                int x_step_q4,
-                               const int16_t* filter_y,
+                               int y0_q4,
                                int y_step_q4,
                                int w,
                                int h);
@@ -151,9 +162,10 @@
                                   ptrdiff_t src_stride,
                                   uint8_t* dst,
                                   ptrdiff_t dst_stride,
-                                  const int16_t* filter_x,
+                                  const InterpKernel* filter,
+                                  int x0_q4,
                                   int x_step_q4,
-                                  const int16_t* filter_y,
+                                  int y0_q4,
                                   int y_step_q4,
                                   int w,
                                   int h);
@@ -161,9 +173,10 @@
                                    ptrdiff_t src_stride,
                                    uint8_t* dst,
                                    ptrdiff_t dst_stride,
-                                   const int16_t* filter_x,
+                                   const InterpKernel* filter,
+                                   int x0_q4,
                                    int x_step_q4,
-                                   const int16_t* filter_y,
+                                   int y0_q4,
                                    int y_step_q4,
                                    int w,
                                    int h);
@@ -171,9 +184,10 @@
                                             ptrdiff_t src_stride,
                                             uint8_t* dst,
                                             ptrdiff_t dst_stride,
-                                            const int16_t* filter_x,
+                                            const InterpKernel* filter,
+                                            int x0_q4,
                                             int x_step_q4,
-                                            const int16_t* filter_y,
+                                            int y0_q4,
                                             int y_step_q4,
                                             int w,
                                             int h);
@@ -182,9 +196,10 @@
                               ptrdiff_t src_stride,
                               uint8_t* dst,
                               ptrdiff_t dst_stride,
-                              const int16_t* filter_x,
+                              const InterpKernel* filter,
+                              int x0_q4,
                               int x_step_q4,
-                              const int16_t* filter_y,
+                              int y0_q4,
                               int y_step_q4,
                               int w,
                               int h);
@@ -192,9 +207,10 @@
                                  ptrdiff_t src_stride,
                                  uint8_t* dst,
                                  ptrdiff_t dst_stride,
-                                 const int16_t* filter_x,
+                                 const InterpKernel* filter,
+                                 int x0_q4,
                                  int x_step_q4,
-                                 const int16_t* filter_y,
+                                 int y0_q4,
                                  int y_step_q4,
                                  int w,
                                  int h);
@@ -202,9 +218,10 @@
                                   ptrdiff_t src_stride,
                                   uint8_t* dst,
                                   ptrdiff_t dst_stride,
-                                  const int16_t* filter_x,
+                                  const InterpKernel* filter,
+                                  int x0_q4,
                                   int x_step_q4,
-                                  const int16_t* filter_y,
+                                  int y0_q4,
                                   int y_step_q4,
                                   int w,
                                   int h);
@@ -212,9 +229,10 @@
                                            ptrdiff_t src_stride,
                                            uint8_t* dst,
                                            ptrdiff_t dst_stride,
-                                           const int16_t* filter_x,
+                                           const InterpKernel* filter,
+                                           int x0_q4,
                                            int x_step_q4,
-                                           const int16_t* filter_y,
+                                           int y0_q4,
                                            int y_step_q4,
                                            int w,
                                            int h);
@@ -223,9 +241,10 @@
                            ptrdiff_t src_stride,
                            uint8_t* dst,
                            ptrdiff_t dst_stride,
-                           const int16_t* filter_x,
+                           const InterpKernel* filter,
+                           int x0_q4,
                            int x_step_q4,
-                           const int16_t* filter_y,
+                           int y0_q4,
                            int y_step_q4,
                            int w,
                            int h);
@@ -233,9 +252,10 @@
                               ptrdiff_t src_stride,
                               uint8_t* dst,
                               ptrdiff_t dst_stride,
-                              const int16_t* filter_x,
+                              const InterpKernel* filter,
+                              int x0_q4,
                               int x_step_q4,
-                              const int16_t* filter_y,
+                              int y0_q4,
                               int y_step_q4,
                               int w,
                               int h);
@@ -243,9 +263,10 @@
                                ptrdiff_t src_stride,
                                uint8_t* dst,
                                ptrdiff_t dst_stride,
-                               const int16_t* filter_x,
+                               const InterpKernel* filter,
+                               int x0_q4,
                                int x_step_q4,
-                               const int16_t* filter_y,
+                               int y0_q4,
                                int y_step_q4,
                                int w,
                                int h);
@@ -253,9 +274,10 @@
                               ptrdiff_t src_stride,
                               uint8_t* dst,
                               ptrdiff_t dst_stride,
-                              const int16_t* filter_x,
+                              const InterpKernel* filter,
+                              int x0_q4,
                               int x_step_q4,
-                              const int16_t* filter_y,
+                              int y0_q4,
                               int y_step_q4,
                               int w,
                               int h);
@@ -263,9 +285,10 @@
                                         ptrdiff_t src_stride,
                                         uint8_t* dst,
                                         ptrdiff_t dst_stride,
-                                        const int16_t* filter_x,
+                                        const InterpKernel* filter,
+                                        int x0_q4,
                                         int x_step_q4,
-                                        const int16_t* filter_y,
+                                        int y0_q4,
                                         int y_step_q4,
                                         int w,
                                         int h);
@@ -274,9 +297,10 @@
                           ptrdiff_t src_stride,
                           uint8_t* dst,
                           ptrdiff_t dst_stride,
-                          const int16_t* filter_x,
+                          const InterpKernel* filter,
+                          int x0_q4,
                           int x_step_q4,
-                          const int16_t* filter_y,
+                          int y0_q4,
                           int y_step_q4,
                           int w,
                           int h);
@@ -284,9 +308,10 @@
                              ptrdiff_t src_stride,
                              uint8_t* dst,
                              ptrdiff_t dst_stride,
-                             const int16_t* filter_x,
+                             const InterpKernel* filter,
+                             int x0_q4,
                              int x_step_q4,
-                             const int16_t* filter_y,
+                             int y0_q4,
                              int y_step_q4,
                              int w,
                              int h);
@@ -294,9 +319,10 @@
                               ptrdiff_t src_stride,
                               uint8_t* dst,
                               ptrdiff_t dst_stride,
-                              const int16_t* filter_x,
+                              const InterpKernel* filter,
+                              int x0_q4,
                               int x_step_q4,
-                              const int16_t* filter_y,
+                              int y0_q4,
                               int y_step_q4,
                               int w,
                               int h);
@@ -304,9 +330,10 @@
                              ptrdiff_t src_stride,
                              uint8_t* dst,
                              ptrdiff_t dst_stride,
-                             const int16_t* filter_x,
+                             const InterpKernel* filter,
+                             int x0_q4,
                              int x_step_q4,
-                             const int16_t* filter_y,
+                             int y0_q4,
                              int y_step_q4,
                              int w,
                              int h);
@@ -314,9 +341,10 @@
                                        ptrdiff_t src_stride,
                                        uint8_t* dst,
                                        ptrdiff_t dst_stride,
-                                       const int16_t* filter_x,
+                                       const InterpKernel* filter,
+                                       int x0_q4,
                                        int x_step_q4,
-                                       const int16_t* filter_y,
+                                       int y0_q4,
                                        int y_step_q4,
                                        int w,
                                        int h);
@@ -325,9 +353,10 @@
                         ptrdiff_t src_stride,
                         uint8_t* dst,
                         ptrdiff_t dst_stride,
-                        const int16_t* filter_x,
+                        const InterpKernel* filter,
+                        int x0_q4,
                         int x_step_q4,
-                        const int16_t* filter_y,
+                        int y0_q4,
                         int y_step_q4,
                         int w,
                         int h);
@@ -335,9 +364,10 @@
                            ptrdiff_t src_stride,
                            uint8_t* dst,
                            ptrdiff_t dst_stride,
-                           const int16_t* filter_x,
+                           const InterpKernel* filter,
+                           int x0_q4,
                            int x_step_q4,
-                           const int16_t* filter_y,
+                           int y0_q4,
                            int y_step_q4,
                            int w,
                            int h);
@@ -345,9 +375,10 @@
                                      ptrdiff_t src_stride,
                                      uint8_t* dst,
                                      ptrdiff_t dst_stride,
-                                     const int16_t* filter_x,
+                                     const InterpKernel* filter,
+                                     int x0_q4,
                                      int x_step_q4,
-                                     const int16_t* filter_y,
+                                     int y0_q4,
                                      int y_step_q4,
                                      int w,
                                      int h);
@@ -356,9 +387,10 @@
                          ptrdiff_t src_stride,
                          uint8_t* dst,
                          ptrdiff_t dst_stride,
-                         const int16_t* filter_x,
+                         const InterpKernel* filter,
+                         int x0_q4,
                          int x_step_q4,
-                         const int16_t* filter_y,
+                         int y0_q4,
                          int y_step_q4,
                          int w,
                          int h);
@@ -366,9 +398,10 @@
                             ptrdiff_t src_stride,
                             uint8_t* dst,
                             ptrdiff_t dst_stride,
-                            const int16_t* filter_x,
+                            const InterpKernel* filter,
+                            int x0_q4,
                             int x_step_q4,
-                            const int16_t* filter_y,
+                            int y0_q4,
                             int y_step_q4,
                             int w,
                             int h);
@@ -376,9 +409,10 @@
                                       ptrdiff_t src_stride,
                                       uint8_t* dst,
                                       ptrdiff_t dst_stride,
-                                      const int16_t* filter_x,
+                                      const InterpKernel* filter,
+                                      int x0_q4,
                                       int x_step_q4,
-                                      const int16_t* filter_y,
+                                      int y0_q4,
                                       int y_step_q4,
                                       int w,
                                       int h);
@@ -3582,9 +3616,10 @@
                             ptrdiff_t src_stride,
                             uint16_t* dst,
                             ptrdiff_t dst_stride,
-                            const int16_t* filter_x,
+                            const InterpKernel* filter,
+                            int x0_q4,
                             int x_step_q4,
-                            const int16_t* filter_y,
+                            int y0_q4,
                             int y_step_q4,
                             int w,
                             int h,
@@ -3593,9 +3628,10 @@
                                ptrdiff_t src_stride,
                                uint16_t* dst,
                                ptrdiff_t dst_stride,
-                               const int16_t* filter_x,
+                               const InterpKernel* filter,
+                               int x0_q4,
                                int x_step_q4,
-                               const int16_t* filter_y,
+                               int y0_q4,
                                int y_step_q4,
                                int w,
                                int h,
@@ -3604,9 +3640,10 @@
                                          ptrdiff_t src_stride,
                                          uint16_t* dst,
                                          ptrdiff_t dst_stride,
-                                         const int16_t* filter_x,
+                                         const InterpKernel* filter,
+                                         int x0_q4,
                                          int x_step_q4,
-                                         const int16_t* filter_y,
+                                         int y0_q4,
                                          int y_step_q4,
                                          int w,
                                          int h,
@@ -3616,9 +3653,10 @@
                                 ptrdiff_t src_stride,
                                 uint16_t* dst,
                                 ptrdiff_t dst_stride,
-                                const int16_t* filter_x,
+                                const InterpKernel* filter,
+                                int x0_q4,
                                 int x_step_q4,
-                                const int16_t* filter_y,
+                                int y0_q4,
                                 int y_step_q4,
                                 int w,
                                 int h,
@@ -3627,9 +3665,10 @@
                                    ptrdiff_t src_stride,
                                    uint16_t* dst,
                                    ptrdiff_t dst_stride,
-                                   const int16_t* filter_x,
+                                   const InterpKernel* filter,
+                                   int x0_q4,
                                    int x_step_q4,
-                                   const int16_t* filter_y,
+                                   int y0_q4,
                                    int y_step_q4,
                                    int w,
                                    int h,
@@ -3638,9 +3677,10 @@
                                              ptrdiff_t src_stride,
                                              uint16_t* dst,
                                              ptrdiff_t dst_stride,
-                                             const int16_t* filter_x,
+                                             const InterpKernel* filter,
+                                             int x0_q4,
                                              int x_step_q4,
-                                             const int16_t* filter_y,
+                                             int y0_q4,
                                              int y_step_q4,
                                              int w,
                                              int h,
@@ -3650,9 +3690,10 @@
                                       ptrdiff_t src_stride,
                                       uint16_t* dst,
                                       ptrdiff_t dst_stride,
-                                      const int16_t* filter_x,
+                                      const InterpKernel* filter,
+                                      int x0_q4,
                                       int x_step_q4,
-                                      const int16_t* filter_y,
+                                      int y0_q4,
                                       int y_step_q4,
                                       int w,
                                       int h,
@@ -3661,9 +3702,10 @@
                                          ptrdiff_t src_stride,
                                          uint16_t* dst,
                                          ptrdiff_t dst_stride,
-                                         const int16_t* filter_x,
+                                         const InterpKernel* filter,
+                                         int x0_q4,
                                          int x_step_q4,
-                                         const int16_t* filter_y,
+                                         int y0_q4,
                                          int y_step_q4,
                                          int w,
                                          int h,
@@ -3672,9 +3714,10 @@
                                                    ptrdiff_t src_stride,
                                                    uint16_t* dst,
                                                    ptrdiff_t dst_stride,
-                                                   const int16_t* filter_x,
+                                                   const InterpKernel* filter,
+                                                   int x0_q4,
                                                    int x_step_q4,
-                                                   const int16_t* filter_y,
+                                                   int y0_q4,
                                                    int y_step_q4,
                                                    int w,
                                                    int h,
@@ -3684,9 +3727,10 @@
                                      ptrdiff_t src_stride,
                                      uint16_t* dst,
                                      ptrdiff_t dst_stride,
-                                     const int16_t* filter_x,
+                                     const InterpKernel* filter,
+                                     int x0_q4,
                                      int x_step_q4,
-                                     const int16_t* filter_y,
+                                     int y0_q4,
                                      int y_step_q4,
                                      int w,
                                      int h,
@@ -3695,9 +3739,10 @@
                                         ptrdiff_t src_stride,
                                         uint16_t* dst,
                                         ptrdiff_t dst_stride,
-                                        const int16_t* filter_x,
+                                        const InterpKernel* filter,
+                                        int x0_q4,
                                         int x_step_q4,
-                                        const int16_t* filter_y,
+                                        int y0_q4,
                                         int y_step_q4,
                                         int w,
                                         int h,
@@ -3706,9 +3751,10 @@
                                                   ptrdiff_t src_stride,
                                                   uint16_t* dst,
                                                   ptrdiff_t dst_stride,
-                                                  const int16_t* filter_x,
+                                                  const InterpKernel* filter,
+                                                  int x0_q4,
                                                   int x_step_q4,
-                                                  const int16_t* filter_y,
+                                                  int y0_q4,
                                                   int y_step_q4,
                                                   int w,
                                                   int h,
@@ -3718,9 +3764,10 @@
                                   ptrdiff_t src_stride,
                                   uint16_t* dst,
                                   ptrdiff_t dst_stride,
-                                  const int16_t* filter_x,
+                                  const InterpKernel* filter,
+                                  int x0_q4,
                                   int x_step_q4,
-                                  const int16_t* filter_y,
+                                  int y0_q4,
                                   int y_step_q4,
                                   int w,
                                   int h,
@@ -3729,9 +3776,10 @@
                                      ptrdiff_t src_stride,
                                      uint16_t* dst,
                                      ptrdiff_t dst_stride,
-                                     const int16_t* filter_x,
+                                     const InterpKernel* filter,
+                                     int x0_q4,
                                      int x_step_q4,
-                                     const int16_t* filter_y,
+                                     int y0_q4,
                                      int y_step_q4,
                                      int w,
                                      int h,
@@ -3740,9 +3788,10 @@
                                                ptrdiff_t src_stride,
                                                uint16_t* dst,
                                                ptrdiff_t dst_stride,
-                                               const int16_t* filter_x,
+                                               const InterpKernel* filter,
+                                               int x0_q4,
                                                int x_step_q4,
-                                               const int16_t* filter_y,
+                                               int y0_q4,
                                                int y_step_q4,
                                                int w,
                                                int h,
@@ -3752,9 +3801,10 @@
                                  ptrdiff_t src_stride,
                                  uint16_t* dst,
                                  ptrdiff_t dst_stride,
-                                 const int16_t* filter_x,
+                                 const InterpKernel* filter,
+                                 int x0_q4,
                                  int x_step_q4,
-                                 const int16_t* filter_y,
+                                 int y0_q4,
                                  int y_step_q4,
                                  int w,
                                  int h,
@@ -3763,9 +3813,10 @@
                                     ptrdiff_t src_stride,
                                     uint16_t* dst,
                                     ptrdiff_t dst_stride,
-                                    const int16_t* filter_x,
+                                    const InterpKernel* filter,
+                                    int x0_q4,
                                     int x_step_q4,
-                                    const int16_t* filter_y,
+                                    int y0_q4,
                                     int y_step_q4,
                                     int w,
                                     int h,
@@ -3774,9 +3825,10 @@
                                               ptrdiff_t src_stride,
                                               uint16_t* dst,
                                               ptrdiff_t dst_stride,
-                                              const int16_t* filter_x,
+                                              const InterpKernel* filter,
+                                              int x0_q4,
                                               int x_step_q4,
-                                              const int16_t* filter_y,
+                                              int y0_q4,
                                               int y_step_q4,
                                               int w,
                                               int h,
@@ -3786,9 +3838,10 @@
                                ptrdiff_t src_stride,
                                uint16_t* dst,
                                ptrdiff_t dst_stride,
-                               const int16_t* filter_x,
+                               const InterpKernel* filter,
+                               int x0_q4,
                                int x_step_q4,
-                               const int16_t* filter_y,
+                               int y0_q4,
                                int y_step_q4,
                                int w,
                                int h,
@@ -3797,9 +3850,10 @@
                                   ptrdiff_t src_stride,
                                   uint16_t* dst,
                                   ptrdiff_t dst_stride,
-                                  const int16_t* filter_x,
+                                  const InterpKernel* filter,
+                                  int x0_q4,
                                   int x_step_q4,
-                                  const int16_t* filter_y,
+                                  int y0_q4,
                                   int y_step_q4,
                                   int w,
                                   int h,
@@ -3808,9 +3862,10 @@
                                   ptrdiff_t src_stride,
                                   uint16_t* dst,
                                   ptrdiff_t dst_stride,
-                                  const int16_t* filter_x,
+                                  const InterpKernel* filter,
+                                  int x0_q4,
                                   int x_step_q4,
-                                  const int16_t* filter_y,
+                                  int y0_q4,
                                   int y_step_q4,
                                   int w,
                                   int h,
@@ -3819,9 +3874,10 @@
                                             ptrdiff_t src_stride,
                                             uint16_t* dst,
                                             ptrdiff_t dst_stride,
-                                            const int16_t* filter_x,
+                                            const InterpKernel* filter,
+                                            int x0_q4,
                                             int x_step_q4,
-                                            const int16_t* filter_y,
+                                            int y0_q4,
                                             int y_step_q4,
                                             int w,
                                             int h,
@@ -3831,9 +3887,10 @@
                                 ptrdiff_t src_stride,
                                 uint16_t* dst,
                                 ptrdiff_t dst_stride,
-                                const int16_t* filter_x,
+                                const InterpKernel* filter,
+                                int x0_q4,
                                 int x_step_q4,
-                                const int16_t* filter_y,
+                                int y0_q4,
                                 int y_step_q4,
                                 int w,
                                 int h,
@@ -3842,9 +3899,10 @@
                                    ptrdiff_t src_stride,
                                    uint16_t* dst,
                                    ptrdiff_t dst_stride,
-                                   const int16_t* filter_x,
+                                   const InterpKernel* filter,
+                                   int x0_q4,
                                    int x_step_q4,
-                                   const int16_t* filter_y,
+                                   int y0_q4,
                                    int y_step_q4,
                                    int w,
                                    int h,
@@ -3853,9 +3911,10 @@
                                    ptrdiff_t src_stride,
                                    uint16_t* dst,
                                    ptrdiff_t dst_stride,
-                                   const int16_t* filter_x,
+                                   const InterpKernel* filter,
+                                   int x0_q4,
                                    int x_step_q4,
-                                   const int16_t* filter_y,
+                                   int y0_q4,
                                    int y_step_q4,
                                    int w,
                                    int h,
@@ -3864,9 +3923,10 @@
                                              ptrdiff_t src_stride,
                                              uint16_t* dst,
                                              ptrdiff_t dst_stride,
-                                             const int16_t* filter_x,
+                                             const InterpKernel* filter,
+                                             int x0_q4,
                                              int x_step_q4,
-                                             const int16_t* filter_y,
+                                             int y0_q4,
                                              int y_step_q4,
                                              int w,
                                              int h,
@@ -4045,56 +4105,128 @@
                                          const uint16_t* above,
                                          const uint16_t* left,
                                          int bd);
-#define vpx_highbd_dc_128_predictor_16x16 vpx_highbd_dc_128_predictor_16x16_c
+void vpx_highbd_dc_128_predictor_16x16_sse2(uint16_t* dst,
+                                            ptrdiff_t y_stride,
+                                            const uint16_t* above,
+                                            const uint16_t* left,
+                                            int bd);
+RTCD_EXTERN void (*vpx_highbd_dc_128_predictor_16x16)(uint16_t* dst,
+                                                      ptrdiff_t y_stride,
+                                                      const uint16_t* above,
+                                                      const uint16_t* left,
+                                                      int bd);
 
 void vpx_highbd_dc_128_predictor_32x32_c(uint16_t* dst,
                                          ptrdiff_t y_stride,
                                          const uint16_t* above,
                                          const uint16_t* left,
                                          int bd);
-#define vpx_highbd_dc_128_predictor_32x32 vpx_highbd_dc_128_predictor_32x32_c
+void vpx_highbd_dc_128_predictor_32x32_sse2(uint16_t* dst,
+                                            ptrdiff_t y_stride,
+                                            const uint16_t* above,
+                                            const uint16_t* left,
+                                            int bd);
+RTCD_EXTERN void (*vpx_highbd_dc_128_predictor_32x32)(uint16_t* dst,
+                                                      ptrdiff_t y_stride,
+                                                      const uint16_t* above,
+                                                      const uint16_t* left,
+                                                      int bd);
 
 void vpx_highbd_dc_128_predictor_4x4_c(uint16_t* dst,
                                        ptrdiff_t y_stride,
                                        const uint16_t* above,
                                        const uint16_t* left,
                                        int bd);
-#define vpx_highbd_dc_128_predictor_4x4 vpx_highbd_dc_128_predictor_4x4_c
+void vpx_highbd_dc_128_predictor_4x4_sse2(uint16_t* dst,
+                                          ptrdiff_t y_stride,
+                                          const uint16_t* above,
+                                          const uint16_t* left,
+                                          int bd);
+RTCD_EXTERN void (*vpx_highbd_dc_128_predictor_4x4)(uint16_t* dst,
+                                                    ptrdiff_t y_stride,
+                                                    const uint16_t* above,
+                                                    const uint16_t* left,
+                                                    int bd);
 
 void vpx_highbd_dc_128_predictor_8x8_c(uint16_t* dst,
                                        ptrdiff_t y_stride,
                                        const uint16_t* above,
                                        const uint16_t* left,
                                        int bd);
-#define vpx_highbd_dc_128_predictor_8x8 vpx_highbd_dc_128_predictor_8x8_c
+void vpx_highbd_dc_128_predictor_8x8_sse2(uint16_t* dst,
+                                          ptrdiff_t y_stride,
+                                          const uint16_t* above,
+                                          const uint16_t* left,
+                                          int bd);
+RTCD_EXTERN void (*vpx_highbd_dc_128_predictor_8x8)(uint16_t* dst,
+                                                    ptrdiff_t y_stride,
+                                                    const uint16_t* above,
+                                                    const uint16_t* left,
+                                                    int bd);
 
 void vpx_highbd_dc_left_predictor_16x16_c(uint16_t* dst,
                                           ptrdiff_t y_stride,
                                           const uint16_t* above,
                                           const uint16_t* left,
                                           int bd);
-#define vpx_highbd_dc_left_predictor_16x16 vpx_highbd_dc_left_predictor_16x16_c
+void vpx_highbd_dc_left_predictor_16x16_sse2(uint16_t* dst,
+                                             ptrdiff_t y_stride,
+                                             const uint16_t* above,
+                                             const uint16_t* left,
+                                             int bd);
+RTCD_EXTERN void (*vpx_highbd_dc_left_predictor_16x16)(uint16_t* dst,
+                                                       ptrdiff_t y_stride,
+                                                       const uint16_t* above,
+                                                       const uint16_t* left,
+                                                       int bd);
 
 void vpx_highbd_dc_left_predictor_32x32_c(uint16_t* dst,
                                           ptrdiff_t y_stride,
                                           const uint16_t* above,
                                           const uint16_t* left,
                                           int bd);
-#define vpx_highbd_dc_left_predictor_32x32 vpx_highbd_dc_left_predictor_32x32_c
+void vpx_highbd_dc_left_predictor_32x32_sse2(uint16_t* dst,
+                                             ptrdiff_t y_stride,
+                                             const uint16_t* above,
+                                             const uint16_t* left,
+                                             int bd);
+RTCD_EXTERN void (*vpx_highbd_dc_left_predictor_32x32)(uint16_t* dst,
+                                                       ptrdiff_t y_stride,
+                                                       const uint16_t* above,
+                                                       const uint16_t* left,
+                                                       int bd);
 
 void vpx_highbd_dc_left_predictor_4x4_c(uint16_t* dst,
                                         ptrdiff_t y_stride,
                                         const uint16_t* above,
                                         const uint16_t* left,
                                         int bd);
-#define vpx_highbd_dc_left_predictor_4x4 vpx_highbd_dc_left_predictor_4x4_c
+void vpx_highbd_dc_left_predictor_4x4_sse2(uint16_t* dst,
+                                           ptrdiff_t y_stride,
+                                           const uint16_t* above,
+                                           const uint16_t* left,
+                                           int bd);
+RTCD_EXTERN void (*vpx_highbd_dc_left_predictor_4x4)(uint16_t* dst,
+                                                     ptrdiff_t y_stride,
+                                                     const uint16_t* above,
+                                                     const uint16_t* left,
+                                                     int bd);
 
 void vpx_highbd_dc_left_predictor_8x8_c(uint16_t* dst,
                                         ptrdiff_t y_stride,
                                         const uint16_t* above,
                                         const uint16_t* left,
                                         int bd);
-#define vpx_highbd_dc_left_predictor_8x8 vpx_highbd_dc_left_predictor_8x8_c
+void vpx_highbd_dc_left_predictor_8x8_sse2(uint16_t* dst,
+                                           ptrdiff_t y_stride,
+                                           const uint16_t* above,
+                                           const uint16_t* left,
+                                           int bd);
+RTCD_EXTERN void (*vpx_highbd_dc_left_predictor_8x8)(uint16_t* dst,
+                                                     ptrdiff_t y_stride,
+                                                     const uint16_t* above,
+                                                     const uint16_t* left,
+                                                     int bd);
 
 void vpx_highbd_dc_predictor_16x16_c(uint16_t* dst,
                                      ptrdiff_t y_stride,
@@ -4165,28 +4297,64 @@
                                          const uint16_t* above,
                                          const uint16_t* left,
                                          int bd);
-#define vpx_highbd_dc_top_predictor_16x16 vpx_highbd_dc_top_predictor_16x16_c
+void vpx_highbd_dc_top_predictor_16x16_sse2(uint16_t* dst,
+                                            ptrdiff_t y_stride,
+                                            const uint16_t* above,
+                                            const uint16_t* left,
+                                            int bd);
+RTCD_EXTERN void (*vpx_highbd_dc_top_predictor_16x16)(uint16_t* dst,
+                                                      ptrdiff_t y_stride,
+                                                      const uint16_t* above,
+                                                      const uint16_t* left,
+                                                      int bd);
 
 void vpx_highbd_dc_top_predictor_32x32_c(uint16_t* dst,
                                          ptrdiff_t y_stride,
                                          const uint16_t* above,
                                          const uint16_t* left,
                                          int bd);
-#define vpx_highbd_dc_top_predictor_32x32 vpx_highbd_dc_top_predictor_32x32_c
+void vpx_highbd_dc_top_predictor_32x32_sse2(uint16_t* dst,
+                                            ptrdiff_t y_stride,
+                                            const uint16_t* above,
+                                            const uint16_t* left,
+                                            int bd);
+RTCD_EXTERN void (*vpx_highbd_dc_top_predictor_32x32)(uint16_t* dst,
+                                                      ptrdiff_t y_stride,
+                                                      const uint16_t* above,
+                                                      const uint16_t* left,
+                                                      int bd);
 
 void vpx_highbd_dc_top_predictor_4x4_c(uint16_t* dst,
                                        ptrdiff_t y_stride,
                                        const uint16_t* above,
                                        const uint16_t* left,
                                        int bd);
-#define vpx_highbd_dc_top_predictor_4x4 vpx_highbd_dc_top_predictor_4x4_c
+void vpx_highbd_dc_top_predictor_4x4_sse2(uint16_t* dst,
+                                          ptrdiff_t y_stride,
+                                          const uint16_t* above,
+                                          const uint16_t* left,
+                                          int bd);
+RTCD_EXTERN void (*vpx_highbd_dc_top_predictor_4x4)(uint16_t* dst,
+                                                    ptrdiff_t y_stride,
+                                                    const uint16_t* above,
+                                                    const uint16_t* left,
+                                                    int bd);
 
 void vpx_highbd_dc_top_predictor_8x8_c(uint16_t* dst,
                                        ptrdiff_t y_stride,
                                        const uint16_t* above,
                                        const uint16_t* left,
                                        int bd);
-#define vpx_highbd_dc_top_predictor_8x8 vpx_highbd_dc_top_predictor_8x8_c
+void vpx_highbd_dc_top_predictor_8x8_sse2(uint16_t* dst,
+                                          ptrdiff_t y_stride,
+                                          const uint16_t* above,
+                                          const uint16_t* left,
+                                          int bd);
+RTCD_EXTERN void (*vpx_highbd_dc_top_predictor_8x8)(uint16_t* dst,
+                                                    ptrdiff_t y_stride,
+                                                    const uint16_t* above,
+                                                    const uint16_t* left,
+                                                    int bd);
 
 void vpx_highbd_fdct16x16_c(const int16_t* input,
                             tran_low_t* output,
@@ -4254,28 +4422,64 @@
                                     const uint16_t* above,
                                     const uint16_t* left,
                                     int bd);
-#define vpx_highbd_h_predictor_16x16 vpx_highbd_h_predictor_16x16_c
+void vpx_highbd_h_predictor_16x16_sse2(uint16_t* dst,
+                                       ptrdiff_t y_stride,
+                                       const uint16_t* above,
+                                       const uint16_t* left,
+                                       int bd);
+RTCD_EXTERN void (*vpx_highbd_h_predictor_16x16)(uint16_t* dst,
+                                                 ptrdiff_t y_stride,
+                                                 const uint16_t* above,
+                                                 const uint16_t* left,
+                                                 int bd);
 
 void vpx_highbd_h_predictor_32x32_c(uint16_t* dst,
                                     ptrdiff_t y_stride,
                                     const uint16_t* above,
                                     const uint16_t* left,
                                     int bd);
-#define vpx_highbd_h_predictor_32x32 vpx_highbd_h_predictor_32x32_c
+void vpx_highbd_h_predictor_32x32_sse2(uint16_t* dst,
+                                       ptrdiff_t y_stride,
+                                       const uint16_t* above,
+                                       const uint16_t* left,
+                                       int bd);
+RTCD_EXTERN void (*vpx_highbd_h_predictor_32x32)(uint16_t* dst,
+                                                 ptrdiff_t y_stride,
+                                                 const uint16_t* above,
+                                                 const uint16_t* left,
+                                                 int bd);
 
 void vpx_highbd_h_predictor_4x4_c(uint16_t* dst,
                                   ptrdiff_t y_stride,
                                   const uint16_t* above,
                                   const uint16_t* left,
                                   int bd);
-#define vpx_highbd_h_predictor_4x4 vpx_highbd_h_predictor_4x4_c
+void vpx_highbd_h_predictor_4x4_sse2(uint16_t* dst,
+                                     ptrdiff_t y_stride,
+                                     const uint16_t* above,
+                                     const uint16_t* left,
+                                     int bd);
+RTCD_EXTERN void (*vpx_highbd_h_predictor_4x4)(uint16_t* dst,
+                                               ptrdiff_t y_stride,
+                                               const uint16_t* above,
+                                               const uint16_t* left,
+                                               int bd);
 
 void vpx_highbd_h_predictor_8x8_c(uint16_t* dst,
                                   ptrdiff_t y_stride,
                                   const uint16_t* above,
                                   const uint16_t* left,
                                   int bd);
-#define vpx_highbd_h_predictor_8x8 vpx_highbd_h_predictor_8x8_c
+void vpx_highbd_h_predictor_8x8_sse2(uint16_t* dst,
+                                     ptrdiff_t y_stride,
+                                     const uint16_t* above,
+                                     const uint16_t* left,
+                                     int bd);
+RTCD_EXTERN void (*vpx_highbd_h_predictor_8x8)(uint16_t* dst,
+                                               ptrdiff_t y_stride,
+                                               const uint16_t* above,
+                                               const uint16_t* left,
+                                               int bd);
 
 void vpx_highbd_idct16x16_10_add_c(const tran_low_t* input,
                                    uint16_t* dest,
@@ -6162,7 +6366,32 @@
                             uint16_t* eob_ptr,
                             const int16_t* scan,
                             const int16_t* iscan);
-#define vpx_quantize_b_32x32 vpx_quantize_b_32x32_c
+void vpx_quantize_b_32x32_ssse3(const tran_low_t* coeff_ptr,
+                                intptr_t n_coeffs,
+                                int skip_block,
+                                const int16_t* zbin_ptr,
+                                const int16_t* round_ptr,
+                                const int16_t* quant_ptr,
+                                const int16_t* quant_shift_ptr,
+                                tran_low_t* qcoeff_ptr,
+                                tran_low_t* dqcoeff_ptr,
+                                const int16_t* dequant_ptr,
+                                uint16_t* eob_ptr,
+                                const int16_t* scan,
+                                const int16_t* iscan);
+RTCD_EXTERN void (*vpx_quantize_b_32x32)(const tran_low_t* coeff_ptr,
+                                         intptr_t n_coeffs,
+                                         int skip_block,
+                                         const int16_t* zbin_ptr,
+                                         const int16_t* round_ptr,
+                                         const int16_t* quant_ptr,
+                                         const int16_t* quant_shift_ptr,
+                                         tran_low_t* qcoeff_ptr,
+                                         tran_low_t* dqcoeff_ptr,
+                                         const int16_t* dequant_ptr,
+                                         uint16_t* eob_ptr,
+                                         const int16_t* scan,
+                                         const int16_t* iscan);
 
 unsigned int vpx_sad16x16_c(const uint8_t* src_ptr,
                             int src_stride,
@@ -6982,9 +7211,10 @@
                      ptrdiff_t src_stride,
                      uint8_t* dst,
                      ptrdiff_t dst_stride,
-                     const int16_t* filter_x,
+                     const InterpKernel* filter,
+                     int x0_q4,
                      int x_step_q4,
-                     const int16_t* filter_y,
+                     int y0_q4,
                      int y_step_q4,
                      int w,
                      int h);
@@ -6992,9 +7222,10 @@
                          ptrdiff_t src_stride,
                          uint8_t* dst,
                          ptrdiff_t dst_stride,
-                         const int16_t* filter_x,
+                         const InterpKernel* filter,
+                         int x0_q4,
                          int x_step_q4,
-                         const int16_t* filter_y,
+                         int y0_q4,
                          int y_step_q4,
                          int w,
                          int h);
@@ -7002,9 +7233,10 @@
                                   ptrdiff_t src_stride,
                                   uint8_t* dst,
                                   ptrdiff_t dst_stride,
-                                  const int16_t* filter_x,
+                                  const InterpKernel* filter,
+                                  int x0_q4,
                                   int x_step_q4,
-                                  const int16_t* filter_y,
+                                  int y0_q4,
                                   int y_step_q4,
                                   int w,
                                   int h);
@@ -7013,9 +7245,10 @@
                          ptrdiff_t src_stride,
                          uint8_t* dst,
                          ptrdiff_t dst_stride,
-                         const int16_t* filter_x,
+                         const InterpKernel* filter,
+                         int x0_q4,
                          int x_step_q4,
-                         const int16_t* filter_y,
+                         int y0_q4,
                          int y_step_q4,
                          int w,
                          int h);
@@ -7025,9 +7258,10 @@
                             ptrdiff_t src_stride,
                             uint8_t* dst,
                             ptrdiff_t dst_stride,
-                            const int16_t* filter_x,
+                            const InterpKernel* filter,
+                            int x0_q4,
                             int x_step_q4,
-                            const int16_t* filter_y,
+                            int y0_q4,
                             int y_step_q4,
                             int w,
                             int h);
@@ -7037,9 +7271,10 @@
                            ptrdiff_t src_stride,
                            uint8_t* dst,
                            ptrdiff_t dst_stride,
-                           const int16_t* filter_x,
+                           const InterpKernel* filter,
+                           int x0_q4,
                            int x_step_q4,
-                           const int16_t* filter_y,
+                           int y0_q4,
                            int y_step_q4,
                            int w,
                            int h);
@@ -7049,9 +7284,10 @@
                         ptrdiff_t src_stride,
                         uint8_t* dst,
                         ptrdiff_t dst_stride,
-                        const int16_t* filter_x,
+                        const InterpKernel* filter,
+                        int x0_q4,
                         int x_step_q4,
-                        const int16_t* filter_y,
+                        int y0_q4,
                         int y_step_q4,
                         int w,
                         int h);
@@ -7061,9 +7297,10 @@
                        ptrdiff_t src_stride,
                        uint8_t* dst,
                        ptrdiff_t dst_stride,
-                       const int16_t* filter_x,
+                       const InterpKernel* filter,
+                       int x0_q4,
                        int x_step_q4,
-                       const int16_t* filter_y,
+                       int y0_q4,
                        int y_step_q4,
                        int w,
                        int h);
@@ -8957,6 +9194,32 @@
     vpx_highbd_convolve_copy = vpx_highbd_convolve_copy_sse2;
   if (flags & HAS_AVX2)
     vpx_highbd_convolve_copy = vpx_highbd_convolve_copy_avx2;
+  vpx_highbd_dc_128_predictor_16x16 = vpx_highbd_dc_128_predictor_16x16_c;
+  if (flags & HAS_SSE2)
+    vpx_highbd_dc_128_predictor_16x16 = vpx_highbd_dc_128_predictor_16x16_sse2;
+  vpx_highbd_dc_128_predictor_32x32 = vpx_highbd_dc_128_predictor_32x32_c;
+  if (flags & HAS_SSE2)
+    vpx_highbd_dc_128_predictor_32x32 = vpx_highbd_dc_128_predictor_32x32_sse2;
+  vpx_highbd_dc_128_predictor_4x4 = vpx_highbd_dc_128_predictor_4x4_c;
+  if (flags & HAS_SSE2)
+    vpx_highbd_dc_128_predictor_4x4 = vpx_highbd_dc_128_predictor_4x4_sse2;
+  vpx_highbd_dc_128_predictor_8x8 = vpx_highbd_dc_128_predictor_8x8_c;
+  if (flags & HAS_SSE2)
+    vpx_highbd_dc_128_predictor_8x8 = vpx_highbd_dc_128_predictor_8x8_sse2;
+  vpx_highbd_dc_left_predictor_16x16 = vpx_highbd_dc_left_predictor_16x16_c;
+  if (flags & HAS_SSE2)
+    vpx_highbd_dc_left_predictor_16x16 =
+        vpx_highbd_dc_left_predictor_16x16_sse2;
+  vpx_highbd_dc_left_predictor_32x32 = vpx_highbd_dc_left_predictor_32x32_c;
+  if (flags & HAS_SSE2)
+    vpx_highbd_dc_left_predictor_32x32 =
+        vpx_highbd_dc_left_predictor_32x32_sse2;
+  vpx_highbd_dc_left_predictor_4x4 = vpx_highbd_dc_left_predictor_4x4_c;
+  if (flags & HAS_SSE2)
+    vpx_highbd_dc_left_predictor_4x4 = vpx_highbd_dc_left_predictor_4x4_sse2;
+  vpx_highbd_dc_left_predictor_8x8 = vpx_highbd_dc_left_predictor_8x8_c;
+  if (flags & HAS_SSE2)
+    vpx_highbd_dc_left_predictor_8x8 = vpx_highbd_dc_left_predictor_8x8_sse2;
   vpx_highbd_dc_predictor_16x16 = vpx_highbd_dc_predictor_16x16_c;
   if (flags & HAS_SSE2)
     vpx_highbd_dc_predictor_16x16 = vpx_highbd_dc_predictor_16x16_sse2;
@@ -8969,6 +9232,18 @@
   vpx_highbd_dc_predictor_8x8 = vpx_highbd_dc_predictor_8x8_c;
   if (flags & HAS_SSE2)
     vpx_highbd_dc_predictor_8x8 = vpx_highbd_dc_predictor_8x8_sse2;
+  vpx_highbd_dc_top_predictor_16x16 = vpx_highbd_dc_top_predictor_16x16_c;
+  if (flags & HAS_SSE2)
+    vpx_highbd_dc_top_predictor_16x16 = vpx_highbd_dc_top_predictor_16x16_sse2;
+  vpx_highbd_dc_top_predictor_32x32 = vpx_highbd_dc_top_predictor_32x32_c;
+  if (flags & HAS_SSE2)
+    vpx_highbd_dc_top_predictor_32x32 = vpx_highbd_dc_top_predictor_32x32_sse2;
+  vpx_highbd_dc_top_predictor_4x4 = vpx_highbd_dc_top_predictor_4x4_c;
+  if (flags & HAS_SSE2)
+    vpx_highbd_dc_top_predictor_4x4 = vpx_highbd_dc_top_predictor_4x4_sse2;
+  vpx_highbd_dc_top_predictor_8x8 = vpx_highbd_dc_top_predictor_8x8_c;
+  if (flags & HAS_SSE2)
+    vpx_highbd_dc_top_predictor_8x8 = vpx_highbd_dc_top_predictor_8x8_sse2;
   vpx_highbd_fdct16x16 = vpx_highbd_fdct16x16_c;
   if (flags & HAS_SSE2)
     vpx_highbd_fdct16x16 = vpx_highbd_fdct16x16_sse2;
@@ -8984,6 +9259,18 @@
   vpx_highbd_fdct8x8 = vpx_highbd_fdct8x8_c;
   if (flags & HAS_SSE2)
     vpx_highbd_fdct8x8 = vpx_highbd_fdct8x8_sse2;
+  vpx_highbd_h_predictor_16x16 = vpx_highbd_h_predictor_16x16_c;
+  if (flags & HAS_SSE2)
+    vpx_highbd_h_predictor_16x16 = vpx_highbd_h_predictor_16x16_sse2;
+  vpx_highbd_h_predictor_32x32 = vpx_highbd_h_predictor_32x32_c;
+  if (flags & HAS_SSE2)
+    vpx_highbd_h_predictor_32x32 = vpx_highbd_h_predictor_32x32_sse2;
+  vpx_highbd_h_predictor_4x4 = vpx_highbd_h_predictor_4x4_c;
+  if (flags & HAS_SSE2)
+    vpx_highbd_h_predictor_4x4 = vpx_highbd_h_predictor_4x4_sse2;
+  vpx_highbd_h_predictor_8x8 = vpx_highbd_h_predictor_8x8_c;
+  if (flags & HAS_SSE2)
+    vpx_highbd_h_predictor_8x8 = vpx_highbd_h_predictor_8x8_sse2;
   vpx_highbd_idct16x16_10_add = vpx_highbd_idct16x16_10_add_c;
   if (flags & HAS_SSE2)
     vpx_highbd_idct16x16_10_add = vpx_highbd_idct16x16_10_add_sse2;
@@ -9343,6 +9630,9 @@
     vpx_quantize_b = vpx_quantize_b_ssse3;
   if (flags & HAS_AVX)
     vpx_quantize_b = vpx_quantize_b_avx;
+  vpx_quantize_b_32x32 = vpx_quantize_b_32x32_c;
+  if (flags & HAS_SSSE3)
+    vpx_quantize_b_32x32 = vpx_quantize_b_32x32_ssse3;
   vpx_sad16x16 = vpx_sad16x16_c;
   if (flags & HAS_SSE2)
     vpx_sad16x16 = vpx_sad16x16_sse2;
diff --git a/third_party/libvpx/source/config/win/x64/vpx_dsp_rtcd.h b/third_party/libvpx/source/config/win/x64/vpx_dsp_rtcd.h
index 76174db..e3352ff2 100644
--- a/third_party/libvpx/source/config/win/x64/vpx_dsp_rtcd.h
+++ b/third_party/libvpx/source/config/win/x64/vpx_dsp_rtcd.h
@@ -13,6 +13,7 @@
 
 #include "vpx/vpx_integer.h"
 #include "vpx_dsp/vpx_dsp_common.h"
+#include "vpx_dsp/vpx_filter.h"
 
 #ifdef __cplusplus
 extern "C" {
@@ -44,9 +45,10 @@
                      ptrdiff_t src_stride,
                      uint8_t* dst,
                      ptrdiff_t dst_stride,
-                     const int16_t* filter_x,
+                     const InterpKernel* filter,
+                     int x0_q4,
                      int x_step_q4,
-                     const int16_t* filter_y,
+                     int y0_q4,
                      int y_step_q4,
                      int w,
                      int h);
@@ -54,9 +56,10 @@
                         ptrdiff_t src_stride,
                         uint8_t* dst,
                         ptrdiff_t dst_stride,
-                        const int16_t* filter_x,
+                        const InterpKernel* filter,
+                        int x0_q4,
                         int x_step_q4,
-                        const int16_t* filter_y,
+                        int y0_q4,
                         int y_step_q4,
                         int w,
                         int h);
@@ -64,9 +67,10 @@
                          ptrdiff_t src_stride,
                          uint8_t* dst,
                          ptrdiff_t dst_stride,
-                         const int16_t* filter_x,
+                         const InterpKernel* filter,
+                         int x0_q4,
                          int x_step_q4,
-                         const int16_t* filter_y,
+                         int y0_q4,
                          int y_step_q4,
                          int w,
                          int h);
@@ -74,9 +78,10 @@
                         ptrdiff_t src_stride,
                         uint8_t* dst,
                         ptrdiff_t dst_stride,
-                        const int16_t* filter_x,
+                        const InterpKernel* filter,
+                        int x0_q4,
                         int x_step_q4,
-                        const int16_t* filter_y,
+                        int y0_q4,
                         int y_step_q4,
                         int w,
                         int h);
@@ -84,9 +89,10 @@
                                   ptrdiff_t src_stride,
                                   uint8_t* dst,
                                   ptrdiff_t dst_stride,
-                                  const int16_t* filter_x,
+                                  const InterpKernel* filter,
+                                  int x0_q4,
                                   int x_step_q4,
-                                  const int16_t* filter_y,
+                                  int y0_q4,
                                   int y_step_q4,
                                   int w,
                                   int h);
@@ -95,9 +101,10 @@
                          ptrdiff_t src_stride,
                          uint8_t* dst,
                          ptrdiff_t dst_stride,
-                         const int16_t* filter_x,
+                         const InterpKernel* filter,
+                         int x0_q4,
                          int x_step_q4,
-                         const int16_t* filter_y,
+                         int y0_q4,
                          int y_step_q4,
                          int w,
                          int h);
@@ -105,9 +112,10 @@
                             ptrdiff_t src_stride,
                             uint8_t* dst,
                             ptrdiff_t dst_stride,
-                            const int16_t* filter_x,
+                            const InterpKernel* filter,
+                            int x0_q4,
                             int x_step_q4,
-                            const int16_t* filter_y,
+                            int y0_q4,
                             int y_step_q4,
                             int w,
                             int h);
@@ -115,9 +123,10 @@
                              ptrdiff_t src_stride,
                              uint8_t* dst,
                              ptrdiff_t dst_stride,
-                             const int16_t* filter_x,
+                             const InterpKernel* filter,
+                             int x0_q4,
                              int x_step_q4,
-                             const int16_t* filter_y,
+                             int y0_q4,
                              int y_step_q4,
                              int w,
                              int h);
@@ -125,9 +134,10 @@
                                       ptrdiff_t src_stride,
                                       uint8_t* dst,
                                       ptrdiff_t dst_stride,
-                                      const int16_t* filter_x,
+                                      const InterpKernel* filter,
+                                      int x0_q4,
                                       int x_step_q4,
-                                      const int16_t* filter_y,
+                                      int y0_q4,
                                       int y_step_q4,
                                       int w,
                                       int h);
@@ -136,9 +146,10 @@
                                ptrdiff_t src_stride,
                                uint8_t* dst,
                                ptrdiff_t dst_stride,
-                               const int16_t* filter_x,
+                               const InterpKernel* filter,
+                               int x0_q4,
                                int x_step_q4,
-                               const int16_t* filter_y,
+                               int y0_q4,
                                int y_step_q4,
                                int w,
                                int h);
@@ -146,9 +157,10 @@
                                   ptrdiff_t src_stride,
                                   uint8_t* dst,
                                   ptrdiff_t dst_stride,
-                                  const int16_t* filter_x,
+                                  const InterpKernel* filter,
+                                  int x0_q4,
                                   int x_step_q4,
-                                  const int16_t* filter_y,
+                                  int y0_q4,
                                   int y_step_q4,
                                   int w,
                                   int h);
@@ -156,9 +168,10 @@
                                    ptrdiff_t src_stride,
                                    uint8_t* dst,
                                    ptrdiff_t dst_stride,
-                                   const int16_t* filter_x,
+                                   const InterpKernel* filter,
+                                   int x0_q4,
                                    int x_step_q4,
-                                   const int16_t* filter_y,
+                                   int y0_q4,
                                    int y_step_q4,
                                    int w,
                                    int h);
@@ -166,9 +179,10 @@
                                             ptrdiff_t src_stride,
                                             uint8_t* dst,
                                             ptrdiff_t dst_stride,
-                                            const int16_t* filter_x,
+                                            const InterpKernel* filter,
+                                            int x0_q4,
                                             int x_step_q4,
-                                            const int16_t* filter_y,
+                                            int y0_q4,
                                             int y_step_q4,
                                             int w,
                                             int h);
@@ -177,9 +191,10 @@
                               ptrdiff_t src_stride,
                               uint8_t* dst,
                               ptrdiff_t dst_stride,
-                              const int16_t* filter_x,
+                              const InterpKernel* filter,
+                              int x0_q4,
                               int x_step_q4,
-                              const int16_t* filter_y,
+                              int y0_q4,
                               int y_step_q4,
                               int w,
                               int h);
@@ -187,9 +202,10 @@
                                  ptrdiff_t src_stride,
                                  uint8_t* dst,
                                  ptrdiff_t dst_stride,
-                                 const int16_t* filter_x,
+                                 const InterpKernel* filter,
+                                 int x0_q4,
                                  int x_step_q4,
-                                 const int16_t* filter_y,
+                                 int y0_q4,
                                  int y_step_q4,
                                  int w,
                                  int h);
@@ -197,9 +213,10 @@
                                   ptrdiff_t src_stride,
                                   uint8_t* dst,
                                   ptrdiff_t dst_stride,
-                                  const int16_t* filter_x,
+                                  const InterpKernel* filter,
+                                  int x0_q4,
                                   int x_step_q4,
-                                  const int16_t* filter_y,
+                                  int y0_q4,
                                   int y_step_q4,
                                   int w,
                                   int h);
@@ -207,9 +224,10 @@
                                            ptrdiff_t src_stride,
                                            uint8_t* dst,
                                            ptrdiff_t dst_stride,
-                                           const int16_t* filter_x,
+                                           const InterpKernel* filter,
+                                           int x0_q4,
                                            int x_step_q4,
-                                           const int16_t* filter_y,
+                                           int y0_q4,
                                            int y_step_q4,
                                            int w,
                                            int h);
@@ -218,9 +236,10 @@
                            ptrdiff_t src_stride,
                            uint8_t* dst,
                            ptrdiff_t dst_stride,
-                           const int16_t* filter_x,
+                           const InterpKernel* filter,
+                           int x0_q4,
                            int x_step_q4,
-                           const int16_t* filter_y,
+                           int y0_q4,
                            int y_step_q4,
                            int w,
                            int h);
@@ -228,9 +247,10 @@
                               ptrdiff_t src_stride,
                               uint8_t* dst,
                               ptrdiff_t dst_stride,
-                              const int16_t* filter_x,
+                              const InterpKernel* filter,
+                              int x0_q4,
                               int x_step_q4,
-                              const int16_t* filter_y,
+                              int y0_q4,
                               int y_step_q4,
                               int w,
                               int h);
@@ -238,9 +258,10 @@
                                ptrdiff_t src_stride,
                                uint8_t* dst,
                                ptrdiff_t dst_stride,
-                               const int16_t* filter_x,
+                               const InterpKernel* filter,
+                               int x0_q4,
                                int x_step_q4,
-                               const int16_t* filter_y,
+                               int y0_q4,
                                int y_step_q4,
                                int w,
                                int h);
@@ -248,9 +269,10 @@
                               ptrdiff_t src_stride,
                               uint8_t* dst,
                               ptrdiff_t dst_stride,
-                              const int16_t* filter_x,
+                              const InterpKernel* filter,
+                              int x0_q4,
                               int x_step_q4,
-                              const int16_t* filter_y,
+                              int y0_q4,
                               int y_step_q4,
                               int w,
                               int h);
@@ -258,9 +280,10 @@
                                         ptrdiff_t src_stride,
                                         uint8_t* dst,
                                         ptrdiff_t dst_stride,
-                                        const int16_t* filter_x,
+                                        const InterpKernel* filter,
+                                        int x0_q4,
                                         int x_step_q4,
-                                        const int16_t* filter_y,
+                                        int y0_q4,
                                         int y_step_q4,
                                         int w,
                                         int h);
@@ -269,9 +292,10 @@
                           ptrdiff_t src_stride,
                           uint8_t* dst,
                           ptrdiff_t dst_stride,
-                          const int16_t* filter_x,
+                          const InterpKernel* filter,
+                          int x0_q4,
                           int x_step_q4,
-                          const int16_t* filter_y,
+                          int y0_q4,
                           int y_step_q4,
                           int w,
                           int h);
@@ -279,9 +303,10 @@
                              ptrdiff_t src_stride,
                              uint8_t* dst,
                              ptrdiff_t dst_stride,
-                             const int16_t* filter_x,
+                             const InterpKernel* filter,
+                             int x0_q4,
                              int x_step_q4,
-                             const int16_t* filter_y,
+                             int y0_q4,
                              int y_step_q4,
                              int w,
                              int h);
@@ -289,9 +314,10 @@
                               ptrdiff_t src_stride,
                               uint8_t* dst,
                               ptrdiff_t dst_stride,
-                              const int16_t* filter_x,
+                              const InterpKernel* filter,
+                              int x0_q4,
                               int x_step_q4,
-                              const int16_t* filter_y,
+                              int y0_q4,
                               int y_step_q4,
                               int w,
                               int h);
@@ -299,9 +325,10 @@
                              ptrdiff_t src_stride,
                              uint8_t* dst,
                              ptrdiff_t dst_stride,
-                             const int16_t* filter_x,
+                             const InterpKernel* filter,
+                             int x0_q4,
                              int x_step_q4,
-                             const int16_t* filter_y,
+                             int y0_q4,
                              int y_step_q4,
                              int w,
                              int h);
@@ -309,9 +336,10 @@
                                        ptrdiff_t src_stride,
                                        uint8_t* dst,
                                        ptrdiff_t dst_stride,
-                                       const int16_t* filter_x,
+                                       const InterpKernel* filter,
+                                       int x0_q4,
                                        int x_step_q4,
-                                       const int16_t* filter_y,
+                                       int y0_q4,
                                        int y_step_q4,
                                        int w,
                                        int h);
@@ -320,9 +348,10 @@
                         ptrdiff_t src_stride,
                         uint8_t* dst,
                         ptrdiff_t dst_stride,
-                        const int16_t* filter_x,
+                        const InterpKernel* filter,
+                        int x0_q4,
                         int x_step_q4,
-                        const int16_t* filter_y,
+                        int y0_q4,
                         int y_step_q4,
                         int w,
                         int h);
@@ -330,9 +359,10 @@
                            ptrdiff_t src_stride,
                            uint8_t* dst,
                            ptrdiff_t dst_stride,
-                           const int16_t* filter_x,
+                           const InterpKernel* filter,
+                           int x0_q4,
                            int x_step_q4,
-                           const int16_t* filter_y,
+                           int y0_q4,
                            int y_step_q4,
                            int w,
                            int h);
@@ -342,9 +372,10 @@
                          ptrdiff_t src_stride,
                          uint8_t* dst,
                          ptrdiff_t dst_stride,
-                         const int16_t* filter_x,
+                         const InterpKernel* filter,
+                         int x0_q4,
                          int x_step_q4,
-                         const int16_t* filter_y,
+                         int y0_q4,
                          int y_step_q4,
                          int w,
                          int h);
@@ -352,9 +383,10 @@
                             ptrdiff_t src_stride,
                             uint8_t* dst,
                             ptrdiff_t dst_stride,
-                            const int16_t* filter_x,
+                            const InterpKernel* filter,
+                            int x0_q4,
                             int x_step_q4,
-                            const int16_t* filter_y,
+                            int y0_q4,
                             int y_step_q4,
                             int w,
                             int h);
@@ -2895,9 +2927,10 @@
                             ptrdiff_t src_stride,
                             uint16_t* dst,
                             ptrdiff_t dst_stride,
-                            const int16_t* filter_x,
+                            const InterpKernel* filter,
+                            int x0_q4,
                             int x_step_q4,
-                            const int16_t* filter_y,
+                            int y0_q4,
                             int y_step_q4,
                             int w,
                             int h,
@@ -2906,9 +2939,10 @@
                                ptrdiff_t src_stride,
                                uint16_t* dst,
                                ptrdiff_t dst_stride,
-                               const int16_t* filter_x,
+                               const InterpKernel* filter,
+                               int x0_q4,
                                int x_step_q4,
-                               const int16_t* filter_y,
+                               int y0_q4,
                                int y_step_q4,
                                int w,
                                int h,
@@ -2917,9 +2951,10 @@
                                ptrdiff_t src_stride,
                                uint16_t* dst,
                                ptrdiff_t dst_stride,
-                               const int16_t* filter_x,
+                               const InterpKernel* filter,
+                               int x0_q4,
                                int x_step_q4,
-                               const int16_t* filter_y,
+                               int y0_q4,
                                int y_step_q4,
                                int w,
                                int h,
@@ -2928,9 +2963,10 @@
                                          ptrdiff_t src_stride,
                                          uint16_t* dst,
                                          ptrdiff_t dst_stride,
-                                         const int16_t* filter_x,
+                                         const InterpKernel* filter,
+                                         int x0_q4,
                                          int x_step_q4,
-                                         const int16_t* filter_y,
+                                         int y0_q4,
                                          int y_step_q4,
                                          int w,
                                          int h,
@@ -2940,9 +2976,10 @@
                                 ptrdiff_t src_stride,
                                 uint16_t* dst,
                                 ptrdiff_t dst_stride,
-                                const int16_t* filter_x,
+                                const InterpKernel* filter,
+                                int x0_q4,
                                 int x_step_q4,
-                                const int16_t* filter_y,
+                                int y0_q4,
                                 int y_step_q4,
                                 int w,
                                 int h,
@@ -2951,9 +2988,10 @@
                                    ptrdiff_t src_stride,
                                    uint16_t* dst,
                                    ptrdiff_t dst_stride,
-                                   const int16_t* filter_x,
+                                   const InterpKernel* filter,
+                                   int x0_q4,
                                    int x_step_q4,
-                                   const int16_t* filter_y,
+                                   int y0_q4,
                                    int y_step_q4,
                                    int w,
                                    int h,
@@ -2962,9 +3000,10 @@
                                    ptrdiff_t src_stride,
                                    uint16_t* dst,
                                    ptrdiff_t dst_stride,
-                                   const int16_t* filter_x,
+                                   const InterpKernel* filter,
+                                   int x0_q4,
                                    int x_step_q4,
-                                   const int16_t* filter_y,
+                                   int y0_q4,
                                    int y_step_q4,
                                    int w,
                                    int h,
@@ -2973,9 +3012,10 @@
                                              ptrdiff_t src_stride,
                                              uint16_t* dst,
                                              ptrdiff_t dst_stride,
-                                             const int16_t* filter_x,
+                                             const InterpKernel* filter,
+                                             int x0_q4,
                                              int x_step_q4,
-                                             const int16_t* filter_y,
+                                             int y0_q4,
                                              int y_step_q4,
                                              int w,
                                              int h,
@@ -2985,9 +3025,10 @@
                                       ptrdiff_t src_stride,
                                       uint16_t* dst,
                                       ptrdiff_t dst_stride,
-                                      const int16_t* filter_x,
+                                      const InterpKernel* filter,
+                                      int x0_q4,
                                       int x_step_q4,
-                                      const int16_t* filter_y,
+                                      int y0_q4,
                                       int y_step_q4,
                                       int w,
                                       int h,
@@ -2996,9 +3037,10 @@
                                          ptrdiff_t src_stride,
                                          uint16_t* dst,
                                          ptrdiff_t dst_stride,
-                                         const int16_t* filter_x,
+                                         const InterpKernel* filter,
+                                         int x0_q4,
                                          int x_step_q4,
-                                         const int16_t* filter_y,
+                                         int y0_q4,
                                          int y_step_q4,
                                          int w,
                                          int h,
@@ -3007,9 +3049,10 @@
                                          ptrdiff_t src_stride,
                                          uint16_t* dst,
                                          ptrdiff_t dst_stride,
-                                         const int16_t* filter_x,
+                                         const InterpKernel* filter,
+                                         int x0_q4,
                                          int x_step_q4,
-                                         const int16_t* filter_y,
+                                         int y0_q4,
                                          int y_step_q4,
                                          int w,
                                          int h,
@@ -3018,9 +3061,10 @@
                                                    ptrdiff_t src_stride,
                                                    uint16_t* dst,
                                                    ptrdiff_t dst_stride,
-                                                   const int16_t* filter_x,
+                                                   const InterpKernel* filter,
+                                                   int x0_q4,
                                                    int x_step_q4,
-                                                   const int16_t* filter_y,
+                                                   int y0_q4,
                                                    int y_step_q4,
                                                    int w,
                                                    int h,
@@ -3030,9 +3074,10 @@
                                      ptrdiff_t src_stride,
                                      uint16_t* dst,
                                      ptrdiff_t dst_stride,
-                                     const int16_t* filter_x,
+                                     const InterpKernel* filter,
+                                     int x0_q4,
                                      int x_step_q4,
-                                     const int16_t* filter_y,
+                                     int y0_q4,
                                      int y_step_q4,
                                      int w,
                                      int h,
@@ -3041,9 +3086,10 @@
                                         ptrdiff_t src_stride,
                                         uint16_t* dst,
                                         ptrdiff_t dst_stride,
-                                        const int16_t* filter_x,
+                                        const InterpKernel* filter,
+                                        int x0_q4,
                                         int x_step_q4,
-                                        const int16_t* filter_y,
+                                        int y0_q4,
                                         int y_step_q4,
                                         int w,
                                         int h,
@@ -3052,9 +3098,10 @@
                                         ptrdiff_t src_stride,
                                         uint16_t* dst,
                                         ptrdiff_t dst_stride,
-                                        const int16_t* filter_x,
+                                        const InterpKernel* filter,
+                                        int x0_q4,
                                         int x_step_q4,
-                                        const int16_t* filter_y,
+                                        int y0_q4,
                                         int y_step_q4,
                                         int w,
                                         int h,
@@ -3063,9 +3110,10 @@
                                                   ptrdiff_t src_stride,
                                                   uint16_t* dst,
                                                   ptrdiff_t dst_stride,
-                                                  const int16_t* filter_x,
+                                                  const InterpKernel* filter,
+                                                  int x0_q4,
                                                   int x_step_q4,
-                                                  const int16_t* filter_y,
+                                                  int y0_q4,
                                                   int y_step_q4,
                                                   int w,
                                                   int h,
@@ -3075,9 +3123,10 @@
                                   ptrdiff_t src_stride,
                                   uint16_t* dst,
                                   ptrdiff_t dst_stride,
-                                  const int16_t* filter_x,
+                                  const InterpKernel* filter,
+                                  int x0_q4,
                                   int x_step_q4,
-                                  const int16_t* filter_y,
+                                  int y0_q4,
                                   int y_step_q4,
                                   int w,
                                   int h,
@@ -3086,9 +3135,10 @@
                                      ptrdiff_t src_stride,
                                      uint16_t* dst,
                                      ptrdiff_t dst_stride,
-                                     const int16_t* filter_x,
+                                     const InterpKernel* filter,
+                                     int x0_q4,
                                      int x_step_q4,
-                                     const int16_t* filter_y,
+                                     int y0_q4,
                                      int y_step_q4,
                                      int w,
                                      int h,
@@ -3097,9 +3147,10 @@
                                      ptrdiff_t src_stride,
                                      uint16_t* dst,
                                      ptrdiff_t dst_stride,
-                                     const int16_t* filter_x,
+                                     const InterpKernel* filter,
+                                     int x0_q4,
                                      int x_step_q4,
-                                     const int16_t* filter_y,
+                                     int y0_q4,
                                      int y_step_q4,
                                      int w,
                                      int h,
@@ -3108,9 +3159,10 @@
                                                ptrdiff_t src_stride,
                                                uint16_t* dst,
                                                ptrdiff_t dst_stride,
-                                               const int16_t* filter_x,
+                                               const InterpKernel* filter,
+                                               int x0_q4,
                                                int x_step_q4,
-                                               const int16_t* filter_y,
+                                               int y0_q4,
                                                int y_step_q4,
                                                int w,
                                                int h,
@@ -3120,9 +3172,10 @@
                                  ptrdiff_t src_stride,
                                  uint16_t* dst,
                                  ptrdiff_t dst_stride,
-                                 const int16_t* filter_x,
+                                 const InterpKernel* filter,
+                                 int x0_q4,
                                  int x_step_q4,
-                                 const int16_t* filter_y,
+                                 int y0_q4,
                                  int y_step_q4,
                                  int w,
                                  int h,
@@ -3131,9 +3184,10 @@
                                     ptrdiff_t src_stride,
                                     uint16_t* dst,
                                     ptrdiff_t dst_stride,
-                                    const int16_t* filter_x,
+                                    const InterpKernel* filter,
+                                    int x0_q4,
                                     int x_step_q4,
-                                    const int16_t* filter_y,
+                                    int y0_q4,
                                     int y_step_q4,
                                     int w,
                                     int h,
@@ -3142,9 +3196,10 @@
                                     ptrdiff_t src_stride,
                                     uint16_t* dst,
                                     ptrdiff_t dst_stride,
-                                    const int16_t* filter_x,
+                                    const InterpKernel* filter,
+                                    int x0_q4,
                                     int x_step_q4,
-                                    const int16_t* filter_y,
+                                    int y0_q4,
                                     int y_step_q4,
                                     int w,
                                     int h,
@@ -3153,9 +3208,10 @@
                                               ptrdiff_t src_stride,
                                               uint16_t* dst,
                                               ptrdiff_t dst_stride,
-                                              const int16_t* filter_x,
+                                              const InterpKernel* filter,
+                                              int x0_q4,
                                               int x_step_q4,
-                                              const int16_t* filter_y,
+                                              int y0_q4,
                                               int y_step_q4,
                                               int w,
                                               int h,
@@ -3165,9 +3221,10 @@
                                ptrdiff_t src_stride,
                                uint16_t* dst,
                                ptrdiff_t dst_stride,
-                               const int16_t* filter_x,
+                               const InterpKernel* filter,
+                               int x0_q4,
                                int x_step_q4,
-                               const int16_t* filter_y,
+                               int y0_q4,
                                int y_step_q4,
                                int w,
                                int h,
@@ -3176,9 +3233,10 @@
                                   ptrdiff_t src_stride,
                                   uint16_t* dst,
                                   ptrdiff_t dst_stride,
-                                  const int16_t* filter_x,
+                                  const InterpKernel* filter,
+                                  int x0_q4,
                                   int x_step_q4,
-                                  const int16_t* filter_y,
+                                  int y0_q4,
                                   int y_step_q4,
                                   int w,
                                   int h,
@@ -3187,9 +3245,10 @@
                                   ptrdiff_t src_stride,
                                   uint16_t* dst,
                                   ptrdiff_t dst_stride,
-                                  const int16_t* filter_x,
+                                  const InterpKernel* filter,
+                                  int x0_q4,
                                   int x_step_q4,
-                                  const int16_t* filter_y,
+                                  int y0_q4,
                                   int y_step_q4,
                                   int w,
                                   int h,
@@ -3198,9 +3257,10 @@
                                             ptrdiff_t src_stride,
                                             uint16_t* dst,
                                             ptrdiff_t dst_stride,
-                                            const int16_t* filter_x,
+                                            const InterpKernel* filter,
+                                            int x0_q4,
                                             int x_step_q4,
-                                            const int16_t* filter_y,
+                                            int y0_q4,
                                             int y_step_q4,
                                             int w,
                                             int h,
@@ -3210,9 +3270,10 @@
                                 ptrdiff_t src_stride,
                                 uint16_t* dst,
                                 ptrdiff_t dst_stride,
-                                const int16_t* filter_x,
+                                const InterpKernel* filter,
+                                int x0_q4,
                                 int x_step_q4,
-                                const int16_t* filter_y,
+                                int y0_q4,
                                 int y_step_q4,
                                 int w,
                                 int h,
@@ -3221,9 +3282,10 @@
                                    ptrdiff_t src_stride,
                                    uint16_t* dst,
                                    ptrdiff_t dst_stride,
-                                   const int16_t* filter_x,
+                                   const InterpKernel* filter,
+                                   int x0_q4,
                                    int x_step_q4,
-                                   const int16_t* filter_y,
+                                   int y0_q4,
                                    int y_step_q4,
                                    int w,
                                    int h,
@@ -3232,9 +3294,10 @@
                                    ptrdiff_t src_stride,
                                    uint16_t* dst,
                                    ptrdiff_t dst_stride,
-                                   const int16_t* filter_x,
+                                   const InterpKernel* filter,
+                                   int x0_q4,
                                    int x_step_q4,
-                                   const int16_t* filter_y,
+                                   int y0_q4,
                                    int y_step_q4,
                                    int w,
                                    int h,
@@ -3243,9 +3306,10 @@
                                              ptrdiff_t src_stride,
                                              uint16_t* dst,
                                              ptrdiff_t dst_stride,
-                                             const int16_t* filter_x,
+                                             const InterpKernel* filter,
+                                             int x0_q4,
                                              int x_step_q4,
-                                             const int16_t* filter_y,
+                                             int y0_q4,
                                              int y_step_q4,
                                              int w,
                                              int h,
@@ -3424,56 +3488,98 @@
                                          const uint16_t* above,
                                          const uint16_t* left,
                                          int bd);
-#define vpx_highbd_dc_128_predictor_16x16 vpx_highbd_dc_128_predictor_16x16_c
+void vpx_highbd_dc_128_predictor_16x16_sse2(uint16_t* dst,
+                                            ptrdiff_t y_stride,
+                                            const uint16_t* above,
+                                            const uint16_t* left,
+                                            int bd);
+#define vpx_highbd_dc_128_predictor_16x16 vpx_highbd_dc_128_predictor_16x16_sse2
 
 void vpx_highbd_dc_128_predictor_32x32_c(uint16_t* dst,
                                          ptrdiff_t y_stride,
                                          const uint16_t* above,
                                          const uint16_t* left,
                                          int bd);
-#define vpx_highbd_dc_128_predictor_32x32 vpx_highbd_dc_128_predictor_32x32_c
+void vpx_highbd_dc_128_predictor_32x32_sse2(uint16_t* dst,
+                                            ptrdiff_t y_stride,
+                                            const uint16_t* above,
+                                            const uint16_t* left,
+                                            int bd);
+#define vpx_highbd_dc_128_predictor_32x32 vpx_highbd_dc_128_predictor_32x32_sse2
 
 void vpx_highbd_dc_128_predictor_4x4_c(uint16_t* dst,
                                        ptrdiff_t y_stride,
                                        const uint16_t* above,
                                        const uint16_t* left,
                                        int bd);
-#define vpx_highbd_dc_128_predictor_4x4 vpx_highbd_dc_128_predictor_4x4_c
+void vpx_highbd_dc_128_predictor_4x4_sse2(uint16_t* dst,
+                                          ptrdiff_t y_stride,
+                                          const uint16_t* above,
+                                          const uint16_t* left,
+                                          int bd);
+#define vpx_highbd_dc_128_predictor_4x4 vpx_highbd_dc_128_predictor_4x4_sse2
 
 void vpx_highbd_dc_128_predictor_8x8_c(uint16_t* dst,
                                        ptrdiff_t y_stride,
                                        const uint16_t* above,
                                        const uint16_t* left,
                                        int bd);
-#define vpx_highbd_dc_128_predictor_8x8 vpx_highbd_dc_128_predictor_8x8_c
+void vpx_highbd_dc_128_predictor_8x8_sse2(uint16_t* dst,
+                                          ptrdiff_t y_stride,
+                                          const uint16_t* above,
+                                          const uint16_t* left,
+                                          int bd);
+#define vpx_highbd_dc_128_predictor_8x8 vpx_highbd_dc_128_predictor_8x8_sse2
 
 void vpx_highbd_dc_left_predictor_16x16_c(uint16_t* dst,
                                           ptrdiff_t y_stride,
                                           const uint16_t* above,
                                           const uint16_t* left,
                                           int bd);
-#define vpx_highbd_dc_left_predictor_16x16 vpx_highbd_dc_left_predictor_16x16_c
+void vpx_highbd_dc_left_predictor_16x16_sse2(uint16_t* dst,
+                                             ptrdiff_t y_stride,
+                                             const uint16_t* above,
+                                             const uint16_t* left,
+                                             int bd);
+#define vpx_highbd_dc_left_predictor_16x16 \
+  vpx_highbd_dc_left_predictor_16x16_sse2
 
 void vpx_highbd_dc_left_predictor_32x32_c(uint16_t* dst,
                                           ptrdiff_t y_stride,
                                           const uint16_t* above,
                                           const uint16_t* left,
                                           int bd);
-#define vpx_highbd_dc_left_predictor_32x32 vpx_highbd_dc_left_predictor_32x32_c
+void vpx_highbd_dc_left_predictor_32x32_sse2(uint16_t* dst,
+                                             ptrdiff_t y_stride,
+                                             const uint16_t* above,
+                                             const uint16_t* left,
+                                             int bd);
+#define vpx_highbd_dc_left_predictor_32x32 \
+  vpx_highbd_dc_left_predictor_32x32_sse2
 
 void vpx_highbd_dc_left_predictor_4x4_c(uint16_t* dst,
                                         ptrdiff_t y_stride,
                                         const uint16_t* above,
                                         const uint16_t* left,
                                         int bd);
-#define vpx_highbd_dc_left_predictor_4x4 vpx_highbd_dc_left_predictor_4x4_c
+void vpx_highbd_dc_left_predictor_4x4_sse2(uint16_t* dst,
+                                           ptrdiff_t y_stride,
+                                           const uint16_t* above,
+                                           const uint16_t* left,
+                                           int bd);
+#define vpx_highbd_dc_left_predictor_4x4 vpx_highbd_dc_left_predictor_4x4_sse2
 
 void vpx_highbd_dc_left_predictor_8x8_c(uint16_t* dst,
                                         ptrdiff_t y_stride,
                                         const uint16_t* above,
                                         const uint16_t* left,
                                         int bd);
-#define vpx_highbd_dc_left_predictor_8x8 vpx_highbd_dc_left_predictor_8x8_c
+void vpx_highbd_dc_left_predictor_8x8_sse2(uint16_t* dst,
+                                           ptrdiff_t y_stride,
+                                           const uint16_t* above,
+                                           const uint16_t* left,
+                                           int bd);
+#define vpx_highbd_dc_left_predictor_8x8 vpx_highbd_dc_left_predictor_8x8_sse2
 
 void vpx_highbd_dc_predictor_16x16_c(uint16_t* dst,
                                      ptrdiff_t y_stride,
@@ -3528,28 +3634,48 @@
                                          const uint16_t* above,
                                          const uint16_t* left,
                                          int bd);
-#define vpx_highbd_dc_top_predictor_16x16 vpx_highbd_dc_top_predictor_16x16_c
+void vpx_highbd_dc_top_predictor_16x16_sse2(uint16_t* dst,
+                                            ptrdiff_t y_stride,
+                                            const uint16_t* above,
+                                            const uint16_t* left,
+                                            int bd);
+#define vpx_highbd_dc_top_predictor_16x16 vpx_highbd_dc_top_predictor_16x16_sse2
 
 void vpx_highbd_dc_top_predictor_32x32_c(uint16_t* dst,
                                          ptrdiff_t y_stride,
                                          const uint16_t* above,
                                          const uint16_t* left,
                                          int bd);
-#define vpx_highbd_dc_top_predictor_32x32 vpx_highbd_dc_top_predictor_32x32_c
+void vpx_highbd_dc_top_predictor_32x32_sse2(uint16_t* dst,
+                                            ptrdiff_t y_stride,
+                                            const uint16_t* above,
+                                            const uint16_t* left,
+                                            int bd);
+#define vpx_highbd_dc_top_predictor_32x32 vpx_highbd_dc_top_predictor_32x32_sse2
 
 void vpx_highbd_dc_top_predictor_4x4_c(uint16_t* dst,
                                        ptrdiff_t y_stride,
                                        const uint16_t* above,
                                        const uint16_t* left,
                                        int bd);
-#define vpx_highbd_dc_top_predictor_4x4 vpx_highbd_dc_top_predictor_4x4_c
+void vpx_highbd_dc_top_predictor_4x4_sse2(uint16_t* dst,
+                                          ptrdiff_t y_stride,
+                                          const uint16_t* above,
+                                          const uint16_t* left,
+                                          int bd);
+#define vpx_highbd_dc_top_predictor_4x4 vpx_highbd_dc_top_predictor_4x4_sse2
 
 void vpx_highbd_dc_top_predictor_8x8_c(uint16_t* dst,
                                        ptrdiff_t y_stride,
                                        const uint16_t* above,
                                        const uint16_t* left,
                                        int bd);
-#define vpx_highbd_dc_top_predictor_8x8 vpx_highbd_dc_top_predictor_8x8_c
+void vpx_highbd_dc_top_predictor_8x8_sse2(uint16_t* dst,
+                                          ptrdiff_t y_stride,
+                                          const uint16_t* above,
+                                          const uint16_t* left,
+                                          int bd);
+#define vpx_highbd_dc_top_predictor_8x8 vpx_highbd_dc_top_predictor_8x8_sse2
 
 void vpx_highbd_fdct16x16_c(const int16_t* input,
                             tran_low_t* output,
@@ -3607,28 +3733,48 @@
                                     const uint16_t* above,
                                     const uint16_t* left,
                                     int bd);
-#define vpx_highbd_h_predictor_16x16 vpx_highbd_h_predictor_16x16_c
+void vpx_highbd_h_predictor_16x16_sse2(uint16_t* dst,
+                                       ptrdiff_t y_stride,
+                                       const uint16_t* above,
+                                       const uint16_t* left,
+                                       int bd);
+#define vpx_highbd_h_predictor_16x16 vpx_highbd_h_predictor_16x16_sse2
 
 void vpx_highbd_h_predictor_32x32_c(uint16_t* dst,
                                     ptrdiff_t y_stride,
                                     const uint16_t* above,
                                     const uint16_t* left,
                                     int bd);
-#define vpx_highbd_h_predictor_32x32 vpx_highbd_h_predictor_32x32_c
+void vpx_highbd_h_predictor_32x32_sse2(uint16_t* dst,
+                                       ptrdiff_t y_stride,
+                                       const uint16_t* above,
+                                       const uint16_t* left,
+                                       int bd);
+#define vpx_highbd_h_predictor_32x32 vpx_highbd_h_predictor_32x32_sse2
 
 void vpx_highbd_h_predictor_4x4_c(uint16_t* dst,
                                   ptrdiff_t y_stride,
                                   const uint16_t* above,
                                   const uint16_t* left,
                                   int bd);
-#define vpx_highbd_h_predictor_4x4 vpx_highbd_h_predictor_4x4_c
+void vpx_highbd_h_predictor_4x4_sse2(uint16_t* dst,
+                                     ptrdiff_t y_stride,
+                                     const uint16_t* above,
+                                     const uint16_t* left,
+                                     int bd);
+#define vpx_highbd_h_predictor_4x4 vpx_highbd_h_predictor_4x4_sse2
 
 void vpx_highbd_h_predictor_8x8_c(uint16_t* dst,
                                   ptrdiff_t y_stride,
                                   const uint16_t* above,
                                   const uint16_t* left,
                                   int bd);
-#define vpx_highbd_h_predictor_8x8 vpx_highbd_h_predictor_8x8_c
+void vpx_highbd_h_predictor_8x8_sse2(uint16_t* dst,
+                                     ptrdiff_t y_stride,
+                                     const uint16_t* above,
+                                     const uint16_t* left,
+                                     int bd);
+#define vpx_highbd_h_predictor_8x8 vpx_highbd_h_predictor_8x8_sse2
 
 void vpx_highbd_idct16x16_10_add_c(const tran_low_t* input,
                                    uint16_t* dest,
@@ -5891,9 +6037,10 @@
                      ptrdiff_t src_stride,
                      uint8_t* dst,
                      ptrdiff_t dst_stride,
-                     const int16_t* filter_x,
+                     const InterpKernel* filter,
+                     int x0_q4,
                      int x_step_q4,
-                     const int16_t* filter_y,
+                     int y0_q4,
                      int y_step_q4,
                      int w,
                      int h);
@@ -5901,9 +6048,10 @@
                          ptrdiff_t src_stride,
                          uint8_t* dst,
                          ptrdiff_t dst_stride,
-                         const int16_t* filter_x,
+                         const InterpKernel* filter,
+                         int x0_q4,
                          int x_step_q4,
-                         const int16_t* filter_y,
+                         int y0_q4,
                          int y_step_q4,
                          int w,
                          int h);
@@ -5911,9 +6059,10 @@
                                   ptrdiff_t src_stride,
                                   uint8_t* dst,
                                   ptrdiff_t dst_stride,
-                                  const int16_t* filter_x,
+                                  const InterpKernel* filter,
+                                  int x0_q4,
                                   int x_step_q4,
-                                  const int16_t* filter_y,
+                                  int y0_q4,
                                   int y_step_q4,
                                   int w,
                                   int h);
@@ -5922,9 +6071,10 @@
                          ptrdiff_t src_stride,
                          uint8_t* dst,
                          ptrdiff_t dst_stride,
-                         const int16_t* filter_x,
+                         const InterpKernel* filter,
+                         int x0_q4,
                          int x_step_q4,
-                         const int16_t* filter_y,
+                         int y0_q4,
                          int y_step_q4,
                          int w,
                          int h);
@@ -5934,9 +6084,10 @@
                             ptrdiff_t src_stride,
                             uint8_t* dst,
                             ptrdiff_t dst_stride,
-                            const int16_t* filter_x,
+                            const InterpKernel* filter,
+                            int x0_q4,
                             int x_step_q4,
-                            const int16_t* filter_y,
+                            int y0_q4,
                             int y_step_q4,
                             int w,
                             int h);
@@ -5946,9 +6097,10 @@
                            ptrdiff_t src_stride,
                            uint8_t* dst,
                            ptrdiff_t dst_stride,
-                           const int16_t* filter_x,
+                           const InterpKernel* filter,
+                           int x0_q4,
                            int x_step_q4,
-                           const int16_t* filter_y,
+                           int y0_q4,
                            int y_step_q4,
                            int w,
                            int h);
@@ -5958,9 +6110,10 @@
                         ptrdiff_t src_stride,
                         uint8_t* dst,
                         ptrdiff_t dst_stride,
-                        const int16_t* filter_x,
+                        const InterpKernel* filter,
+                        int x0_q4,
                         int x_step_q4,
-                        const int16_t* filter_y,
+                        int y0_q4,
                         int y_step_q4,
                         int w,
                         int h);
@@ -5970,9 +6123,10 @@
                        ptrdiff_t src_stride,
                        uint8_t* dst,
                        ptrdiff_t dst_stride,
-                       const int16_t* filter_x,
+                       const InterpKernel* filter,
+                       int x0_q4,
                        int x_step_q4,
-                       const int16_t* filter_y,
+                       int y0_q4,
                        int y_step_q4,
                        int w,
                        int h);
diff --git a/tools/metrics/histograms/enums.xml b/tools/metrics/histograms/enums.xml
index 6b63576..acfe9a1b 100644
--- a/tools/metrics/histograms/enums.xml
+++ b/tools/metrics/histograms/enums.xml
@@ -19291,7 +19291,7 @@
              AMD"/>
 </enum>
 
-<enum name="GpuImageUsageState">
+<enum name="GpuImageDecodeState">
   <int value="0" label="Wasted, once"/>
   <int value="1" label="Used, once"/>
   <int value="2" label="Wasted, relocked"/>
@@ -30799,6 +30799,12 @@
   <int value="11" label="Bad Key Validation Signature"/>
 </enum>
 
+<enum name="PopupBlockerAction">
+  <int value="0" label="Popup initiated"/>
+  <int value="1" label="Popup blocked"/>
+  <int value="2" label="Popup clicked through"/>
+</enum>
+
 <enum name="PopupPosition">
   <int value="0" label="Only popup"/>
   <int value="1" label="First popup"/>
diff --git a/tools/metrics/histograms/histograms.xml b/tools/metrics/histograms/histograms.xml
index 41f83cb..db405a9 100644
--- a/tools/metrics/histograms/histograms.xml
+++ b/tools/metrics/histograms/histograms.xml
@@ -10268,6 +10268,17 @@
   </summary>
 </histogram>
 
+<histogram name="ContentSettings.Popups.BlockerActions"
+    enum="PopupBlockerAction">
+  <owner>csharrison@chromium.org</owner>
+  <summary>
+    Counts of various events related to the popup blocker. Including blocked
+    popups and overridden (clicked through) popups. This is similar to the
+    ContentSettings.Popups but is at the per-popup layer rather than at the UI
+    layer.
+  </summary>
+</histogram>
+
 <histogram name="ContentSettings.Popups.ClickThroughPosition"
     enum="PopupPosition">
   <owner>csharrison@chromium.org</owner>
@@ -10281,6 +10292,16 @@
   </summary>
 </histogram>
 
+<histogram name="ContentSettings.Popups.FirstDocumentEngagementTime" units="ms">
+  <owner>csharrison@chromium.org</owner>
+  <summary>
+    Measures the total duration a popup WebContents is visible / foregrounded
+    for the duration of its first document load. This time is measured from the
+    first navigation commit to the time either the WebContents is destroyed or
+    when a new navigation commits.
+  </summary>
+</histogram>
+
 <histogram name="ContextMenu.SaveLinkType" enum="ContextMenuSaveLinkType">
   <owner>qinmin@chromium.org</owner>
   <summary>
@@ -64670,7 +64691,7 @@
   </summary>
 </histogram>
 
-<histogram name="Renderer4.GpuImageDecodeState" enum="GpuImageUsageState">
+<histogram name="Renderer4.GpuImageDecodeState" enum="GpuImageDecodeState">
   <owner>vmpstr@chromium.org</owner>
   <summary>
     Gpu image decode usage statistics. Images are decoded and locked prior to
@@ -64688,29 +64709,8 @@
   </summary>
 </histogram>
 
-<histogram name="Renderer4.GpuImageUploadState" enum="GpuImageUsageState">
-  <owner>ericrk@chromium.org</owner>
-  <summary>
-    Gpu image upload usage statistics. Images are uploaded and locked prior to
-    use; this indicates how that upload is used during tile management.
-  </summary>
-</histogram>
-
-<histogram name="Renderer4.GpuImageUploadState.FirstLockWasted"
-    enum="BooleanWasted">
-  <owner>ericrk@chromium.org</owner>
-  <summary>
-    Indication whether the first lock of an image upload was wasted (image was
-    not used). Images are uploaded and locked prior to raster; this indicates
-    whether the upload was used or not during the first lock.
-  </summary>
-</histogram>
-
 <histogram name="Renderer4.GpuImageUploadState.FirstRefWasted"
     enum="BooleanWasted">
-  <obsolete>
-    Deprecated as of 06/2017.  No longer generated.
-  </obsolete>
   <owner>vmpstr@chromium.org</owner>
   <summary>
     Indication whether the first ref of a GPU image upload was wasted (not used
@@ -64720,9 +64720,6 @@
 </histogram>
 
 <histogram name="Renderer4.GpuImageUploadState.Used" enum="BooleanUsage">
-  <obsolete>
-    Deprecated as of 06/2017.  No longer generated.
-  </obsolete>
   <owner>vmpstr@chromium.org</owner>
   <summary>
     Indication whether the GPU image upload was used in raster. Images are
diff --git a/tools/perf/benchmarks/blink_perf.py b/tools/perf/benchmarks/blink_perf.py
index ac3efb6..f2fd033d 100644
--- a/tools/perf/benchmarks/blink_perf.py
+++ b/tools/perf/benchmarks/blink_perf.py
@@ -302,13 +302,13 @@
     trace_cpu_time_metrics = {}
     if tab.EvaluateJavaScript('testRunner.isWaitingForTracingStart'):
       trace_data = self._ContinueTestRunWithTracing(tab)
-      # TODO(#763375): Rely on results.telemetry_info.file_path/etc.
+      # TODO(#763375): Rely on results.telemetry_info.trace_local_path/etc.
       kwargs = {}
-      if hasattr(results.telemetry_info, 'file_path'):
-        kwargs['file_path'] = results.telemetry_info.file_path
-        kwargs['remote_path'] = results.telemetry_info.remote_path
+      if hasattr(results.telemetry_info, 'trace_local_path'):
+        kwargs['file_path'] = results.telemetry_info.trace_local_path
+        kwargs['remote_path'] = results.telemetry_info.trace_remote_path
         kwargs['upload_bucket'] = results.telemetry_info.upload_bucket
-        kwargs['cloud_url'] = results.telemetry_info.cloud_url
+        kwargs['cloud_url'] = results.telemetry_info.trace_remote_url
       trace_value = trace.TraceValue(page, trace_data, **kwargs)
       results.AddValue(trace_value)
 
diff --git a/tools/perf/measurements/timeline_controller.py b/tools/perf/measurements/timeline_controller.py
index 104ea9b..14c850a 100644
--- a/tools/perf/measurements/timeline_controller.py
+++ b/tools/perf/measurements/timeline_controller.py
@@ -54,13 +54,13 @@
     # Stop tracing.
     timeline_data = tab.browser.platform.tracing_controller.StopTracing()
 
-    # TODO(#763375): Rely on results.telemetry_info.file_path/etc.
+    # TODO(#763375): Rely on results.telemetry_info.trace_local_path/etc.
     kwargs = {}
-    if hasattr(results.telemetry_info, 'file_path'):
-      kwargs['file_path'] = results.telemetry_info.file_path
-      kwargs['remote_path'] = results.telemetry_info.remote_path
+    if hasattr(results.telemetry_info, 'trace_local_path'):
+      kwargs['file_path'] = results.telemetry_info.trace_local_path
+      kwargs['remote_path'] = results.telemetry_info.trace_remote_path
       kwargs['upload_bucket'] = results.telemetry_info.upload_bucket
-      kwargs['cloud_url'] = results.telemetry_info.cloud_url
+      kwargs['cloud_url'] = results.telemetry_info.trace_remote_url
     results.AddValue(trace.TraceValue(
         results.current_page, timeline_data, **kwargs))
 
diff --git a/ui/views/accessibility/ax_view_obj_wrapper.cc b/ui/views/accessibility/ax_view_obj_wrapper.cc
index e636e34..974f2a5 100644
--- a/ui/views/accessibility/ax_view_obj_wrapper.cc
+++ b/ui/views/accessibility/ax_view_obj_wrapper.cc
@@ -55,6 +55,13 @@
   if (!view_->visible())
     out_node_data->AddState(ui::AX_STATE_INVISIBLE);
 
+  if (!out_node_data->HasStringAttribute(ui::AX_ATTR_DESCRIPTION)) {
+    base::string16 description;
+    view_->GetTooltipText(gfx::Point(), &description);
+    out_node_data->AddStringAttribute(ui::AX_ATTR_DESCRIPTION,
+                                      base::UTF16ToUTF8(description));
+  }
+
   out_node_data->location = gfx::RectF(view_->GetBoundsInScreen());
 }