two-extenders.s
3.06 KB
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
# RUN: llvm-mc -arch=hexagon -filetype=obj %s | llvm-objdump -d - | FileCheck %s
#
# In packets with two extensions assembler is not extending both instructions
#
//['D_DUMMY,C4_or_or,L4_ploadrbtnew_abs,S2_storerfgp']
{
if (p3) r23 = memb(##2164335510)
memh(##1696682668) = r28.h
}
# CHECK: { immext(#2164335488)
# CHECK: if (p3) r23 = memb(##2164335510)
# CHECK: immext(#1696682624)
# CHECK: memh(##1696682668) = r28.h }
//['D_DUMMY,C4_or_or,L4_ploadrbtnew_abs,S2_storerfgp']
{
if (p3.new) r23 = memb(##2164335510)
p3 = or(p2,or(p3, p0))
}
# CHECK: { p3 = or(p2,or(p3,p0))
# CHECK: immext(#2164335488)
# CHECK: if (p3.new) r23 = memb(##2164335510) }
# -------------------------- Non-extended cases:
# -------------------------- Use GP and non GP notation
R2 = memb(gp+#0x1000)
# CHECK: { r2 = memb(gp+#4096) }
R3 = memh(gp+#0x1000)
# CHECK: { r3 = memh(gp+#4096) }
r4 = memub(gp+#0x1000)
# CHECK: { r4 = memub(gp+#4096) }
r5 = memuh(gp+#0x1000)
# CHECK: { r5 = memuh(gp+#4096) }
r6 = memw(gp+#0x1000)
# CHECK: { r6 = memw(gp+#4096) }
R1:0 = memd(gp+#0x1000)
# CHECK: { r1:0 = memd(gp+#4096) }
{R25 = #1; memb(gp+#0x1000) = R25.new}
# CHECK: { r25 = #1
# CHECK-NEXT: memb(gp+#4096) = r25.new }
{R26 = #1; memh(gp+#0x1000) = R26.new}
# CHECK: { r26 = #1
# CHECK-NEXT: memh(gp+#4096) = r26.new }
{R27 = #1; memw(gp+#0x1000) = R27.new}
# CHECK: { r27 = #1
# CHECK-NEXT: memw(gp+#4096) = r27.new }
memd(gp+#0x1000) = R1:0
# CHECK: { memd(gp+#4096) = r1:0 }
memb(gp+#0x1000) = R2
# CHECK: { memb(gp+#4096) = r2 }
memh(gp+#0x1000) = r3.h
# CHECK: { memh(gp+#4096) = r3.h }
memh(gp+#0x1000) = R4
# CHECK: { memh(gp+#4096) = r4 }
memw(gp+#0x1000) = R5
# CHECK: { memw(gp+#4096) = r5 }
# -------------------------- Extended cases:
# -------------------------- Use GP and non GP notation
R11:10 = memd(##0x1000)
# CHECK: { immext(#4096)
# CHECK-NEXT: r11:10 = memd(##4096) }
R11 = memb(##0x1000)
# CHECK: { immext(#4096)
# CHECK-NEXT: r11 = memb(##4096) }
R12 = memh(##0x1000)
# CHECK: { immext(#4096)
# CHECK-NEXT: r12 = memh(##4096) }
r13 = memub(##0x1000)
# CHECK: { immext(#4096)
# CHECK-NEXT: r13 = memub(##4096) }
r14 = memuh(##0x1000)
# CHECK: { immext(#4096)
# CHECK-NEXT: r14 = memuh(##4096) }
r15 = memw(##0x1000)
# CHECK: { immext(#4096)
# CHECK-NEXT: r15 = memw(##4096) }
{R22 = #1; memb(##0x1000) = R22.new}
# CHECK: { r22 = #1
# CHECK-NEXT: immext(#4096)
# CHECK-NEXT: memb(##4096) = r22.new }
{R23 = #1; memh(##0x1000) = R23.new}
# CHECK: { r23 = #1
# CHECK-NEXT: immext(#4096)
# CHECK-NEXT: memh(##4096) = r23.new }
{R24 = #1; memw(##0x1000) = R24.new}
# CHECK: { r24 = #1
# CHECK-NEXT: immext(#4096)
# CHECK-NEXT: memw(##4096) = r24.new }
memd(##0x1000) = R17:16
# CHECK: { immext(#4096)
# CHECK-NEXT: memd(##4096) = r17:16 }
memb(##0x1000) = R18
# CHECK: { immext(#4096)
# CHECK-NEXT: memb(##4096) = r18 }
memh(##0x1000) = r19.h
# CHECK: { immext(#4096)
# CHECK-NEXT: memh(##4096) = r19.h }
memh(##0x1000) = R20
# CHECK: { immext(#4096)
# CHECK-NEXT: memh(##4096) = r20 }
memw(##0x1000) = R21
# CHECK: { immext(#4096)
# CHECK-NEXT: memw(##4096) = r21 }