bug-14538: Remove driver validation checks
Marked validation checks done in the driver with
TODOVV. Once we verify the check is covered in a
validation layer we can remove the driver code.
diff --git a/icd/intel/shader.c b/icd/intel/shader.c
index 29dd2ee..fde1036 100644
--- a/icd/intel/shader.c
+++ b/icd/intel/shader.c
@@ -52,10 +52,16 @@
if (!sm)
return VK_ERROR_OUT_OF_HOST_MEMORY;
- if (info->codeSize < sizeof(*spv))
- return VK_ERROR_INVALID_MEMORY_SIZE;
- if (spv->magic != ICD_SPV_MAGIC)
- return VK_ERROR_BAD_SHADER_CODE;
+ /* TODOVV: Move test to validation layer */
+ if (info->codeSize < sizeof(*spv)) {
+// return VK_ERROR_INVALID_MEMORY_SIZE;
+ return VK_ERROR_UNKNOWN;
+ }
+ /* TODOVV: Move test to validation layer */
+ if (spv->magic != ICD_SPV_MAGIC) {
+// return VK_ERROR_BAD_SHADER_CODE;
+ return VK_ERROR_UNKNOWN;
+ }
sm->code_size = info->codeSize;
sm->code = malloc(info->codeSize);
@@ -119,7 +125,9 @@
sh->ir = shader_create_ir(dev->gpu, sm->code, sm->code_size, info->stage);
if (!sh->ir) {
shader_destroy(&sh->obj);
- return VK_ERROR_BAD_SHADER_CODE;
+ /* TODOVV: Can this move to validation layer? */
+// return VK_ERROR_BAD_SHADER_CODE;
+ return VK_ERROR_UNKNOWN;
}
sh->obj.destroy = shader_destroy;