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
PPC: Fix rldcl
[qemu/agraf.git]
/
tests
/
tcg
/
mips
/
mips32-dsp
/
shra_ph.c
blob
5b2d840a6bc5ebd1638d1fc92709781deb4bec63
1
#include<stdio.h>
2
#include<assert.h>
3
4
int
main
()
5
{
6
int
rd
,
rt
;
7
int
result
;
8
9
rt
=
0x87654321
;
10
result
=
0xF0EC0864
;
11
12
__asm
13
(
"shra.ph %0, %1, 0x03
\n\t
"
14
:
"=r"
(
rd
)
15
:
"r"
(
rt
)
16
);
17
assert
(
rd
==
result
);
18
19
rt
=
0x87654321
;
20
result
=
0x87654321
;
21
22
__asm
23
(
"shra.ph %0, %1, 0x00
\n\t
"
24
:
"=r"
(
rd
)
25
:
"r"
(
rt
)
26
);
27
assert
(
rd
==
result
);
28
29
return
0
;
30
}