From e95beacb4c2655865f8e8b081ba5137ce9878b82 Mon Sep 17 00:00:00 2001 From: Chad Rakoczy Date: Fri, 17 Apr 2026 18:30:56 +0000 Subject: [PATCH] 8382146: jdk/jfr/event/compiler/TestCodeCacheFull.java fails when C2 is disabled Reviewed-by: chagedorn --- .../jfr/event/compiler/TestCodeCacheFull.java | 18 ++++++++++++++++-- 1 file changed, 16 insertions(+), 2 deletions(-) diff --git a/test/jdk/jdk/jfr/event/compiler/TestCodeCacheFull.java b/test/jdk/jdk/jfr/event/compiler/TestCodeCacheFull.java index 12c9d6c40fa..266eb73a656 100644 --- a/test/jdk/jdk/jfr/event/compiler/TestCodeCacheFull.java +++ b/test/jdk/jdk/jfr/event/compiler/TestCodeCacheFull.java @@ -1,5 +1,5 @@ /* - * Copyright (c) 2013, 2025, Oracle and/or its affiliates. All rights reserved. + * Copyright (c) 2013, 2026, 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,7 +34,7 @@ import jdk.test.whitebox.WhiteBox; import jdk.test.whitebox.code.BlobType; /** - * @test TestCodeCacheFull + * @test id=Default * @requires vm.hasJFR * @requires vm.opt.UseCodeCacheFlushing == null | vm.opt.UseCodeCacheFlushing == true * @@ -50,6 +50,20 @@ import jdk.test.whitebox.code.BlobType; * @run main/othervm -Xbootclasspath/a:. * -XX:+UnlockDiagnosticVMOptions -XX:+WhiteBoxAPI * -XX:-SegmentedCodeCache jdk.jfr.event.compiler.TestCodeCacheFull + */ + +/** + * @test id=HotCode + * @requires vm.hasJFR + * @requires vm.opt.UseCodeCacheFlushing == null | vm.opt.UseCodeCacheFlushing == true + * @requires vm.compiler2.enabled + * + * @library /test/lib + * @modules jdk.jfr + * jdk.management.jfr + * @build jdk.test.whitebox.WhiteBox + * @run driver jdk.test.lib.helpers.ClassFileInstaller jdk.test.whitebox.WhiteBox + * * @run main/othervm -Xbootclasspath/a:. * -XX:+UnlockDiagnosticVMOptions -XX:+WhiteBoxAPI * -XX:+TieredCompilation -XX:+UnlockExperimentalVMOptions -XX:+HotCodeHeap -XX:HotCodeHeapSize=8M jdk.jfr.event.compiler.TestCodeCacheFull