Re: [PATCH 1/2] ipc semaphores: reduce ipc_lock contention in semtimedop

Previous message: [thread] [date] [author]
Next message: [thread] [date] [author]
From: Nick Piggin
Date: Tuesday, April 13, 2010 - 11:09 am

On Tue, Apr 13, 2010 at 01:39:41PM -0400, Chris Mason wrote:

I had a bit of a hack at doing per-semaphore stuff when I was looking
at the first optimization, but it was tricky to make it work.

The other thing I don't know if your patch gets right is requeueing on
of the operations. When you requeue from one list to another, then you
seem to lose ordering with other pending operations, so that would
seem to break the API as well (can't remember if the API strictly
mandates FIFO, but anyway it can open up starvation cases).

I was looking at doing a sequence number to be able to sort these, but
it ended up getting over complex (and SAP was only using simple ops so
it didn't seem to need much better).

We want to be careful not to change semantics at all. And it gets
tricky quickly :( What about Zach's simpler wakeup API?


--
Previous message: [thread] [date] [author]
Next message: [thread] [date] [author]

Messages in current thread:
[PATCH RFC] Optimize semtimedop, Chris Mason, (Mon Apr 12, 11:49 am)
Re: [PATCH 1/2] ipc semaphores: reduce ipc_lock contention ..., Nick Piggin, (Tue Apr 13, 11:09 am)