/** * Checks if the store is creating a reference from a mature generation * object (target) to a young generation object (val). If it is, target * (i.e. the mature object) is added to the remember set. * * @param target The object holding the reference (i.e. the referer). * @param val The object being referenced (i.e. the referee). */ void write_barrier(ObjectHeader* target, ObjectHeader* val) { if(target->remembered_p()) return; if(!val->reference_p()) return; if(target->young_object_p()) return; if(!val->young_object_p()) return; remember_object(reinterpret_cast<Object*>(target)); }
void write_barrier(Object* target, Object* val) { if(target->Remember) return; if(!REFERENCE_P(val)) return; if(target->zone != MatureObjectZone) return; if(val->zone != YoungObjectZone) return; remember_object(target); }
/** * Checks if the store is creating a reference from a mature generation * object (target) to a young generation object (val). If it is, target * (i.e. the mature object) is added to the remember set. * * @param target The object holding the reference (i.e. the referer). * @param val The object being referenced (i.e. the referee). */ void write_barrier(Object* target, Object* val) { if(target->remembered_p()) return; if(!REFERENCE_P(val)) return; if(target->zone() == YoungObjectZone) return; if(val->zone() != YoungObjectZone) return; remember_object(target); }
static void amf3_decode_str(lua_State *L, amf_cursor *c, int sidx) { uint32_t ref, len; amf3_decode_u29(c, &ref); amf_cursor_checkerr(c); if (!amf3_is_ref(ref)) { len = ref >> 1; if (len > 0) { amf_cursor_need(c, len); lua_pushlstring(L, c->p, len); amf_cursor_consume(c, len); remember_object(L, -1, sidx); } else { lua_pushliteral(L, ""); } } else {