[Openmp-commits] [PATCH] D132965: [amdgpu] Drop multiple calls to hsa_init

Jon Chesterfield via Phabricator via Openmp-commits openmp-commits at lists.llvm.org
Tue Aug 30 12:38:28 PDT 2022


JonChesterfield created this revision.
JonChesterfield added a reviewer: saiislam.
Herald added subscribers: kosarev, kerbowa, t-tye, tpr, dstuttard, yaxunl, jvesely, kzhuravl.
Herald added a project: All.
JonChesterfield requested review of this revision.
Herald added subscribers: openmp-commits, wdng.
Herald added a project: OpenMP.

Revert likely unintentional part of 4075a811ad99b7 <https://reviews.llvm.org/rG4075a811ad99b7e263b8b99954cef8c96b042e22>


Repository:
  rG LLVM Github Monorepo

https://reviews.llvm.org/D132965

Files:
  openmp/libomptarget/plugins/amdgpu/src/rtl.cpp


Index: openmp/libomptarget/plugins/amdgpu/src/rtl.cpp
===================================================================
--- openmp/libomptarget/plugins/amdgpu/src/rtl.cpp
+++ openmp/libomptarget/plugins/amdgpu/src/rtl.cpp
@@ -2080,11 +2080,8 @@
 }
 
 int32_t __tgt_rtl_init_device(int DeviceId) {
-  hsa_status_t Err = hsa_init();
-  if (Err != HSA_STATUS_SUCCESS) {
-    DP("HSA Initialization Failed.\n");
-    return HSA_STATUS_ERROR;
-  }
+  hsa_status_t Err;
+
   // this is per device id init
   DP("Initialize the device id: %d\n", DeviceId);
 


-------------- next part --------------
A non-text attachment was scrubbed...
Name: D132965.456760.patch
Type: text/x-patch
Size: 554 bytes
Desc: not available
URL: <http://lists.llvm.org/pipermail/openmp-commits/attachments/20220830/5eb6fc2c/attachment.bin>


More information about the Openmp-commits mailing list