feat(rust): encode and decode v2 float columns as ALP - #1603
Merged
Merged
Conversation
Contributor
Performance ComparisonPerformance Comparison
|
| zoom | tiles | prev_total | curr_total | delta_total | avg_delta | pct | best | worst |
|---|---|---|---|---|---|---|---|---|
| 0 | 1 | 71471 | 71471 | 0 | 0.0 | 0.0 | ||
| 1 | 4 | 220986 | 220986 | 0 | 0.0 | 0.0 | ||
| 2 | 16 | 615003 | 615003 | 0 | 0.0 | 0.0 | ||
| 3 | 64 | 1653851 | 1653851 | 0 | 0.0 | 0.0 | ||
| 4 | 256 | 3828904 | 3828904 | 0 | 0.0 | 0.0 | ||
| 5 | 1024 | 9716821 | 9716821 | 0 | 0.0 | 0.0 | ||
| 6 | 4096 | 32401914 | 32401914 | 0 | 0.0 | 0.0 | ||
| ALL | 5461 | 48508950 | 48508950 | 0 | 0.0 | 0.0 |
Top 3 improvements
Top 3 degradations
CommanderStorm
force-pushed
the
stack-v2-float-alp
branch
from
September 1, 2026 10:24
38078aa to
773480f
Compare
CommanderStorm
force-pushed
the
stack-v2-float-alp
branch
2 times, most recently
from
September 1, 2026 12:04
be5da75 to
2e8a58a
Compare
Codecov Report✅ All modified and coverable lines are covered by tests. Additional details and impacted files@@ Coverage Diff @@
## stack-v2-float-dict-encode #1603 +/- ##
=============================================================
Coverage ? 67.58%
Complexity ? 1261
=============================================================
Files ? 154
Lines ? 10912
Branches ? 2688
=============================================================
Hits ? 7375
Misses ? 2393
Partials ? 1144 ☔ View full report in Codecov by Harness. 🚀 New features to boost your workflow:
|
CommanderStorm
force-pushed
the
stack-v2-float-alp
branch
from
September 1, 2026 13:18
3db9132 to
2e8a58a
Compare
CommanderStorm
force-pushed
the
stack-v2-float-alp
branch
from
September 1, 2026 14:09
2e8a58a to
56bcf01
Compare
CommanderStorm
force-pushed
the
stack-v2-float-alp
branch
from
September 1, 2026 14:14
37cc842 to
0f0f0df
Compare
CommanderStorm
force-pushed
the
stack-v2-float-alp
branch
from
September 2, 2026 13:20
0f0f0df to
badee44
Compare
CommanderStorm
marked this pull request as ready for review
September 2, 2026 20:43
CommanderStorm
force-pushed
the
stack-v2-float-alp
branch
2 times, most recently
from
September 3, 2026 15:16
032b0c7 to
8ecce89
Compare
CommanderStorm
force-pushed
the
stack-v2-float-alp
branch
2 times, most recently
from
September 3, 2026 21:13
78372c8 to
78d4b9a
Compare
CommanderStorm
force-pushed
the
stack-v2-float-alp
branch
from
September 4, 2026 08:53
78d4b9a to
fa384e7
Compare
CommanderStorm
force-pushed
the
stack-v2-float-alp
branch
from
September 4, 2026 09:20
fa384e7 to
3eba4c0
Compare
CommanderStorm
force-pushed
the
stack-v2-float-alp
branch
from
September 4, 2026 12:25
1d986b7 to
79e99f4
Compare
CommanderStorm
force-pushed
the
stack-v2-float-alp
branch
from
September 4, 2026 13:43
79e99f4 to
2240457
Compare
CommanderStorm
force-pushed
the
stack-v2-float-alp
branch
from
September 4, 2026 14:03
2240457 to
7fed556
Compare
CommanderStorm
force-pushed
the
stack-v2-float-alp
branch
from
September 4, 2026 14:15
7fed556 to
36f6af2
Compare
CommanderStorm
force-pushed
the
stack-v2-float-alp
branch
from
September 4, 2026 23:59
36f6af2 to
a3773f4
Compare
Code Coverage OverviewLanguages: Rust Rust / code-coverage/llvm-covThe overall line coverage in commit d291c18 in the Show a line coverage summary of the most impacted files.
Updated |
CommanderStorm
force-pushed
the
stack-v2-float-alp
branch
from
September 5, 2026 13:14
a3773f4 to
f265349
Compare
CommanderStorm
force-pushed
the
stack-v2-float-alp
branch
from
September 5, 2026 13:42
f265349 to
3124dba
Compare
CommanderStorm
force-pushed
the
stack-v2-float-alp
branch
from
September 7, 2026 11:06
3124dba to
08d86d5
Compare
CommanderStorm
force-pushed
the
stack-v2-float-alp
branch
from
September 11, 2026 01:18
08d86d5 to
6110059
Compare
CommanderStorm
force-pushed
the
stack-v2-float-alp
branch
from
September 11, 2026 01:21
6110059 to
e094e85
Compare
nyurik
reviewed
Sep 11, 2026
nyurik
approved these changes
Sep 11, 2026
CommanderStorm
force-pushed
the
stack-v2-float-alp
branch
from
September 11, 2026 21:57
e094e85 to
761066f
Compare
ALP stores a float as `i = round(v * 10^e / 10^f)` and recovers it as `v = i * 10^f / 10^e`, so decimal data written with a few fractional digits becomes small integers that compress where the float bit patterns did not. Parameters travel as two header varints, following how v1 writes Morton's. Exception-free only: a column takes ALP when every value returns bit-for-bit, checked against all of them rather than a sample, which is what keeps the reserved exception stream out of scope. Off by default behind its own `with_float_alp`, so either encoding can be measured on its own; where both flags are on, ALP and the dictionary compete on stored bytes, both already costed against storing the floats raw. Co-Authored-By: Claude Opus 5 (1M context) <noreply@anthropic.com>
CommanderStorm
force-pushed
the
stack-v2-float-alp
branch
from
September 11, 2026 22:22
761066f to
d291c18
Compare
Merged
CommanderStorm
pushed a commit
that referenced
this pull request
Sep 14, 2026
## 🤖 New release
* `mlt-core`: 0.12.9 -> 0.13.0 (⚠ API breaking changes)
* `mlt`: 0.1.31 -> 0.1.32
* `mlt-py`: 0.1.31 -> 0.1.32
* `mlt-ffi`: 0.1.17 -> 0.1.18
* `mlt-wasm`: 0.1.23 -> 0.1.24
### ⚠ `mlt-core` breaking changes
```text
--- failure enum_missing: pub enum removed or renamed ---
Description:
A publicly-visible enum cannot be imported by its prior path. A `pub use` may have been removed, or the enum itself may have been renamed or removed entirely.
ref: https://doc.rust-lang.org/cargo/reference/semver.html#item-remove
impl: https://github.com/obi1kenobi/cargo-semver-checks/tree/v0.50.0/src/lints/enum_missing.ron
Failed in:
enum mlt_core::encoder::WireVersion, previously in file /tmp/.tmpsDfGWm/mlt-core/src/encoder/model.rs:171
--- failure enum_repr_int_removed: enum repr(u*)/repr(i*) removed ---
Description:
repr(u*) or repr(i*) was removed from an enum. This can cause its memory representation to change, breaking FFI use cases.
ref: https://doc.rust-lang.org/cargo/reference/semver.html#repr-int-enum-remove
impl: https://github.com/obi1kenobi/cargo-semver-checks/tree/v0.50.0/src/lints/enum_repr_int_removed.ron
Failed in:
enum PhysicalEncoding in /tmp/.tmpsW44Bw/maplibre-tile-spec/rust/mlt-core/src/decoder/stream/model.rs:340
--- failure enum_variant_added: enum variant added on exhaustive enum ---
Description:
A publicly-visible enum without #[non_exhaustive] has a new variant.
ref: https://doc.rust-lang.org/cargo/reference/semver.html#enum-variant-new
impl: https://github.com/obi1kenobi/cargo-semver-checks/tree/v0.50.0/src/lints/enum_variant_added.ron
Failed in:
variant LogicalEncoding:Int in /tmp/.tmpsW44Bw/maplibre-tile-spec/rust/mlt-core/src/decoder/stream/model.rs:238
variant LogicalEncoding:Bool in /tmp/.tmpsW44Bw/maplibre-tile-spec/rust/mlt-core/src/decoder/stream/model.rs:239
variant LogicalEncoding:Float in /tmp/.tmpsW44Bw/maplibre-tile-spec/rust/mlt-core/src/decoder/stream/model.rs:240
variant LogicalEncoding:Vertex in /tmp/.tmpsW44Bw/maplibre-tile-spec/rust/mlt-core/src/decoder/stream/model.rs:241
variant PhysicalEncoding:FastPFor in /tmp/.tmpsW44Bw/maplibre-tile-spec/rust/mlt-core/src/decoder/stream/model.rs:344
--- failure enum_variant_missing: pub enum variant removed or renamed ---
Description:
A publicly-visible enum has at least one variant that is no longer available under its prior name. It may have been renamed or removed entirely.
ref: https://doc.rust-lang.org/cargo/reference/semver.html#item-remove
impl: https://github.com/obi1kenobi/cargo-semver-checks/tree/v0.50.0/src/lints/enum_variant_missing.ron
Failed in:
variant LogicalEncoding::None, previously in file /tmp/.tmpsDfGWm/mlt-core/src/decoder/stream/model.rs:103
variant LogicalEncoding::Delta, previously in file /tmp/.tmpsDfGWm/mlt-core/src/decoder/stream/model.rs:104
variant LogicalEncoding::DeltaRle, previously in file /tmp/.tmpsDfGWm/mlt-core/src/decoder/stream/model.rs:105
variant LogicalEncoding::ComponentwiseDelta, previously in file /tmp/.tmpsDfGWm/mlt-core/src/decoder/stream/model.rs:106
variant LogicalEncoding::Rle, previously in file /tmp/.tmpsDfGWm/mlt-core/src/decoder/stream/model.rs:107
variant LogicalEncoding::Morton, previously in file /tmp/.tmpsDfGWm/mlt-core/src/decoder/stream/model.rs:108
variant LogicalEncoding::MortonDelta, previously in file /tmp/.tmpsDfGWm/mlt-core/src/decoder/stream/model.rs:109
variant LogicalEncoding::MortonRle, previously in file /tmp/.tmpsDfGWm/mlt-core/src/decoder/stream/model.rs:110
variant PhysicalEncoding::FastPFor256, previously in file /tmp/.tmpsDfGWm/mlt-core/src/decoder/stream/model.rs:176
--- failure inherent_method_missing: pub method removed or renamed ---
Description:
A publicly-visible method or associated fn is no longer available under its prior name. It may have been renamed or removed entirely.
ref: https://doc.rust-lang.org/cargo/reference/semver.html#item-remove
impl: https://github.com/obi1kenobi/cargo-semver-checks/tree/v0.50.0/src/lints/inherent_method_missing.ron
Failed in:
EncoderConfig::wire_version, previously in file /tmp/.tmpsDfGWm/mlt-core/src/encoder/model.rs:247
EncoderConfig::with_wire_version, previously in file /tmp/.tmpsDfGWm/mlt-core/src/encoder/model.rs:290
PhysicalEncoding::parse, previously in file /tmp/.tmpsDfGWm/mlt-core/src/encoder/stream/physical.rs:5
```
<details><summary><i><b>Changelog</b></i></summary><p>
## `mlt-core`
<blockquote>
##
[0.13.0](rust-mlt-core-v0.12.9...rust-mlt-core-v0.13.0)
- 2026-09-14
### Added
- *(rust)* give v2 dictionary and tessellated geometry layouts
([#1614](#1614))
- *(rust)* front-code v2 string dictionaries and give v2 a shared one
([#1613](#1613))
- *(rust)* give v2 ALP a frame of reference and let it race FastPFOR
([#1612](#1612))
- *(rust)* add `FPF128` with `u32::from_le_bytes`
([#1611](#1611))
- *(rust)* encode and decode v2 string columns
([#1609](#1609))
- *(rust)* encode and decode v2 float columns as ALP
([#1603](#1603))
- *(rust)* encode v2 float columns as a dictionary, behind a flag
([#1602](#1602))
- *(rust)* decode dictionary-encoded v2 float columns
([#1601](#1601))
- *(rust)* number the v2 encoding byte per stream family
([#1598](#1598))
### Fixed
- *(rust)* reject float streams tagged with an encoding floats do not
have ([#1597](#1597))
### Other
- bound a v2 shared dictionary's child count by the bytes left
([#1690](#1690))
- *(rust)* cover the v2 float encodings with synthetics
([#1606](#1606))
- *(rust)* split the logical encoding per value kind
([#1600](#1600))
- *(rust)* give float columns their own raw model
([#1599](#1599))
</blockquote>
## `mlt`
<blockquote>
##
[0.1.32](rust-mlt-v0.1.31...rust-mlt-v0.1.32)
- 2026-09-14
### Added
- *(rust)* give v2 dictionary and tessellated geometry layouts
([#1614](#1614))
- *(rust)* give v2 ALP a frame of reference and let it race FastPFOR
([#1612](#1612))
- *(rust)* add `FPF128` with `u32::from_le_bytes`
([#1611](#1611))
- *(rust)* encode and decode v2 float columns as ALP
([#1603](#1603))
- *(rust)* decode dictionary-encoded v2 float columns
([#1601](#1601))
### Fixed
- *(rust)* stop silently dropping v2 layers when converting a tile
([#1629](#1629))
- *(rust)* reject float streams tagged with an encoding floats do not
have ([#1597](#1597))
### Other
- *(rust)* split the logical encoding per value kind
([#1600](#1600))
</blockquote>
## `mlt-py`
<blockquote>
##
[0.1.32](python-mlt-v0.1.31...python-mlt-v0.1.32)
- 2026-09-14
### Other
- update Cargo.lock dependencies
</blockquote>
## `mlt-ffi`
<blockquote>
##
[0.1.18](rust-mlt-ffi-v0.1.17...rust-mlt-ffi-v0.1.18)
- 2026-09-14
### Other
- updated the following local packages: mlt-core
</blockquote>
## `mlt-wasm`
<blockquote>
##
[0.1.24](rust-mlt-wasm-v0.1.23...rust-mlt-wasm-v0.1.24)
- 2026-09-14
### Other
- updated the following local packages: mlt-core
</blockquote>
</p></details>
---
This PR was generated with
[release-plz](https://github.com/release-plz/release-plz/).
Co-authored-by: maplibre-release-plz[bot] <329134050+maplibre-release-plz[bot]@users.noreply.github.com>
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
ALP stores a float as a scaled integer and recovers it exactly, so decimal data compresses where the raw bit patterns did not. Exception-free only: a column takes ALP when every value returns bit-for-bit, and it then competes with the dictionary on stored bytes.