repo.or.cz
/
qemu
/
agraf.git
/
blob
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
log
|
graphiclog1
|
graphiclog2
|
commit
|
commitdiff
|
tree
|
refs
|
edit
|
fork
blame
|
history
|
raw
|
HEAD
virtio-serial: make flow control explicit in virtio-console
[qemu/agraf.git]
/
tests
/
tcg
/
mips
/
mips64-dspr2
/
precr_sra_r_ph_w.c
blob
62d220dcaeaeb951e477919e5b7ea9db88118e31
1
#include
"io.h"
2
3
int
main
(
void
)
4
{
5
long long
rs
,
rt
;
6
long long
result
;
7
8
rs
=
0x12345678
;
9
rt
=
0x87654321
;
10
result
=
0x43215678
;
11
12
__asm
13
(
"precr_sra_r.ph.w %0, %1, 0x00
\n\t
"
14
:
"+r"
(
rt
)
15
:
"r"
(
rs
)
16
);
17
if
(
result
!=
rt
) {
18
printf
(
"precr_sra_r.ph.w error
\n
"
);
19
return
-
1
;
20
}
21
22
rs
=
0x12345678
;
23
rt
=
0x87654321
;
24
result
=
0xFFFFFFFFFFFF0000
;
25
26
__asm
27
(
"precr_sra_r.ph.w %0, %1, 0x1F
\n\t
"
28
:
"+r"
(
rt
)
29
:
"r"
(
rs
)
30
);
31
if
(
result
!=
rt
) {
32
printf
(
"precr_sra_r.ph.w error
\n
"
);
33
return
-
1
;
34
}
35
36
return
0
;
37
}