[PATCH] D11361: [OpenMP] Target directive host codegen
Samuel Antao via cfe-commits
cfe-commits at lists.llvm.org
Mon Aug 31 16:03:32 PDT 2015
sfantao added inline comments.
================
Comment at: lib/CodeGen/CGOpenMPRuntime.cpp:2991-3005
@@ +2990,17 @@
+
+/// \brief Values for bit flags used to specify the mapping type for
+/// offloading.
+enum OpenMPOffloadMappingFlags {
+ /// \brief Allocate memory on the device and move data from host to device.
+ OMP_MAP_TO = 0x01,
+ /// \brief Allocate memory on the device and move data from device to host.
+ OMP_MAP_FROM = 0x02,
+};
+
+enum OpenMPOffloadingReservedDeviceIDs {
+ /// \brief Device ID if the device was not defined, runtime should get it
+ /// from environment variables in the spec.
+ OMP_DEVICEID_UNDEF = -1,
+};
+
+void CGOpenMPRuntime::emitTargetCall(CodeGenFunction &CGF,
----------------
ABataev wrote:
> Move them to CGOpenMPRuntime::emitTargetCall(), they can be made local
Ok, done!
================
Comment at: test/OpenMP/target_codegen.cpp:8
@@ +7,3 @@
+// expected-no-diagnostics
+// REQUIRES: powerpc-registered-target
+#ifndef HEADER
----------------
ABataev wrote:
> Some of your tests has triple i386, they don't need PowerPC target
True, I'm not using any target specific property here. So I guess it is safe to remove the requirement. Not using // REQUIRES anymore. Thanks.
http://reviews.llvm.org/D11361
More information about the cfe-commits
mailing list