if (strcmp((const char *)&w[2], "GLSL.std.450") == 0) {
val->ext_handler = vtn_handle_glsl450_instruction;
} else {
- assert(!"Unsupported extension");
+ unreachable("Unsupported extension");
}
break;
}
case SpvImageFormatR16ui: return 0x8234; /* GL_R16UI */
case SpvImageFormatR8ui: return 0x8232; /* GL_R8UI */
default:
- assert(!"Invalid image format");
+ unreachable("Invalid image format");
return 0;
}
}
else if (dim == GLSL_SAMPLER_DIM_SUBPASS)
dim = GLSL_SAMPLER_DIM_SUBPASS_MS;
else
- assert(!"Unsupported multisampled image type");
+ unreachable("Unsupported multisampled image type");
}
val->type->image_format = translate_image_format(format);
val->type->type = glsl_image_type(dim, is_array,
glsl_get_base_type(sampled_type));
} else {
- assert(!"We need to know if the image will be sampled");
+ unreachable("We need to know if the image will be sampled");
}
break;
}
break;
case SpvOpConstantSampler:
- assert(!"OpConstantSampler requires Kernel Capability");
+ unreachable("OpConstantSampler requires Kernel Capability");
break;
default:
case SpvExecutionModeOutputTriangleStrip:
return 5; /* GL_TRIANGLE_STRIP */
default:
- assert(!"Invalid primitive type");
+ unreachable("Invalid primitive type");
return 4;
}
}
case SpvExecutionModeInputTrianglesAdjacency:
return 6;
default:
- assert(!"Invalid GS input mode");
+ unreachable("Invalid GS input mode");
return 0;
}
}
break;
case SpvExecutionModeXfb:
- assert(!"Unhandled execution mode");
+ unreachable("Unhandled execution mode");
break;
case SpvExecutionModeVecTypeHint:
case SpvOpMemberDecorate:
case SpvOpGroupDecorate:
case SpvOpGroupMemberDecorate:
- assert(!"Invalid opcode types and variables section");
+ unreachable("Invalid opcode types and variables section");
break;
case SpvOpTypeVoid:
return type->stride * glsl_get_length(type->type);
default:
- assert(!"Invalid block type");
+ unreachable("Invalid block type");
return 0;
}
}
&access_offset, &access_size);
break;
default:
- assert(!"Invalid block variable mode");
+ unreachable("Invalid block variable mode");
}
nir_ssa_def *offset, *index = NULL;
mode = vtn_variable_mode_ssbo;
nir_mode = 0;
} else {
- assert(!"Invalid uniform variable type");
+ unreachable("Invalid uniform variable type");
}
break;
case SpvStorageClassStorageBuffer:
mode = vtn_variable_mode_sampler;
nir_mode = nir_var_uniform;
} else {
- assert(!"Invalid uniform constant variable type");
+ unreachable("Invalid uniform constant variable type");
}
break;
case SpvStorageClassPushConstant: