ignite-issues mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "Vladimir Ozerov (JIRA)" <j...@apache.org>
Subject [jira] [Commented] (IGNITE-4766) Relax worker thread wakeup logic in StipedExecutor
Date Fri, 26 May 2017 11:49:04 GMT

    [ https://issues.apache.org/jira/browse/IGNITE-4766?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=16026183#comment-16026183
] 

Vladimir Ozerov commented on IGNITE-4766:
-----------------------------------------

Closing as I failed to find any improvement in distributed benchmarks. Original patch is attached
in case we would like to continue investigation in future.

> Relax worker thread wakeup logic in StipedExecutor
> --------------------------------------------------
>
>                 Key: IGNITE-4766
>                 URL: https://issues.apache.org/jira/browse/IGNITE-4766
>             Project: Ignite
>          Issue Type: Task
>          Components: general
>    Affects Versions: 1.9
>            Reporter: Vladimir Ozerov
>            Assignee: Vladimir Ozerov
>             Fix For: 2.1
>
>         Attachments: IGNITE_4766.patch
>
>
> *Problem*
> Worker threads in {{StripedExecutor}} have {{parked}} state flag. When set to {{true}}
NIO threads will call {{LockSupport.unpark}} after submitting new task to a queue.
> The problem is that this flag is only changed by worker thread. Thus, if NIO worker submitted
a new task and called {{unpark}}, worker will clean up {{parked}} state only after real wake
up what may take microseconds. All subsequent submits from NIO thread occurred during this
time will also invoke {{unpark}} thus generating high contention on the underlying OS primitives.
Namely, condition variables which ultimately delegates to {{futex}} on Linux.
> *Solution*
> NIO threads must be able to clear {{parked}} state as well. Some CAS magic will be required
there. This way we will minimize number of {{unapark}} calls.



--
This message was sent by Atlassian JIRA
(v6.3.15#6346)

Mime
View raw message