Skip to content

Challenge 28: Safety of float to decimal conversion module #524

Open

Description

@AlexLB99

#523

Runbook Link

Will add once runbook link is up

Activity

  1. added
    Challenge
    on Jan 12, 2026
  2. MavenRain commented on Jun 15, 2026

    @MavenRain

    I'd like to claim challenge #28 (core::num::flt2dec). PR:

    It adds Kani harnesses for all 12 target functions (the 6 flt2dec/mod.rs entry points and the 6 Grisu/Dragon strategy functions), proving each assume_init/indexing unsafe block touches only initialized, in-bounds memory. Bignum/Fp arithmetic is abstracted via sound stubbing; the two shortest-mode functions' loop bounds are discharged by citing the Grisu/Loitsch <=17-digit theorem as an assume under the exact decode() precondition (details and caveats in the PR).

  3. lucasccordeiro commented on Nov 22, 2026

    @lucasccordeiro

    We are evaluating Challenge 28 with ESBMC (listed in doc/src/tools.md, run by .github/workflows/esbmc.yml) and have one CI question.

    We want to verify the digit-generation loops in grisu::format_shortest_opt, grisu::format_exact_opt, dragon::format_shortest and dragon::format_exact on their real bodies, with no stubs and no assumptions on the digit value or the buffer index. Kani may not finish these harnesses in CI, and scripts/run-kani.sh verifies every harness kani list reports. How should such harnesses be submitted?

    1. With a marker that run-kani.sh skips and scripts/run-esbmc.sh runs.
    2. As a stubbed harness that Kani finishes, plus the unstubbed harness for ESBMC as the proof of record.

    We would also move run-esbmc.sh from ESBMC v8.7 (line 13) to the next release.

  4. fromtaoyuanhsinchuuuu commented on Dec 4, 2026

    @fromtaoyuanhsinchuuuu

    Hi all — I've opened #819 for Challenge 28 (flt2dec), covering all 12 target functions with 44 Kani harnesses. It's a rework of the earlier #818 and addresses the #606 review feedback: the production bodies are unchanged (no #[cfg(kani)] body swaps), there is no assume(q < 10) at the digit writes, the digit loops have explicit MAX_SIG_DIGITS bounds, and the arithmetic models are checked by separate lemma harnesses (Fp::mul interval, cached_power postcondition, max_pow10 specification). CI is fully green on all 17 checks.

    I understand #596 is also in flight and reviewer bandwidth is limited; I'd appreciate a look whenever convenient, and I'm happy to adapt to whatever direction the committee prefers.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

No one assigned

    Labels

    Challenge

    Type

    No type

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions