[Openmp-commits] [PATCH] D96812: [OpenMP][NFC] Eliminate sign comparison warning via explicit casts

Shilei Tian via Phabricator via Openmp-commits openmp-commits at lists.llvm.org
Tue Feb 16 13:13:16 PST 2021


tianshilei1992 added inline comments.


================
Comment at: openmp/libomptarget/plugins/cuda/src/rtl.cpp:231
     // No CUstream left in the pool, we need to request from CUDA RT
-    if (Id == StreamPool[DeviceId].size()) {
+    if (Id == int(StreamPool[DeviceId].size())) {
       // By default we double the stream pool every time
----------------
I'd use C++ cast, aka `static_cast<int>(...)`.


Repository:
  rG LLVM Github Monorepo

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

https://reviews.llvm.org/D96812



More information about the Openmp-commits mailing list