blmfl
i-rex · Experimental bloom-filter and range-summary aggregates for I-Rex.
Overview
PostgreSQL · 16
Usage
Sources:
- I-Rex extension guide
- Control file
- Version 0.0.1 SQL
- Usage tests
- C implementation
- PostgreSQL 16 environment
blmfl 0.0.1 is the experimental bloom-filter and range-summary extension shipped with the I-Rex SQL-debugging research artifact. It supplies aggregates and membership probes; it does not automatically optimize ordinary PostgreSQL queries.
Enable and Create a Summary
The native extension requires administrative installation. The supplied environment uses PostgreSQL 16; other majors are not established by that artifact. No shared preload is required.
Set positive sizes and counts explicitly: all three GUCs default to zero, and the source contains divisions and modulo operations using them. These session settings determine subsequently constructed summaries, not existing values.
SQL Surface
BLMFL_RESULTstores filter bytes, size, estimated count, hash count and accumulated-item count.blmfl_anyandblmfl_test_anyaccept typed arguments;blmflandblmfl_testexpose the bytea variant. Keep construction and probe types consistent.blmfl_optimal_k,blmfl_fprandblmfl_approx_unique_countexpose sizing and estimate helpers.blmfl_mergeandblmfl_aggcombine summaries. The implementation checks matching bit lengths but does not establish every compatibility invariant.sarg_aggbuilds or combines lower/upper summaries; theis_iid_*,min_iidandmax_iidhelpers support I-Rex’s internal identifiers.
Research Boundaries
Source inspection shows that the typed hash loop retains only its final argument’s hash and ignores the per-hash seed. Do not treat it as a validated multi-column bloom filter. The merge buffer is allocated without explicit zeroing, and empty-input finalization raises an error. Estimates and merged summaries therefore need independent correctness checks.
Keep this artifact in an isolated research environment. Do not use its summaries to exclude application rows without exact validation. The supplied revision has no identified license grant, supported upgrade chain or production compatibility guarantee.