RFR: 8301403: Eliminate memory allocations in JVMFlag::printFlags during signal handling [v10]

Thomas Stuefe stuefe at openjdk.org
Fri Jul 26 06:53:33 UTC 2024


On Fri, 26 Jul 2024 04:21:36 GMT, David Holmes <dholmes at openjdk.org> wrote:

> <sigh> I don't understand what Windows was complaining about, and I really don't like the way constexpr had to spread like a virus. If the problem was the definition of `length` why did other code have to change?

I don't disagree with the many constexpr, but maybe we can cut down the number done in this RFE.

The `constexpr` in globalDefinitions.hpp for the `Log...` are okay, these things really should be constexpr. But maybe we can remove some of the constexpr spreading in BitMap itself.

Using `BitMap::calc_size_in_words(length)` pulls a long thread of follow-up constexpr. One compromise could be to just use `BitMap::raw_to_words_align_up` instead. That looks like you can make it constexpr without causing a long follow-up chain if LogBitsPerWord is constexpr.

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

PR Comment: https://git.openjdk.org/jdk/pull/20202#issuecomment-2252090067


More information about the hotspot-runtime-dev mailing list