Skip to content

Commit ad98f6c

Browse files
committed
8372272: Hotspot shared lib loading - add load attempts to Events::log
Reviewed-by: mdoerr Backport-of: d328e4e
1 parent 5473030 commit ad98f6c

4 files changed

Lines changed: 7 additions & 0 deletions

File tree

src/hotspot/os/aix/os_aix.cpp

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1134,6 +1134,8 @@ static void* dll_load_library(const char *filename, int *eno, char *ebuf, int eb
11341134
dflags |= RTLD_MEMBER;
11351135
}
11361136

1137+
Events::log_dll_message(nullptr, "Attempting to load shared library %s", filename);
1138+
11371139
void* result;
11381140
const char* error_report = nullptr;
11391141
result = Aix_dlopen(filename, dflags, eno, &error_report);

src/hotspot/os/bsd/os_bsd.cpp

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -990,6 +990,8 @@ void *os::Bsd::dlopen_helper(const char *filename, int mode) {
990990
assert(rtn == 0, "fegetenv must succeed");
991991
#endif // IA32
992992

993+
Events::log_dll_message(nullptr, "Attempting to load shared library %s", filename);
994+
993995
void * result= ::dlopen(filename, RTLD_LAZY);
994996

995997
#ifndef IA32

src/hotspot/os/linux/os_linux.cpp

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1838,6 +1838,8 @@ void * os::Linux::dlopen_helper(const char *filename, char *ebuf,
18381838
assert(rtn == 0, "fegetenv must succeed");
18391839
#endif // IA32
18401840

1841+
Events::log_dll_message(nullptr, "Attempting to load shared library %s", filename);
1842+
18411843
void * result = ::dlopen(filename, RTLD_LAZY);
18421844
if (result == nullptr) {
18431845
const char* error_report = ::dlerror();

src/hotspot/os/windows/os_windows.cpp

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1649,6 +1649,7 @@ static int _print_module(const char* fname, address base_address,
16491649
// same architecture as Hotspot is running on
16501650
void * os::dll_load(const char *name, char *ebuf, int ebuflen) {
16511651
log_info(os)("attempting shared library load of %s", name);
1652+
Events::log_dll_message(nullptr, "Attempting to load shared library %s", name);
16521653

16531654
void * result = LoadLibrary(name);
16541655
if (result != nullptr) {

0 commit comments

Comments
 (0)