repo.or.cz
/
qemu
/
ar7.git
/
blob
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
log
|
graphiclog1
|
graphiclog2
|
commit
|
commitdiff
|
tree
|
refs
|
edit
|
fork
blame
|
history
|
raw
|
HEAD
cputlb: Move tlb_lock to CPUTLBCommon
[qemu/ar7.git]
/
tests
/
tcg
/
mips
/
mips64-dspr2
/
shrav_qb.c
blob
a716203d806ed1cb182225c5e0933a8e6f471081
1
#include
"io.h"
2
3
int
main
(
void
)
4
{
5
long long
rd
,
rs
,
rt
;
6
long long
result
;
7
8
rs
=
0x03
;
9
rt
=
0x12345678
;
10
result
=
0x02060A0F
;
11
12
__asm
13
(
"shrav.qb %0, %1, %2
\n\t
"
14
:
"=r"
(
rd
)
15
:
"r"
(
rt
),
"r"
(
rs
)
16
);
17
if
(
rd
!=
result
) {
18
printf
(
"shrav.qb error
\n
"
);
19
return
-
1
;
20
}
21
22
rs
=
0x03
;
23
rt
=
0x87654321
;
24
result
=
0xFFFFFFFFF00C0804
;
25
26
__asm
27
(
"shrav.qb %0, %1, %2
\n\t
"
28
:
"=r"
(
rd
)
29
:
"r"
(
rt
),
"r"
(
rs
)
30
);
31
if
(
rd
!=
result
) {
32
printf
(
"shrav.qb error
\n
"
);
33
return
-
1
;
34
}
35
36
return
0
;
37
}