RFC: C++/OMP PATCH for c++/53565 (libgomp for-2.C failure)
Jason Merrill
jason@redhat.com
Thu Jun 21 09:14:00 GMT 2012
A recent change of mine caused auto to persist until instantiation time
in more cases, and the OMP for instantiation code wasn't prepared to
deal with that. This patch simplifies the handling of the for-init-expr
in an OMP loop by processing the DECL_EXPR right away, rather than
trying to split handling it between tsubst_omp_for_iterator and tsubst_expr.
All the tests in the libgomp and gcc testsuites pass with this patch,
but I'm not very confident about it because I don't fully understand
what the code is doing. In particular, I'm not sure what the condition
controlling the code in tsubst_omp_for_iterator that looks at the
clauses should be; init can never be a DECL_EXPR at that point anymore.
I'm also not sure whether moving the begin_omp_structured_block is
necessary, but it seemed like a good idea since we're handling the
DECL_EXPR earlier.
Does this make sense to you?
-------------- next part --------------
A non-text attachment was scrubbed...
Name: 53565.patch
Type: text/x-patch
Size: 3521 bytes
Desc: not available
URL: <http://gcc.gnu.org/pipermail/gcc-patches/attachments/20120621/6efdfa2e/attachment.bin>
More information about the Gcc-patches
mailing list