s_scalbnl.S 822 B

12345678910111213141516171819202122232425262728293031323334353637383940
  1. /*
  2. * Based on code written by J.T. Conklin <[email protected]>.
  3. * Public domain.
  4. */
  5. #include <amd64/bsd_asm.h>
  6. //__FBSDID("$FreeBSD: src/lib/msun/amd64/s_scalbnl.S,v 1.3 2011/01/07 16:13:12 kib Exp $")
  7. /* //RCSID("$NetBSD: s_scalbnf.S,v 1.4 1999/01/02 05:15:40 kristerw Exp $") */
  8. ENTRY(scalbnl)
  9. #ifndef _WIN64
  10. movl %edi,-4(%rsp)
  11. fildl -4(%rsp)
  12. fldt 8(%rsp)
  13. #else
  14. mov %r8,%rax
  15. movl %eax,-4(%rsp)
  16. fildl -4(%rsp)
  17. fldt (%rdx)
  18. #endif
  19. fscale
  20. fstp %st(1)
  21. #ifdef _WIN64
  22. mov %rcx,%rax
  23. movq $0x0,0x8(%rcx)
  24. fstpt (%rcx)
  25. #endif
  26. ret
  27. #ifndef _WIN64
  28. END(scalbnl)
  29. .globl CNAME(ldexpl)
  30. #else
  31. .globl CNAME(ldexpl); .section .drectve; .ascii " -export:ldexpl"
  32. #endif
  33. .set CNAME(ldexpl),CNAME(scalbnl)
  34. /* Enable stack protection */
  35. #if defined(__ELF__)
  36. .section .note.GNU-stack,"",%progbits
  37. #endif