1*073d9f2cSAleksandar Markovic #include<stdio.h> 2*073d9f2cSAleksandar Markovic #include<assert.h> 3*073d9f2cSAleksandar Markovic 4*073d9f2cSAleksandar Markovic int main() 5*073d9f2cSAleksandar Markovic { 6*073d9f2cSAleksandar Markovic int rd, rs, rt; 7*073d9f2cSAleksandar Markovic int result; 8*073d9f2cSAleksandar Markovic 9*073d9f2cSAleksandar Markovic rs = 0x03; 10*073d9f2cSAleksandar Markovic rt = 0x12345678; 11*073d9f2cSAleksandar Markovic result = 0x02070B0F; 12*073d9f2cSAleksandar Markovic 13*073d9f2cSAleksandar Markovic __asm 14*073d9f2cSAleksandar Markovic ("shrav_r.qb %0, %1, %2\n\t" 15*073d9f2cSAleksandar Markovic : "=r"(rd) 16*073d9f2cSAleksandar Markovic : "r"(rt), "r"(rs) 17*073d9f2cSAleksandar Markovic ); 18*073d9f2cSAleksandar Markovic assert(rd == result); 19*073d9f2cSAleksandar Markovic 20*073d9f2cSAleksandar Markovic rs = 0x03; 21*073d9f2cSAleksandar Markovic rt = 0x87654321; 22*073d9f2cSAleksandar Markovic result = 0xF10D0804; 23*073d9f2cSAleksandar Markovic 24*073d9f2cSAleksandar Markovic __asm 25*073d9f2cSAleksandar Markovic ("shrav_r.qb %0, %1, %2\n\t" 26*073d9f2cSAleksandar Markovic : "=r"(rd) 27*073d9f2cSAleksandar Markovic : "r"(rt), "r"(rs) 28*073d9f2cSAleksandar Markovic ); 29*073d9f2cSAleksandar Markovic assert(rd == result); 30*073d9f2cSAleksandar Markovic 31*073d9f2cSAleksandar Markovic return 0; 32*073d9f2cSAleksandar Markovic } 33