s390-ccw.img: replace while loop with a disabled wait on s390 bios
[qemu/agraf.git] / tests / tcg / mips / mips64-dsp / precrq_rs_ph_w.c
blob61da3331fbecef5e648303b95fbcfa8e80788d15
1 #include "io.h"
3 int main(void)
5 long long rd, rs, rt;
6 long long dsp;
7 long long result;
9 rs = 0x12345678;
10 rt = 0x87654321;
11 result = 0x12348765;
13 __asm
14 ("precrq_rs.ph.w %0, %1, %2\n\t"
15 : "=r"(rd)
16 : "r"(rs), "r"(rt)
18 if (result != rd) {
19 printf("1 precrq_rs.ph.w wrong\n");
21 return -1;
24 rs = 0x7fffC678;
25 rt = 0x865432A0;
26 result = 0x7fff8654;
28 __asm
29 ("precrq_rs.ph.w %0, %2, %3\n\t"
30 "rddsp %1\n\t"
31 : "=r"(rd), "=r"(dsp)
32 : "r"(rs), "r"(rt)
34 if ((result != rd) || (((dsp >> 22) & 0x01) != 1)) {
35 printf("2 precrq_rs.ph.w wrong\n");
37 return -1;
40 return 0;