File tree Expand file tree Collapse file tree 2 files changed +34
-1
lines changed Expand file tree Collapse file tree 2 files changed +34
-1
lines changed Original file line number Diff line number Diff line change @@ -72,6 +72,7 @@ std::string VRegRenamer::getInstructionOpcodeHash(MachineInstr &MI) {
7272 return MO.getOffset () | (MO.getTargetFlags () << 16 );
7373 case MachineOperand::MO_FrameIndex:
7474 case MachineOperand::MO_ConstantPoolIndex:
75+ case MachineOperand::MO_JumpTableIndex:
7576 return llvm::hash_value (MO);
7677
7778 // We could explicitly handle all the types of the MachineOperand,
@@ -82,7 +83,6 @@ std::string VRegRenamer::getInstructionOpcodeHash(MachineInstr &MI) {
8283
8384 // TODO: Handle the following Index/ID/Predicate cases. They can
8485 // be hashed on in a stable manner.
85- case MachineOperand::MO_JumpTableIndex:
8686 case MachineOperand::MO_CFIIndex:
8787 case MachineOperand::MO_IntrinsicID:
8888 case MachineOperand::MO_Predicate:
Original file line number Diff line number Diff line change 1+ # RUN: llc -run-pass mir-canonicalizer -verify-machineinstrs -mtriple aarch64-unknown-linux-gnu -o - %s | FileCheck %s
2+ ...
3+ ---
4+ name : foo
5+ alignment : 16
6+ jumpTable :
7+ kind : block-address
8+ entries :
9+ - id : 0
10+ blocks : [ '%bb.0', '%bb.1']
11+ - id : 1
12+ blocks : [ '%bb.2', '%bb.3' ]
13+ - id : 2
14+ blocks : [ '%bb.3', '%bb.7']
15+ - id : 3
16+ blocks : [ '%bb.2', '%bb.3' ]
17+ body : |
18+ bb.0:
19+ bb.1:
20+ bb.2:
21+ bb.3:
22+ bb.7:
23+ ;CHECK: %bb{{[0-9]+}}_{{[0-9]+}}__1:_(p0) = G_JUMP_TABLE %jump-table.0
24+ ;CHECK: %bb{{[0-9]+}}_{{[0-9]+}}__1:_(p0) = G_JUMP_TABLE %jump-table.1
25+ ;CHECK: %bb{{[0-9]+}}_{{[0-9]+}}__1:_(p0) = G_JUMP_TABLE %jump-table.2
26+ ;CHECK: %bb{{[0-9]+}}_{{[0-9]+}}__1:_(p0) = G_JUMP_TABLE %jump-table.3
27+ %a:_(p0) = G_JUMP_TABLE %jump-table.0
28+ %b:_(p0) = G_JUMP_TABLE %jump-table.1
29+ %c:_(p0) = G_JUMP_TABLE %jump-table.2
30+ %d:_(p0) = G_JUMP_TABLE %jump-table.3
31+
32+ ...
33+
You can’t perform that action at this time.
0 commit comments