Re: [PATCH] perf lock: Implement basic sorting function of perflock

From: Peter Zijlstra
Date: Mon Dec 28 2009 - 06:01:52 EST


On Sun, 2009-12-20 at 11:56 +0900, Hitoshi Mitake wrote:
> +static struct lock_stat *lock_stat_findnew(void *addr, const char *name)
> +{
> + struct list_head *entry = lockhashentry(addr);
> + struct lock_stat *ret, *new;


Right, so you use a hash table to match lock instances, I suppose that's
faster than an rb-tree?

Do you also remove instances after a match to keep the hash relatively
small?

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