I have seen the light. Seriously, I initially had it as you said, but
Linus was strongly recommending cacheline size objects to
avoid false sharing other than on the lock word
However, there should be no problem whatsoever to bring that back
to 2 words.
> typedef struct ulock_t {
> unsigned long status;
> unsigned long qcount; /* this will change instead of type */
> }
Counters are only there for lock statistics.
padding is only there for filling the cacheline (might be obsolute anyway.
What can be done is to make the ____cacheline_aligned a configuration
option. Nothing in the system relies on this. I'll see how I'll
do this.
Also, this can be brought down to one word, if we don't have
demand based kernel object allocation and/or multiple queue requirements
as requested by BenLeHaise.
Rusty, how would your pin based approach be effected by this ?
Comments ?
-- Hubertus
>
> http://sourceforge.net/projects/skiplist
>
> I have put test results up on that site as well, but those tests were
> made using spinlocks at user-level! In otherwords, I don't really
> believe my results are meaningful.
>
> (And let me warn you that there's a bug and haven't uploaded the
> latest version yet...)
>
> -josh
-
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/