repo.or.cz
/
qemu.git
/
blob
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
log
|
graphiclog1
|
graphiclog2
|
commit
|
commitdiff
|
tree
|
refs
|
edit
|
fork
blame
|
history
|
raw
|
HEAD
Merge tag 'qemu-macppc-20230206' of https://github.com/mcayland/qemu into staging
[qemu.git]
/
tests
/
tcg
/
mips
/
user
/
ase
/
dsp
/
test_dsp_r2_addqh_ph.c
blob
921f0eaf33c7c81066dd6d330542065ed17bfab3
1
#include<stdio.h>
2
#include<assert.h>
3
4
int
main
()
5
{
6
int
rd
,
rs
,
rt
;
7
int
result
;
8
9
rs
=
0x706A13FE
;
10
rt
=
0x13065174
;
11
result
=
0x41B832B9
;
12
__asm
13
(
"addqh.ph %0, %1, %2
\n\t
"
14
:
"=r"
(
rd
)
15
:
"r"
(
rs
),
"r"
(
rt
)
16
);
17
assert
(
rd
==
result
);
18
19
rs
=
0x81000100
;
20
rt
=
0xc2000100
;
21
result
=
0xa1800100
;
22
__asm
23
(
"addqh.ph %0, %1, %2
\n\t
"
24
:
"=r"
(
rd
)
25
:
"r"
(
rs
),
"r"
(
rt
)
26
);
27
assert
(
rd
==
result
);
28
29
return
0
;
30
}