mirror of
http://git.haproxy.org/git/haproxy.git/
synced 2025-02-17 02:56:51 +00:00
MAJOR: threads: Offically enable the threads support in HAProxy
Now, USE_THREAD option is implicitly enabled when HAProxy is compiled, for targets linux2628 and freebsd. To enable it for other targets, you can set "USE_THREAD=1" explicitly on the command line. And to disable it explicitly, you must set "USE_THREAD=" on the command line. Now, to be clear. This does not means it is bug free, far from that. But it seems stable enough to be tested. You can try to experiment it and to report bugs of course by setting nbthread parameter. By leaving it to 1 (or not using it at all), it should be as safe as an HAProxy compiled without threads. Between the commit "MINOR: threads: Prepare makefile to link with pthread" and this one, the feature was in development and really unstable. It could be hard to track a bug using a bisect for all these commits.
This commit is contained in:
parent
1bc04c7664
commit
a1ae7e81cd
6
Makefile
6
Makefile
@ -17,6 +17,7 @@
|
||||
# USE_PCRE2_JIT : enable JIT for faster regex on libpcre2
|
||||
# USE_POLL : enable poll(). Automatic.
|
||||
# USE_PRIVATE_CACHE : disable shared memory cache of ssl sessions.
|
||||
# USE_THREAD : enable threads support.
|
||||
# USE_PTHREAD_PSHARED : enable pthread process shared mutex on sslcache.
|
||||
# USE_REGPARM : enable regparm optimization. Recommended on x86.
|
||||
# USE_STATIC_PCRE : enable static libpcre. Recommended.
|
||||
@ -238,6 +239,9 @@ LDFLAGS = $(ARCH_FLAGS) -g
|
||||
# passing USE_POLL="" on the make command line.
|
||||
USE_POLL = default
|
||||
|
||||
# Always enable threads support by default and let the Makefile detect if
|
||||
# HAProxy can be compiled with threads or not.
|
||||
|
||||
ifeq ($(TARGET),generic)
|
||||
# generic system target has nothing specific
|
||||
USE_POLL = implicit
|
||||
@ -298,6 +302,7 @@ ifeq ($(TARGET),linux2628)
|
||||
USE_CPU_AFFINITY= implicit
|
||||
ASSUME_SPLICE_WORKS= implicit
|
||||
USE_DL = implicit
|
||||
USE_THREAD = implicit
|
||||
else
|
||||
ifeq ($(TARGET),solaris)
|
||||
# This is for Solaris 8
|
||||
@ -316,6 +321,7 @@ ifeq ($(TARGET),freebsd)
|
||||
USE_KQUEUE = implicit
|
||||
USE_TPROXY = implicit
|
||||
USE_LIBCRYPT = implicit
|
||||
USE_THREAD = implicit
|
||||
else
|
||||
ifeq ($(TARGET),osx)
|
||||
# This is for Mac OS/X
|
||||
|
Loading…
Reference in New Issue
Block a user