Skip to content

Commit

Permalink
Update SPIRV-Headers, add cache control operand kinds
Browse files Browse the repository at this point in the history
Adds SPV_OPERAND_TYPE_LOAD_CACHE_CONTROL
and  SPV_OPERAND_TYPE_STORE_CACHE_CONTROL,
from SPV_INTEL_cache_controls

Fixes: KhronosGroup#5404
  • Loading branch information
dneto0 committed Sep 13, 2023
1 parent fc54e17 commit 8ddefac
Show file tree
Hide file tree
Showing 3 changed files with 11 additions and 1 deletion.
2 changes: 1 addition & 1 deletion DEPS
Original file line number Diff line number Diff line change
Expand Up @@ -13,7 +13,7 @@ vars = {
'protobuf_revision': 'v21.12',

're2_revision': 'a807e8a3aac2cc33c77b7071efea54fcabe38e0c',
'spirv_headers_revision': 'd790ced752b5bfc06b6988baadef6eb2d16bdf96',
'spirv_headers_revision': 'fc7d2462765183c784a0c46beb13eee9e506a067',
}

deps = {
Expand Down
4 changes: 4 additions & 0 deletions include/spirv-tools/libspirv.h
Original file line number Diff line number Diff line change
Expand Up @@ -297,6 +297,10 @@ typedef enum spv_operand_type_t {
SPV_OPERAND_TYPE_INITIALIZATION_MODE_QUALIFIER,
// Enum type from SPV_INTEL_global_variable_host_access
SPV_OPERAND_TYPE_HOST_ACCESS_QUALIFIER,
// Enum type from SPV_INTEL_cache_controls
SPV_OPERAND_TYPE_LOAD_CACHE_CONTROL,
// Enum type from SPV_INTEL_cache_controls
SPV_OPERAND_TYPE_STORE_CACHE_CONTROL,

// This is a sentinel value, and does not represent an operand type.
// It should come last.
Expand Down
6 changes: 6 additions & 0 deletions source/operand.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -216,6 +216,10 @@ const char* spvOperandTypeStr(spv_operand_type_t type) {
return "initialization mode qualifier";
case SPV_OPERAND_TYPE_HOST_ACCESS_QUALIFIER:
return "host access qualifier";
case SPV_OPERAND_TYPE_LOAD_CACHE_CONTROL:
return "load cache control";
case SPV_OPERAND_TYPE_STORE_CACHE_CONTROL:
return "store cache control";
case SPV_OPERAND_TYPE_IMAGE:
case SPV_OPERAND_TYPE_OPTIONAL_IMAGE:
return "image";
Expand Down Expand Up @@ -354,6 +358,8 @@ bool spvOperandIsConcrete(spv_operand_type_t type) {
case SPV_OPERAND_TYPE_COOPERATIVE_MATRIX_USE:
case SPV_OPERAND_TYPE_INITIALIZATION_MODE_QUALIFIER:
case SPV_OPERAND_TYPE_HOST_ACCESS_QUALIFIER:
case SPV_OPERAND_TYPE_LOAD_CACHE_CONTROL:
case SPV_OPERAND_TYPE_STORE_CACHE_CONTROL:
return true;
default:
break;
Expand Down

0 comments on commit 8ddefac

Please sign in to comment.