Re: [PATCH 0/3] smp: reduce stack requirements for smp_call_function_mask

Mike Travis
2008-09-08T15:41:19Z

Jes Sorensen wrote:
> Ingo Molnar wrote:
>>> Applies to linux-2.6.tip/master (with FUZZ).
>>
>> applied to tip/cpus4096, thanks Mike.
>>
>> I'm still wondering whether we should get rid of non-reference based
>> cpumask_t altogether ...
>
> Cool,
>
> I think we should, it's like a ticking bomb waiting to explode on us
> eventually. IMHO it was a big mistake to allow cpumask_t being passed
> by value in the first place.
>
> Cheers,
> Jes

Linus's idea of defining cpumask_t to be a simple long[1] or a pointer to
a cpumask is a good one. Unfortunately, the amount (and breadth) of the
code changes required is daunting, to say the least. In my source tree
there are 892 references to cpumask_t.

But I'll start looking into it asap. I don't know however if "NR_CPUS >
BITS_PER_LONG" is the correct metric to decide when to use pointers. There
must be a better "pain" indicator... ;-)

Thanks,
Mike