xref: /aosp_15_r20/external/llvm/test/MC/Disassembler/Hexagon/jr.txt (revision 9880d6810fe72a1726cb53787c6711e909410d58)
1*9880d681SAndroid Build Coastguard Worker# RUN: llvm-mc -triple hexagon -disassemble < %s | FileCheck %s
2*9880d681SAndroid Build Coastguard Worker# Hexagon Programmer's Reference Manual 11.3 JR
3*9880d681SAndroid Build Coastguard Worker
4*9880d681SAndroid Build Coastguard Worker# Call subroutine from register
5*9880d681SAndroid Build Coastguard Worker0x00 0xc0 0xb5 0x50
6*9880d681SAndroid Build Coastguard Worker# CHECK: callr r21
7*9880d681SAndroid Build Coastguard Worker0x00 0xc1 0x15 0x51
8*9880d681SAndroid Build Coastguard Worker# CHECK: if (p1) callr r21
9*9880d681SAndroid Build Coastguard Worker0x00 0xc3 0x35 0x51
10*9880d681SAndroid Build Coastguard Worker# CHECK: if (!p3) callr r21
11*9880d681SAndroid Build Coastguard Worker
12*9880d681SAndroid Build Coastguard Worker# Hint an indirect jump address
13*9880d681SAndroid Build Coastguard Worker0x00 0xc0 0xb5 0x52
14*9880d681SAndroid Build Coastguard Worker# CHECK: hintjr(r21)
15*9880d681SAndroid Build Coastguard Worker
16*9880d681SAndroid Build Coastguard Worker# Jump to address from register
17*9880d681SAndroid Build Coastguard Worker0x00 0xc0 0x95 0x52
18*9880d681SAndroid Build Coastguard Worker# CHECK: jumpr r21
19*9880d681SAndroid Build Coastguard Worker0x00 0xc1 0x55 0x53
20*9880d681SAndroid Build Coastguard Worker# CHECK: if (p1) jumpr:nt r21
21*9880d681SAndroid Build Coastguard Worker0x03 0x40 0x45 0x85 0x00 0xcb 0x55 0x53
22*9880d681SAndroid Build Coastguard Worker# CHECK: p3 = r5
23*9880d681SAndroid Build Coastguard Worker# CHECK-NEXT: if (p3.new) jumpr:nt r21
24*9880d681SAndroid Build Coastguard Worker0x03 0x40 0x45 0x85 0x00 0xdb 0x55 0x53
25*9880d681SAndroid Build Coastguard Worker# CHECK: p3 = r5
26*9880d681SAndroid Build Coastguard Worker# CHECK-NEXT: if (p3.new) jumpr:t r21
27*9880d681SAndroid Build Coastguard Worker0x00 0xc3 0x75 0x53
28*9880d681SAndroid Build Coastguard Worker# CHECK: if (!p3) jumpr:nt r21
29*9880d681SAndroid Build Coastguard Worker0x03 0x40 0x45 0x85 0x00 0xcb 0x75 0x53
30*9880d681SAndroid Build Coastguard Worker# CHECK: p3 = r5
31*9880d681SAndroid Build Coastguard Worker# CHECK-NEXT: if (!p3.new) jumpr:nt r21
32*9880d681SAndroid Build Coastguard Worker0x03 0x40 0x45 0x85 0x00 0xdb 0x75 0x53
33*9880d681SAndroid Build Coastguard Worker# CHECK: p3 = r5
34*9880d681SAndroid Build Coastguard Worker# CHECK-NEXT: if (!p3.new) jumpr:t r21
35