[PATCH, og8] Don't rescan "attach" node for dereferenced struct member

Julian Brown julian@codesourcery.com
Fri Feb 15 18:47:00 GMT 2019


Hi,

The following (og8 branch) patch added support for
attaching/detaching from dereferenced struct members:

https://gcc.gnu.org/ml/gcc-patches/2019-01/msg01778.html

Unfortunately I made a mistake in the portion of that patch that
inserts new alloc and firstprivate_pointer nodes for the struct base,
meaning that the node rewritten to an attach operation would be
scanned again. This is both unnecessary, and can cause problems in some
circumstances.

Tested with offloading to nvptx, no regressions and the new test passes.
I will apply (to the og8 branch) shortly.

Thanks,

Julian

ChangeLog

            gcc/
            * gimplify.c (gimplify_scan_omp_clauses): Avoid scanning
            'c' again after creating base-pointer nodes for
            dereferenced struct.

            gcc/testsuite/
            * gfortran.dg/goacc/derived-types-2.f90: New.
-------------- next part --------------
A non-text attachment was scrubbed...
Name: no-deref-attach-rescanning-1.diff
Type: text/x-patch
Size: 1439 bytes
Desc: not available
URL: <http://gcc.gnu.org/pipermail/gcc-patches/attachments/20190215/59584ea7/attachment.bin>


More information about the Gcc-patches mailing list