unsigned value_id_bound;
struct vtn_value *values;
+
+ SpvExecutionModel execution_model;
+ struct vtn_value *entry_point;
};
static void
return ralloc_strndup(b, (char *)words, (word_count - 2) * sizeof(*words));
}
+static void
+vtn_handle_extension(struct vtn_builder *b, SpvOp opcode,
+ const uint32_t *w, unsigned count)
+{
+ switch (opcode) {
+ case SpvOpExtInstImport:
+ /* Do nothing for the moment */
+ break;
+
+ case SpvOpExtInst:
+ default:
+ unreachable("Unhandled opcode");
+ }
+}
+
typedef void (*decoration_foreach_cb)(struct vtn_builder *,
struct vtn_value *,
const struct vtn_decoration *,
case SpvOpSourceExtension:
case SpvOpMemberName:
case SpvOpLine:
+ case SpvOpExtension:
/* Unhandled, but these are for debug so that's ok. */
break;
vtn_push_token(b, w[2], vtn_value_type_undef);
break;
+ case SpvOpMemoryModel:
+ assert(w[1] == SpvAddressingModelLogical);
+ assert(w[2] == SpvMemoryModelGLSL450);
+ break;
+
+ case SpvOpEntryPoint:
+ assert(b->entry_point == NULL);
+ b->entry_point = &b->values[w[2]];
+ b->execution_model = w[1];
+ break;
+
+ case SpvOpExtInstImport:
+ case SpvOpExtInst:
+ vtn_handle_extension(b, opcode, w, count);
+ break;
+
case SpvOpTypeVoid:
case SpvOpTypeBool:
case SpvOpTypeInt: