[Openmp-dev] Question about gcc support related to file kmp_gsupport.cpp

Cownie, James H via Openmp-dev openmp-dev at lists.llvm.org
Wed Oct 17 01:47:29 PDT 2018


Your question is really about the code which is generated by gcc for a statically scheduled loop, which has nothing to do with the runtime.

If you investigate how gcc compiles a statically scheduled OpenMP loop (look at https://godbolt.org/z/GtUnND for instance), you’ll see that there are no calls into the runtime for static loop scheduling.

-- Jim

Jim Cownie <james.h.cownie at intel.com>
CVCG/DPD/TCAR (Technical Computing, Analyzers, and Runtimes)
Tel: +44 117 9071438

From: Openmp-dev [mailto:openmp-dev-bounces at lists.llvm.org] On Behalf Of Tianyi Zhang via Openmp-dev
Sent: Tuesday, October 16, 2018 10:27 PM
To: openmp-dev at lists.llvm.org
Subject: [Openmp-dev] Question about gcc support related to file kmp_gsupport.cpp

Hi,
Could anyone familiar with the gcc support for llvm-openmp help with this:

When I build everything with gcc, and using debug mode, the debugger refuses to stop at


#pragma omp parallel

#pragma omp for schedule(static)
 It seems that for schedule(static) is not mapped to GCC.

Or is there any marco that are introduced inside function

KMP_EXPAND_NAME(KMP_API_NAME_GOMP_PARALLEL)
As It is only calling this function when I was running the program.


however, if I use

#pragma omp parallel

#pragma omp for schedule(dynamic)
it is calling

void KMP_EXPAND_NAME(KMP_API_NAME_GOMP_PARALLEL_LOOP_DYNAMIC)

Thanks,
Tianyi

---------------------------------------------------------------------
Intel Corporation (UK) Limited
Registered No. 1134945 (England)
Registered Office: Pipers Way, Swindon SN3 1RJ
VAT No: 860 2173 47

This e-mail and any attachments may contain confidential material for
the sole use of the intended recipient(s). Any review or distribution
by others is strictly prohibited. If you are not the intended
recipient, please contact the sender and delete all copies.
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.llvm.org/pipermail/openmp-dev/attachments/20181017/1b95198a/attachment-0001.html>


More information about the Openmp-dev mailing list