[OpenMP] Add Error Handling for Conflicting Pointer Sizes for Target Offload
authorJoseph Huber <jhuber6@vols.utk.edu>
Wed, 30 Sep 2020 17:10:32 +0000 (13:10 -0400)
committerHuber, Joseph <huberjn@ornl.gov>
Wed, 30 Sep 2020 17:58:24 +0000 (13:58 -0400)
commit9d2378b59150f6f1cb5c9cf42ea06b0bb57029a1
treee9a82228f43fe6a4264eba9d753eba7ce1161528
parent892df30a7f344b6cb9995710efbc94bb25cfb95b
[OpenMP] Add Error Handling for Conflicting Pointer Sizes for Target Offload

Summary:
This patch adds an error to Clang that detects if OpenMP offloading is used
between two architectures with incompatible pointer sizes. This ensures that
the data mapping can be done correctly and solves an issue in code generation
generating the wrong size pointer.

Reviewer: jdoerfert

Subscribers:

Tags: #OpenMP #Clang

Differential Revision:
clang/include/clang/Basic/DiagnosticDriverKinds.td
clang/lib/Frontend/CompilerInvocation.cpp
clang/test/OpenMP/nvptx_target_parallel_reduction_codegen_tbaa_PR46146.cpp
clang/test/OpenMP/target_incompatible_architecture_messages.cpp [new file with mode: 0644]