[jira] [Commented] (TS-3044) linux native AIO should use eventfd if available to signal thread

2014-10-02 Thread ASF subversion and git services (JIRA)

[ 
https://issues.apache.org/jira/browse/TS-3044?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanelfocusedCommentId=14157141#comment-14157141
 ] 

ASF subversion and git services commented on TS-3044:
-

Commit 86295176ccb5b7ef5c96686b398733e1edf6f2ee in trafficserver's branch 
refs/heads/master from [~jplevyak]
[ https://git-wip-us.apache.org/repos/asf?p=trafficserver.git;h=8629517 ]

TS-3044: Use eventfd in AIO_MODE_NATIVE if available


 linux native AIO should use eventfd if available to signal thread
 -

 Key: TS-3044
 URL: https://issues.apache.org/jira/browse/TS-3044
 Project: Traffic Server
  Issue Type: Improvement
  Components: Cache
Reporter: John Plevyak
Assignee: Phil Sorber
 Fix For: 5.2.0

 Attachments: native-aio-eventfd.patch


 linux native AIO has the ability to signal the event thread to get off the 
 poll and service the disk via the io_set_eventfd() call.  linux native AIO 
 scales better than the thread-based IO, but the current implementation can 
 introduce delays on lightly loaded systems because of the thread is waiting 
 on epoll().   This can be remedied by using io_set_eventfd



--
This message was sent by Atlassian JIRA
(v6.3.4#6332)


[jira] [Commented] (TS-3044) linux native AIO should use eventfd if available to signal thread

2014-10-01 Thread Phil Sorber (JIRA)

[ 
https://issues.apache.org/jira/browse/TS-3044?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanelfocusedCommentId=14154972#comment-14154972
 ] 

Phil Sorber commented on TS-3044:
-

Ok, you've convinced me. I am +1 on this patch. If you want to commit this as 
is, I will fix the perror() in the AIO_MODE_NATIVE code.

 linux native AIO should use eventfd if available to signal thread
 -

 Key: TS-3044
 URL: https://issues.apache.org/jira/browse/TS-3044
 Project: Traffic Server
  Issue Type: Improvement
  Components: Cache
Reporter: John Plevyak
Assignee: Phil Sorber
 Fix For: 5.2.0

 Attachments: native-aio-eventfd.patch


 linux native AIO has the ability to signal the event thread to get off the 
 poll and service the disk via the io_set_eventfd() call.  linux native AIO 
 scales better than the thread-based IO, but the current implementation can 
 introduce delays on lightly loaded systems because of the thread is waiting 
 on epoll().   This can be remedied by using io_set_eventfd



--
This message was sent by Atlassian JIRA
(v6.3.4#6332)


[jira] [Commented] (TS-3044) linux native AIO should use eventfd if available to signal thread

2014-09-30 Thread Phil Sorber (JIRA)

[ 
https://issues.apache.org/jira/browse/TS-3044?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanelfocusedCommentId=14153806#comment-14153806
 ] 

Phil Sorber commented on TS-3044:
-

[~jplevyak]

I really like this approach. This is something I feel we should do with the 
threaded AIO as well.

A couple of comments:

Why perror here and not some ATS built in logging?
{noformat}
+  perror(io_getevents);
{noformat}

Does lowering the AIO_PERIOD make sense globally if we have a case where we may 
still not use eventfd?
{noformat}
-#define AIO_PERIOD-HRTIME_MSECONDS(4)
+#define AIO_PERIOD-HRTIME_MSECONDS(10)
--
+#ifdef HAVE_EVENTFD
+  io_set_eventfd(op-aiocb, t-evfd);
+#endif
{noformat}

 linux native AIO should use eventfd if available to signal thread
 -

 Key: TS-3044
 URL: https://issues.apache.org/jira/browse/TS-3044
 Project: Traffic Server
  Issue Type: Improvement
  Components: Cache
Reporter: John Plevyak
Assignee: Phil Sorber
 Fix For: 5.2.0

 Attachments: native-aio-eventfd.patch


 linux native AIO has the ability to signal the event thread to get off the 
 poll and service the disk via the io_set_eventfd() call.  linux native AIO 
 scales better than the thread-based IO, but the current implementation can 
 introduce delays on lightly loaded systems because of the thread is waiting 
 on epoll().   This can be remedied by using io_set_eventfd



--
This message was sent by Atlassian JIRA
(v6.3.4#6332)


[jira] [Commented] (TS-3044) linux native AIO should use eventfd if available to signal thread

2014-09-30 Thread John Plevyak (JIRA)

[ 
https://issues.apache.org/jira/browse/TS-3044?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanelfocusedCommentId=14154210#comment-14154210
 ] 

John Plevyak commented on TS-3044:
--

The perror is from the original AIO_MODE_NATIVE code.   I was just following 
the style as this was a minimal patch just to add the eventfd handling.   I 
agree that we should change that to standard ATS errors.  For most unix/linux 
installations waiting for less than 10msec is the same as waiting for 0msecs, 
and can result in busy spinning.   The iocore has a minimum wait time, so 
HRTIME_MSECONDS(4) is disingenuous as well as being a poor idea (if it actually 
was obeyed).  

 linux native AIO should use eventfd if available to signal thread
 -

 Key: TS-3044
 URL: https://issues.apache.org/jira/browse/TS-3044
 Project: Traffic Server
  Issue Type: Improvement
  Components: Cache
Reporter: John Plevyak
Assignee: Phil Sorber
 Fix For: 5.2.0

 Attachments: native-aio-eventfd.patch


 linux native AIO has the ability to signal the event thread to get off the 
 poll and service the disk via the io_set_eventfd() call.  linux native AIO 
 scales better than the thread-based IO, but the current implementation can 
 introduce delays on lightly loaded systems because of the thread is waiting 
 on epoll().   This can be remedied by using io_set_eventfd



--
This message was sent by Atlassian JIRA
(v6.3.4#6332)


[jira] [Commented] (TS-3044) linux native AIO should use eventfd if available to signal thread

2014-08-25 Thread John Plevyak (JIRA)

[ 
https://issues.apache.org/jira/browse/TS-3044?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanelfocusedCommentId=14110181#comment-14110181
 ] 

John Plevyak commented on TS-3044:
--

Assigned to weijin for review as he was in charge of the native linux AIO and 
can assess the impact.  As I remember, this isn't enabled by default because of 
the latency concerns by Leif.  With this patch, if the latency concerns are 
addressed, we might want to enable this feature by default.

 linux native AIO should use eventfd if available to signal thread
 -

 Key: TS-3044
 URL: https://issues.apache.org/jira/browse/TS-3044
 Project: Traffic Server
  Issue Type: Improvement
  Components: Cache
Reporter: John Plevyak
Assignee: weijin
 Attachments: native-aio-eventfd.patch


 linux native AIO has the ability to signal the event thread to get off the 
 poll and service the disk via the io_set_eventfd() call.  linux native AIO 
 scales better than the thread-based IO, but the current implementation can 
 introduce delays on lightly loaded systems because of the thread is waiting 
 on epoll().   This can be remedied by using io_set_eventfd



--
This message was sent by Atlassian JIRA
(v6.2#6252)


[jira] [Commented] (TS-3044) linux native AIO should use eventfd if available to signal thread

2014-08-25 Thread weijin (JIRA)

[ 
https://issues.apache.org/jira/browse/TS-3044?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanelfocusedCommentId=14110206#comment-14110206
 ] 

weijin commented on TS-3044:


Nice work, John. And I can`t wait to test it. :)

 linux native AIO should use eventfd if available to signal thread
 -

 Key: TS-3044
 URL: https://issues.apache.org/jira/browse/TS-3044
 Project: Traffic Server
  Issue Type: Improvement
  Components: Cache
Reporter: John Plevyak
Assignee: weijin
 Fix For: 5.2.0

 Attachments: native-aio-eventfd.patch


 linux native AIO has the ability to signal the event thread to get off the 
 poll and service the disk via the io_set_eventfd() call.  linux native AIO 
 scales better than the thread-based IO, but the current implementation can 
 introduce delays on lightly loaded systems because of the thread is waiting 
 on epoll().   This can be remedied by using io_set_eventfd



--
This message was sent by Atlassian JIRA
(v6.2#6252)