OpenACC in Flang¶
Intentional deviation from the specification¶
See OpenACC-extensions.md for the full list of extensions supported by Flang. Flang also adds the following restrictions:
The OpenACC specification does not prohibit the same variable from appearing in multiple data clauses, but this is disallowed for variables appearing in
reductionclauses.The OpenACC specification does not prohibit the same variable from appearing multiple times in a
use_deviceclause on ahost_dataconstruct, but this is disallowed.
Remarks about incompatibilities with other implementations¶
Array element references in the data clauses are equivalent to array sections consisting of this single element, i.e.
copyin(a(n))is equivalent tocopyin(a(n:n)). Some other implementations have treated it ascopyin(a(:n)), which does not correspond to OpenACC spec – Flang does not support this interpretation of an array element reference.