RFR: 8328630: Add logging when needed symbols in dll are missing. [v3]

David Holmes dholmes at openjdk.org
Tue Apr 2 01:32:01 UTC 2024


On Thu, 28 Mar 2024 14:00:33 GMT, Robbin Ehn <rehn at openjdk.org> wrote:

>> src/hotspot/os/posix/os_posix.cpp line 720:
>> 
>>> 718:     // It is possible that we found a NULL symbol, hence no error.
>>> 719:     if (tmp != nullptr) {
>>> 720:       log_debug(os)("Symbol %s not found in dll: %s", name, tmp);
>> 
>> I'm still a little confused about the message here. Are we just reporting that the symbol doesn't exist, or are we actually reporting that the attempt to lookup the symbol failed due to some error?
>
> Yes, the issue is that we don't know if there was an error or no such symbol, "undefined symbol".
> From dlsym/dlerror API perspective "symbol doesn't exist" is an error.
> But for our case it would be logical to separate them.
> 
> All we know is that the user tried to find X in dll-file, and it was not found due to "string".
> 
> Happy to change it, but I can't think of a better message. For my case with hsdis this would had been good enough.

Okay

-------------

PR Review Comment: https://git.openjdk.org/jdk/pull/18404#discussion_r1547035005


More information about the hotspot-runtime-dev mailing list