home *** CD-ROM | disk | FTP | other *** search
/ NetNews Usenet Archive 1992 #27 / NN_1992_27.iso / spool / comp / sys / atari / st / 16988 < prev    next >
Encoding:
Text File  |  1992-11-21  |  3.4 KB  |  69 lines

  1. Newsgroups: comp.sys.atari.st
  2. Path: sparky!uunet!microsoft!hexnut!darekm
  3. From: darekm@microsoft.com (Darek Mihocka)
  4. Subject: Re: New TOS versions?
  5. Message-ID: <1992Nov22.011545.3921@microsoft.com>
  6. Date: 22 Nov 92 01:15:45 GMT
  7. Organization: Microsoft Corporation
  8. References: <1992Nov17.122627.16049@crc.ac.uk> <1992Nov19.024438.22369@microsoft.com> <1992Nov20.160320.11380@dcs.warwick.ac.uk>
  9. Lines: 55
  10.  
  11. >  I didn't know the story behind the inclusion of Line-F system before - I
  12. >always thought it seem an extreamly slow way of doing things.
  13. >  Interestingly some of the line A functions are actually very well written
  14. >- I tried to write a fast resolution dependant line drawing routine in
  15. >assembler once, using the best algorithms I could find in books and in the end
  16. >used line A because it was so very nearly as fast.
  17.  
  18. Line A and Line F traps are a good idea and a bad idea, depending on what you
  19. use them for. A line A or line F instruction occupies 2 bytes of code, compared
  20. to 6 bytes for a typical JSR instruction. So if you make a lot of calls to the
  21. same routines, it becomes a great reduction method to use line F, which is
  22. exactly what the TOS ROMs did. The line F handler simply had a table of the
  23. routines and jumped to the appropriate routine depending on what the full 16-bit
  24. line F trap number was. Same goes for line A. The Mac operating system does the
  25. same thing with line A.
  26.  
  27. But, there is a certain amount of overhead with handling each trap, let's just
  28. say 100 clock cycles. A JSR RTS combination is only 36 cycles. If the routine
  29. you're calling takes thousands of clock cycles, the overhead is minimum. But
  30. if you do it every few lines of code like the TOS ROMs, you waste a lot of time
  31. in the line F handler. That's exactly why TOS 1.0 on disk (which uses no line F)
  32. is about 10% faster than TOS 1.0 in ROM. Of why TOS 1.4 in ROM is slower than
  33. TOS 1.6 in ROM. 1.4 has line F and 1.6 doesn't.
  34.  
  35.  
  36. >  Then sell the source to Derek for recompilation to 386 code for his
  37. >Gemulator which would then be usably fast on a sub #1000 PC (if not too fast).
  38.  
  39. I'm way ahead of you there. When I sold off Quick ST to Codehead, I kept rights
  40. to the source code for just such a purpose. Already, Gemulator 2.0 has parts
  41. of Quick ST implemented in it as 386 code. That's what the QUICK option in
  42. Gemulator does. oooooh, pretty sneaky, huh? Right now, a chunk of VT52 and
  43. a little bit of VDI is implemented, so if you flick QUICK on, you'll notice
  44. about a 50% speedup in text and string redraws, and about 10% in VDI. As I do
  45. more work on it in the next few months you'll see the numbers go up more and more.
  46.  
  47. And this is a faster and more compatible thing to do than hooking trap handlers
  48. like Quick ST does. The QUICK option actually writes 386 code directly over top
  49. the 68000 in the TOS ROMs (since Gemulator loads them into RAM).
  50.  
  51. I'm not sure what you meant by "sub #1000 PC". Is that 1000 dollars or 1000 pounds?
  52. Right now you can buy 25 Mhz 486SX machine for under $1000, and that will give
  53. you roughly 8 Mhz 68000 emulation. You can still use the real Quick ST or Warp 9
  54. running on Gemulator to give you the kind of speed ups you get on a real ST,
  55. since Quick ST does things in less code, Gemulator has to emulate less code and
  56. thus speeds up. Same reason it speeds up a real 68000.
  57.  
  58. - Darek
  59.  
  60. >
  61. >- Leo
  62.  
  63.  
  64. -- 
  65. /--------------------------------------\
  66. | Darek Mihocka. net: darekm@microsoft |
  67. | Views expressed are my own, I think. |
  68. \--------------------------------------/
  69.