home *** CD-ROM | disk | FTP | other *** search
/ Aminet 18 / aminetcdnumber181997.iso / Aminet / dev / gcc / ixemulsrc.lha / ixemul / stack / stkchk_d0.c < prev    next >
C/C++ Source or Header  |  1996-12-11  |  318b  |  25 lines

  1. #include "a4.h"        /* for the A4 macro */
  2.  
  3. asm("
  4.     .text
  5.     .even
  6.     .globl    ___stkchk_d0
  7.     .globl    ___stkchk_0
  8.  
  9. ___stkchk_d0:
  10.     negl    d0
  11.     addl    sp,d0
  12.     cmpl    "A4(___stk_limit)",d0
  13.     jcc    stkchk_d0_ret
  14.     jmp    ___stkovf
  15. stkchk_d0_ret:
  16.     rts
  17.  
  18. ___stkchk_0:
  19.     cmpl    "A4(___stk_limit)",sp
  20.     jcc    stkchk_0_ret
  21.     jmp    ___stkovf
  22. stkchk_0_ret:
  23.     rts
  24. ");
  25.