aboutsummaryrefslogtreecommitdiff
path: root/source/fuzz/fuzzer_pass_adjust_selection_controls.cpp
diff options
context:
space:
mode:
Diffstat (limited to 'source/fuzz/fuzzer_pass_adjust_selection_controls.cpp')
-rw-r--r--source/fuzz/fuzzer_pass_adjust_selection_controls.cpp13
1 files changed, 6 insertions, 7 deletions
diff --git a/source/fuzz/fuzzer_pass_adjust_selection_controls.cpp b/source/fuzz/fuzzer_pass_adjust_selection_controls.cpp
index fe0cf7af..7d8e6b57 100644
--- a/source/fuzz/fuzzer_pass_adjust_selection_controls.cpp
+++ b/source/fuzz/fuzzer_pass_adjust_selection_controls.cpp
@@ -34,7 +34,7 @@ void FuzzerPassAdjustSelectionControls::Apply() {
for (auto& block : function) {
if (auto merge_inst = block.GetMergeInst()) {
// Ignore the instruction if it is not a selection merge.
- if (merge_inst->opcode() != spv::Op::OpSelectionMerge) {
+ if (merge_inst->opcode() != SpvOpSelectionMerge) {
continue;
}
@@ -48,14 +48,13 @@ void FuzzerPassAdjustSelectionControls::Apply() {
// The choices to change the selection control to are the set of valid
// controls, minus the current control.
std::vector<uint32_t> choices;
- for (auto control : {spv::SelectionControlMask::MaskNone,
- spv::SelectionControlMask::Flatten,
- spv::SelectionControlMask::DontFlatten}) {
- if (control ==
- spv::SelectionControlMask(merge_inst->GetSingleWordOperand(1))) {
+ for (auto control :
+ {SpvSelectionControlMaskNone, SpvSelectionControlFlattenMask,
+ SpvSelectionControlDontFlattenMask}) {
+ if (control == merge_inst->GetSingleWordOperand(1)) {
continue;
}
- choices.push_back(uint32_t(control));
+ choices.push_back(control);
}
// Apply the transformation and add it to the output transformation