RFR: 8252148: vmError::controlled_crash should be #ifdef ASSERT and move tests to gtest [v4]

Coleen Phillimore coleenp at openjdk.java.net
Mon Dec 14 13:22:13 UTC 2020


On Mon, 14 Dec 2020 05:59:10 GMT, Thomas Stuefe <stuefe at openjdk.org> wrote:

>> Marked as reviewed by iklam (Reviewer).
>
> Hi Coleen,
> 
> sorry, found another issue. In `print_error_for_unit_test` multiple threads may race and overwrite each others _detail_fmt buffer. Later on we block all threads but the first to report an error. But not here yet. So, maybe just use a C-heap allocated buffer or a stack buffer. I also don't think it has to be 1024, I guess 128 or so would be enough. We can make it larger if needed.
> 
> Cheers, Thomas

Hi Thomas, thank you for finding the "last" bug in this.  I made the buffer stack allocated and 256. That should be enough and it passes all the gtests.  Thanks again.

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

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


More information about the hotspot-dev mailing list