Re: [PATCH] Significant performace improvements on reiserfs systems

From: Robert Love (rml@tech9.net)
Date: Thu Sep 20 2001 - 15:52:46 EST


On Thu, 2001-09-20 at 13:39, Andrew Morton wrote:
> > Andrew, are these still maintained or should I pull out the reiserfs bits?
>
> This is the reiserfs part - it applies to 2.4.10-pre12 OK.
>
> For the purposes of Robert's patch, conditional_schedule()
> should be defined as
>
> if (current->need_resched && current->lock_depth == 0) {
> unlock_kernel();
> lock_kernel();
> }
>
> which is somewhat crufty, because the implementation of lock_kernel()
> is arch-specific. But all architectures seem to implement it the same way.

Note that we only support preemption on i386 thus far, so this is not an
issue (yet).

One other note, in not all cases is it OK to just drop the one lock
(above it is). Say we hold a spinlock, but another lock (most notably
the BKL) is also held. Since the preemption counter is recursive, we
still won't allow preemption until all locks are dropped. In this case,
we need to see what else needs to be dropped, or just call schedule()
explicitly.

> <patch snipped>

Looks nice, Andrew.

Anyone try this? (I don't use ReiserFS).

I am putting together a conditional scheduling patch to fix some of the
worst cases, for use in conjunction with the preemption patch, and this
might be useful.

-- 
Robert M. Love
rml at ufl.edu
rml at tech9.net

- To unsubscribe from this list: send the line "unsubscribe linux-kernel" in the body of a message to majordomo@vger.kernel.org More majordomo info at http://vger.kernel.org/majordomo-info.html Please read the FAQ at http://www.tux.org/lkml/



This archive was generated by hypermail 2b29 : Sun Sep 23 2001 - 21:00:40 EST