From 203bf72bebcfb19d0b2ef7b7d1ecd3648a49824c Mon Sep 17 00:00:00 2001 From: duke Date: Mon, 10 Jun 2024 10:08:02 +0000 Subject: [PATCH] Backport 5f9d3e3af8342592242cb304b2c219508d56ed3a --- src/hotspot/share/compiler/compilerDirectives.cpp | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/hotspot/share/compiler/compilerDirectives.cpp b/src/hotspot/share/compiler/compilerDirectives.cpp index b48eb4fb817d8..74259c8e5d436 100644 --- a/src/hotspot/share/compiler/compilerDirectives.cpp +++ b/src/hotspot/share/compiler/compilerDirectives.cpp @@ -761,7 +761,7 @@ DirectiveSet* DirectivesStack::getMatchingDirective(const methodHandle& method, if (dir->is_default_directive() || dir->match(method)) { match = dir->get_for(comp); assert(match != nullptr, "Consistency"); - if (match->EnableOption) { + if (match->EnableOption || dir->is_default_directive()) { // The directiveSet for this compile is also enabled -> success dir->inc_refcount(); break;