[Openmp-commits] [openmp] a90da62 - [libomptarget][amdgpu] Update printed plugin name

Jon Chesterfield via Openmp-commits openmp-commits at lists.llvm.org
Thu Jul 29 06:46:52 PDT 2021


Author: Jon Chesterfield
Date: 2021-07-29T14:46:42+01:00
New Revision: a90da62adb212a5c2ac957de25a4b98e7694588d

URL: https://github.com/llvm/llvm-project/commit/a90da62adb212a5c2ac957de25a4b98e7694588d
DIFF: https://github.com/llvm/llvm-project/commit/a90da62adb212a5c2ac957de25a4b98e7694588d.diff

LOG: [libomptarget][amdgpu] Update printed plugin name

Added: 
    

Modified: 
    openmp/libomptarget/plugins/amdgpu/dynamic_hsa/hsa.cpp
    openmp/libomptarget/plugins/amdgpu/src/rtl.cpp

Removed: 
    


################################################################################
diff  --git a/openmp/libomptarget/plugins/amdgpu/dynamic_hsa/hsa.cpp b/openmp/libomptarget/plugins/amdgpu/dynamic_hsa/hsa.cpp
index ef5c1953cc6f8..3aa749c40463a 100644
--- a/openmp/libomptarget/plugins/amdgpu/dynamic_hsa/hsa.cpp
+++ b/openmp/libomptarget/plugins/amdgpu/dynamic_hsa/hsa.cpp
@@ -56,7 +56,7 @@ DLWRAP_FINALIZE();
 #endif
 
 #ifndef TARGET_NAME
-#define TARGET_NAME AMDHSA
+#error "Missing TARGET_NAME macro"
 #endif
 #define DEBUG_PREFIX "Target " GETNAME(TARGET_NAME) " RTL"
 

diff  --git a/openmp/libomptarget/plugins/amdgpu/src/rtl.cpp b/openmp/libomptarget/plugins/amdgpu/src/rtl.cpp
index b5651ab9e89a1..4865ef6ffbbaa 100644
--- a/openmp/libomptarget/plugins/amdgpu/src/rtl.cpp
+++ b/openmp/libomptarget/plugins/amdgpu/src/rtl.cpp
@@ -39,7 +39,7 @@
 #include "llvm/Frontend/OpenMP/OMPGridValues.h"
 
 #ifndef TARGET_NAME
-#define TARGET_NAME AMDHSA
+#error "Missing TARGET_NAME macro"
 #endif
 #define DEBUG_PREFIX "Target " GETNAME(TARGET_NAME) " RTL"
 
@@ -687,12 +687,12 @@ class RTLDeviceInfoTy {
     else
       print_kernel_trace = 0;
 
-    DP("Start initializing HSA-ATMI\n");
+    DP("Start initializing " GETNAME(TARGET_NAME) "\n");
     hsa_status_t err = core::atl_init_gpu_context();
     if (err == HSA_STATUS_SUCCESS) {
       HSAInitializeSucceeded = true;
     } else {
-      DP("Error when initializing HSA-ATMI\n");
+      DP("Error when initializing " GETNAME(TARGET_NAME) "\n");
       return;
     }
 
@@ -793,7 +793,7 @@ class RTLDeviceInfoTy {
   }
 
   ~RTLDeviceInfoTy() {
-    DP("Finalizing the HSA-ATMI DeviceInfo.\n");
+    DP("Finalizing the " GETNAME(TARGET_NAME) " DeviceInfo.\n");
     if (!HSAInitializeSucceeded) {
       // Then none of these can have been set up and they can't be torn down
       return;


        


More information about the Openmp-commits mailing list