RFR: 8311906: Race condition in String constructor

2023-09-25 Thread Chen Liang
In the constructor of String, many locations the user-supplied byte or char arrays are read multiple times with a plain memory access; if a user previously wrote to one of such locations out of happens-before order, distinct plain memory reads may result in different unanticipated values. The m

Re: RFR: 8311906: Race condition in String constructor

2023-09-25 Thread Alan Bateman
On Mon, 25 Sep 2023 12:28:40 GMT, Chen Liang wrote: > In the constructor of String, many locations the user-supplied byte or char > arrays are read multiple times with a plain memory access; if a user > previously wrote to one of such locations out of happens-before order, > distinct plain mem

Re: RFR: 8311906: Race condition in String constructor

2023-09-25 Thread Roger Riggs
On Mon, 25 Sep 2023 12:28:40 GMT, Chen Liang wrote: > In the constructor of String, many locations the user-supplied byte or char > arrays are read multiple times with a plain memory access; if a user > previously wrote to one of such locations out of happens-before order, > distinct plain mem

Re: RFR: 8311906: Race condition in String constructor

2023-09-25 Thread Chen Liang
On Mon, 25 Sep 2023 12:28:40 GMT, Chen Liang wrote: > In the constructor of String, many locations the user-supplied byte or char > arrays are read multiple times with a plain memory access; if a user > previously wrote to one of such locations out of happens-before order, > distinct plain mem

Re: RFR: 8311906: Race condition in String constructor

2023-09-25 Thread Chen Liang
On Mon, 25 Sep 2023 12:28:40 GMT, Chen Liang wrote: > In the constructor of String, many locations the user-supplied byte or char > arrays are read multiple times with a plain memory access; if a user > previously wrote to one of such locations out of happens-before order, > distinct plain mem

Re: RFR: 8311906: Race condition in String constructor

2023-11-03 Thread Chen Liang
On Mon, 25 Sep 2023 12:28:40 GMT, Chen Liang wrote: > In the constructor of String, many locations the user-supplied byte or char > arrays are read multiple times with a plain memory access; if a user > previously wrote to one of such locations out of happens-before order, > distinct plain mem