Files
ucobs/Cargo.toml
T
swaitsandClaude Opus 4.6 777a37d4cd perf: decode rewrite, encode zeros optimization, iai-callgrind benchmarks (0.3.1)
Decode rewritten with shrinking-slice pattern (split_first/split_at)
instead of index arithmetic. Decode zeros 14% faster, decode nonzero
flips from 5% behind corncobs to 2% ahead, decode mixed closes to tied.

Encode zeros fast path moved before split_at — now tied with cobs
(was 6% behind). Code size reduced to 821B (was 869B).

Replaced criterion with iai-callgrind for deterministic instruction-count
benchmarks via Valgrind. Zero run-to-run variance. Expanded to 162
benchmarks across 9 sizes.

ucobs now wins or ties 16 of 18 benchmarks vs corncobs and cobs.

Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
2026-03-31 21:43:06 -06:00

36 lines
812 B
TOML

[package]
name = "ucobs"
version = "0.3.1"
edition = "2021"
rust-version = "1.93"
license = "MIT"
description = "μCOBS — Consistent Overhead Byte Stuffing. no_std, zero-alloc, fastest, most-tested COBS implementation."
authors = ["Stephen Waits <steve@waits.net>"]
repository = "https://github.com/swaits/ucobs"
homepage = "https://github.com/swaits/ucobs"
documentation = "https://docs.rs/ucobs"
readme = "README.md"
keywords = ["cobs", "framing", "no-std", "embedded", "codec"]
categories = ["encoding", "no-std::no-alloc", "embedded"]
[features]
default = []
legacy-msrv = []
[lints.rust]
unsafe_code = "forbid"
[package.metadata.docs.rs]
all-features = true
[dev-dependencies]
cobs = "0.5"
corncobs = "0.1"
iai-callgrind = "0.16"
proptest = "1"
rand = "0.10"
[[bench]]
name = "bench"
harness = false