Skip to content

Commit b8d82f2

Browse files
committed
format
1 parent 97dbc79 commit b8d82f2

File tree

3 files changed

+8
-8
lines changed

3 files changed

+8
-8
lines changed

substratevm/src/com.oracle.svm.core/src/com/oracle/svm/core/jfr/JfrEventWriterAccess.java

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -26,7 +26,6 @@
2626

2727
import java.lang.reflect.Field;
2828

29-
import com.oracle.svm.core.util.VMError;
3029
import org.graalvm.compiler.serviceprovider.JavaVersionUtil;
3130
import org.graalvm.nativeimage.Platform;
3231
import org.graalvm.nativeimage.Platforms;

substratevm/src/com.oracle.svm.core/src/com/oracle/svm/core/jfr/JfrFeature.java

Lines changed: 1 addition & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -60,8 +60,7 @@
6060
* <ul>
6161
* <li>Java-level events are defined by a Java class that extends {@link Event} and that is
6262
* annotated with JFR-specific annotations. Those events are typically triggered by the Java
63-
* application and a Java {@link EventWriter} object is used when writing the event to a
64-
* buffer.</li>
63+
* application and a Java EventWriter object is used when writing the event to a buffer.</li>
6564
* <li>Native events are triggered by the JVM itself and are defined in the JFR metadata.xml file.
6665
* For writing such an event to a buffer, we call into {@link JfrNativeEventWriter} and pass a
6766
* {@link JfrNativeEventWriterData} struct that is typically allocated on the stack.</li>

substratevm/src/com.oracle.svm.core/src/com/oracle/svm/core/jfr/JfrThreadLocal.java

Lines changed: 7 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -55,7 +55,7 @@
5555
* Each thread uses both a Java and a native {@link JfrBuffer}:
5656
* <ul>
5757
* <li>The Java buffer is accessed by JFR events that are implemented as Java classes and written
58-
* using {@linkplain EventWriter}.</li>
58+
* using EventWriter.</li>
5959
* <li>The native buffer is accessed when {@link JfrNativeEventWriter} is used to write an
6060
* event.</li>
6161
* </ul>
@@ -66,7 +66,7 @@
6666
* modify the buffers of other threads).
6767
*/
6868
public class JfrThreadLocal implements ThreadListener {
69-
private static final FastThreadLocalObject javaEventWriter;
69+
@SuppressWarnings("rawtypes") private static final FastThreadLocalObject javaEventWriter;
7070
private static final FastThreadLocalWord<JfrBuffer> javaBuffer = FastThreadLocalFactory.createWord("JfrThreadLocal.javaBuffer");
7171
private static final FastThreadLocalWord<JfrBuffer> nativeBuffer = FastThreadLocalFactory.createWord("JfrThreadLocal.nativeBuffer");
7272
private static final FastThreadLocalWord<UnsignedWord> dataLost = FastThreadLocalFactory.createWord("JfrThreadLocal.dataLost");
@@ -76,10 +76,10 @@ public class JfrThreadLocal implements ThreadListener {
7676
static {
7777
if (JavaVersionUtil.JAVA_SPEC < 19) {
7878
javaEventWriter = FastThreadLocalFactory.createObject(Target_jdk_jfr_internal_EventWriter.class,
79-
"JfrThreadLocal.javaEventWriter");
79+
"JfrThreadLocal.javaEventWriter");
8080
} else {
8181
javaEventWriter = FastThreadLocalFactory.createObject(Target_jdk_jfr_internal_event_EventWriter.class,
82-
"JfrThreadLocal.javaEventWriter");
82+
"JfrThreadLocal.javaEventWriter");
8383
}
8484
}
8585

@@ -114,6 +114,7 @@ public void beforeThreadRun(IsolateThread isolateThread, Thread javaThread) {
114114

115115
@Uninterruptible(reason = "Accesses a JFR buffer.")
116116
@Override
117+
@SuppressWarnings("rawtypes")
117118
public void afterThreadExit(IsolateThread isolateThread, Thread javaThread) {
118119

119120
// Emit ThreadEnd event after thread.run() finishes.
@@ -162,6 +163,7 @@ public Object getEventWriter() {
162163
// If a safepoint happens in this method, the state that another thread can see is always
163164
// sufficiently consistent as the JFR buffer is still empty. So, this method does not need to be
164165
// uninterruptible.
166+
@SuppressWarnings("rawtypes")
165167
public Target_jdk_jfr_internal_EventWriter newEventWriter() {
166168
assert javaEventWriter.get() == null;
167169
assert javaBuffer.get().isNull();
@@ -221,7 +223,7 @@ public static void notifyEventWriter(IsolateThread thread) {
221223
if (javaEventWriter.get(thread) != null) {
222224
if (JavaVersionUtil.JAVA_SPEC < 19) {
223225
SubstrateUtil.cast(javaEventWriter.get(thread), Target_jdk_jfr_internal_EventWriter.class).notified = true;
224-
}else {
226+
} else {
225227
SubstrateUtil.cast(javaEventWriter.get(thread), Target_jdk_jfr_internal_event_EventWriter.class).notified = true;
226228
}
227229
}

0 commit comments

Comments
 (0)