s390-ccw.img: replace while loop with a disabled wait on s390 bios
[qemu/agraf.git] / tests / tcg / mips / mips64-dsp / pick_qb.c
blob0d5de9db9ed543142e2759c3b2fdde39e8828ef8
1 #include "io.h"
3 int main(void)
5 long long rd, rs, rt, dsp;
6 long long result;
8 rs = 0x12345678;
9 rt = 0x87654321;
10 dsp = 0x0f000000;
11 result = 0x12345678;
13 __asm
14 ("wrdsp %3, 0x10\n\t"
15 "pick.qb %0, %1, %2\n\t"
16 : "=r"(rd)
17 : "r"(rs), "r"(rt), "r"(dsp)
19 if (rd != result) {
20 printf("pick.qb wrong\n");
22 return -1;
25 rs = 0x12345678;
26 rt = 0x87654321;
27 dsp = 0x00000000;
28 result = 0xffffffff87654321;
30 __asm
31 ("wrdsp %3, 0x10\n\t"
32 "pick.qb %0, %1, %2\n\t"
33 : "=r"(rd)
34 : "r"(rs), "r"(rt), "r"(dsp)
36 if (rd != result) {
37 printf("pick.qb wrong\n");
39 return -1;
42 return 0;