-
Notifications
You must be signed in to change notification settings - Fork 55
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
[Issue]: flang-new: runtime and math functions don't link for OpenMP target regions #201
Comments
In the user guide we have documented that adding |
Math functions may alternatively require |
Thanks! With the drop 4.2 compiler I am able to link the runtime with -lFortranRuntimeHostDevice. I'm curious, why is performance poor with the device runtime? Is it just overhead from calling library functions or something else entirely? The program I'm working on uses assign, dot_product, mod, modulo and sum in some target regions. With the math functions I do still have the same problem, adding -lm to the compiler invocation does not help with linking cosh. tanh works fine, just as before.
If I compile with --save-temps and look into link-openmp-amdgcn-amd-amdhsa-gfx90a-llvmir.mlir, I see that the symbols for cosh and tanh look quite different to eachother. cosh is |
I've opened an internal ticket regarding |
Problem Description
I get many linker errors for OpenMP target regions when offloading to GPU. Symbols from libFortranRuntime show as undefined and so do some math intrinsics like cosh.
There are some other math intrinsics that do link successfully, like tanh.
@sfantao
Operating System
SUSE Linux Enterprise Server 15 SP5 (Cray OS on LUMI)
CPU
AMD EPYC 7742 64-Core
GPU
AMD Instinct MI250X
ROCm Version
ROCm 6.2.2
ROCm Component
flang
Steps to Reproduce
(Optional for Linux users) Output of /opt/rocm/bin/rocminfo --support
No response
Additional Information
No response
The text was updated successfully, but these errors were encountered: