Changeset 16466


Ignore:
Timestamp:
Jul 13, 2015, 5:51:32 AM (4 years ago)
Author:
gb
Message:

:spill and :reload attributes.

File:
1 edited

Legend:

Unmodified
Added
Removed
  • branches/lscan/source/compiler/vinsn.lisp

    r16458 r16466  
    3030  (when (and *backend-use-linear-scan* *linear-scan-verbose*)
    3131    (apply #'break args)))
    32 
     32(defun ls-note (&rest args)
     33  (when (and *backend-use-linear-scan* *linear-scan-verbose*)
     34    (apply #'warn args)))
    3335
    3436
     
    285287    :node                               ; saves/restores a node value in stack-like memory
    286288    :word                               ; saves/restores an unboxed word in stack-like memory
    287     :late
     289    :spill
    288290    :vsp                                ; uses the vsp to save/restore
    289291    :tsp                                ; uses the tsp to save/restore
    290     :csp                                ; uses sp to save/restore
     292    :reload                             ;
    291293    :push                               ; saves something
    292294    :pop                                ; restores something
     
    11651167    (setf (vinsn-sequence vinsn) 0)
    11661168    (cond ((not (member interval reloads))
    1167            (push interval (fgn-reloads node))
     1169           ;;(push interval (fgn-reloads node))
    11681170           (insert-vinsn-before vinsn ref)
    11691171           (let* ((seq (vinsn-sequence vinsn)))
    11701172             (if (< seq (interval-begin interval))
    11711173               (setf (interval-begin interval) seq)))
    1172            (push vinsn (lreg-defs (interval-lreg interval)))))))       
     1174           (pushnew vinsn (lreg-defs (interval-lreg interval)))))))       
    11731175
    11741176(defun note-spill (interval vinsn def)
     
    11771179         (spills (fgn-spills node)))
    11781180    (unless (member interval spills)
    1179       (push interval (fgn-spills node))
     1181      ;;(push interval (fgn-spills node))
    11801182      (insert-vinsn-after vinsn def)
    1181       (push vinsn (lreg-refs (interval-lreg interval)))
    1182 )))
     1183      (pushnew vinsn (lreg-refs (interval-lreg interval))))))
    11831184
    11841185         
     
    11931194        (setf (vinsn-list-spill-base seg) next-offset))
    11941195   
    1195       (when (> next-offset (vinsn-list-spill-depth seg))
    1196         (setf (vinsn-list-spill-depth seg) next-offset))
    1197       (when (> next-offset (vinsn-list-max-spill-depth seg))
    1198         (setf (vinsn-list-max-spill-depth seg) next-offset)))
    11991196
    12001197    (dolist (ref (lreg-refs lreg))
    12011198      (let* ((reload-vinsn (select-vinsn 'reload templates (list lreg offset))))
    12021199        (note-reload interval reload-vinsn ref)
    1203         ))))
     1200        )))))
    12041201
    12051202(defun spill-offset-for-interval (seg interval)
     
    14531450                    ;; should see if preg is in the killed set
    14541451                    (push a caller-save)))
    1455                 (ls-break "caller-save = ~s, call = ~s" caller-save call-vinsn)
     1452                (ls-note "caller-save = ~s, call = ~s" caller-save call-vinsn)
    14561453                (dolist (cs caller-save)
    14571454                  (spill-and-split-interval    seg 'call cs begin intervals unhandled)
Note: See TracChangeset for help on using the changeset viewer.