Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

add support for SPV_INTEL_global_variable_host_access #5786

Merged
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
1 change: 1 addition & 0 deletions source/binary.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -673,6 +673,7 @@ spv_result_t Parser::parseOperand(size_t inst_offset,
case SPV_OPERAND_TYPE_OPTIONAL_PACKED_VECTOR_FORMAT:
case SPV_OPERAND_TYPE_FPENCODING:
case SPV_OPERAND_TYPE_OPTIONAL_FPENCODING:
case SPV_OPERAND_TYPE_HOST_ACCESS_QUALIFIER:
case SPV_OPERAND_TYPE_LOAD_CACHE_CONTROL:
case SPV_OPERAND_TYPE_STORE_CACHE_CONTROL:
case SPV_OPERAND_TYPE_NAMED_MAXIMUM_NUMBER_OF_REGISTERS: {
Expand Down
10 changes: 10 additions & 0 deletions test/binary_to_text_test.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -418,6 +418,16 @@ INSTANTIATE_TEST_SUITE_P(
"OpDecorate %1 CacheControlStoreINTEL 3 StreamingINTEL\n",
})));

INSTANTIATE_TEST_SUITE_P(
HostAccessINTEL, RoundTripInstructionsTest,
Combine(::testing::Values(SPV_ENV_UNIVERSAL_1_0),
::testing::ValuesIn(std::vector<std::string>{
"OpDecorate %1 HostAccessINTEL NoneINTEL \"none\"\n",
"OpDecorate %1 HostAccessINTEL ReadINTEL \"read\"\n",
"OpDecorate %1 HostAccessINTEL WriteINTEL \"write\"\n",
"OpDecorate %1 HostAccessINTEL ReadWriteINTEL \"readwrite\"\n",
})));

using MaskSorting = TextToBinaryTest;

TEST_F(MaskSorting, MasksAreSortedFromLSBToMSB) {
Expand Down