Message ID | 20240403155950.2068109-1-dawei.li@shingroup.cn |
---|---|
Headers | show |
Series | perf: Avoid placing cpumask on the stack | expand |
On Wed, 3 Apr 2024 23:59:47 +0800 Dawei Li <dawei.li@shingroup.cn> wrote: > In general it's preferable to avoid placing cpumasks on the stack, as > for large values of NR_CPUS these can consume significant amounts of > stack space and make stack overflows more likely. > > Use cpumask_any_and_but() to avoid the need for a temporary cpumask on > the stack. > > Suggested-by: Mark Rutland <mark.rutland@arm.com> > Reviewed-by: Mark Rutland <mark.rutland@arm.com> > Signed-off-by: Dawei Li <dawei.li@shingroup.cn> Acked-by: Jonathan Cameron <Jonathan.Cameron@huawei.com>
On Wed, 3 Apr 2024 23:59:48 +0800 Dawei Li <dawei.li@shingroup.cn> wrote: > In general it's preferable to avoid placing cpumasks on the stack, as > for large values of NR_CPUS these can consume significant amounts of > stack space and make stack overflows more likely. > > Use cpumask_any_and_but() to avoid the need for a temporary cpumask on > the stack. > > Suggested-by: Mark Rutland <mark.rutland@arm.com> > Reviewed-by: Mark Rutland <mark.rutland@arm.com> > Signed-off-by: Dawei Li <dawei.li@shingroup.cn> Acked-by: Jonathan Cameron <Jonathan.Cameron@huawei.com>
On 2024/4/3 23:59, Dawei Li wrote: > In general it's preferable to avoid placing cpumasks on the stack, as > for large values of NR_CPUS these can consume significant amounts of > stack space and make stack overflows more likely. > > Use cpumask_any_and_but() to avoid the need for a temporary cpumask on > the stack. > > Suggested-by: Mark Rutland <mark.rutland@arm.com> > Reviewed-by: Mark Rutland <mark.rutland@arm.com> > Signed-off-by: Dawei Li <dawei.li@shingroup.cn> Reviewed-by: Shuai Xue <xueshuai@linux.alibaba.com> Thank you. Shuai
On Wed, 03 Apr 2024 23:59:40 +0800, Dawei Li wrote: > This is v3 of previous series on elimination of placing cpumask var on > stack. > > Change since v2: > - Update commit message for patch[2-10]. [Mark] > - Add Reviewed-by from Mark for patch[2-10]. > > [...] Applied to will (for-next/perf), thanks! [01/10] cpumask: add cpumask_any_and_but() https://git.kernel.org/will/c/897fa2c38c07 [02/10] perf/alibaba_uncore_drw: Avoid placing cpumask on the stack https://git.kernel.org/will/c/2f6589df124e [03/10] perf/arm-cmn: Avoid placing cpumask on the stack https://git.kernel.org/will/c/60c73240f304 [04/10] perf/arm_cspmu: Avoid placing cpumask on the stack https://git.kernel.org/will/c/b5310fa1fe8e [05/10] perf/arm_dsu: Avoid placing cpumask on the stack https://git.kernel.org/will/c/bea2a13b207e [06/10] perf/dwc_pcie: Avoid placing cpumask on the stack https://git.kernel.org/will/c/cf276ee46bc4 [07/10] perf/hisi_pcie: Avoid placing cpumask on the stack https://git.kernel.org/will/c/d7df79e6af29 [08/10] perf/hisi_uncore: Avoid placing cpumask on the stack https://git.kernel.org/will/c/b78d0fa25462 [09/10] perf/qcom_l2: Avoid placing cpumask on the stack https://git.kernel.org/will/c/fc85cee97029 [10/10] perf/thunderx2: Avoid placing cpumask on the stack https://git.kernel.org/will/c/595275ca4984 Cheers,