Messages in this thread | | | Subject | Re: [PATCH] task_work: avoid unneeded cmpxchg() in task_work_run() | From | Peter Zijlstra <> | Date | Tue, 09 Oct 2012 13:04:57 +0200 |
| |
On Mon, 2012-10-08 at 14:38 +0200, Oleg Nesterov wrote: > But the code looks more complex, and the only advantage is that > non-exiting task does xchg() instead of cmpxchg(). Not sure this > worth the trouble, in this case task_work_run() will likey run > the callbacks (the caller checks ->task_works != NULL), I do not > think this can add any noticeable speedup.
Yeah, I agree, the patch doesn't seem worth the trouble. It makes tricky code unreadable at best.
| |