- Notifications
You must be signed in to change notification settings - Fork5.2k
Commit2973b1c
committed
Lower bounds related to pgstats kinds
This commit changes stats kinds to have the following bounds, makingtheir handling in core cheaper by default:- PGSTAT_KIND_CUSTOM_MIN 128 -> 24- PGSTAT_KIND_MAX 256 -> 32The original numbers were rather high, and showed an impact onperformance in pgstat_report_stat() for the case of simple queries withits early-exit path if there are no pending statistics to flush. Thislogic will be improved more in a follow-up commit to bring theperformance of pgstat_report_stat() on par with v17 and older versions.Lowering the bounds is a change worth doing on its own, independently ofthe other improvement.These new numbers should be enough to leave some room for the followingyears for built-in and custom stats kinds, with stable ID numbers. Atleast that should be enough to start with this facility for extensiondevelopers. It can be always increased in the tree depending on therequirements wanted.Per discussion with Andres Freund and Bertrand Drouvot.Discussion:https://postgr.es/m/eb224uegsga2hgq7dfq3ps5cduhpqej7ir2hjxzzozjthrekx5@dysei6buqtheBackpatch-through: 181 parent33f74b8 commit2973b1c
File tree
3 files changed
+5
-5
lines changed- src
- include/utils
- test/modules/injection_points
3 files changed
+5
-5
lines changed| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
18 | 18 | | |
19 | 19 | | |
20 | 20 | | |
21 | | - | |
| 21 | + | |
22 | 22 | | |
23 | 23 | | |
24 | 24 | | |
| |||
46 | 46 | | |
47 | 47 | | |
48 | 48 | | |
49 | | - | |
| 49 | + | |
50 | 50 | | |
51 | 51 | | |
52 | 52 | | |
| |||
55 | 55 | | |
56 | 56 | | |
57 | 57 | | |
58 | | - | |
| 58 | + | |
59 | 59 | | |
60 | 60 | | |
61 | 61 | | |
| |||
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
59 | 59 | | |
60 | 60 | | |
61 | 61 | | |
62 | | - | |
| 62 | + | |
63 | 63 | | |
64 | 64 | | |
65 | 65 | | |
| |||
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
64 | 64 | | |
65 | 65 | | |
66 | 66 | | |
67 | | - | |
| 67 | + | |
68 | 68 | | |
69 | 69 | | |
70 | 70 | | |
| |||
0 commit comments
Comments
(0)