mirror of
https://github.com/darlinghq/darling-openjdk.git
synced 2024-11-27 06:10:37 +00:00
8235934: gc/g1/TestGCLogMessages.java fails with 'DerivedPointerTable Update' found
Fix determining whether C2 or JVMCI are enabled in the test. Reviewed-by: sjohanss, kbarrett
This commit is contained in:
parent
ef5b447b04
commit
89f2d14518
@ -1,5 +1,5 @@
|
||||
/*
|
||||
* Copyright (c) 2012, 2019, Oracle and/or its affiliates. All rights reserved.
|
||||
* Copyright (c) 2012, 2020, Oracle and/or its affiliates. All rights reserved.
|
||||
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
|
||||
*
|
||||
* This code is free software; you can redistribute it and/or modify it
|
||||
@ -1986,6 +1986,14 @@ WB_ENTRY(jboolean, WB_IsCDSIncludedInVmBuild(JNIEnv* env))
|
||||
#endif // INCLUDE_CDS
|
||||
WB_END
|
||||
|
||||
WB_ENTRY(jboolean, WB_isC2OrJVMCIIncludedInVmBuild(JNIEnv* env))
|
||||
#if COMPILER2_OR_JVMCI
|
||||
return true;
|
||||
#else
|
||||
return false;
|
||||
#endif
|
||||
WB_END
|
||||
|
||||
WB_ENTRY(jboolean, WB_IsJavaHeapArchiveSupported(JNIEnv* env))
|
||||
return HeapShared::is_heap_object_archiving_allowed();
|
||||
WB_END
|
||||
@ -2411,6 +2419,7 @@ static JNINativeMethod methods[] = {
|
||||
{CC"areOpenArchiveHeapObjectsMapped", CC"()Z", (void*)&WB_AreOpenArchiveHeapObjectsMapped},
|
||||
{CC"isCDSIncludedInVmBuild", CC"()Z", (void*)&WB_IsCDSIncludedInVmBuild },
|
||||
{CC"isJFRIncludedInVmBuild", CC"()Z", (void*)&WB_IsJFRIncludedInVmBuild },
|
||||
{CC"isC2OrJVMCIIncludedInVmBuild", CC"()Z", (void*)&WB_isC2OrJVMCIIncludedInVmBuild },
|
||||
{CC"isJavaHeapArchiveSupported", CC"()Z", (void*)&WB_IsJavaHeapArchiveSupported },
|
||||
{CC"cdsMemoryMappingFailed", CC"()Z", (void*)&WB_CDSMemoryMappingFailed },
|
||||
|
||||
|
@ -1,5 +1,5 @@
|
||||
/*
|
||||
* Copyright (c) 2014, 2019, Oracle and/or its affiliates. All rights reserved.
|
||||
* Copyright (c) 2014, 2020, Oracle and/or its affiliates. All rights reserved.
|
||||
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
|
||||
*
|
||||
* This code is free software; you can redistribute it and/or modify it
|
||||
@ -87,7 +87,7 @@ public class TestGCLogMessages {
|
||||
}
|
||||
|
||||
public boolean isAvailable() {
|
||||
return Compiler.isC2Enabled() || Compiler.isGraalEnabled();
|
||||
return Compiler.isC2OrJVMCIIncludedInVmBuild();
|
||||
}
|
||||
}
|
||||
|
||||
|
@ -1,5 +1,5 @@
|
||||
/*
|
||||
* Copyright (c) 2012, 2019, Oracle and/or its affiliates. All rights reserved.
|
||||
* Copyright (c) 2012, 2020, Oracle and/or its affiliates. All rights reserved.
|
||||
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
|
||||
*
|
||||
* This code is free software; you can redistribute it and/or modify it
|
||||
@ -227,6 +227,8 @@ public class WhiteBox {
|
||||
public native void NMTArenaMalloc(long arena, long size);
|
||||
|
||||
// Compiler
|
||||
public native boolean isC2OrJVMCIIncludedInVmBuild();
|
||||
|
||||
public native int matchesMethod(Executable method, String pattern);
|
||||
public native int matchesInline(Executable method, String pattern);
|
||||
public native boolean shouldPrintAssembly(Executable method, int comp_level);
|
||||
|
@ -1,5 +1,5 @@
|
||||
/*
|
||||
* Copyright (c) 2018, Oracle and/or its affiliates. All rights reserved.
|
||||
* Copyright (c) 2018, 2020, Oracle and/or its affiliates. All rights reserved.
|
||||
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
|
||||
*
|
||||
* This code is free software; you can redistribute it and/or modify it
|
||||
@ -34,6 +34,15 @@ public class Compiler {
|
||||
|
||||
private static final WhiteBox WB = WhiteBox.getWhiteBox();
|
||||
|
||||
/**
|
||||
* Check if C2 or JVMCI were included in the VM build
|
||||
*
|
||||
* @return true if either C2 or JVMCI were included in the VM build.
|
||||
*/
|
||||
public static boolean isC2OrJVMCIIncludedInVmBuild() {
|
||||
return WB.isC2OrJVMCIIncludedInVmBuild();
|
||||
}
|
||||
|
||||
/**
|
||||
* Check if Graal is used as JIT compiler.
|
||||
*
|
||||
|
Loading…
Reference in New Issue
Block a user