s390-ccw.img: replace while loop with a disabled wait on s390 bios
[qemu/agraf.git] / tests / tcg / mips / mips64-dsp / dextrv_w.c
blob973765c1c0acdfdb73ef78d6fcadd2d3966839a7
1 #include "io.h"
3 int main(void)
5 long long rt, rs;
6 long long achi, acli;
7 long long res;
9 achi = 0x87654321;
10 acli = 0x12345678;
11 rs = 0x8;
13 res = 0x123456;
15 __asm
16 ("mthi %1, $ac1\n\t"
17 "mtlo %2, $ac1\n\t"
18 "dextrv.w %0, $ac1, %3\n\t"
19 : "=r"(rt)
20 : "r"(achi), "r"(acli), "r"(rs)
22 if (rt != res) {
23 printf("dextrv.w error\n");
24 return -1;
27 achi = 0x87654321;
28 acli = 0x12345678;
29 rs = 0x0;
31 res = 0x12345678;
33 __asm
34 ("mthi %1, $ac1\n\t"
35 "mtlo %2, $ac1\n\t"
36 "dextrv.w %0, $ac1, %3\n\t"
37 : "=r"(rt)
38 : "r"(achi), "r"(acli), "r"(rs)
40 if (rt != res) {
41 printf("dextrv.w error\n");
42 return -1;
45 return 0;