Quantcast
Channel: Intel® Software - Intel® Fortran Compiler for Linux* and macOS*
Viewing all articles
Browse latest Browse all 2746

Compiler not detecting missing OMP4 declare target variable

$
0
0

Most of the time, the compiler will complain if a global variable used in an OMP4 target region is not declared for the target (!$omp declare targt(foo))

But now I had a (very big) program that compiled without errors (finally after fixing all the missing declares) but failed at runtime with the message:

On the remote process, dlopen() failed. The error message sent back from the sink is /tmp/coi_procs/1/56338/load_lib/ifortoutfGrs7D: undefined symbol: control_parameters_mp_surface_pressure_
On the sink, dlopen() returned NULL. The result of dlerror() is "/tmp/coi_procs/1/56338/load_lib/ifortoutfGrs7D: undefined symbol: control_parameters_mp_surface_pressure_"
offload error: cannot load library to the device 0 (error code 20)

Investigating the code, I found that in module "control_parameters" a real variable "surface_pressure" was declared and used inside a target region. Nothing special there, just omp target, parallel do and do simd. However the compiler did not detect it.

How is this possible? "Just" a bug in the compiler or are there (documented) circumstances where this might not work?
I cannot post the code itself, as it is part of the SPEC ACCEL suite and reducing it is hard due to the code consisting of ~160 files and in most of them, it detects the missing declare (even same module and/or same target region)


Viewing all articles
Browse latest Browse all 2746

Trending Articles



<script src="https://jsc.adskeeper.com/r/s/rssing.com.1596347.js" async> </script>