home *** CD-ROM | disk | FTP | other *** search
/ OS/2 Shareware BBS: 10 Tools / 10-Tools.zip / mitsch75.zip / scheme-7_5_17-src.zip / scheme-7.5.17 / src / compiler / machines / spectrum / TODO < prev   
Encoding:
Text File  |  1993-10-29  |  2.4 KB  |  106 lines

  1. Optimizations:
  2.  
  3. A:    - Done
  4.  
  5. 5510        (ldi () #x32 8)
  6. 5514        (ldi () 0 9)
  7. 5518        (dep () 8 5 6 9)
  8.  
  9. Could be done with a single ldil instruction.
  10.  
  11. It comes from the sequence
  12.  
  13. (assign (register #x30) (machine-constant #x32))
  14. (assign (register #x31) (machine-constant 0))
  15. (assign (register #x32) (cons-pointer (register #x30) (register #x31)))
  16.  
  17. B:    - Done
  18.  
  19.     (ldi () #x28 7)
  20.     (bl () 1 (@pco 0))
  21.     (dep () 0 #x1F 2 1)
  22.     (ldo () (offset (- continuation-695 *pc*) 0 1) 6)
  23.     (dep () 7 5 6 6)
  24.  
  25. No need for ldi/dep, can be done with depi.
  26.  
  27. It comes from sequence
  28.  
  29. (assign (register #x33) (machine-constant #x28))
  30. (assign (register #x34) (entry:continuation #[uninterned-symbol 482 continuation-695]))
  31. (assign (register #x35) (cons-pointer (register #x33) (register #x34)))
  32.  
  33. C:
  34.  
  35.     (bl () 1 (@pco 0))
  36.     (dep () 0 #x1F 2 1)
  37.     (ldo () (offset (- continuation-695 *pc*) 0 1) 6)
  38.  
  39. can become
  40.  
  41.     (bl () 1 (@pco 0))
  42.     (ldo () (offset (- (- continuation-695 (+ *pc* 4)) privilege-bits) 0 1) 6)
  43.  
  44. assuming that privilege bits are constant.
  45.  
  46. D:    - Done
  47.  
  48.     (ldi () #x28 #xA)
  49.     (stw () #x1F (offset #xC8 0 4))
  50.     (ldil () #x68000 8)
  51.     (ldo () (offset #x18 0 8) 8)
  52.     (stwm () 8 (offset 4 0 #x15))
  53.     (ldil () #x2020 8)
  54.     (ldo () (offset 4 0 8) 8)
  55.     (stwm () 8 (offset 4 0 #x15))
  56.     (bl () 1 (@pco 0))
  57.     (dep () 0 #x1F 2 1)
  58.     (ldo () (offset (- lambda-1814 *pc*) 0 1) 1)
  59.     (ble () (offset #x64 4 3))
  60.  
  61. [Closure consing code]
  62.  
  63. This can be shortened, and the ldi/dep can become a depi.
  64.  
  65. E:
  66.  
  67. 4DC4        (ldi () #x36 8)
  68. 4DC8        (copy () #x15 9)
  69. 4DCC        (dep () 8 5 6 9)
  70.  
  71. No need for ldi/dep.  Can be done with depi. (as long as free).
  72.  
  73. F:
  74.  
  75. (flo:- 0.0 x)
  76. uses a scheme object for 0.0
  77. fpr0 (the status register) reads as 0.0 (except for stores), a rule
  78. should use this.
  79.  
  80. G:    - Done
  81.  
  82. Introduce new macro instructions
  83. COMIBTN
  84. COMIBFN
  85. COMBN
  86.  
  87. which work like the versions without N except that they always nullify
  88. the following instruction.  The branch tensioner knows the sign of the
  89. displacement and can therfore insert the NOP when necessary.
  90.  
  91. H:
  92.  
  93. Hooks are invoked by the following sequence:
  94.  
  95.     BLE n(4,scheme_to_interface_ble_reg)
  96.     NOP
  97.  
  98. Why?  The NOP should go away, and the hooks should use -4(4,31)
  99.  
  100. No.  The sequence must be uniform, and the NOP allows for further
  101. optimization.  If the sequence were BLE,n, there would be no way
  102. to improve it.
  103.  
  104. Note that hooks that don't return (e.g. +) can use BE,n .
  105.  
  106.