RFR: 7903519 : jtreg/jtharness is missing features for basic crash testing [v4]

andrlos duke at openjdk.org
Thu Dec 14 08:12:08 UTC 2023


On Thu, 14 Dec 2023 04:23:58 GMT, Vladimir Sitnikov <vsitnikov at openjdk.org> wrote:

>> andrlos has updated the pull request incrementally with one additional commit since the last revision:
>> 
>>   improvement to the naming scheme 2
>
> src/com/sun/javatest/Script.java line 493:
> 
>> 491:      */
>> 492:     private Status tryModifyStatus(Status originalStatus, TestDescription td){
>> 493:         if (statusModifier == null) {
> 
> `statusModifier` is not `volatile`, so reading the field without synchronization is unsafe

I fail to see your problem. `tryModifyStatus` tries to read the `statusModifier`, if its null it calls a `synchronized` function to search for usable `statusModifier` which is then set and then the field remains unchanged for the rest of the execution.

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

PR Review Comment: https://git.openjdk.org/jtharness/pull/57#discussion_r1426373404


More information about the jtharness-dev mailing list