[OpenMP][libomptarget] New map interface: remove translation code and ensure proper...
authorGeorge Rokos <grokos@us.ibm.com>
Thu, 19 Jul 2018 13:41:03 +0000 (13:41 +0000)
committerGeorge Rokos <grokos@us.ibm.com>
Thu, 19 Jul 2018 13:41:03 +0000 (13:41 +0000)
commita0da24683b2bf40a3c16077834ca2ac98622591c
tree4ce399e2b75630893c5bad3596296f3d4efbcecf
parenta67eb91047ac16ad757fc85eb2b9f35c649acb34
[OpenMP][libomptarget] New map interface: remove translation code and ensure proper alignment of struct members

This patch removes the translation code since this functionality is now implemented in the compiler.
target_data_begin and target_data_end are also patched to handle some special cases that used to be
handled by the obsolete translation function, namely ensure proper alignment of struct members when
we have partially mapped structs. Mapping a struct from a higher address (i.e. not from its beginning)
can result in distortion of the alignment for some of its member fields. Padding restores the original
(proper) alignment.

Differential revision: https://reviews.llvm.org/D44186

llvm-svn: 337455
openmp/libomptarget/include/omptarget.h
openmp/libomptarget/src/interface.cpp
openmp/libomptarget/src/omptarget.cpp