Test "perf/ite-taken-branch"
Expected: 馃憤 accept 路 Size: 4.3鈥疢B 路 Lines: 88.9鈥痥 路 lean4export: 3.2.0 路 Lean: 4.38.0-nightly-2026-12-03 路 Timeout: 3.83鈥痬in 路 馃搫 Declaration 路 馃敆 Source
The declarations to check compare
(if true = true then piA else tA) and piA
(and two variants: the sides swapped, and a case split on a variable o
as in the CFSG proof), where piA := invCand 300 tA is the inverse of a
permutation table, computed by a for loop of Array.set!.
Unfolding ite and deciding true = true takes the then branch, and
the sides are identical, for 螛(1). But piA is higher than ite, and
a checker that unfolds the higher side first evaluates piA, for
螛(n虏) list steps, before ite gets its turn. Unlike in
unroll-versus-evaluate, the cheap step is on the lower side, it is a
Decidable instance rather than a recursion, and the other side is a
constant without arguments.
Official (v4.36.0) needed about 14 s and 1.7 GB here, nearly all of it
evaluating piA, piB and piC. Distilled from AxiomMath/CFSG's
CertificateChecks.Batch27011.optI_eq, where the same shape over 1755
points took it, sokonanoda, con-ron and con-leche past 8 GB.