1#include <math.h> 2 3long long llrint(double x) 4{ 5 long long r; 6 __asm__ ("fistpll %0" : "=m"(r) : "t"(x) : "st"); 7 return r; 8} 9