* Given a feature id this method increments the feature usage count for the * feature for the current backend process. * * Postgres guarantees that MyBackendId is always between 1 and MaxBackend. */
| 501 | * Postgres guarantees that MyBackendId is always between 1 and MaxBackend. |
| 502 | */ |
| 503 | static inline void |
| 504 | ReportFeatureUsage(int featureId) |
| 505 | { |
| 506 | pg_write_barrier(); |
| 507 | #if PG_VERSION_NUM >= 170000 |
| 508 | FeatureCounterBackendArray[MyProcNumber][featureId]++; |
| 509 | #else |
| 510 | FeatureCounterBackendArray[MyBackendId - 1][featureId]++; |
| 511 | #endif |
| 512 | } |
| 513 | |
| 514 | |
| 515 | #endif /* FEATURE_COUNTER_H */ |
no outgoing calls
no test coverage detected