fork(3) download
  1. #include <stdio.h>
  2. int main (void) {
  3. double sin_a, cos_a, a = 0.5;
  4. __asm__ ("fldl %2;"
  5. "fsincos;"
  6. "fstpl %1;"
  7. "fstpl %0;" : "=m"(sin_a), "=m"(cos_a) : "m"(a));
  8. printf("sin(29°) = %f, cos(29°) = %f\n", sin_a, cos_a);
  9. return 0;
  10. }
Success #stdin #stdout 0.01s 1720KB
stdin
Standard input is empty
stdout
sin(29°) = 0.479426, cos(29°) = 0.877583