Skip to content

Commit b59008a

Browse files
authored
Merge pull request #18546 from pshipton/rasflag0.42
(0.42) Use correct GC flag in HCR dark matter cleanup
2 parents 2e15576 + 1b9bc72 commit b59008a

File tree

1 file changed

+4
-1
lines changed

1 file changed

+4
-1
lines changed

runtime/jvmti/jvmtiClass.c

Lines changed: 4 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1233,7 +1233,10 @@ redefineClassesCommon(jvmtiEnv* env,
12331233
/* Eliminate dark matter so that none will be encountered in prepareToFixMemberNames(). */
12341234
UDATA savedAllowUserHeapWalkFlag = vm->requiredDebugAttributes & J9VM_DEBUG_ATTRIBUTE_ALLOW_USER_HEAP_WALK;
12351235
vm->requiredDebugAttributes |= J9VM_DEBUG_ATTRIBUTE_ALLOW_USER_HEAP_WALK;
1236-
vm->memoryManagerFunctions->j9gc_modron_global_collect_with_overrides(currentThread, J9MMCONSTANT_EXPLICIT_GC_EXCLUSIVE_VMACCESS_ALREADY_ACQUIRED);
1236+
/* J9MMCONSTANT_EXPLICIT_GC_RASDUMP_COMPACT allows the GC to run while the current thread is holding
1237+
* exclusive VM access.
1238+
*/
1239+
vm->memoryManagerFunctions->j9gc_modron_global_collect_with_overrides(currentThread, J9MMCONSTANT_EXPLICIT_GC_RASDUMP_COMPACT);
12371240
if (0 == savedAllowUserHeapWalkFlag) {
12381241
/* Clear the flag to restore its original value. */
12391242
vm->requiredDebugAttributes &= ~J9VM_DEBUG_ATTRIBUTE_ALLOW_USER_HEAP_WALK;

0 commit comments

Comments
 (0)