src/hotspot/share/prims/nativeLookup.cpp
changeset 59016 3b9eeae66fa0
parent 58722 cba8afa5cfed
child 59056 15936b142f86
--- a/src/hotspot/share/prims/nativeLookup.cpp	Mon Nov 11 16:59:42 2019 +0100
+++ b/src/hotspot/share/prims/nativeLookup.cpp	Mon Nov 11 12:11:34 2019 -0500
@@ -27,6 +27,8 @@
 #include "classfile/symbolTable.hpp"
 #include "classfile/systemDictionary.hpp"
 #include "classfile/vmSymbols.hpp"
+#include "logging/log.hpp"
+#include "logging/logTag.hpp"
 #include "memory/oopFactory.hpp"
 #include "memory/resourceArea.hpp"
 #include "oops/instanceKlass.hpp"
@@ -413,11 +415,11 @@
     method->set_native_function(entry,
       Method::native_bind_event_is_interesting);
     // -verbose:jni printing
-    if (PrintJNIResolving) {
+    if (log_is_enabled(Debug, jni, resolve)) {
       ResourceMark rm(THREAD);
-      tty->print_cr("[Dynamic-linking native method %s.%s ... JNI]",
-        method->method_holder()->external_name(),
-        method->name()->as_C_string());
+      log_debug(jni, resolve)("[Dynamic-linking native method %s.%s ... JNI]",
+                              method->method_holder()->external_name(),
+                              method->name()->as_C_string());
     }
   }
   return method->native_function();