home *** CD-ROM | disk | FTP | other *** search
/ NetNews Usenet Archive 1992 #26 / NN_1992_26.iso / spool / comp / unix / sysv386 / 16311 < prev    next >
Encoding:
Internet Message Format  |  1992-11-08  |  1.7 KB

  1. Xref: sparky comp.unix.sysv386:16311 comp.unix.sys5.r4:459
  2. Path: sparky!uunet!auspex-gw!guy
  3. From: guy@Auspex.COM (Guy Harris)
  4. Newsgroups: comp.unix.sysv386,comp.unix.sys5.r4
  5. Subject: Re: mmap and segv, a better way. Was: Re: av386mon source posted to alt.sources
  6. Message-ID: <15387@auspex-gw.auspex.com>
  7. Date: 7 Nov 92 09:52:18 GMT
  8. References: <1992Oct2.184624.4441@omega.ssw.de> <1992Nov6.181051.8438@cichlid.com>
  9. Sender: news@auspex-gw.auspex.com
  10. Followup-To: comp.unix.sysv386
  11. Organization: Auspex Systems, Santa Clara
  12. Lines: 23
  13. Nntp-Posting-Host: auspex-gw.auspex.com
  14. Nntp-Posting-Host: bootme.auspex.com
  15. Originator: news@auspex-gw.Auspex.COM
  16.  
  17. >An even cleaner way works on SunOS. You may want to check if sysvr4
  18. >supports this. In the signal handler if you simply return the
  19. >OS retrys the faulting instruction.
  20.  
  21. Err, in *some* SunOS releases on *some* processors, it does so.
  22.  
  23. It didn't do so on the 68K Suns until 4.1 or 4.1.1 or so; the problem is
  24. that there's some amount of context information required to continue the
  25. faulting instruction, and that information wasn't saved until the
  26. release in question.
  27.  
  28. It should work OK on SPARC and 386-based Suns.
  29.  
  30. I.e., it's not a question of whether SVR4 supports it, it's a question
  31. of whether SVR4 *on the platform in question* supports it (although it
  32. probably does, in order to make the Bourne shell work, unless they back
  33. the SIGSEGV hack out in SVR4, as we had to do at one point in SunOS).
  34.  
  35. >Oh yes, the exact details of what address was accessed, program counter, etc
  36. >is supplied to the signal handler (3rd argument is pointer to a struct that
  37. >contains this info, as I recall).
  38.  
  39. In SVR4, that's done as well, although in a different form.
  40.