2006/6/14, Weldon Washburn <[EMAIL PROTECTED]>:

Alex,
It looks like the JIT needs to support write barriers written in both
C as well as Java.   Its probably best to think of the C write barrier
as a conventional vm helper call.  For a garbage collector written in
Java like MMTk, the write barrier is actually Java code.  Injecting a
vm helper call and crossing the JNI boundary twice per each MMTk write
barrier will be a nightmare to debug.  Most likely performance would
be unacceptable even for debug.


Can't we inline the Java write barrier with JIT?

For a general purpose GC/VM interface, it is best not to assume the GC
algorithm will always scan all the static variables containing
reference pointers.  The write barrier needs to also be applied to
putstatic.


Either way can be correct, but I agree to have write barrier support for
putstatic that can be toggled off if that's desired.



--
Thanks,
Ming

Reply via email to