Fix: alloc_callback_fail.render_pass test
authorArkadiusz Sarwa <arkadiusz.sarwa@amd.com>
Wed, 28 Nov 2018 16:23:32 +0000 (17:23 +0100)
committerAlexander Galazin <Alexander.Galazin@arm.com>
Fri, 30 Nov 2018 09:54:37 +0000 (04:54 -0500)
Test does not use the created allocator and always reports
quality error.

Components: Vulkan

Affects: dEQP-VK.api.object_management.alloc_callback_fail.render_pass

VK-GL-CTS issue: 1488

Change-Id: I18b87dec78e1c50cb8caf6d2e5acdeec42b05dd6

external/vulkancts/framework/vulkan/vkObjUtil.cpp
external/vulkancts/framework/vulkan/vkObjUtil.hpp
external/vulkancts/modules/vulkan/api/vktApiObjectManagementTests.cpp

index ae1950b..fb28474 100644 (file)
@@ -376,15 +376,16 @@ Move<VkPipeline> makeGraphicsPipeline (const DeviceInterface&                                                     vk,
        return createGraphicsPipeline(vk, device, DE_NULL, &pipelineCreateInfo);
 }
 
-Move<VkRenderPass> makeRenderPass (const DeviceInterface&              vk,
-                                                                  const VkDevice                               device,
-                                                                  const VkFormat                               colorFormat,
-                                                                  const VkFormat                               depthStencilFormat,
-                                                                  const VkAttachmentLoadOp             loadOperation,
-                                                                  const VkImageLayout                  finalLayoutColor,
-                                                                  const VkImageLayout                  finalLayoutDepthStencil,
-                                                                  const VkImageLayout                  subpassLayoutColor,
-                                                                  const VkImageLayout                  subpassLayoutDepthStencil)
+Move<VkRenderPass> makeRenderPass (const DeviceInterface&                              vk,
+                                                                  const VkDevice                                               device,
+                                                                  const VkFormat                                               colorFormat,
+                                                                  const VkFormat                                               depthStencilFormat,
+                                                                  const VkAttachmentLoadOp                             loadOperation,
+                                                                  const VkImageLayout                                  finalLayoutColor,
+                                                                  const VkImageLayout                                  finalLayoutDepthStencil,
+                                                                  const VkImageLayout                                  subpassLayoutColor,
+                                                                  const VkImageLayout                                  subpassLayoutDepthStencil,
+                                                                  const VkAllocationCallbacks* const   allocationCallbacks)
 {
        const bool                                                              hasColor                                                        = colorFormat != VK_FORMAT_UNDEFINED;
        const bool                                                              hasDepthStencil                                         = depthStencilFormat != VK_FORMAT_UNDEFINED;
@@ -463,7 +464,7 @@ Move<VkRenderPass> makeRenderPass (const DeviceInterface&           vk,
                DE_NULL                                                                         // const VkSubpassDependency*        pDependencies
        };
 
-       return createRenderPass(vk, device, &renderPassInfo);
+       return createRenderPass(vk, device, &renderPassInfo, allocationCallbacks);
 }
 
 } // vk
index 66deaca..d576675 100644 (file)
@@ -70,15 +70,16 @@ Move<VkPipeline> makeGraphicsPipeline (const DeviceInterface&                                                       vk,
                                                                           const VkPipelineColorBlendStateCreateInfo*           colorBlendStateCreateInfo = DE_NULL,
                                                                           const VkPipelineDynamicStateCreateInfo*                      dynamicStateCreateInfo = DE_NULL);
 
-Move<VkRenderPass> makeRenderPass (const DeviceInterface&              vk,
-                                                                  const VkDevice                               device,
-                                                                  const VkFormat                               colorFormat,
-                                                                  const VkFormat                               depthStencilFormat                      = VK_FORMAT_UNDEFINED,
-                                                                  const VkAttachmentLoadOp             loadOperation                           = VK_ATTACHMENT_LOAD_OP_CLEAR,
-                                                                  const VkImageLayout                  finalLayoutColor                        = VK_IMAGE_LAYOUT_COLOR_ATTACHMENT_OPTIMAL,
-                                                                  const VkImageLayout                  finalLayoutDepthStencil         = VK_IMAGE_LAYOUT_DEPTH_STENCIL_ATTACHMENT_OPTIMAL,
-                                                                  const VkImageLayout                  subpassLayoutColor                      = VK_IMAGE_LAYOUT_COLOR_ATTACHMENT_OPTIMAL,
-                                                                  const VkImageLayout                  subpassLayoutDepthStencil       = VK_IMAGE_LAYOUT_DEPTH_STENCIL_ATTACHMENT_OPTIMAL);
+Move<VkRenderPass> makeRenderPass (const DeviceInterface&                              vk,
+                                                                  const VkDevice                                               device,
+                                                                  const VkFormat                                               colorFormat,
+                                                                  const VkFormat                                               depthStencilFormat                      = VK_FORMAT_UNDEFINED,
+                                                                  const VkAttachmentLoadOp                             loadOperation                           = VK_ATTACHMENT_LOAD_OP_CLEAR,
+                                                                  const VkImageLayout                                  finalLayoutColor                        = VK_IMAGE_LAYOUT_COLOR_ATTACHMENT_OPTIMAL,
+                                                                  const VkImageLayout                                  finalLayoutDepthStencil         = VK_IMAGE_LAYOUT_DEPTH_STENCIL_ATTACHMENT_OPTIMAL,
+                                                                  const VkImageLayout                                  subpassLayoutColor                      = VK_IMAGE_LAYOUT_COLOR_ATTACHMENT_OPTIMAL,
+                                                                  const VkImageLayout                                  subpassLayoutDepthStencil       = VK_IMAGE_LAYOUT_DEPTH_STENCIL_ATTACHMENT_OPTIMAL,
+                                                                  const VkAllocationCallbacks* const   allocationCallbacks                     = DE_NULL);
 
 } // vk
 
index fd3e415..6455734 100644 (file)
@@ -1573,7 +1573,13 @@ struct RenderPass
 
        static Move<VkRenderPass> create (const Environment& env, const Resources&, const Parameters&)
        {
-               return makeRenderPass(env.vkd, env.device, VK_FORMAT_R8G8B8A8_UNORM, VK_FORMAT_D16_UNORM);
+               return makeRenderPass(env.vkd, env.device, VK_FORMAT_R8G8B8A8_UNORM, VK_FORMAT_D16_UNORM,
+                       VK_ATTACHMENT_LOAD_OP_CLEAR,
+                       VK_IMAGE_LAYOUT_COLOR_ATTACHMENT_OPTIMAL,
+                       VK_IMAGE_LAYOUT_DEPTH_STENCIL_ATTACHMENT_OPTIMAL,
+                       VK_IMAGE_LAYOUT_COLOR_ATTACHMENT_OPTIMAL,
+                       VK_IMAGE_LAYOUT_DEPTH_STENCIL_ATTACHMENT_OPTIMAL,
+                       env.allocationCallbacks);
        }
 };