You can not select more than 25 topics
Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
203 lines
6.4 KiB
203 lines
6.4 KiB
4 months ago
|
# RUN: llvm-mc -triple hexagon -disassemble < %s | FileCheck %s
|
||
|
# Hexagon Programmer's Reference Manual 11.4 J
|
||
|
|
||
|
# Call subroutine
|
||
|
0x22 0xc0 0x00 0x5a
|
||
|
# CHECK: call
|
||
|
0x22 0xc3 0x00 0x5d
|
||
|
# CHECK: if (p3) call
|
||
|
0x22 0xc3 0x20 0x5d
|
||
|
# CHECK: if (!p3) call
|
||
|
|
||
|
# Compare and jump
|
||
|
0x00 0xc0 0x89 0x11
|
||
|
# CHECK: p0 = cmp.eq(r17,#-1); if (p0.new) jump:nt
|
||
|
0x00 0xc1 0x89 0x11
|
||
|
# CHECK: p0 = cmp.gt(r17,#-1); if (p0.new) jump:nt
|
||
|
0x00 0xc3 0x89 0x11
|
||
|
# CHECK: p0 = tstbit(r17, #0); if (p0.new) jump:nt
|
||
|
0x00 0xe0 0x89 0x11
|
||
|
# CHECK: p0 = cmp.eq(r17,#-1); if (p0.new) jump:t
|
||
|
0x00 0xe1 0x89 0x11
|
||
|
# CHECK: p0 = cmp.gt(r17,#-1); if (p0.new) jump:t
|
||
|
0x00 0xe3 0x89 0x11
|
||
|
# CHECK: p0 = tstbit(r17, #0); if (p0.new) jump:t
|
||
|
0x00 0xc0 0xc9 0x11
|
||
|
# CHECK: p0 = cmp.eq(r17,#-1); if (!p0.new) jump:nt
|
||
|
0x00 0xc1 0xc9 0x11
|
||
|
# CHECK: p0 = cmp.gt(r17,#-1); if (!p0.new) jump:nt
|
||
|
0x00 0xc3 0xc9 0x11
|
||
|
# CHECK: p0 = tstbit(r17, #0); if (!p0.new) jump:nt
|
||
|
0x00 0xe0 0xc9 0x11
|
||
|
# CHECK: p0 = cmp.eq(r17,#-1); if (!p0.new) jump:t
|
||
|
0x00 0xe1 0xc9 0x11
|
||
|
# CHECK: p0 = cmp.gt(r17,#-1); if (!p0.new) jump:t
|
||
|
0x00 0xe3 0xc9 0x11
|
||
|
# CHECK: p0 = tstbit(r17, #0); if (!p0.new) jump:t
|
||
|
0x00 0xd5 0x09 0x10
|
||
|
# CHECK: p0 = cmp.eq(r17, #21); if (p0.new) jump:nt
|
||
|
0x00 0xf5 0x09 0x10
|
||
|
# CHECK: p0 = cmp.eq(r17, #21); if (p0.new) jump:t
|
||
|
0x00 0xd5 0x49 0x10
|
||
|
# CHECK: p0 = cmp.eq(r17, #21); if (!p0.new) jump:nt
|
||
|
0x00 0xf5 0x49 0x10
|
||
|
# CHECK: p0 = cmp.eq(r17, #21); if (!p0.new) jump:t
|
||
|
0x00 0xd5 0x89 0x10
|
||
|
# CHECK: p0 = cmp.gt(r17, #21); if (p0.new) jump:nt
|
||
|
0x00 0xf5 0x89 0x10
|
||
|
# CHECK: p0 = cmp.gt(r17, #21); if (p0.new) jump:t
|
||
|
0x00 0xd5 0xc9 0x10
|
||
|
# CHECK: p0 = cmp.gt(r17, #21); if (!p0.new) jump:nt
|
||
|
0x00 0xf5 0xc9 0x10
|
||
|
# CHECK: p0 = cmp.gt(r17, #21); if (!p0.new) jump:t
|
||
|
0x00 0xd5 0x09 0x11
|
||
|
# CHECK: p0 = cmp.gtu(r17, #21); if (p0.new) jump:nt
|
||
|
0x00 0xf5 0x09 0x11
|
||
|
# CHECK: p0 = cmp.gtu(r17, #21); if (p0.new) jump:t
|
||
|
0x00 0xd5 0x49 0x11
|
||
|
# CHECK: p0 = cmp.gtu(r17, #21); if (!p0.new) jump:nt
|
||
|
0x00 0xf5 0x49 0x11
|
||
|
# CHECK: p0 = cmp.gtu(r17, #21); if (!p0.new) jump:t
|
||
|
0x00 0xc0 0x89 0x13
|
||
|
# CHECK: p1 = cmp.eq(r17,#-1); if (p1.new) jump:nt
|
||
|
0x00 0xc1 0x89 0x13
|
||
|
# CHECK: p1 = cmp.gt(r17,#-1); if (p1.new) jump:nt
|
||
|
0x00 0xc3 0x89 0x13
|
||
|
# CHECK: p1 = tstbit(r17, #0); if (p1.new) jump:nt
|
||
|
0x00 0xe0 0x89 0x13
|
||
|
# CHECK: p1 = cmp.eq(r17,#-1); if (p1.new) jump:t
|
||
|
0x00 0xe1 0x89 0x13
|
||
|
# CHECK: p1 = cmp.gt(r17,#-1); if (p1.new) jump:t
|
||
|
0x00 0xe3 0x89 0x13
|
||
|
# CHECK: p1 = tstbit(r17, #0); if (p1.new) jump:t
|
||
|
0x00 0xc0 0xc9 0x13
|
||
|
# CHECK: p1 = cmp.eq(r17,#-1); if (!p1.new) jump:nt
|
||
|
0x00 0xc1 0xc9 0x13
|
||
|
# CHECK: p1 = cmp.gt(r17,#-1); if (!p1.new) jump:nt
|
||
|
0x00 0xc3 0xc9 0x13
|
||
|
# CHECK: p1 = tstbit(r17, #0); if (!p1.new) jump:nt
|
||
|
0x00 0xe0 0xc9 0x13
|
||
|
# CHECK: p1 = cmp.eq(r17,#-1); if (!p1.new) jump:t
|
||
|
0x00 0xe1 0xc9 0x13
|
||
|
# CHECK: p1 = cmp.gt(r17,#-1); if (!p1.new) jump:t
|
||
|
0x00 0xe3 0xc9 0x13
|
||
|
# CHECK: p1 = tstbit(r17, #0); if (!p1.new) jump:t
|
||
|
0x00 0xd5 0x09 0x12
|
||
|
# CHECK: p1 = cmp.eq(r17, #21); if (p1.new) jump:nt
|
||
|
0x00 0xf5 0x09 0x12
|
||
|
# CHECK: p1 = cmp.eq(r17, #21); if (p1.new) jump:t
|
||
|
0x00 0xd5 0x49 0x12
|
||
|
# CHECK: p1 = cmp.eq(r17, #21); if (!p1.new) jump:nt
|
||
|
0x00 0xf5 0x49 0x12
|
||
|
# CHECK: p1 = cmp.eq(r17, #21); if (!p1.new) jump:t
|
||
|
0x00 0xd5 0x89 0x12
|
||
|
# CHECK: p1 = cmp.gt(r17, #21); if (p1.new) jump:nt
|
||
|
0x00 0xf5 0x89 0x12
|
||
|
# CHECK: p1 = cmp.gt(r17, #21); if (p1.new) jump:t
|
||
|
0x00 0xd5 0xc9 0x12
|
||
|
# CHECK: p1 = cmp.gt(r17, #21); if (!p1.new) jump:nt
|
||
|
0x00 0xf5 0xc9 0x12
|
||
|
# CHECK: p1 = cmp.gt(r17, #21); if (!p1.new) jump:t
|
||
|
0x00 0xd5 0x09 0x13
|
||
|
# CHECK: p1 = cmp.gtu(r17, #21); if (p1.new) jump:nt
|
||
|
0x00 0xf5 0x09 0x13
|
||
|
# CHECK: p1 = cmp.gtu(r17, #21); if (p1.new) jump:t
|
||
|
0x00 0xd5 0x49 0x13
|
||
|
# CHECK: p1 = cmp.gtu(r17, #21); if (!p1.new) jump:nt
|
||
|
0x00 0xf5 0x49 0x13
|
||
|
# CHECK: p1 = cmp.gtu(r17, #21); if (!p1.new) jump:t
|
||
|
0x00 0xcd 0x09 0x14
|
||
|
# CHECK: p0 = cmp.eq(r17, r21); if (p0.new) jump:nt
|
||
|
0x00 0xdd 0x09 0x14
|
||
|
# CHECK: p1 = cmp.eq(r17, r21); if (p1.new) jump:nt
|
||
|
0x00 0xed 0x09 0x14
|
||
|
# CHECK: p0 = cmp.eq(r17, r21); if (p0.new) jump:t
|
||
|
0x00 0xfd 0x09 0x14
|
||
|
# CHECK: p1 = cmp.eq(r17, r21); if (p1.new) jump:t
|
||
|
0x00 0xcd 0x49 0x14
|
||
|
# CHECK: p0 = cmp.eq(r17, r21); if (!p0.new) jump:nt
|
||
|
0x00 0xdd 0x49 0x14
|
||
|
# CHECK: p1 = cmp.eq(r17, r21); if (!p1.new) jump:nt
|
||
|
0x00 0xed 0x49 0x14
|
||
|
# CHECK: p0 = cmp.eq(r17, r21); if (!p0.new) jump:t
|
||
|
0x00 0xfd 0x49 0x14
|
||
|
# CHECK: p1 = cmp.eq(r17, r21); if (!p1.new) jump:t
|
||
|
0x00 0xcd 0x89 0x14
|
||
|
# CHECK: p0 = cmp.gt(r17, r21); if (p0.new) jump:nt
|
||
|
0x00 0xdd 0x89 0x14
|
||
|
# CHECK: p1 = cmp.gt(r17, r21); if (p1.new) jump:nt
|
||
|
0x00 0xed 0x89 0x14
|
||
|
# CHECK: p0 = cmp.gt(r17, r21); if (p0.new) jump:t
|
||
|
0x00 0xfd 0x89 0x14
|
||
|
# CHECK: p1 = cmp.gt(r17, r21); if (p1.new) jump:t
|
||
|
0x00 0xcd 0xc9 0x14
|
||
|
# CHECK: p0 = cmp.gt(r17, r21); if (!p0.new) jump:nt
|
||
|
0x00 0xdd 0xc9 0x14
|
||
|
# CHECK: p1 = cmp.gt(r17, r21); if (!p1.new) jump:nt
|
||
|
0x00 0xed 0xc9 0x14
|
||
|
# CHECK: p0 = cmp.gt(r17, r21); if (!p0.new) jump:t
|
||
|
0x00 0xfd 0xc9 0x14
|
||
|
# CHECK: p1 = cmp.gt(r17, r21); if (!p1.new) jump:t
|
||
|
0x00 0xcd 0x09 0x15
|
||
|
# CHECK: p0 = cmp.gtu(r17, r21); if (p0.new) jump:nt
|
||
|
0x00 0xdd 0x09 0x15
|
||
|
# CHECK: p1 = cmp.gtu(r17, r21); if (p1.new) jump:nt
|
||
|
0x00 0xed 0x09 0x15
|
||
|
# CHECK: p0 = cmp.gtu(r17, r21); if (p0.new) jump:t
|
||
|
0x00 0xfd 0x09 0x15
|
||
|
# CHECK: p1 = cmp.gtu(r17, r21); if (p1.new) jump:t
|
||
|
0x00 0xcd 0x49 0x15
|
||
|
# CHECK: p0 = cmp.gtu(r17, r21); if (!p0.new) jump:nt
|
||
|
0x00 0xdd 0x49 0x15
|
||
|
# CHECK: p1 = cmp.gtu(r17, r21); if (!p1.new) jump:nt
|
||
|
0x00 0xed 0x49 0x15
|
||
|
# CHECK: p0 = cmp.gtu(r17, r21); if (!p0.new) jump:t
|
||
|
0x00 0xfd 0x49 0x15
|
||
|
# CHECK: p1 = cmp.gtu(r17, r21); if (!p1.new) jump:t
|
||
|
|
||
|
# Jump to address
|
||
|
0x22 0xc0 0x00 0x58
|
||
|
# CHECK: jump
|
||
|
0x22 0xc3 0x00 0x5c
|
||
|
# CHECK: if (p3) jump
|
||
|
0x22 0xc3 0x20 0x5c
|
||
|
# CHECK: if (!p3) jump
|
||
|
|
||
|
# Jump to address conditioned on new predicate
|
||
|
0x03 0x40 0x45 0x85 0x00 0xcb 0x00 0x5c
|
||
|
# CHECK: p3 = r5
|
||
|
# CHECK-NEXT: if (p3.new) jump:nt
|
||
|
0x03 0x40 0x45 0x85 0x00 0xdb 0x00 0x5c
|
||
|
# CHECK: p3 = r5
|
||
|
# CHECK-NEXT: if (p3.new) jump:t
|
||
|
0x03 0x40 0x45 0x85 0x00 0xcb 0x20 0x5c
|
||
|
# CHECK: p3 = r5
|
||
|
# CHECK-NEXT: if (!p3.new) jump:nt
|
||
|
0x03 0x40 0x45 0x85 0x00 0xdb 0x20 0x5c
|
||
|
# CHECK: p3 = r5
|
||
|
# CHECK-NEXT: if (!p3.new) jump:t
|
||
|
|
||
|
# Jump to address conditioned on register value
|
||
|
0x00 0xc0 0x11 0x61
|
||
|
# CHECK: if (r17!=#0) jump:nt
|
||
|
0x00 0xd0 0x11 0x61
|
||
|
# CHECK: if (r17!=#0) jump:t
|
||
|
0x00 0xc0 0x51 0x61
|
||
|
# CHECK: if (r17>=#0) jump:nt
|
||
|
0x00 0xd0 0x51 0x61
|
||
|
# CHECK: if (r17>=#0) jump:t
|
||
|
0x00 0xc0 0x91 0x61
|
||
|
# CHECK: if (r17==#0) jump:nt
|
||
|
0x00 0xd0 0x91 0x61
|
||
|
# CHECK: if (r17==#0) jump:t
|
||
|
0x00 0xc0 0xd1 0x61
|
||
|
# CHECK: if (r17<=#0) jump:nt
|
||
|
0x00 0xd0 0xd1 0x61
|
||
|
# CHECK: if (r17<=#0) jump:t
|
||
|
|
||
|
# Transfer and jump
|
||
|
0x00 0xd5 0x09 0x16
|
||
|
# CHECK: r17 = #21 ; jump
|
||
|
0x00 0xc9 0x0d 0x17
|
||
|
# CHECK: r17 = r21 ; jump
|