home *** CD-ROM | disk | FTP | other *** search
/ NetNews Usenet Archive 1992 #31 / NN_1992_31.iso / spool / comp / os / research / 1152 next >
Encoding:
Internet Message Format  |  1992-12-22  |  3.7 KB

  1. Path: sparky!uunet!olivea!hal.com!darkstar.UCSC.EDU!osr
  2. From: pcg@aber.ac.uk (Piercarlo Grandi)
  3. Newsgroups: comp.os.research
  4. Subject: Re: On debugging (was Re: Microkernel for Real-Time Computing)
  5. Message-ID: <1h8gmpINNnlg@darkstar.UCSC.EDU>
  6. Date: 23 Dec 92 01:51:21 GMT
  7. References: <1fgqaaINNntl@darkstar.UCSC.EDU> <1g35g7INNfvt@darkstar.UCSC.EDU>
  8. Organization: Prifysgol Cymru, Aberystwyth
  9. Lines: 73
  10. Approved: comp-os-research@ftp.cse.ucsc.edu
  11. NNTP-Posting-Host: ftp.cse.ucsc.edu
  12. Originator: osr@ftp
  13.  
  14. Tage Stabell-kuloe writes:
  15.  
  16.   [ .. micro kernelization helps as putting each separate bit of
  17.   functionality is a separate address space helps with catching
  18.   errorneous memory references ... ]
  19.  
  20. Tage> There is no such thing as a free lunch.  It is more expensive for
  21. Tage> one service in the kernel to [insert your favourite IPC mechanism
  22. Tage> here] in order to inform another part of some event, then just
  23. Tage> jumping to it.
  24.  
  25. The cost can be very much reduced. I have proposed ten years ago having
  26. threads that can switch address spaces, so that each address space
  27. becomes a protected procedure (a la CAP or PDP-1, or more recently
  28. Richester's Elmwood or Psyche), that can have a variable number of
  29. threads (from zero to N) running in it.
  30.  
  31. So for example each device driver, file system type, cache manager could
  32. be a different address space, and (both kernel and user) threads can
  33. switch address space to access each module's code and state.
  34.  
  35. The cost of doing so is amazingly small even on stock processors (wait
  36. about one year for my dissertation to complete :->). All you do
  37. essentially is, on many architectures, change the pointer to the page
  38. tables.
  39.  
  40. Then this becomes quite true:
  41.  
  42. On 15 Dec 92 20:41:53 GMT, peter@ferranti.com (peter da silva) commented:
  43.  
  44. peter> Sure, but if you simultaneously speed up IPC (like, by making the
  45. peter> kernel small enough to fit in the on-chip cache) then everything
  46. peter> in the system becomes faster. If you speed up IPC enough, it
  47. peter> becomes lost in the noise.
  48.  
  49. Since one can use exactly the same mechanism described above for
  50. kernel-kernel, user-kernel, user-user address space communications, then
  51. one get even a speed up.
  52.  
  53. Even kernels that copy things around a bit (starting with Thoth) or that
  54. do copy-on-writing have been shown to have low enough IPC costs.
  55.  
  56. If anybody from QNX is reading, I guess they will take the opportunity
  57. to boast about how low have become their overheads with release 4.0 (and
  58. I think they were low enough already).n
  59.  
  60. Only if you do it very innocently on totally unsuitable hardware
  61. (Berkeley's venerable capability OS for CDC's mainframes) things are
  62. bleak.
  63.  
  64. peter> Personally, I think the ideal solution would be to provide a
  65. peter> binary interface to the kernel that reains the same whether
  66. peter> you're running in the kernel address space or not,
  67.  
  68. Indeed, indeed. This is particularly easy if one uses doubly indirect
  69. pointers to address space entry points, much as Mach does for ports.
  70.  
  71. peter> so moving things into and out of the kernel simply becomes a
  72. peter> matter of performance tuning.
  73.  
  74. Actually you never need move anything in the 'kernel'; the kernel just
  75. maintains the entry point capabilities, and does address space
  76. switching, not even task switching (well, in theory). Everything else is
  77. in some address space. Some address spaces are given privilege to access
  78. hw resources (e.g. drivers, the real memory allocator), but that's all.
  79.  
  80. There have been a few systems like this in the past, for example KeyKOS
  81. (the scheduler(s) can be user code, which is one up on Mach or TWENEX,
  82. where only the pager(s) can be user code)
  83. --
  84. Piercarlo Grandi, Dept of CS, PC/UW@Aberystwyth <pcg@aber.ac.uk>
  85.   E l'italiano cantava, cantava. E le sue disperate invocazioni giunsero
  86.   alle orecchie del suo divino protettore, il dio della barzelletta
  87.