Skip to content

Commit aa32b6f

Browse files
authored
[tablegen][test] Make additional-encoding.td more reliable (#158123)
Similar to `OPC_Decode`, `OPC_TryDecode` should also be relaxed in case new opcodes are added. `llvm/test/TableGen/trydecode-emission.td` is an example of a test that follows this pattern. Apply the same relaxation in `additional-encoding.td` as well.
1 parent 580fdeb commit aa32b6f

File tree

1 file changed

+4
-4
lines changed

1 file changed

+4
-4
lines changed

llvm/test/TableGen/FixedLenDecoderEmitter/additional-encoding.td

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -35,22 +35,22 @@ class I<dag out_ops, dag in_ops> : Instruction {
3535
// CHECK-NEXT: /* 7 */ MCD::OPC_Scope, 8, 0, // Skip to: 18
3636
// CHECK-NEXT: /* 10 */ MCD::OPC_CheckField, 6, 6, 0,
3737
// CHECK-NEXT: /* 14 */ MCD::OPC_Decode, {{[0-9]+}}, 2, 0, // Opcode: {{.*}}:NOP, DecodeIdx: 0
38-
// CHECK-NEXT: /* 18 */ MCD::OPC_TryDecode, 187, 2, 1,
38+
// CHECK-NEXT: /* 18 */ MCD::OPC_TryDecode, {{[0-9]+}}, 2, 1,
3939
// CHECK-NEXT: /* 22 */ MCD::OPC_FilterValueOrSkip, 1, 15, 0, // Skip to: 41
4040
// CHECK-NEXT: /* 26 */ MCD::OPC_Scope, 8, 0, // Skip to: 37
4141
// CHECK-NEXT: /* 29 */ MCD::OPC_CheckField, 6, 6, 0,
4242
// CHECK-NEXT: /* 33 */ MCD::OPC_Decode, {{[0-9]+}}, 2, 0, // Opcode: {{.*}}:NOP, DecodeIdx: 0
43-
// CHECK-NEXT: /* 37 */ MCD::OPC_TryDecode, 188, 2, 1,
43+
// CHECK-NEXT: /* 37 */ MCD::OPC_TryDecode, {{[0-9]+}}, 2, 1,
4444
// CHECK-NEXT: /* 41 */ MCD::OPC_FilterValueOrSkip, 2, 15, 0, // Skip to: 60
4545
// CHECK-NEXT: /* 45 */ MCD::OPC_Scope, 8, 0, // Skip to: 56
4646
// CHECK-NEXT: /* 48 */ MCD::OPC_CheckField, 6, 6, 0,
4747
// CHECK-NEXT: /* 52 */ MCD::OPC_Decode, {{[0-9]+}}, 2, 0, // Opcode: {{.*}}:NOP, DecodeIdx: 0
48-
// CHECK-NEXT: /* 56 */ MCD::OPC_TryDecode, 189, 2, 1,
48+
// CHECK-NEXT: /* 56 */ MCD::OPC_TryDecode, {{[0-9]+}}, 2, 1,
4949
// CHECK-NEXT: /* 60 */ MCD::OPC_FilterValue, 3,
5050
// CHECK-NEXT: /* 62 */ MCD::OPC_Scope, 8, 0, // Skip to: 73
5151
// CHECK-NEXT: /* 65 */ MCD::OPC_CheckField, 6, 6, 0,
5252
// CHECK-NEXT: /* 69 */ MCD::OPC_Decode, {{[0-9]+}}, 2, 0, // Opcode: {{.*}}:NOP, DecodeIdx: 0
53-
// CHECK-NEXT: /* 73 */ MCD::OPC_TryDecode, 190, 2, 1,
53+
// CHECK-NEXT: /* 73 */ MCD::OPC_TryDecode, {{[0-9]+}}, 2, 1,
5454

5555

5656
class SHIFT<bits<2> opc> : I<(outs), (ins ShAmtOp:$shamt)>, EncSHIFT<opc>;

0 commit comments

Comments
 (0)