home *** CD-ROM | disk | FTP | other *** search
/ Il CD di internet / CD.iso / SOURCE / D / LIBC / LIBC-4.6 / LIBC-4 / libc-linux / sysdeps / linux / i386 / math / coshl.S < prev    next >
Encoding:
Text File  |  1994-10-10  |  1.6 KB  |  103 lines

  1. /* Copyright (C) 1993  Hongjiu Lu
  2. This file is part of the Linux C Library.
  3.  
  4. The Linux C Library is free software; you can redistribute it and/or
  5. modify it under the terms of the GNU Library General Public License as
  6. published by the Free Software Foundation; either version 2 of the
  7. License, or (at your option) any later version.
  8.  
  9. The Linux C Library is distributed in the hope that it will be useful,
  10. but WITHOUT ANY WARRANTY; without even the implied warranty of
  11. MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the GNU
  12. Library General Public License for more details. */
  13.  
  14.     .file    "cosh.S"
  15.  
  16. #ifdef __ELF__
  17. #define _coshl    coshl
  18. #endif
  19.  
  20. #ifdef __ELF__
  21.     .section    .rodata
  22. #else
  23.     .text
  24. #endif
  25.  
  26. #ifdef __i486__
  27.     .align    4,0x90
  28. #else
  29.     .align    2,0x90
  30. #endif
  31.  
  32. #ifdef __ELF__
  33. .LC0:
  34. #else
  35. LC0:
  36. #endif
  37.     .double 0d5.0000000000000000000000e-01
  38.  
  39.     .text
  40.     .globl    _coshl
  41. #ifdef __i486__
  42.     .align    4,0x90
  43. #else
  44.     .align    2,0x90
  45. #endif
  46.  
  47. _coshl:
  48.     pushl    %ebp
  49.     movl    %esp,%ebp
  50.     subl    $8,%esp
  51. #ifdef __PIC__
  52.     pushl    %ebx
  53.     call    .L2
  54. .L2:
  55.     popl    %ebx
  56.     addl    $_GLOBAL_OFFSET_TABLE_+[.-.L2],%ebx
  57. #endif
  58.     fldt    8(%ebp)
  59.     fldl2e
  60.     fmulp    %st,%st(1)
  61.     fst    %st(1)
  62.     fstcw    -4(%ebp)
  63.     fstcw    -8(%ebp)
  64.     fwait
  65.     andw    $0xf3ff,-4(%ebp)
  66.     fldcw    -4(%ebp)
  67.     frndint
  68.     fldcw    -8(%ebp)
  69.     fst    %st(2)
  70.     fsubrp    %st,%st(1)
  71.     f2xm1
  72.     fld1
  73.     faddp    %st,%st(1)
  74.     fscale
  75.     fst    %st(1)
  76.  
  77.     fld1
  78.     fdivp    %st,%st(1)
  79.     faddp    %st,%st(1)
  80.  
  81. #ifdef __PIC__
  82.     fldl    .LC0@GOTOFF(%ebx)
  83. #else
  84. #ifdef __ELF__
  85.     fldl    .LC0
  86. #else
  87.     fldl    LC0
  88. #endif
  89. #endif
  90.     fmulp    %st,%st(1)
  91.  
  92. #ifdef __PIC__
  93.     popl    %ebx
  94. #endif
  95.     movl    %ebp,%esp
  96.     popl    %ebp
  97.     ret
  98.  
  99.  
  100. #ifdef __ELF__
  101.     .type    coshl,@function
  102. #endif
  103.