Remove count_one_bits() in acl.c.
Nathan Bossart <nathan@postgresql.org>
Remove count_one_bits() in acl.c. The only caller, select_best_grantor(), can instead use pg_popcount64(). This isn't performance-critical code, but we might as well use the centralized implementation. While at it, add some test coverage for this part of select_best_grantor(). Reviewed-by: Álvaro Herrera <alvherre@alvh.no-ip.org> Discussion: https://postgr.es/m/Z9GtL7Nm6hsYyJnF%40nathan
Files
| Path | Change | +/− |
|---|---|---|
| src/backend/utils/adt/acl.c | modified | +1 −19 |
| src/test/regress/expected/privileges.out | modified | +27 −0 |
| src/test/regress/sql/privileges.sql | modified | +22 −0 |
Discussion
- remove open-coded popcount in acl.c 6 messages · 2025-03-12