[Openmp-dev] kmp vs. gomp

Jeff Hammond via Openmp-dev openmp-dev at lists.llvm.org
Fri Jun 22 10:22:48 PDT 2018


On Fri, Jun 22, 2018 at 8:09 AM, Joachim Protze via Openmp-dev <
openmp-dev at lists.llvm.org> wrote:

> Ok, different proposal:
>
> Many computing centers carefully provide separate tool chains for
> different compilers used on their clusters based on module system or
> similar approaches.
>
> I also think, that in the near future several tools will integrate the
> LLVM/OpenMP runtime into their build to enable their tool to work with
> applications built with older compilers coming without OMPT interface.
> Hopefully this will be solved within the next years :) But experience
> shows that HPC machines tend to run with quite old software stack, so it
> could take another 5-10 years :(
>

I spent 5 years of my life in software support for a major HPC center and I
don't think this is a fair characterization.  It is true that some of the
more exotic machines place limits on the software upgrades, but if we
ignore IBM Blue Gene/Q and Fujitsu K, there is no issue installing the
latest everything.  The support staff might not do it at the pace you like
because of finite resources, or because the majority of users do not care
about GCC 8.1 or Intel 18.0.2 compilers, but if there is demonstrable need
for new software, it is not a technical problem to get it installed.

If you are struggling with unhelpful HPC center support staff not
installing needed software updates, I can provide advice on how to engage
them in a way that is more likely to lead to positive results.

Jeff


> A configure switch might provide the ability to turn off kmp or gomp
> interface in these module environments. So, if the sysadmin compiles the
> runtime for the gcc toolchain, he would only activate the gomp interface.
> Based on this switch a more detailed support level of OMPT callbacks might
> be announced to the tool.
> Default for this switch would be of cause kmp+gomp.
>
> Best
> Joachim
>
>
> On 06/20/2018 07:32 PM, Churbanov, Andrey wrote:
>
>> Doesn't sound like a good idea to me.
>>
>> The whole point why we have GOMP and KMP interfaces in the library is to
>> allow same binary be used with code compiled by different compilers.
>>
>> You may solve one particular problem of running unit tests for an OpenMP
>> implementation (one combination of compiler+runtime).  But what if people
>> use several OpenMP implementations to produce single application (e.g.
>> several OpenMP-parallelized third-party libraries)?  These cases may stop
>> working or produce unexpected (or unspecified) results.
>>
>> I'd rather look for some other solution for the problem.  E.g. always
>> return ompt_set_sometimes when registering ompt_callback_work.  Or make a
>> tool to cope somehow with the absence of end_single event. Etc.
>>
>> Regards,
>> Andrey
>>
>> -----Original Message-----
>> From: Joachim Protze [mailto:protze.joachim at gmail.com]
>> Sent: Monday, June 18, 2018 4:17 PM
>> To: Churbanov, Andrey <Andrey.Churbanov at intel.com>
>> Cc: openmp-dev at lists.llvm.org
>> Subject: Re: [Openmp-dev] kmp vs. gomp
>>
>> Following Michael Klemms opinion, that an OpenMP implementation consists
>> of a fixed pair of compiler+runtime, I suggest to add a CMake flag, that
>> selects whether the intended use of the runtime is KMP or GOMP.
>>
>> Based on this flag, we would provide return codes for OMPT callback
>> registration.
>>
>> What do you think about this proposal?
>>
>> Best
>> Joachim
>>
>> On 06/13/2018 03:05 PM, Churbanov, Andrey wrote:
>>
>>> In general, it is not possible to know which compiler used to compile
>>> the code that caused the initialization of the runtime library.
>>> It could be possible if kmp or gomp interface caused the initialization,
>>> but definitely not possible if it was omp_* call.
>>>
>>> Note also that we tentatively support case when executable linked from
>>> objects compiled by different compilers, so the library can be initialized
>>> in code compiled by one compiler and then used in the code compiled by
>>> another compiler (we do not cover all the cases of cause, but simple cases
>>> should work).
>>>
>>> -- Andrey
>>>
>>> -----Original Message-----
>>> From: Openmp-dev [mailto:openmp-dev-bounces at lists.llvm.org] On Behalf
>>> Of Joachim Protze via Openmp-dev
>>> Sent: Wednesday, June 13, 2018 12:35 AM
>>> To: openmp-dev at lists.llvm.org
>>> Subject: [Openmp-dev] kmp vs. gomp
>>>
>>> Hi all,
>>>
>>> is there a way in the runtime to tell whether the runtime was
>>> initialized through a call to the kmp or gomp interface? As I understand
>>> the initialization, this is currently not possible.
>>>
>>> A way to implement this would be to pass a flag through
>>> __kmp_get_global_thread_id_reg to __kmp_do_serial_initialize. Would this be
>>> acceptable?
>>>
>>> The background for this question is the different behavior regarding
>>> OMPT callbacks. Specifically, gomp has currently no way to provide a
>>> callback for the single-end event.
>>> Following the specification, the runtime should return
>>> ompt_set_sometimes instead of ompt_set_always when registering
>>> ompt_callback_work knowing that the application uses the gomp interface.
>>>
>>> Best
>>> Joachim
>>> _______________________________________________
>>> Openmp-dev mailing list
>>> Openmp-dev at lists.llvm.org
>>> http://lists.llvm.org/cgi-bin/mailman/listinfo/openmp-dev
>>>
>>> --------------------------------------------------------------------
>>> Joint Stock Company Intel A/O
>>> Registered legal address: Krylatsky Hills Business Park,
>>> 17 Krylatskaya Str., Bldg 4, Moscow 121614, Russian Federation
>>>
>>> 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.
>>>
>>>
>>
>> --------------------------------------------------------------------
>> Joint Stock Company Intel A/O
>> Registered legal address: Krylatsky Hills Business Park,
>> 17 Krylatskaya Str., Bldg 4, Moscow 121614,
>> Russian Federation
>>
>> 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.
>>
>>
> _______________________________________________
> Openmp-dev mailing list
> Openmp-dev at lists.llvm.org
> http://lists.llvm.org/cgi-bin/mailman/listinfo/openmp-dev
>



-- 
Jeff Hammond
jeff.science at gmail.com
http://jeffhammond.github.io/
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.llvm.org/pipermail/openmp-dev/attachments/20180622/bde8749f/attachment.html>


More information about the Openmp-dev mailing list