head_ac.e 1.3 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081
  1. #
  2. #include "em_abs.h"
  3. /*
  4. * (c) copyright 1983 by the Vrije Universiteit, Amsterdam, The Netherlands.
  5. *
  6. * This product is part of the Amsterdam Compiler Kit.
  7. *
  8. * Permission to use, sell, duplicate or disclose this software must be
  9. * obtained in writing. Requests for such permissions may be sent to
  10. *
  11. * Dr. Andrew S. Tanenbaum
  12. * Wiskundig Seminarium
  13. * Vrije Universiteit
  14. * Postbox 7161
  15. * 1007 MC Amsterdam
  16. * The Netherlands
  17. *
  18. */
  19. /* Disabled catch handler --- this is the platform's job. dtrg */
  20. #undef CATCHHANDLER
  21. mes 2,_EM_WSIZE,_EM_PSIZE
  22. exa environ
  23. exa _end
  24. exp $_m_a_i_n
  25. pro $_m_a_i_n,0
  26. loc 1336 ; EIOVFL | EIUND | ECONV | EFOVFL | EFUNFL
  27. sim ; ignored
  28. lal _EM_WSIZE+_EM_PSIZE
  29. loi _EM_PSIZE
  30. lae environ
  31. sti _EM_PSIZE
  32. #ifdef CATCHHANDLER
  33. #if __unix && ! (__em22 || __em24 || __em44)
  34. lpi $_ctch_
  35. sig
  36. asp _EM_PSIZE
  37. #endif
  38. #endif
  39. lal _EM_WSIZE+_EM_PSIZE
  40. loi _EM_PSIZE
  41. lal _EM_WSIZE
  42. loi _EM_PSIZE
  43. lal 0
  44. loi _EM_WSIZE
  45. cal $main
  46. asp _EM_WSIZE+_EM_PSIZE+_EM_PSIZE
  47. lfr _EM_WSIZE
  48. cal $exit
  49. end
  50. #ifdef CATCHHANDLER
  51. #if __unix && ! (__em22 || __em24 || __em44)
  52. exp $_ctch_
  53. pro $_ctch_,0
  54. lol 0
  55. loc EIDIVZ
  56. beq *1
  57. lol 0
  58. loc EFDIVZ
  59. beq *1
  60. lol 0
  61. trp
  62. bra *3
  63. 1
  64. loc 8
  65. cal $getpid
  66. lfr _EM_WSIZE
  67. cal $kill
  68. asp 2*_EM_WSIZE
  69. 3
  70. lpi $_ctch_
  71. sig
  72. asp _EM_PSIZE
  73. rtt
  74. end 0
  75. #endif
  76. #endif