stress=(p1)
public
Updates the GC stress mode.
When stress mode is enabled, the GC is invoked at every GC
opportunity: all memory and object allocations.
Enabling stress mode will degrade
performance, it is only for debugging.
Show source
static VALUE
gc_stress_set(VALUE self, VALUE flag)
{
rb_objspace_t *objspace = &rb_objspace;
rb_secure(2);
ruby_gc_stress = FIXNUM_P(flag) ? flag : (RTEST(flag) ? Qtrue : Qfalse);
return flag;
}