https://gcc.gnu.org/bugzilla/show_bug.cgi?id=96810

--- Comment #5 from Wei Wentao <weiwt.fnst at cn dot fujitsu.com> ---
Sorry for the last comment.I don't know how this happened.
Let's get to the point.

>>And while the bug described in the comment is really hard to diagnose at
>>compile time and in most cases impossible, what clang diagnoses is the fact
>>that
>>the target construct has implicit map(tofrom:A) clause and because the target
>>data maps only a small part of it, it mapping in target construct will fail.
>>Still, clang implements it incorrectly,

>>Both are completely valid and e.g. the latter could work just fine at runtime
>>if bar performs #pragma omp target enter data (arg1[:30]) for arg2 0 and exit
>>data for arg2 non-zero.

Thank you for your explanation. I agree with that. May I think that clang can
at least emit a diagnostic while gcc did nothing?
Since clang can find the problem in implicit the map, why can't it and gcc find
the problem in the explicit map?
Does it mean that there are some areas in gcc need to be improved? That is what
I am wondering about.

Reply via email to