Skip to content

Commit 007426e

Browse files
OracleLabsAutomationzapster
authored andcommitted
[GR-68596] Update labsjdk to 26+10-jvmci-b01
PullRequest: graal/21797
2 parents e904e09 + 174707f commit 007426e

File tree

22 files changed

+115
-104
lines changed

22 files changed

+115
-104
lines changed

common.json

Lines changed: 8 additions & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -8,7 +8,7 @@
88

99
"COMMENT.jdks": "When adding or removing JDKs keep in sync with JDKs in ci/common.jsonnet",
1010
"jdks": {
11-
"galahad-jdk": {"name": "jpg-jdk", "version": "26", "build_id": "jdk-26+9-846", "platformspecific": true, "extrabundles": ["static-libs"]},
11+
"galahad-jdk": {"name": "jpg-jdk", "version": "26", "build_id": "jdk-26+10-1012", "platformspecific": true, "extrabundles": ["static-libs"]},
1212

1313
"oraclejdk17": {"name": "jpg-jdk", "version": "17.0.7", "build_id": "jdk-17.0.7+8", "platformspecific": true, "extrabundles": ["static-libs"]},
1414
"labsjdk-ce-17": {"name": "labsjdk", "version": "ce-17.0.7+4-jvmci-23.1-b02", "platformspecific": true },
@@ -53,13 +53,13 @@
5353
"labsjdk-ee-25Debug": {"name": "labsjdk", "version": "ee-25+30-jvmci-b01-debug", "platformspecific": true },
5454
"labsjdk-ee-25-llvm": {"name": "labsjdk", "version": "ee-25+30-jvmci-b01-sulong", "platformspecific": true },
5555

56-
"oraclejdk-latest": {"name": "jpg-jdk", "version": "26", "build_id": "jdk-26+9", "platformspecific": true, "extrabundles": ["static-libs"]},
57-
"labsjdk-ce-latest": {"name": "labsjdk", "version": "ce-26+9-jvmci-b01", "platformspecific": true },
58-
"labsjdk-ce-latestDebug": {"name": "labsjdk", "version": "ce-26+9-jvmci-b01-debug", "platformspecific": true },
59-
"labsjdk-ce-latest-llvm": {"name": "labsjdk", "version": "ce-26+9-jvmci-b01-sulong", "platformspecific": true },
60-
"labsjdk-ee-latest": {"name": "labsjdk", "version": "ee-26+9-jvmci-b01", "platformspecific": true },
61-
"labsjdk-ee-latestDebug": {"name": "labsjdk", "version": "ee-26+9-jvmci-b01-debug", "platformspecific": true },
62-
"labsjdk-ee-latest-llvm": {"name": "labsjdk", "version": "ee-26+9-jvmci-b01-sulong", "platformspecific": true }
56+
"oraclejdk-latest": {"name": "jpg-jdk", "version": "26", "build_id": "jdk-26+10", "platformspecific": true, "extrabundles": ["static-libs"]},
57+
"labsjdk-ce-latest": {"name": "labsjdk", "version": "ce-26+10-jvmci-b01", "platformspecific": true },
58+
"labsjdk-ce-latestDebug": {"name": "labsjdk", "version": "ce-26+10-jvmci-b01-debug", "platformspecific": true },
59+
"labsjdk-ce-latest-llvm": {"name": "labsjdk", "version": "ce-26+10-jvmci-b01-sulong", "platformspecific": true },
60+
"labsjdk-ee-latest": {"name": "labsjdk", "version": "ee-26+10-jvmci-b01", "platformspecific": true },
61+
"labsjdk-ee-latestDebug": {"name": "labsjdk", "version": "ee-26+10-jvmci-b01-debug", "platformspecific": true },
62+
"labsjdk-ee-latest-llvm": {"name": "labsjdk", "version": "ee-26+10-jvmci-b01-sulong", "platformspecific": true }
6363
},
6464

6565
"eclipse": {

compiler/src/jdk.graal.compiler.test/src/jdk/graal/compiler/hotspot/test/HotSpotCompressedKlassPointerTest.java

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,5 @@
11
/*
2-
* Copyright (c) 2024, Oracle and/or its affiliates. All rights reserved.
2+
* Copyright (c) 2024, 2025, Oracle and/or its affiliates. All rights reserved.
33
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
44
*
55
* This code is free software; you can redistribute it and/or modify it
@@ -40,7 +40,7 @@ public class HotSpotCompressedKlassPointerTest extends HotSpotGraalCompilerTest
4040
@Before
4141
public void setUp() {
4242
GraalHotSpotVMConfig config = runtime().getVMConfig();
43-
assumeTrue("compressed class pointers specific tests", config.useCompressedClassPointers);
43+
assumeTrue("compressed class pointers specific tests", config.useCompressedClassPointers && !config.useClassMetaspaceForAllClasses);
4444
}
4545

4646
// Non-abstract class

compiler/src/jdk.graal.compiler/src/jdk/graal/compiler/hotspot/GraalHotSpotVMConfig.java

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -195,6 +195,9 @@ public long gcTotalCollectionsAddress() {
195195
// Compressed Oops related values.
196196
public final boolean useCompressedOops = getFlag("UseCompressedOops", Boolean.class);
197197
public final boolean useCompressedClassPointers = getFlag("UseCompressedClassPointers", Boolean.class);
198+
199+
public final boolean useClassMetaspaceForAllClasses = getFlag("UseClassMetaspaceForAllClasses", Boolean.class);
200+
198201
// JDK-8305895 allows storing the compressed class pointer in the upper 22 bits of the mark
199202
// word. This runtime optimization is guarded by the flag UseCompactObjectHeaders. It depends
200203
// on compressed class pointers, meaning that if useCompactObjectHeaders is true,

compiler/src/jdk.graal.compiler/src/jdk/graal/compiler/hotspot/JVMCIVersionCheck.java

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -57,8 +57,8 @@ public final class JVMCIVersionCheck {
5757
// Checkstyle: stop stable iteration order check
5858
private static final Map<String, Map<String, Version>> JVMCI_MIN_VERSIONS = Map.of(
5959
"26", Map.of(
60-
"Oracle Corporation", createLabsJDKVersion("26+9", 1),
61-
DEFAULT_VENDOR_ENTRY, createLabsJDKVersion("26+9", 1)));
60+
"Oracle Corporation", createLabsJDKVersion("26+10", 1),
61+
DEFAULT_VENDOR_ENTRY, createLabsJDKVersion("26+10", 1)));
6262
// Checkstyle: resume stable iteration order check
6363

6464
private static final int NA = 0;

compiler/src/jdk.graal.compiler/src/jdk/graal/compiler/hotspot/meta/HotSpotGraphBuilderPlugins.java

Lines changed: 2 additions & 16 deletions
Original file line numberDiff line numberDiff line change
@@ -289,7 +289,7 @@ public void run() {
289289
registerMathPlugins(invocationPlugins, target.arch);
290290
registerContinuationPlugins(invocationPlugins, config);
291291
registerCallSitePlugins(invocationPlugins);
292-
registerReflectionPlugins(invocationPlugins, config);
292+
registerReflectionPlugins(invocationPlugins);
293293
registerAESPlugins(invocationPlugins, config);
294294
registerAdler32Plugins(invocationPlugins, config);
295295
registerCRC32Plugins(invocationPlugins, config);
@@ -508,7 +508,7 @@ public boolean apply(GraphBuilderContext b, ResolvedJavaMethod targetMethod, Rec
508508
plugins.register(VolatileCallSite.class, plugin);
509509
}
510510

511-
private static void registerReflectionPlugins(InvocationPlugins plugins, GraalHotSpotVMConfig config) {
511+
private static void registerReflectionPlugins(InvocationPlugins plugins) {
512512
Registration r = new Registration(plugins, "jdk.internal.reflect.Reflection");
513513
r.register(new InlineOnlyInvocationPlugin("getCallerClass") {
514514
@Override
@@ -517,20 +517,6 @@ public boolean apply(GraphBuilderContext b, ResolvedJavaMethod targetMethod, Rec
517517
return true;
518518
}
519519
});
520-
r.register(new InvocationPlugin("getClassAccessFlags", Class.class) {
521-
@Override
522-
public boolean apply(GraphBuilderContext b, ResolvedJavaMethod targetMethod, Receiver receiver, ValueNode arg) {
523-
try (HotSpotInvocationPluginHelper helper = new HotSpotInvocationPluginHelper(b, targetMethod, config)) {
524-
ValueNode klass = helper.readKlassFromClass(b.nullCheckedValue(arg));
525-
// Primitive Class case
526-
ValueNode klassNonNull = helper.emitNullReturnGuard(klass, ConstantNode.forInt(Modifier.ABSTRACT | Modifier.FINAL | Modifier.PUBLIC), GraalDirectives.UNLIKELY_PROBABILITY);
527-
// Return (Klass::_access_flags & jvmAccWrittenFlags)
528-
ValueNode accessFlags = helper.readKlassAccessFlags(klassNonNull);
529-
helper.emitFinalReturn(JavaKind.Int, accessFlags);
530-
}
531-
return true;
532-
}
533-
});
534520
}
535521

536522
private static final SpeculationReasonGroup JVMTI_NOTIFY_ALLOCATE_INSTANCE = new SpeculationReasonGroup("JvmtiNotifyAllocateInstance");

compiler/src/jdk.graal.compiler/src/jdk/graal/compiler/hotspot/meta/UnimplementedGraalIntrinsics.java

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -87,6 +87,8 @@ private static void add(Collection<String> c, String... elements) {
8787

8888
public UnimplementedGraalIntrinsics(Architecture arch) {
8989
add(toBeInvestigated, // @formatter:off
90+
// JDK-8360559: Optimize Math.sinh for x86 64 bit platforms
91+
"java/lang/Math.sinh(D)D",
9092
// JDK-8342103: C2 compiler support for Float16 type and associated
9193
// scalar operations
9294
"jdk/internal/vm/vector/Float16Math.fma(Ljava/lang/Class;Ljava/lang/Object;Ljava/lang/Object;Ljava/lang/Object;Ljdk/internal/vm/vector/Float16Math$TernaryOperator;)Ljava/lang/Object;",

compiler/src/jdk.graal.compiler/src/jdk/graal/compiler/hotspot/nodes/HotSpotCompressionNode.java

Lines changed: 6 additions & 13 deletions
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,5 @@
11
/*
2-
* Copyright (c) 2017, 2024, Oracle and/or its affiliates. All rights reserved.
2+
* Copyright (c) 2017, 2025, Oracle and/or its affiliates. All rights reserved.
33
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
44
*
55
* This code is free software; you can redistribute it and/or modify it
@@ -44,7 +44,6 @@
4444
import jdk.vm.ci.meta.Constant;
4545
import jdk.vm.ci.meta.ConstantReflectionProvider;
4646
import jdk.vm.ci.meta.JavaConstant;
47-
import jdk.vm.ci.meta.ResolvedJavaType;
4847

4948
@NodeInfo(nameTemplate = "{p#op/s}", cycles = CYCLES_2, size = SIZE_2)
5049
public final class HotSpotCompressionNode extends CompressionNode {
@@ -74,9 +73,7 @@ private static CompressionNode uncompress(ValueNode input, CompressEncoding enco
7473
@Override
7574
public boolean isCompressible(Constant constant) {
7675
if (constant instanceof HotSpotMetaspaceConstant mc) {
77-
ResolvedJavaType type = mc.asResolvedJavaType();
78-
// As of JDK-8338526, interface and abstract types are not compressible.
79-
return type.isArray() || (!type.isAbstract() && !type.isInterface());
76+
return mc.isCompressible();
8077
}
8178
return true;
8279
}
@@ -103,14 +100,10 @@ protected Constant uncompress(Constant c) {
103100

104101
@Override
105102
public ValueNode reverse(ValueNode input) {
106-
switch (op) {
107-
case Compress:
108-
return uncompress(input, encoding);
109-
case Uncompress:
110-
return compress(input, encoding);
111-
default:
112-
throw GraalError.shouldNotReachHereUnexpectedValue(op); // ExcludeFromJacocoGeneratedReport
113-
}
103+
return switch (op) {
104+
case Compress -> uncompress(input, encoding);
105+
case Uncompress -> compress(input, encoding);
106+
};
114107
}
115108

116109
@Override

compiler/src/jdk.graal.compiler/src/jdk/graal/compiler/nodes/CompressionNode.java

Lines changed: 15 additions & 33 deletions
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,5 @@
11
/*
2-
* Copyright (c) 2014, 2024, Oracle and/or its affiliates. All rights reserved.
2+
* Copyright (c) 2014, 2025, Oracle and/or its affiliates. All rights reserved.
33
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
44
*
55
* This code is free software; you can redistribute it and/or modify it
@@ -30,7 +30,6 @@
3030
import jdk.graal.compiler.core.common.CompressEncoding;
3131
import jdk.graal.compiler.core.common.type.AbstractObjectStamp;
3232
import jdk.graal.compiler.core.common.type.Stamp;
33-
import jdk.graal.compiler.debug.GraalError;
3433
import jdk.graal.compiler.graph.NodeClass;
3534
import jdk.graal.compiler.lir.gen.LIRGeneratorTool;
3635
import jdk.graal.compiler.nodeinfo.NodeInfo;
@@ -83,26 +82,18 @@ public JavaConstant nullConstant() {
8382

8483
@Override
8584
public Constant convert(Constant c, ConstantReflectionProvider constantReflection) {
86-
switch (op) {
87-
case Compress:
88-
return compress(c);
89-
case Uncompress:
90-
return uncompress(c);
91-
default:
92-
throw GraalError.shouldNotReachHereUnexpectedValue(op); // ExcludeFromJacocoGeneratedReport
93-
}
85+
return switch (op) {
86+
case Compress -> compress(c);
87+
case Uncompress -> uncompress(c);
88+
};
9489
}
9590

9691
@Override
9792
public Constant reverse(Constant c, ConstantReflectionProvider constantReflection) {
98-
switch (op) {
99-
case Compress:
100-
return uncompress(c);
101-
case Uncompress:
102-
return compress(c);
103-
default:
104-
throw GraalError.shouldNotReachHereUnexpectedValue(op); // ExcludeFromJacocoGeneratedReport
105-
}
93+
return switch (op) {
94+
case Compress -> uncompress(c);
95+
case Uncompress -> compress(c);
96+
};
10697
}
10798

10899
/**
@@ -138,14 +129,12 @@ public boolean isCompressible(Constant constant) {
138129

139130
@Override
140131
public ValueNode canonical(CanonicalizerTool tool, ValueNode forValue) {
141-
if (forValue.isConstant()) {
142-
ConstantNode constant = (ConstantNode) forValue;
132+
if (forValue instanceof ConstantNode constant) {
143133
if (isCompressible(constant.getValue())) {
144134
return ConstantNode.forConstant(stamp(NodeView.DEFAULT), convert(constant.getValue(), tool.getConstantReflection()), constant.getStableDimension(),
145135
constant.isDefaultStable(), tool.getMetaAccess());
146136
}
147-
} else if (forValue instanceof CompressionNode) {
148-
CompressionNode other = (CompressionNode) forValue;
137+
} else if (forValue instanceof CompressionNode other) {
149138
if (op != other.op && encoding.equals(other.encoding)) {
150139
return other.getValue();
151140
}
@@ -164,17 +153,10 @@ public void generate(NodeLIRBuilderTool gen) {
164153
}
165154

166155
LIRGeneratorTool tool = gen.getLIRGeneratorTool();
167-
Value result;
168-
switch (op) {
169-
case Compress:
170-
result = tool.emitCompress(gen.operand(value), encoding, nonNull);
171-
break;
172-
case Uncompress:
173-
result = tool.emitUncompress(gen.operand(value), encoding, nonNull);
174-
break;
175-
default:
176-
throw GraalError.shouldNotReachHereUnexpectedValue(op); // ExcludeFromJacocoGeneratedReport
177-
}
156+
Value result = switch (op) {
157+
case Compress -> tool.emitCompress(gen.operand(value), encoding, nonNull);
158+
case Uncompress -> tool.emitUncompress(gen.operand(value), encoding, nonNull);
159+
};
178160

179161
gen.setResult(this, result);
180162
}

espresso-shared/src/com.oracle.truffle.espresso.classfile/src/com/oracle/truffle/espresso/classfile/JavaVersion.java

Lines changed: 9 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -43,6 +43,7 @@ public static final class VersionRange {
4343
public static final VersionRange VERSION_22_OR_HIGHER = higher(22);
4444
public static final VersionRange VERSION_24_OR_LOWER = lower(24);
4545
public static final VersionRange VERSION_25_OR_HIGHER = higher(25);
46+
public static final VersionRange VERSION_26_OR_HIGHER = higher(26);
4647

4748
public static final VersionRange ALL = between(0, LATEST_SUPPORTED);
4849
public static final VersionRange VERSION_9_TO_21 = between(9, 21);
@@ -211,6 +212,14 @@ public boolean java25OrLater() {
211212
return version >= 25;
212213
}
213214

215+
public boolean java25OrEarlier() {
216+
return version <= 25;
217+
}
218+
219+
public boolean java26OrLater() {
220+
return version >= 26;
221+
}
222+
214223
public boolean inRange(int low, int high) {
215224
return version >= low && version <= high;
216225
}

espresso/src/com.oracle.truffle.espresso/src/com/oracle/truffle/espresso/descriptors/EspressoSymbols.java

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -612,6 +612,7 @@ public static class Names {
612612
public static final Symbol<Name> componentType = SYMBOLS.putName("componentType");
613613
public static final Symbol<Name> protectionDomain = SYMBOLS.putName("protectionDomain");
614614
public static final Symbol<Name> modifiers = SYMBOLS.putName("modifiers");
615+
public static final Symbol<Name> classFileAccessFlags = SYMBOLS.putName("classFileAccessFlags");
615616
public static final Symbol<Name> primitive = SYMBOLS.putName("primitive");
616617
public static final Symbol<Name> signers = SYMBOLS.putName("signers");
617618
// j.l.ClassLoader

0 commit comments

Comments
 (0)