s390-ccw.img: replace while loop with a disabled wait on s390 bios
[qemu/agraf.git] / tests / tcg / mips / mips32-dsp / modsub.c
blobc294eebb519d7f7f148e0c052818fd362cc38bdd
1 #include<stdio.h>
2 #include<assert.h>
4 int main()
6 int rd, rs, rt;
7 int result;
9 rs = 0xFFFFFFFF;
10 rt = 0x000000FF;
11 result = 0xFFFFFF00;
12 __asm
13 ("modsub %0, %1, %2\n\t"
14 : "=r"(rd)
15 : "r"(rs), "r"(rt)
17 assert(result == rd);
19 rs = 0x00000000;
20 rt = 0x00CD1FFF;
21 result = 0x0000CD1F;
22 __asm
23 ("modsub %0, %1, %2\n\t"
24 : "=r"(rd)
25 : "r"(rs), "r"(rt)
27 assert(result == rd);
29 return 0;