Commit f884c331 authored by Xida Chen's avatar Xida Chen Committed by Commit Bot

[OT-PW] Fix some crash layout test

There are 3 layout tests that crashes with off-thread paint worklet.
The reason is that these tests are checking paint invalidation and have
a special code path that never goes to the compositor thread. So for
these tests, we should just fall to the main thread.

Bug: 990382
Change-Id: I389b991da4469e4ba965e1390f4bcc2d3800e2b1
Reviewed-on: https://chromium-review.googlesource.com/c/chromium/src/+/1789828Reviewed-by: default avatarPhilip Rogers <pdr@chromium.org>
Reviewed-by: default avatarStephen McGruer <smcgruer@chromium.org>
Commit-Queue: Xida Chen <xidachen@chromium.org>
Cr-Commit-Position: refs/heads/master@{#702120}
parent c1b20814
......@@ -1256,7 +1256,11 @@ void DrawImageRectOp::RasterWithFlags(const DrawImageRectOp* op,
// TODO(crbug.com/931704): make sure to support the case where paint worklet
// generated images are used in other raster work such as canvas2d.
if (op->image.IsPaintWorklet()) {
DCHECK(params.image_provider);
// When rasterizing on the main thread (e.g. paint invalidation checking,
// see https://crbug.com/990382), an image provider may not be available, so
// we should draw nothing.
if (!params.image_provider)
return;
ImageProvider::ScopedResult result =
params.image_provider->GetRasterContent(DrawImage(op->image));
......
......@@ -4262,10 +4262,6 @@ crbug.com/626703 [ Linux Mac10.10 ] virtual/cross-origin-embedder-policy/externa
# Failure due to on-going off-thread paint worklet project.
crbug.com/957457 virtual/threaded/external/wpt/css/css-paint-api/invalid-image-pending-script.https.html [ Crash ]
crbug.com/990382 virtual/threaded/http/tests/csspaint/invalidation-content-image.html [ Crash ]
crbug.com/990382 virtual/threaded/http/tests/csspaint/invalidation-background-image.html [ Crash ]
crbug.com/990382 virtual/threaded/http/tests/csspaint/invalidation-border-image.html [ Crash ]
crbug.com/982116 http/tests/devtools/elements/styles-4/styles-new-API.js [ Pass Timeout ]
# Shared memory growth temporarily disabled.
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment