Welcome to mirror list, hosted at ThFree Co, Russian Federation.

github.com/KhronosGroup/SPIRV-Tools.git - Unnamed repository; edit this file 'description' to name the repository.
summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
Diffstat (limited to 'source/fuzz/transformation_set_selection_control.cpp')
-rw-r--r--source/fuzz/transformation_set_selection_control.cpp11
1 files changed, 7 insertions, 4 deletions
diff --git a/source/fuzz/transformation_set_selection_control.cpp b/source/fuzz/transformation_set_selection_control.cpp
index 6dddbdf83..c6f68d9c4 100644
--- a/source/fuzz/transformation_set_selection_control.cpp
+++ b/source/fuzz/transformation_set_selection_control.cpp
@@ -29,14 +29,17 @@ TransformationSetSelectionControl::TransformationSetSelectionControl(
bool TransformationSetSelectionControl::IsApplicable(
opt::IRContext* ir_context, const TransformationContext& /*unused*/) const {
- assert((message_.selection_control() == SpvSelectionControlMaskNone ||
- message_.selection_control() == SpvSelectionControlFlattenMask ||
- message_.selection_control() == SpvSelectionControlDontFlattenMask) &&
+ assert((spv::SelectionControlMask(message_.selection_control()) ==
+ spv::SelectionControlMask::MaskNone ||
+ spv::SelectionControlMask(message_.selection_control()) ==
+ spv::SelectionControlMask::Flatten ||
+ spv::SelectionControlMask(message_.selection_control()) ==
+ spv::SelectionControlMask::DontFlatten) &&
"Selection control should never be set to something other than "
"'None', 'Flatten' or 'DontFlatten'");
if (auto block = ir_context->get_instr_block(message_.block_id())) {
if (auto merge_inst = block->GetMergeInst()) {
- return merge_inst->opcode() == SpvOpSelectionMerge;
+ return merge_inst->opcode() == spv::Op::OpSelectionMerge;
}
}
// Either the block did not exit, or did not end with OpSelectionMerge.