[Q] explanations on the virtual machine

Tim Wilkinson tim at tjwassoc.co.uk
Wed Apr 30 09:24:58 PDT 1997


Hi Eric,

Eric VINCK (LCN) wrote:
> 
> I'm trying to understand how the kaffevm is working.
> My question is about the INTERPRETER and is related with the GC:
> 
> In kaffe.def (the core of the vm) i can see:
> 
> define_insn(ASTORE)
> {
> ...
>         move_ref(local(idx), rstack(0));
> ...
> }
> 
> move_ref is a macro which does : (t)[0].v.taddr = (f)[0].v.taddr
> 
> Why isn't there a write-barrier here ????
> (like SOFT_ADDREFERENCE ?)

This instruction only moves a reference from a stack to a local - both
of which are in the current function activation (ie. on the thread
stack).  Thread stacks are walked in a 'stop the world' situation so a
SOFT_ADDREFERENCE isn't needed.

> PS: what about the project of making kaffe GC-customizable ?
>     has someone news about it?

The GC is now reasonably abstracted, but all the support for things like
copy collectors isn't in yet.  This is unlikely to happen until JNI goes
in too (since there is some relation).

Tim

--
  Tim Wilkinson                         Tel/Fax: +44 181 440 0658
  T. J. Wilkinson & Associates,         Mobile:  +44 370 621006
  London, UK.                           Email:   tim at tjwassoc.co.uk



More information about the kaffe mailing list