mirror of
https://github.com/haproxy/haproxy.git
synced 2026-04-15 21:59:41 -04:00
MINOR: threads: Add THREAD_LOCAL macro
When compiled with threads support, this marco is set to __thread. Else it is empty.
This commit is contained in:
parent
5f271850bd
commit
e9bd686b68
1 changed files with 6 additions and 0 deletions
|
|
@ -41,6 +41,12 @@
|
|||
# define CONFIG_HAP_MEM_OPTIM
|
||||
#endif /* CONFIG_HAP_NO_MEM_OPTIM */
|
||||
|
||||
#ifdef USE_THREAD
|
||||
#define THREAD_LOCAL __thread
|
||||
#else
|
||||
#define THREAD_LOCAL
|
||||
#endif
|
||||
|
||||
/* CONFIG_HAP_INLINE_FD_SET
|
||||
* This makes use of inline FD_* macros instead of calling equivalent
|
||||
* functions. Benchmarks on a Pentium-M show that using functions is
|
||||
|
|
|
|||
Loading…
Reference in a new issue