From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: by sourceware.org (Postfix, from userid 48) id 505F1383F41F; Sun, 5 Sep 2021 03:30:39 +0000 (GMT) DKIM-Filter: OpenDKIM Filter v2.11.0 sourceware.org 505F1383F41F From: "xw111luoye at gmail dot com" To: gcc-bugs@gcc.gnu.org Subject: [Bug c++/102204] New: OpenMP offload map type restriction Date: Sun, 05 Sep 2021 03:30:39 +0000 X-Bugzilla-Reason: CC X-Bugzilla-Type: new X-Bugzilla-Watch-Reason: None X-Bugzilla-Product: gcc X-Bugzilla-Component: c++ X-Bugzilla-Version: unknown X-Bugzilla-Keywords: X-Bugzilla-Severity: normal X-Bugzilla-Who: xw111luoye at gmail dot com X-Bugzilla-Status: UNCONFIRMED X-Bugzilla-Resolution: X-Bugzilla-Priority: P3 X-Bugzilla-Assigned-To: unassigned at gcc dot gnu.org X-Bugzilla-Target-Milestone: --- X-Bugzilla-Flags: X-Bugzilla-Changed-Fields: bug_id short_desc product version bug_status bug_severity priority component assigned_to reporter target_milestone Message-ID: Content-Type: text/plain; charset="UTF-8" Content-Transfer-Encoding: quoted-printable X-Bugzilla-URL: http://gcc.gnu.org/bugzilla/ Auto-Submitted: auto-generated MIME-Version: 1.0 X-BeenThere: gcc-bugs@gcc.gnu.org X-Mailman-Version: 2.1.29 Precedence: list List-Id: Gcc-bugs mailing list List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Sun, 05 Sep 2021 03:30:39 -0000 https://gcc.gnu.org/bugzilla/show_bug.cgi?id=3D102204 Bug ID: 102204 Summary: OpenMP offload map type restriction Product: gcc Version: unknown Status: UNCONFIRMED Severity: normal Priority: P3 Component: c++ Assignee: unassigned at gcc dot gnu.org Reporter: xw111luoye at gmail dot com Target Milestone: --- With branch devel/omp/gcc-11 I'm getting /home/yeluo/opt/qmcpack/build_rtx3060_gcc_offload_real/src/config.h:42:29: error: array section does not have mappable type in =E2=80=98map=E2=80=99 c= lause 42 | #define PRAGMA_OFFLOAD(x) _Pragma(x) | ^~~~~~~ /home/yeluo/opt/qmcpack/src/Particle/SoaDistanceTableAAOMPTarget.h:84:5: no= te: in expansion of macro =E2=80=98PRAGMA_OFFLOAD=E2=80=99 84 | PRAGMA_OFFLOAD("omp target enter data map(to : this[:1])") | ^~~~~~~~~~~~~~ In file included from /home/yeluo/opt/qmcpack/src/Particle/createDistanceTableAAOMPTarget.cpp:19: /home/yeluo/opt/qmcpack/src/Particle/SoaDistanceTableAAOMPTarget.h:31:8: no= te: type =E2=80=98qmcplusplus::SoaDistanceTableAAOMPTarget=E2=80= =99 with virtual members is not mappable 31 | struct SoaDistanceTableAAOMPTarget : public DTD_BConds, public DistanceTableData | ^~~~~~~~~~~~~~~~~~~~~~~~~~~ because SoaDistanceTableAAOMPTarget is a derived class and there is virtual function overriding. https://github.com/QMCPACK/qmcpack/blob/1a7af8e589726a91da94e5f6ad8b4e8d9e2= acd4d/src/Particle/SoaDistanceTableAAOMPTarget.h#L31 In my case virtual functions are never called in offload region and I map "this[:1]" for easy access a fixed data set. So I'm expecting just bit wise copy to the device. please remove this restriction.=