[OpenMP] Rename the offload entry points.
authorSamuel Antao <sfantao@us.ibm.com>
Sat, 13 Feb 2016 23:35:10 +0000 (23:35 +0000)
committerSamuel Antao <sfantao@us.ibm.com>
Sat, 13 Feb 2016 23:35:10 +0000 (23:35 +0000)
commit2de62b0c891853feb07089efc1782bfdfa40a5d7
tree818cd4508f2c79c69ef9a04f306e72ba63ca1f5a
parent6f5770b10f85958b53d9638c560c0e918a8ad239
[OpenMP] Rename the offload entry points.

Summary:
Unlike other outlined regions in OpenMP, offloading entry points have to have be visible (external linkage) for the device side. Using dots in the names of the entries can be therefore problematic for some toolchains, e.g. NVPTX.

Also the patch drops the column information in the unique name of the entry points. The parsing of directives ignore unknown tokens, preventing several target  regions to be implemented in the same line. Therefore, the line information is sufficient for the name to be unique. Also, the preprocessor printer does not preserve the column information, causing offloading-entry detection issues if the host uses an integrated preprocessor and the target doesn't (or vice versa).

Reviewers: hfinkel, arpith-jacob, carlo.bertolli, kkwli0, ABataev

Subscribers: cfe-commits, fraggamuffin, caomhin

Differential Revision: http://reviews.llvm.org/D17179

llvm-svn: 260837
clang/lib/CodeGen/CGOpenMPRuntime.cpp
clang/lib/CodeGen/CGOpenMPRuntime.h
clang/test/OpenMP/target_codegen_registration.cpp
clang/test/OpenMP/target_codegen_registration_naming.cpp