forked frompostgres/postgres
- Notifications
You must be signed in to change notification settings - Fork6
Commit2c93818
committed
Remove not-very-useful early checks of __pg_log_level in logging.h.
Enforce __pg_log_level message filtering centrally in logging.c,instead of relying on the calling macros to do it. This is morereliable (e.g. it works correctly for direct calls to pg_log_generic)and it saves a percent or so of total code size because we get rid ofso many duplicate checks of __pg_log_level.This does mean that argument expressions in a logging macro will beevaluated even if we end up not printing anything. That seems oflittle concern for INFO and higher levels as those messages are printedby default, and most of our frontend programs don't even offer a way toturn them off. I left the unlikely() checks in place for DEBUGmessages, though.Discussion:https://postgr.es/m/3993549.1649449609@sss.pgh.pa.us1 parentd4f109e commit2c93818
File tree
3 files changed
+24
-40
lines changed- src
- bin/pg_dump
- common
- include/common
3 files changed
+24
-40
lines changedLines changed: 1 addition & 2 deletions
Original file line number | Diff line number | Diff line change | |
---|---|---|---|
| |||
34 | 34 |
| |
35 | 35 |
| |
36 | 36 |
| |
37 |
| - | |
38 |
| - | |
| 37 | + | |
39 | 38 |
| |
40 | 39 |
| |
41 | 40 |
| |
|
Lines changed: 4 additions & 0 deletions
Original file line number | Diff line number | Diff line change | |
---|---|---|---|
| |||
228 | 228 |
| |
229 | 229 |
| |
230 | 230 |
| |
| 231 | + | |
| 232 | + | |
| 233 | + | |
| 234 | + | |
231 | 235 |
| |
232 | 236 |
| |
233 | 237 |
| |
|
Lines changed: 19 additions & 38 deletions
Original file line number | Diff line number | Diff line change | |
---|---|---|---|
| |||
103 | 103 |
| |
104 | 104 |
| |
105 | 105 |
| |
106 |
| - | |
107 |
| - | |
108 |
| - | |
109 |
| - | |
| 106 | + | |
| 107 | + | |
110 | 108 |
| |
111 |
| - | |
112 |
| - | |
113 |
| - | |
114 |
| - | |
| 109 | + | |
| 110 | + | |
115 | 111 |
| |
116 |
| - | |
117 |
| - | |
118 |
| - | |
119 |
| - | |
| 112 | + | |
| 113 | + | |
120 | 114 |
| |
121 |
| - | |
122 |
| - | |
123 |
| - | |
124 |
| - | |
| 115 | + | |
| 116 | + | |
125 | 117 |
| |
126 |
| - | |
127 |
| - | |
128 |
| - | |
129 |
| - | |
| 118 | + | |
| 119 | + | |
130 | 120 |
| |
131 |
| - | |
132 |
| - | |
133 |
| - | |
134 |
| - | |
| 121 | + | |
| 122 | + | |
135 | 123 |
| |
136 |
| - | |
137 |
| - | |
138 |
| - | |
139 |
| - | |
| 124 | + | |
| 125 | + | |
140 | 126 |
| |
141 |
| - | |
142 |
| - | |
143 |
| - | |
144 |
| - | |
| 127 | + | |
| 128 | + | |
145 | 129 |
| |
146 |
| - | |
147 |
| - | |
148 |
| - | |
149 |
| - | |
| 130 | + | |
| 131 | + | |
150 | 132 |
| |
151 | 133 |
| |
152 | 134 |
| |
| |||
167 | 149 |
| |
168 | 150 |
| |
169 | 151 |
| |
170 |
| - | |
171 |
| - | |
| 152 | + | |
172 | 153 |
| |
173 | 154 |
| |
174 | 155 |
| |
|
0 commit comments
Comments
(0)