home *** CD-ROM | disk | FTP | other *** search
/ Amiga ISO Collection / AmigaUtilCD2.iso / Programming / Misc / CLISP-2.LHA / CLISP960530-ki.lha / ffcall / avcall / avcall-i386.S < prev    next >
Encoding:
Text File  |  1996-04-15  |  2.4 KB  |  186 lines

  1. #ifdef UNDERSCORE
  2. #ifdef __STDC__
  3. #define C(entrypoint) _##entrypoint
  4. #else
  5. #define C(entrypoint) _/**/entrypoint
  6. #endif
  7. #else
  8. #define C(entrypoint) entrypoint
  9. #endif
  10.     .file    "avcall-i386.c"
  11. gcc2_compiled.:
  12. C(__gnu_compiled_c:)
  13. .text
  14.     .align 4
  15. .globl C(__builtin_avcall)
  16. C(__builtin_avcall:)
  17.     pushl %ebp
  18.     movl %esp,%ebp
  19.     pushl %esi
  20.     pushl %ebx
  21.     movl 8(%ebp),%esi
  22.     addl $-1024,%esp
  23.     movl 20(%esi),%eax
  24.     addl $-32,%eax
  25.     subl %esi,%eax
  26.     movl %eax,%ecx
  27.     sarl $2,%ecx
  28.     xorl %ebx,%ebx
  29.     cmpl %ecx,%ebx
  30.     jge L3
  31.     movl %esp,%edx
  32. L5:
  33.     movl 32(%esi,%ebx,4),%eax
  34.     movl %eax,(%edx)
  35.     addl $4,%edx
  36.     incl %ebx
  37.     cmpl %ecx,%ebx
  38.     jl L5
  39. L3:
  40.     testb $8,4(%esi)
  41.     je L7
  42.     cmpl $14,12(%esi)
  43.     jne L7
  44. #APP
  45.     movl 8(%esi),%ebx
  46. #NO_APP
  47. L7:
  48.     movl 12(%esi),%eax
  49.     cmpl $11,%eax
  50.     je L9
  51.     cmpl $12,%eax
  52.     je L10
  53.     jmp L11
  54. L9:
  55.     movl (%esi),%eax
  56.     call *%eax
  57.     movl 8(%esi),%eax
  58.     fstps (%eax)
  59.     jmp L13
  60. L10:
  61.     movl (%esi),%eax
  62.     call *%eax
  63.     movl 8(%esi),%eax
  64.     fstpl (%eax)
  65.     jmp L13
  66. L11:
  67.     movl (%esi),%eax
  68.     call *%eax
  69.     movl %eax,%ebx
  70.     cmpl $14,12(%esi)
  71.     ja L13
  72.     movl 12(%esi),%eax
  73.     jmp *L53(,%eax,4)
  74. L53:
  75.     .long L47
  76.     .long L13
  77.     .long L45
  78.     .long L45
  79.     .long L45
  80.     .long L46
  81.     .long L46
  82.     .long L47
  83.     .long L47
  84.     .long L47
  85.     .long L47
  86.     .long L13
  87.     .long L13
  88.     .long L47
  89.     .long L28
  90. L28:
  91.     testb $1,4(%esi)
  92.     je L29
  93.     movl 16(%esi),%eax
  94.     cmpl $2,%eax
  95.     je L32
  96.     ja L41
  97.     cmpl $1,%eax
  98.     je L31
  99.     jmp L35
  100. L41:
  101.     cmpl $4,%eax
  102.     je L33
  103.     cmpl $8,%eax
  104.     je L34
  105.     jmp L35
  106. L31:
  107.     movl 8(%esi),%edx
  108.     movb (%ebx),%al
  109.     movb %al,(%edx)
  110.     jmp L13
  111. L32:
  112.     movl 8(%esi),%edx
  113.     movw (%ebx),%ax
  114.     movw %ax,(%edx)
  115.     jmp L13
  116. L33:
  117.     movl 8(%esi),%edx
  118.     movl (%ebx),%eax
  119.     movl %eax,(%edx)
  120.     jmp L13
  121. L34:
  122.     movl 8(%esi),%edx
  123.     movl (%ebx),%eax
  124.     movl %eax,(%edx)
  125.     movl 8(%esi),%edx
  126.     movl 4(%ebx),%eax
  127.     movl %eax,4(%edx)
  128.     jmp L13
  129. L35:
  130.     movl 16(%esi),%eax
  131.     addl $3,%eax
  132.     movl %eax,%ecx
  133.     shrl $2,%ecx
  134.     decl %ecx
  135.     js L13
  136.     leal (%ebx,%ecx,4),%ebx
  137. L38:
  138.     movl 8(%esi),%edx
  139.     movl (%ebx),%eax
  140.     movl %eax,(%edx,%ecx,4)
  141.     addl $-4,%ebx
  142.     decl %ecx
  143.     jns L38
  144.     jmp L13
  145. L29:
  146.     testb $1,5(%esi)
  147.     je L13
  148.     movl 16(%esi),%eax
  149.     cmpl $2,%eax
  150.     je L46
  151.     ja L51
  152.     cmpl $1,%eax
  153.     je L45
  154.     jmp L13
  155. L51:
  156.     cmpl $4,%eax
  157.     je L47
  158.     cmpl $8,%eax
  159.     je L48
  160.     jmp L13
  161. L45:
  162.     movl 8(%esi),%eax
  163.     movb %bl,(%eax)
  164.     jmp L13
  165. L46:
  166.     movl 8(%esi),%eax
  167.     movw %bx,(%eax)
  168.     jmp L13
  169. L47:
  170.     movl 8(%esi),%eax
  171.     movl %ebx,(%eax)
  172.     jmp L13
  173. L48:
  174.     movl 8(%esi),%eax
  175.     movl %ebx,(%eax)
  176.     movl 8(%esi),%eax
  177.     movl %edx,4(%eax)
  178. L13:
  179.     xorl %eax,%eax
  180.     leal -8(%ebp),%esp
  181.     popl %ebx
  182.     popl %esi
  183.     movl %ebp,%esp
  184.     popl %ebp
  185.     ret
  186.