[Openmp-commits] [PATCH] D106751: [OpenMP][Libomptarget] Adding `print_device_info` to RTL and `omptarget`

Jose Manuel Monsalve Diaz via Phabricator via Openmp-commits openmp-commits at lists.llvm.org
Sat Jul 24 15:22:30 PDT 2021


josemonsalve2 added inline comments.


================
Comment at: openmp/libomptarget/plugins/cuda/src/rtl.cpp:1339
+
+void __tgt_rtl_print_device_info(int32_t device_id) {
+  assert(DeviceRTL.isValidDeviceId(device_id) && "device_id is invalid");
----------------
JonChesterfield wrote:
> Verbose. Can probably format as a table containing the cuda API call, the text to print, possibly the corresponding HSA API call, then iterate over that table printing / building json etc 
I believe this is a good idea. Let me think about how to adopt it. 


================
Comment at: openmp/libomptarget/plugins/cuda/src/rtl.cpp:1342
+
+  char TmpChar[1000];
+  size_t TmpSt;
----------------
tianshilei1992 wrote:
> Suggest to put all implementation details into the class above.
Also a good idea.


Repository:
  rG LLVM Github Monorepo

CHANGES SINCE LAST ACTION
  https://reviews.llvm.org/D106751/new/

https://reviews.llvm.org/D106751



More information about the Openmp-commits mailing list