llvm-project/openmp/libomptarget/test
Alexey Bataev 9148b8b734 [OpenMP][Offloading] Fix the issue that omp_get_num_devices returns wrong number of devices, by Shiley Tian.
Summary:
This patch is to fix issue in the following simple case:

  #include <omp.h>
  #include <stdio.h>

  int main(int argc, char *argv[]) {
    int num = omp_get_num_devices();
    printf("%d\n", num);

    return 0;
  }

Currently it returns 0 even devices exist. Since this file doesn't contain any
target region, the host entry is empty so further actions like initialization
will not be proceeded, leading to wrong device number returned by runtime
function call.

Reviewers: jdoerfert, ABataev, protze.joachim

Reviewed By: ABataev

Subscribers: protze.joachim

Tags: #openmp

Differential Revision: https://reviews.llvm.org/D72576
2020-01-21 13:25:18 -05:00
..
api [OpenMP][Offloading] Fix the issue that omp_get_num_devices returns wrong number of devices, by Shiley Tian. 2020-01-21 13:25:18 -05:00
env [OpenMP] libomptarget: move debugging dumps under control of env var LIBOMPTARGET_DEBUG 2017-08-14 15:09:59 +00:00
mapping [LIBOMPTARGET] Do not increment/decrement the refcount for "declare target" objects 2020-01-14 16:30:38 -08:00
offloading [LIBOMPTARGET]Ignore empty target descriptors. 2020-01-10 09:45:27 -05:00
unified_shared_memory [OpenMP][libomptarget] Add support for close map modifier 2019-08-09 21:32:57 +00:00
CMakeLists.txt [OpenMP] build offload plugins before testing them 2019-11-28 17:43:56 -05:00
lit.cfg [libomptaret][test] Announce compiler features 2018-09-05 07:26:00 +00:00
lit.site.cfg.in [libomptarget-nvptx] Add testing infrastructure 2018-09-28 15:05:43 +00:00