mirror of
https://gitlab.freedesktop.org/mesa/mesa.git
synced 2026-05-05 00:58:05 +02:00
spirv: Store SPIR-V version of the module
Reviewed-by: Rhys Perry <pendingchaos02@gmail.com> Reviewed-by: Jason Ekstrand <jason@jlekstrand.net> Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/8786>
This commit is contained in:
parent
a0d73ca65c
commit
1869072c80
2 changed files with 5 additions and 2 deletions
|
|
@ -5716,8 +5716,10 @@ vtn_create_builder(const uint32_t *words, size_t word_count,
|
|||
vtn_err("words[0] was 0x%x, want 0x%x", words[0], SpvMagicNumber);
|
||||
goto fail;
|
||||
}
|
||||
if (words[1] < 0x10000) {
|
||||
vtn_err("words[1] was 0x%x, want >= 0x10000", words[1]);
|
||||
|
||||
b->version = words[1];
|
||||
if (b->version < 0x10000) {
|
||||
vtn_err("version was 0x%x, want >= 0x10000", b->version);
|
||||
goto fail;
|
||||
}
|
||||
|
||||
|
|
|
|||
|
|
@ -648,6 +648,7 @@ struct vtn_builder {
|
|||
|
||||
const uint32_t *spirv;
|
||||
size_t spirv_word_count;
|
||||
uint32_t version;
|
||||
|
||||
nir_shader *shader;
|
||||
struct spirv_to_nir_options *options;
|
||||
|
|
|
|||
Loading…
Add table
Reference in a new issue