PPC: Fix rldcl
[qemu/agraf.git] / tests / tcg / mips / mips64-dsp / shllv_qh.c
blob0de4077e7d0036292c9cea4b11d97d7b1b9084e6
1 #include "io.h"
3 int main(void)
5 long long rd, rt, rs, dsp;
6 long long result, resultdsp;
8 rt = 0x8765432112345678;
9 rs = 0x0;
10 result = 0x8765432112345678;
11 resultdsp = 0;
13 __asm
14 ("shllv.qh %0, %2, %3\n\t"
15 "rddsp %1\n\t"
16 : "=r"(rd), "=r"(dsp)
17 : "r"(rt), "r"(rs)
20 dsp = (dsp >> 22) & 0x01;
21 if ((dsp != resultdsp) || (rd != result)) {
22 printf("shllv.qh wrong\n");
23 return -1;
26 rt = 0x8765432112345678;
27 rs = 0x4;
28 result = 0x7650321023406780;
29 resultdsp = 1;
31 __asm
32 ("shllv.qh %0, %2, %3\n\t"
33 "rddsp %1\n\t"
34 : "=r"(rd), "=r"(dsp)
35 : "r"(rt), "r"(rs)
38 dsp = (dsp >> 22) & 0x01;
39 if ((dsp != resultdsp) || (rd != result)) {
40 printf("shllv.qh wrong\n");
41 return -1;
44 return 0;