Skip to content

Commit

Permalink
8295419: JFR: Change name of jdk.JitRestart
Browse files Browse the repository at this point in the history
Reviewed-by: lucy, mdoerr
Backport-of: ecfb6bce5a9878d7bedce47da60f96fa9146acf7
  • Loading branch information
MBaesken committed Nov 17, 2022
1 parent 10b7a6d commit d4d4dbc
Show file tree
Hide file tree
Showing 6 changed files with 7 additions and 7 deletions.
2 changes: 1 addition & 1 deletion src/hotspot/share/jfr/metadata/metadata.xml
Original file line number Diff line number Diff line change
Expand Up @@ -494,7 +494,7 @@
<Field type="ulong" contentType="bytes" name="used" label="Used" />
</Event>

<Event name="JitRestart" category="Java Virtual Machine, Compiler" label="JIT Restart" stackTrace="false" startTime="false" thread="true">
<Event name="JITRestart" category="Java Virtual Machine, Compiler" label="JIT Restart" stackTrace="false" startTime="false" thread="true">
<Field type="int" contentType="bytes" name="freedMemory" label="Freed Memory" />
<Field type="ulong" contentType="bytes" name="codeCacheMaxCapacity" label="Code Cache Maximum Capacity" />
</Event>
Expand Down
2 changes: 1 addition & 1 deletion src/hotspot/share/runtime/sweeper.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -432,7 +432,7 @@ void NMethodSweeper::sweep_code_cache() {
CompileBroker::set_should_compile_new_jobs(CompileBroker::run_compilation);
log.debug("restart compiler");
log_sweep("restart_compiler");
EventJitRestart event;
EventJITRestart event;
event.set_freedMemory(freed_memory);
event.set_codeCacheMaxCapacity(CodeCache::max_capacity());
event.commit();
Expand Down
2 changes: 1 addition & 1 deletion src/jdk.jfr/share/conf/jfr/default.jfc
Original file line number Diff line number Diff line change
Expand Up @@ -521,7 +521,7 @@
<setting name="enabled" control="compiler-enabled-failure">false</setting>
</event>

<event name="jdk.JitRestart">
<event name="jdk.JITRestart">
<setting name="enabled" control="compiler-enabled">true</setting>
</event>

Expand Down
2 changes: 1 addition & 1 deletion src/jdk.jfr/share/conf/jfr/profile.jfc
Original file line number Diff line number Diff line change
Expand Up @@ -521,7 +521,7 @@
<setting name="enabled" control="compiler-enabled-failure">false</setting>
</event>

<event name="jdk.JitRestart">
<event name="jdk.JITRestart">
<setting name="enabled" control="compiler-enabled">true</setting>
</event>

Expand Down
4 changes: 2 additions & 2 deletions test/jdk/jdk/jfr/event/compiler/TestJitRestart.java
Original file line number Diff line number Diff line change
Expand Up @@ -66,7 +66,7 @@ public static void main(String[] args) throws Exception {
private static boolean testWithBlobType(BlobType btype, long availableSize) throws Exception {
Recording r = new Recording();
r.enable(EventNames.CodeCacheFull);
r.enable(EventNames.JitRestart);
r.enable(EventNames.JITRestart);
r.start();
long addr = WHITE_BOX.allocateCodeBlob(availableSize, btype.id);
WHITE_BOX.freeCodeBlob(addr);
Expand All @@ -79,7 +79,7 @@ private static boolean testWithBlobType(BlobType btype, long availableSize) thro

for (RecordedEvent evt: events) {
System.out.println(evt);
if (evt.getEventType().getName().equals("jdk.JitRestart")) {
if (evt.getEventType().getName().equals("jdk.JITRestart")) {
Events.assertField(evt, "codeCacheMaxCapacity").notEqual(0L);
Events.assertField(evt, "freedMemory").notEqual(0L);
return true;
Expand Down
2 changes: 1 addition & 1 deletion test/lib/jdk/test/lib/jfr/EventNames.java
Original file line number Diff line number Diff line change
Expand Up @@ -169,7 +169,7 @@ public class EventNames {
public final static String ObjectAllocationOutsideTLAB = PREFIX + "ObjectAllocationOutsideTLAB";
public final static String ObjectAllocationSample = PREFIX + "ObjectAllocationSample";
public final static String Deoptimization = PREFIX + "Deoptimization";
public final static String JitRestart = PREFIX + "JitRestart";
public final static String JITRestart = PREFIX + "JITRestart";

// OS
public final static String OSInformation = PREFIX + "OSInformation";
Expand Down

1 comment on commit d4d4dbc

@openjdk-notifier
Copy link

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Please sign in to comment.