RFR: 8256256: UL should not use heap allocation for output string [v4]

Yumin Qi minqi at openjdk.java.net
Tue Dec 1 16:49:57 UTC 2020


On Tue, 1 Dec 2020 15:36:09 GMT, Thomas Stuefe <stuefe at openjdk.org> wrote:

>> src/hotspot/share/logging/logTagSet.cpp line 146:
>> 
>>> 144:       prefix_len = _write_prefix(buf, sizeof(buf));
>>> 145:       if (prefix_len < sizeof(buf)) {
>>> 146:         ret = os::vsnprintf(buf + prefix_len, sizeof(buf) - prefix_len, fmt, args);
>> 
>> Don't you need to use saved_args here? Original args pointer is already invalid.
>
> But if you go with David's proposal this printf becomes unnecessary.

Yes.

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

PR: https://git.openjdk.java.net/jdk/pull/1246


More information about the hotspot-runtime-dev mailing list