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

Thomas Stuefe stuefe at openjdk.java.net
Tue Dec 1 15:39:03 UTC 2020


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

>> Yumin Qi has updated the pull request incrementally with one additional commit since the last revision:
>> 
>>   Fix Copyright year
>
> 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.

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

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


More information about the hotspot-runtime-dev mailing list