help-glpk
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: [Help-glpk] Patch to configure a reentrant version of GLPK


From: Heinrich Schuchardt
Subject: Re: [Help-glpk] Patch to configure a reentrant version of GLPK
Date: Thu, 5 Jan 2017 21:57:30 +0100
User-agent: Mozilla/5.0 (X11; Linux x86_64; rv:45.0) Gecko/20100101 Icedove/45.4.0

On 12/29/2016 03:25 PM, Chris Matrakidis wrote:
> Andrew,
> 
> The attached patch adds the --enable-reentrant option to configure
> (disabled by default)

Thank you Chris for you patch. Thread safeness for GLPK has been a topic
discussed again and again.

Why should this option be disabled by default?

For all applications that up to now were only able to use GLPK with one
thread the patch makes no difference.

If we have such a switch a program calling the library will need a means
of determining if the library is thread-safe or not.

So it would be preferable not to have any switch at all but simply make
the library thread safe in all cases.

> as suggested by David Monniaux a few days ago
> [1]. When selected, the appropriate thread local storage class
> specifier is identified, added to config.h and used in tls.c. The
> patch is based on the work of Dmitry Nadezhin [2] and the ax_tls macro
> form the autoconf archive [3] simplified to match the configure.ac
> style, The code remains C89 if the option is not selected.

It also remains C89 if the compiler does not support any of the prefixes
tested.

Best regards

Heinrich Schuchardt

> 
> I have tested this extensively but only on Linux with gcc, so
> additional testing and feedback is welcome.
> 
> Best Regards,
> 
> Chris Matrakidis
> 
> [1] http://lists.gnu.org/archive/html/help-glpk/2016-12/msg00023.html
> [2] https://github.com/nadezhin/thermocompensation
> [3] http://www.gnu.org/software/autoconf-archive/ax_tls.html




reply via email to

[Prev in Thread] Current Thread [Next in Thread]