Re: [PATCH] genirq: reduce irqdebug bouncing cachelines
From: Cédric Le Goater
Date: Sat May 15 2021 - 13:22:30 EST
On 4/13/21 10:24 PM, Thomas Gleixner wrote:
> On Tue, Apr 13 2021 at 14:16, Cédric Le Goater wrote:
>>>> We could test irq_settings_no_debug() directly under handle_nested_irq()
>>>> and handle_irq_event_percpu() to avoid calling note_interrupt(), just
>>>> like we do for noirqdebug.
>>>
>>> We can do that, but then we should not just make it:
>>>
>>> if (!irqnodebug && !irq_settings_no_debug(desc))
>>> note_interrupt(...);
>>>
>>> Instead have only one condition:
>>>
>>> if (!irq_settings_no_debug(desc))
>>> note_interrupt(...);
>>>
>>> See the uncompiled delta patch below.
>>
>> I merged this second part with the first and gave IRQF_NO_DEBUG a try
>> on P8 and P9 systems and all looked fine. I should send both patches
>> after IRQF_NO_AUTOEN is merged in mainline.
>
> Does having that NODEBUG flag set on the IPI irqs make a measurable
> difference or is it just too small to matter?
Here are some ipistorm results on a P10 system with 12 activated chips,
each with ~120 HW threads. The kernel is a 5.12 plus extras :
- XIVE IPI IRQ domain patchset (merged in 5.13-rc1)
- MSI IRQ domain pachset (should not have any impact)
- your IRQF_NO_DEBUG patch.
There is some slight improvement on the first 4 chips but it gets
better when we reach the fifth which requires an extra hop on the
bus. On 12 chips, we are close to an extra 9%.
Given these results, I think it would good to have the IRQF_NO_DEBUG
flag.
Thanks,
C.
[*] https://github.com/antonblanchard/ipistorm
Mint/s
chips cpus IRQF_NO_DEBUG
---------------------------------------
0 15 4.32 4.32
31 8.63 8.65
47 12.86 12.89
63 17.11 17.16
79 21.29 21.40
95 25.45 25.67
111 29.61 29.80
1 127 33.53 33.64
143 37.55 37.77
159 41.50 41.78
175 45.42 45.63
191 49.39 49.51
207 53.27 53.61
223 57.17 57.73
239 61.05 61.59
2 255 64.94 65.69
271 65.20 62.62
287 62.20 65.18
303 63.96 67.69
319 65.74 69.95
335 67.45 71.84
351 69.63 72.75
3 367 70.96 74.38
383 72.34 75.62
399 74.26 77.69
415 76.49 79.78
431 78.46 81.67
447 79.87 82.50
463 82.07 85.13
479 83.95 87.03
4 495 87.67 92.94
511 93.70 98.74
527 95.43 101.45
543 97.39 103.39
559 98.95 104.76
575 100.08 105.70
591 101.26 107.06
607 102.17 108.16
5 623 103.27 109.44
639 104.95 111.14
655 106.59 112.36
671 107.92 113.72
687 108.75 115.25
703 109.84 117.06
719 110.99 118.45
6 735 112.30 119.07
751 114.19 120.72
767 115.59 122.70
783 116.69 124.80
799 118.62 126.38
815 120.38 128.36
831 120.78 129.15
847 122.69 130.44
7 863 123.65 132.44
879 124.78 133.83
895 126.58 135.43
911 128.02 136.85
927 130.48 138.98
943 130.98 140.58
959 132.17 141.74
8 975 134.55 142.62
991 134.89 143.82
1007 135.64 145.51
1023 137.23 147.22
1039 139.37 149.85
1055 141.80 150.27
1071 141.37 152.33
1087 143.08 153.20
9 1103 144.83 154.23
1119 144.55 155.96
1135 147.32 157.91
1151 148.31 159.04
1167 150.67 160.41
1183 149.44 161.82
1199 152.53 164.69
1215 153.51 165.31
10 1231 154.88 166.67
1247 156.06 168.40
1263 157.59 170.01
1279 158.74 172.10
1295 159.55 172.79
1311 160.74 173.62
1327 161.86 175.02
11 1343 163.75 175.95
1359 163.67 177.96
1375 164.95 178.94
1391 166.53 180.09
1407 167.17 181.25
1423 168.84 183.94
1439 170.20 183.96
1455 170.47 185.47