[Openmp-commits] [PATCH] D159119: [OpenMP] Enable optimization level for memory_manager.cpp OpenMP test.

Joachim Protze via Phabricator via Openmp-commits openmp-commits at lists.llvm.org
Thu Aug 31 08:52:22 PDT 2023


protze.joachim added a comment.

In D159119#4631583 <https://reviews.llvm.org/D159119#4631583>, @tianshilei1992 wrote:

> I don’t think that is the cause of the issue. The default device is 0, at least for OpenMP.

The default device is not 0. At least not according to the OpenMP spec. Check OpenMP-5.2, page 41, lines 10-13:

> If target-offload-var is mandatory and the number of non-host devices is zero then the default-device-var is initialized to **omp_invalid_device**. Otherwise, **the initial value is an implementation-defined non-negative integer** that is less than or, if target-offload-var is not mandatory, equal to omp_get_initial_device().

I didn't claim, that this caused the issue. I just noted that according to the OpenMP spec, the test was sailing in implementation-defined waters.

Thanks Doru for fixing the test :D


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

https://reviews.llvm.org/D159119



More information about the Openmp-commits mailing list