Merge branch 'master' of git://factorcode.org/git/factor
commit
d4f6a9cb43
|
@ -8,6 +8,7 @@ continuations.private fry cpu.architecture
|
||||||
source-files.errors
|
source-files.errors
|
||||||
compiler.errors
|
compiler.errors
|
||||||
compiler.alien
|
compiler.alien
|
||||||
|
compiler.constants
|
||||||
compiler.cfg
|
compiler.cfg
|
||||||
compiler.cfg.instructions
|
compiler.cfg.instructions
|
||||||
compiler.cfg.stack-frame
|
compiler.cfg.stack-frame
|
||||||
|
@ -94,7 +95,9 @@ M: _dispatch generate-insn
|
||||||
[ src>> register ] [ temp>> register ] bi %dispatch ;
|
[ src>> register ] [ temp>> register ] bi %dispatch ;
|
||||||
|
|
||||||
M: _dispatch-label generate-insn
|
M: _dispatch-label generate-insn
|
||||||
label>> lookup-label %dispatch-label ;
|
label>> lookup-label
|
||||||
|
cell 0 <repetition> %
|
||||||
|
rc-absolute-cell label-fixup ;
|
||||||
|
|
||||||
: >slot< ( insn -- dst obj slot tag )
|
: >slot< ( insn -- dst obj slot tag )
|
||||||
{
|
{
|
||||||
|
|
|
@ -55,7 +55,6 @@ HOOK: %jump-label cpu ( label -- )
|
||||||
HOOK: %return cpu ( -- )
|
HOOK: %return cpu ( -- )
|
||||||
|
|
||||||
HOOK: %dispatch cpu ( src temp -- )
|
HOOK: %dispatch cpu ( src temp -- )
|
||||||
HOOK: %dispatch-label cpu ( label -- )
|
|
||||||
|
|
||||||
HOOK: %slot cpu ( dst obj slot tag temp -- )
|
HOOK: %slot cpu ( dst obj slot tag temp -- )
|
||||||
HOOK: %slot-imm cpu ( dst obj slot tag -- )
|
HOOK: %slot-imm cpu ( dst obj slot tag -- )
|
||||||
|
|
|
@ -3,10 +3,11 @@
|
||||||
USING: accessors assocs sequences kernel combinators make math
|
USING: accessors assocs sequences kernel combinators make math
|
||||||
math.order math.ranges system namespaces locals layouts words
|
math.order math.ranges system namespaces locals layouts words
|
||||||
alien alien.accessors alien.c-types literals cpu.architecture
|
alien alien.accessors alien.c-types literals cpu.architecture
|
||||||
cpu.ppc.assembler cpu.ppc.assembler.backend literals compiler.cfg.registers
|
cpu.ppc.assembler cpu.ppc.assembler.backend compiler.cfg.registers
|
||||||
compiler.cfg.instructions compiler.constants compiler.codegen
|
compiler.cfg.instructions compiler.constants compiler.codegen
|
||||||
compiler.codegen.fixup compiler.cfg.intrinsics
|
compiler.codegen.fixup compiler.cfg.intrinsics
|
||||||
compiler.cfg.stack-frame compiler.units ;
|
compiler.cfg.stack-frame compiler.cfg.build-stack-frame
|
||||||
|
compiler.units ;
|
||||||
FROM: cpu.ppc.assembler => B ;
|
FROM: cpu.ppc.assembler => B ;
|
||||||
IN: cpu.ppc
|
IN: cpu.ppc
|
||||||
|
|
||||||
|
@ -461,16 +462,18 @@ M:: ppc %write-barrier ( src card# table -- )
|
||||||
src card# deck-bits SRWI
|
src card# deck-bits SRWI
|
||||||
table scratch-reg card# STBX ;
|
table scratch-reg card# STBX ;
|
||||||
|
|
||||||
M: ppc %gc
|
M:: ppc %gc ( temp1 temp2 gc-roots gc-root-count -- )
|
||||||
"end" define-label
|
"end" define-label
|
||||||
12 load-zone-ptr
|
temp2 load-zone-ptr
|
||||||
11 12 cell LWZ ! nursery.here -> r11
|
temp1 temp2 cell LWZ
|
||||||
12 12 3 cells LWZ ! nursery.end -> r12
|
temp2 temp2 3 cells LWZ
|
||||||
11 11 1024 ADDI ! add ALLOT_BUFFER_ZONE to here
|
temp1 temp1 1024 ADDI ! add ALLOT_BUFFER_ZONE to here
|
||||||
11 0 12 CMP ! is here >= end?
|
temp1 0 temp2 CMP ! is here >= end?
|
||||||
"end" get BLE
|
"end" get BLE
|
||||||
%prepare-alien-invoke
|
%prepare-alien-invoke
|
||||||
"minor_gc" f %alien-invoke
|
0 3 LI
|
||||||
|
0 4 LI
|
||||||
|
"inline_gc" f %alien-invoke
|
||||||
"end" resolve-label ;
|
"end" resolve-label ;
|
||||||
|
|
||||||
M: ppc %prologue ( n -- )
|
M: ppc %prologue ( n -- )
|
||||||
|
|
|
@ -91,9 +91,6 @@ M: x86 %return ( -- ) 0 RET ;
|
||||||
: align-code ( n -- )
|
: align-code ( n -- )
|
||||||
0 <repetition> % ;
|
0 <repetition> % ;
|
||||||
|
|
||||||
M: x86 %dispatch-label ( label -- )
|
|
||||||
0 cell, rc-absolute-cell label-fixup ;
|
|
||||||
|
|
||||||
:: (%slot) ( obj slot tag temp -- op )
|
:: (%slot) ( obj slot tag temp -- op )
|
||||||
temp slot obj [+] LEA
|
temp slot obj [+] LEA
|
||||||
temp tag neg [+] ; inline
|
temp tag neg [+] ; inline
|
||||||
|
|
Loading…
Reference in New Issue