[
https://issues.apache.org/jira/browse/TS-2137?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel
]
Yunkai Zhang updated TS-2137:
-----------------------------
Description:
At the end of lifetime of each http connection, the logging action will call
pthread_cond_signal() to notify flush threads.
As we known, pthread_cond_signal() need to take lock, it'll cause more context
switch than eventfd.
The logging speed is very important for us which will affect RT, it is worth
optimizing.
I can confirm that evenfd is supported in Linux platform.
Let's optimize it in Linux firstly.
===
I have wrote a small program to compare the speed of eventfd and pthread_cond
signal.
was:
At the end of lifetime of each http connection, the logging action will call
pthread_cond_signal() to notify flush threads.
As we known, pthread_cond_signal() need to take lock, it'll cause more context
switch than eventfd.
The logging speed is very important for us which will affect RT, it is worth
optimizing.
I can confirm that evenfd is supported in Linux platform.
Let's optimize it in Linux firstly.
> Use eventfd instread of pthread signal/wait to speed up logging
> ---------------------------------------------------------------
>
> Key: TS-2137
> URL: https://issues.apache.org/jira/browse/TS-2137
> Project: Traffic Server
> Issue Type: Improvement
> Components: Logging
> Reporter: Yunkai Zhang
> Assignee: Yunkai Zhang
> Fix For: 3.5.0
>
> Attachments:
> 0001-TS-2137-Use-eventfd-instread-of-pthread-signal-wait-.patch,
> eventfd_vs_pthread_cond_benchmark.tar.gz
>
>
> At the end of lifetime of each http connection, the logging action will call
> pthread_cond_signal() to notify flush threads.
> As we known, pthread_cond_signal() need to take lock, it'll cause more
> context switch than eventfd.
> The logging speed is very important for us which will affect RT, it is worth
> optimizing.
> I can confirm that evenfd is supported in Linux platform.
> Let's optimize it in Linux firstly.
> ===
> I have wrote a small program to compare the speed of eventfd and pthread_cond
> signal.
--
This message is automatically generated by JIRA.
If you think it was sent incorrectly, please contact your JIRA administrators
For more information on JIRA, see: http://www.atlassian.com/software/jira