compiler: Rename value-info, live-interval
parent
97f6d171ed
commit
5f377c0849
|
@ -50,7 +50,7 @@ IN: compiler.cfg.linear-scan.allocation
|
||||||
|
|
||||||
GENERIC: handle ( obj -- )
|
GENERIC: handle ( obj -- )
|
||||||
|
|
||||||
M: live-interval handle
|
M: live-interval-state handle
|
||||||
[ start>> deactivate-intervals ]
|
[ start>> deactivate-intervals ]
|
||||||
[ start>> activate-intervals ]
|
[ start>> activate-intervals ]
|
||||||
[ assign-register ]
|
[ assign-register ]
|
||||||
|
|
|
@ -20,7 +20,7 @@ TUPLE: vreg-use n def-rep use-rep spill-slot? ;
|
||||||
|
|
||||||
: <vreg-use> ( n -- vreg-use ) vreg-use new swap >>n ;
|
: <vreg-use> ( n -- vreg-use ) vreg-use new swap >>n ;
|
||||||
|
|
||||||
TUPLE: live-interval
|
TUPLE: live-interval-state
|
||||||
vreg
|
vreg
|
||||||
reg spill-to spill-rep reload-from reload-rep
|
reg spill-to spill-rep reload-from reload-rep
|
||||||
start end ranges uses
|
start end ranges uses
|
||||||
|
@ -47,7 +47,7 @@ M: f covers? 2drop f ;
|
||||||
|
|
||||||
M: live-range covers? [ from>> ] [ to>> ] bi between? ;
|
M: live-range covers? [ from>> ] [ to>> ] bi between? ;
|
||||||
|
|
||||||
M: live-interval covers? ( insn# live-interval -- ? )
|
M: live-interval-state covers? ( insn# live-interval -- ? )
|
||||||
ranges>>
|
ranges>>
|
||||||
dup length 4 <= [
|
dup length 4 <= [
|
||||||
[ covers? ] with any?
|
[ covers? ] with any?
|
||||||
|
@ -84,7 +84,7 @@ M: live-interval covers? ( insn# live-interval -- ? )
|
||||||
[ extend-range ] [ add-new-range ] if ;
|
[ extend-range ] [ add-new-range ] if ;
|
||||||
|
|
||||||
: <live-interval> ( vreg reg-class -- live-interval )
|
: <live-interval> ( vreg reg-class -- live-interval )
|
||||||
\ live-interval new
|
\ live-interval-state new
|
||||||
V{ } clone >>uses
|
V{ } clone >>uses
|
||||||
V{ } clone >>ranges
|
V{ } clone >>ranges
|
||||||
swap >>reg-class
|
swap >>reg-class
|
||||||
|
|
|
@ -26,16 +26,16 @@ M: complex eql? over complex? [ = ] [ 2drop f ] if ;
|
||||||
! you receive, always construct new ones. We don't declare the
|
! you receive, always construct new ones. We don't declare the
|
||||||
! slots read-only to allow cloning followed by writing, and to
|
! slots read-only to allow cloning followed by writing, and to
|
||||||
! simplify constructors.
|
! simplify constructors.
|
||||||
TUPLE: value-info
|
TUPLE: value-info-state
|
||||||
class
|
class
|
||||||
interval
|
interval
|
||||||
literal
|
literal
|
||||||
literal?
|
literal?
|
||||||
slots ;
|
slots ;
|
||||||
|
|
||||||
CONSTANT: null-info T{ value-info f null empty-interval }
|
CONSTANT: null-info T{ value-info-state f null empty-interval }
|
||||||
|
|
||||||
CONSTANT: object-info T{ value-info f object full-interval }
|
CONSTANT: object-info T{ value-info-state f object full-interval }
|
||||||
|
|
||||||
: interval>literal ( class interval -- literal literal? )
|
: interval>literal ( class interval -- literal literal? )
|
||||||
#! If interval has zero length and the class is sufficiently
|
#! If interval has zero length and the class is sufficiently
|
||||||
|
@ -52,7 +52,7 @@ CONSTANT: object-info T{ value-info f object full-interval }
|
||||||
} cond
|
} cond
|
||||||
] if ;
|
] if ;
|
||||||
|
|
||||||
: <value-info> ( -- info ) \ value-info new ; inline
|
: <value-info> ( -- info ) \ value-info-state new ; inline
|
||||||
|
|
||||||
DEFER: <literal-info>
|
DEFER: <literal-info>
|
||||||
|
|
||||||
|
|
Loading…
Reference in New Issue