aboutsummaryrefslogtreecommitdiffhomepage
diff options
context:
space:
mode:
-rw-r--r--infra/bots/recipe_modules/sktest/api.py1
-rw-r--r--infra/bots/recipe_modules/sktest/example.expected/Test-Win10-MSVC-AlphaR2-GPU-RadeonR9M470X-x86_64-Debug-Vulkan.json1
-rw-r--r--src/gpu/vk/GrVkImage.cpp11
3 files changed, 6 insertions, 7 deletions
diff --git a/infra/bots/recipe_modules/sktest/api.py b/infra/bots/recipe_modules/sktest/api.py
index 8a2eee7e31..73df2c3fa4 100644
--- a/infra/bots/recipe_modules/sktest/api.py
+++ b/infra/bots/recipe_modules/sktest/api.py
@@ -401,7 +401,6 @@ def dm_flags(bot):
match.append('~ComposedImageFilterBounds_Gpu')
match.append('~CopySurface')
match.append('~ImageFilterZeroBlurSigma_Gpu')
- match.append('~ReadWriteAlpha')
match.append('~XfermodeImageFilterCroppedInput_Gpu')
if 'Vulkan' in bot and 'IntelIris540' in bot and 'Ubuntu' in bot:
diff --git a/infra/bots/recipe_modules/sktest/example.expected/Test-Win10-MSVC-AlphaR2-GPU-RadeonR9M470X-x86_64-Debug-Vulkan.json b/infra/bots/recipe_modules/sktest/example.expected/Test-Win10-MSVC-AlphaR2-GPU-RadeonR9M470X-x86_64-Debug-Vulkan.json
index 4c69425f24..71576986ce 100644
--- a/infra/bots/recipe_modules/sktest/example.expected/Test-Win10-MSVC-AlphaR2-GPU-RadeonR9M470X-x86_64-Debug-Vulkan.json
+++ b/infra/bots/recipe_modules/sktest/example.expected/Test-Win10-MSVC-AlphaR2-GPU-RadeonR9M470X-x86_64-Debug-Vulkan.json
@@ -373,7 +373,6 @@
"~ComposedImageFilterBounds_Gpu",
"~CopySurface",
"~ImageFilterZeroBlurSigma_Gpu",
- "~ReadWriteAlpha",
"~XfermodeImageFilterCroppedInput_Gpu"
],
"env": {
diff --git a/src/gpu/vk/GrVkImage.cpp b/src/gpu/vk/GrVkImage.cpp
index d0457ca28b..c3302a2b04 100644
--- a/src/gpu/vk/GrVkImage.cpp
+++ b/src/gpu/vk/GrVkImage.cpp
@@ -33,11 +33,12 @@ void GrVkImage::setImageLayout(const GrVkGpu* gpu, VkImageLayout newLayout,
VK_IMAGE_LAYOUT_PREINITIALIZED != newLayout);
VkImageLayout currentLayout = this->currentLayout();
- // If the old and new layout are the same, there is no reason to put in a barrier since the
- // operations used for each layout are implicitly synchronized with eachother. The one exception
- // is if the layout is GENERAL. In this case the image could have been used for any operation so
- // we must respect the barrier.
- if (newLayout == currentLayout && VK_IMAGE_LAYOUT_GENERAL != currentLayout) {
+ // If the old and new layout are the same and the layout is a read only layout, there is no need
+ // to put in a barrier.
+ if (newLayout == currentLayout &&
+ (VK_IMAGE_LAYOUT_DEPTH_STENCIL_READ_ONLY_OPTIMAL == currentLayout ||
+ VK_IMAGE_LAYOUT_SHADER_READ_ONLY_OPTIMAL == currentLayout ||
+ VK_IMAGE_LAYOUT_TRANSFER_SRC_OPTIMAL == currentLayout)) {
return;
}