1#include "io.h" 2 3int main(void) 4{ 5 long long rs, rt; 6 long long res; 7 8 rt = 0x8765432187654321; 9 rs = 0x1234567812345678; 10 11 res = 0x4321432156785678; 12 13 __asm 14 ("precr_sra_r.qh.pw %0, %1, 0x0\n\t" 15 : "=r"(rt) 16 : "r"(rs) 17 ); 18 19 if (rt != res) { 20 printf("precr_sra_r.qh.pw error\n"); 21 return -1; 22 } 23 24 rt = 0x8765432187654321; 25 rs = 0x1234567812345678; 26 27 res = 0x5432543245684568; 28 29 __asm 30 ("precr_sra_r.qh.pw %0, %1, 0x4\n\t" 31 : "=r"(rt) 32 : "r"(rs) 33 ); 34 35 if (rt != res) { 36 printf("precr_sra_r.qh.pw error\n"); 37 return -1; 38 } 39 return 0; 40} 41