It would be lovely to have control over these options, including size-dependent control like -heap-arrays[n]
.
One place where the compiler must not make a copy is when ASYNCHRONOUS is involved, because it leads to incorrect results if the asynchronous update happens to a copy of an array. The best example of this is MPI, such as MPI_Irecv
, where the output buffer can be modified after the call returns.