virtio-serial: make flow control explicit in virtio-console
[qemu/agraf.git] / tests / tcg / mips / mips64-dspr2 / mulq_rs_w.c
blobffdc66d54aed8fa62a05bd396ec1d2d42bb5aedb
1 #include"io.h"
3 int main(void)
5 long long rd, rs, rt, dsp;
6 long long result, resultdsp;
8 rs = 0x80001234;
9 rt = 0x80004321;
10 result = 0xFFFFFFFF80005555;
12 __asm
13 ("mulq_rs.w %0, %1, %2\n\t"
14 : "=r"(rd)
15 : "r"(rs), "r"(rt)
17 if (rd != result) {
18 printf("mulq_rs.w error!\n");
19 return -1;
22 rs = 0x80000000;
23 rt = 0x80000000;
24 result = 0x7FFFFFFF;
25 resultdsp = 1;
27 __asm
28 ("mulq_rs.w %0, %2, %3\n\t"
29 "rddsp %1\n\t"
30 : "=r"(rd), "=r"(dsp)
31 : "r"(rs), "r"(rt)
33 dsp = (dsp >> 21) & 0x01;
34 if (rd != result || dsp != resultdsp) {
35 printf("mulq_rs.w error\n");
36 return -1;
39 return 0;