Feature #9761 » try_with_gc-with-gc_stress.patch
gc.c | ||
---|---|---|
}
|
||
#define TRY_WITH_GC(alloc) do { \
|
||
if (!(alloc) && \
|
||
(!garbage_collect_with_gvl(objspace, 1, 1, GPR_FLAG_MALLOC) || /* full mark && immediate sweep */ \
|
||
!(alloc))) { \
|
||
ruby_memerror(); \
|
||
if (!(alloc)) { \
|
||
if (!garbage_collect_with_gvl(objspace, 1, 1, GPR_FLAG_MALLOC) || /* full mark && immediate sweep */ \
|
||
!(alloc)) { \
|
||
ruby_memerror(); \
|
||
} \
|
||
} \
|
||
else if (ruby_gc_stress) { \
|
||
garbage_collect_with_gvl(objspace, 1, 1, GPR_FLAG_MALLOC); \
|
||
} \
|
||
} while (0)
|
||