@@ -380,8 +380,8 @@ static DecodeStatus decodeRVCInstrRdRs1ImmZero(MCInst &Inst, uint32_t Insn,
380380 uint64_t Address,
381381 const MCDisassembler *Decoder) {
382382 uint32_t Rd = fieldFromInstruction (Insn, 7 , 5 );
383- DecodeStatus Result = DecodeGPRNoX0RegisterClass (Inst, Rd, Address, Decoder);
384- ( void )Result ;
383+ [[maybe_unused]] DecodeStatus Result =
384+ DecodeGPRNoX0RegisterClass (Inst, Rd, Address, Decoder) ;
385385 assert (Result == MCDisassembler::Success && " Invalid register" );
386386 Inst.addOperand (Inst.getOperand (0 ));
387387 Inst.addOperand (MCOperand::createImm (0 ));
@@ -392,8 +392,8 @@ static DecodeStatus decodeCSSPushPopchk(MCInst &Inst, uint32_t Insn,
392392 uint64_t Address,
393393 const MCDisassembler *Decoder) {
394394 uint32_t Rs1 = fieldFromInstruction (Insn, 7 , 5 );
395- DecodeStatus Result = DecodeGPRX1X5RegisterClass (Inst, Rs1, Address, Decoder);
396- ( void )Result ;
395+ [[maybe_unused]] DecodeStatus Result =
396+ DecodeGPRX1X5RegisterClass (Inst, Rs1, Address, Decoder) ;
397397 assert (Result == MCDisassembler::Success && " Invalid register" );
398398 return MCDisassembler::Success;
399399}
@@ -404,8 +404,8 @@ static DecodeStatus decodeRVCInstrRdSImm(MCInst &Inst, uint32_t Insn,
404404 Inst.addOperand (MCOperand::createReg (RISCV::X0));
405405 uint32_t SImm6 =
406406 fieldFromInstruction (Insn, 12 , 1 ) << 5 | fieldFromInstruction (Insn, 2 , 5 );
407- DecodeStatus Result = decodeSImmOperand< 6 >(Inst, SImm6, Address, Decoder);
408- ( void )Result ;
407+ [[maybe_unused]] DecodeStatus Result =
408+ decodeSImmOperand< 6 >(Inst, SImm6, Address, Decoder) ;
409409 assert (Result == MCDisassembler::Success && " Invalid immediate" );
410410 return MCDisassembler::Success;
411411}
@@ -417,8 +417,8 @@ static DecodeStatus decodeRVCInstrRdRs1UImm(MCInst &Inst, uint32_t Insn,
417417 Inst.addOperand (Inst.getOperand (0 ));
418418 uint32_t UImm6 =
419419 fieldFromInstruction (Insn, 12 , 1 ) << 5 | fieldFromInstruction (Insn, 2 , 5 );
420- DecodeStatus Result = decodeUImmOperand< 6 >(Inst, UImm6, Address, Decoder);
421- ( void )Result ;
420+ [[maybe_unused]] DecodeStatus Result =
421+ decodeUImmOperand< 6 >(Inst, UImm6, Address, Decoder) ;
422422 assert (Result == MCDisassembler::Success && " Invalid immediate" );
423423 return MCDisassembler::Success;
424424}
@@ -454,8 +454,8 @@ static DecodeStatus decodeXTHeadMemPair(MCInst &Inst, uint32_t Insn,
454454 DecodeGPRRegisterClass (Inst, Rd1, Address, Decoder);
455455 DecodeGPRRegisterClass (Inst, Rd2, Address, Decoder);
456456 DecodeGPRRegisterClass (Inst, Rs1, Address, Decoder);
457- DecodeStatus Result = decodeUImmOperand< 2 >(Inst, UImm2, Address, Decoder);
458- ( void )Result ;
457+ [[maybe_unused]] DecodeStatus Result =
458+ decodeUImmOperand< 2 >(Inst, UImm2, Address, Decoder) ;
459459 assert (Result == MCDisassembler::Success && " Invalid immediate" );
460460
461461 // Disassemble the final operand which is implicit.
0 commit comments