1 #include <stdio.h> 2 3 int main () 4 { 5 int out [] = {0, 0}; 6 unsigned long long in [] = {0x405EE0A3D70A3D71ULL, 0x3FF0000000000000ULL}; 7 __asm__ volatile("cfc1 $a1, $31" "\n\t" 8 "ldc1 $f0, 0(%0)" "\n\t" 9 "ctc1 $zero, $31" "\n\t" 10 "round.w.d $f0, $f0" "\n\t" 11 "cfc1 $a2, $31" "\n\t" 12 "sw $a2, 0(%1)" "\n\t" 13 "ldc1 $f0, 8(%0)" "\n\t" 14 "ctc1 $zero, $31" "\n\t" 15 "round.w.d $f0, $f0" "\n\t" 16 "cfc1 $a2, $31" "\n\t" 17 "sw $a2, 4(%1)" "\n\t" 18 "ctc1 $a1, $31" "\n\t" 19 : 20 : "r" (in), "r" (out) 21 : "a1", "a2", "t0", "$f0", "$f1" 22 ); 23 printf("FCSR::1: 0x%x, 2: 0x%x\n", out[0], out[1]); 24 return 0; 25 } 26