To: J3 J3/21-142 From: Yasuharu Hayashi Subject: NOTE on the coarray memory model Date: 2021-June-02 1. Introduction NOTE 4 in clause 11.7.2 says "In practice, apart from executions of atomic subroutines, the processor could make a copy of a nonvolatile coarray on an image (in cache or a register, for example) and, as an optimization, defer copying a changed value back to the permanent memory location while it is still being used. Since the variable is not volatile, it is safe to defer this transfer until the end of the segment and thereafter to reload from permanent memory any coarray that was not defined within the segment. It might not be safe to defer these actions beyond the end of the segment since another image might reference the variable then." The intention of the latter half of the second sentence "thereafter to reload..." related to cache optimizations for nonvolatile coarrays is unclear, because + Reload from permanent memory after the copy back should be safe irrespective of whether the nonvolatile coarray was defined or not, + The copy back and reload of the nonvolatile coarray that was not defined are not necessary in the first place, and + "thereafter" could be interpreted as "after the end of the segment", which seems to be in contradiction with the description in the last sentence "not be safe to defer these actions beyond the end of the segment". Therefore this paper suggests modifying NOTE 4 in clause 11.7.2 in ISO/IEC JTC1/SC22/WG5/N2184 as follows: 2. Edits to ISO/IEC JTC1/SC22/WG5/N2184 Change "Since the variable is not volatile, it is safe to defer this transfer until the end of the segment and thereafter to reload from permanent memory any coarray that was not defined within the segment." to "Since the variable is not volatile, it is safe to defer this transfer or refer to the value of the local copy without reloading it from permanent memory until the end of the segment." ===END===