PPC: Fix rldcl
[qemu/agraf.git] / tests / tcg / mips / mips32-dsp / absq_s_w.c
blob3f52a48039cdc03c49303ec3e2fdbe56ba473f81
1 #include<stdio.h>
2 #include<assert.h>
4 int main()
6 int rd, rt;
7 int result;
9 rt = 0x80000000;
10 result = 0x7FFFFFFF;
11 __asm
12 ("absq_s.w %0, %1\n\t"
13 : "=r"(rd)
14 : "r"(rt)
16 assert(rd == result);
18 rt = 0x80030000;
19 result = 0x7FFD0000;
20 __asm
21 ("absq_s.w %0, %1\n\t"
22 : "=r"(rd)
23 : "r"(rt)
25 assert(rd == result);
27 rt = 0x31036080;
28 result = 0x31036080;
29 __asm
30 ("absq_s.w %0, %1\n\t"
31 : "=r"(rd)
32 : "r"(rt)
34 assert(rd == result);
36 return 0;