[patch,gomp4] Fix PR74600

Jakub Jelinek jakub@redhat.com
Fri Sep 16 08:39:00 GMT 2016


On Fri, Sep 16, 2016 at 10:28:49AM +0200, Jakub Jelinek wrote:
> I'll need to discuss it on omp-lang.  I think we just need to declare
> accesses to the vars living in parent frame when the parent is partially or
> fully not offloaded and the nested function is as unspecified behavior.
> Of course that means we shouldn't ICE, but runtime errors are just fine.
> 
> CHAIN is just a pointer, making it private doesn't really work well,
> it needs to be pointing to something reasonable.
> And FRAME is a structure holding all the vars that could be accessed by the
> nested functions, mapping it as whole without the user knowing is just
> wrong, first of all it can result in failures, because one could e.g.
> target data map just a couple of vars from it, and then implicitly map it
> all (which is impossible).  And in many cases, e.g. if pointers are used
> etc., the compiler really doesn't know what exactly out of the FRAME vars is
> mapped.

C++11 lambdas are another issue.

Anyway, looks like I've already raised this issue on omp-lang 2 years ago,
but there were no responses to that and I haven't pinged.  Guess I'll create
a ticket then.

	Jakub



More information about the Gcc-patches mailing list