Repository navigation
Conversation
Under ForExtraction, arguments of stuck fvar-headed applications in computationally irrelevant binder positions (prop, prop-valued arrows, non-informative types like slprop/erased/squash) are replaced by l_True / () instead of being normalized. This avoids blowups (and Error 365 from --custard_norm_budget) on large spec-only arguments. Fixes #4828 Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com>
This branch has not been deployed
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.
Fixes #4828.
Under
ForExtraction, when the normalizer rebuilds an application whose head is a stuck fvar, arguments in computationally irrelevant binder positions are now replaced instead of being normalized:propbinders (and Tot/GTot arrows intoprop, when closed) →l_Trueslprop,erased,squash, erasable types, ...) →()Type,a -> Type, ...),unit(thunks), and primitive-step heads (e.g.reveal/hide) are left alonePer-fvar results are cached, validated against the current sigelt by physical equality.
On the MWE from the issue (N=20 prop chain), extraction goes from Error 365 after ~10s to 0.09s with identical output.
Tests:
tests/custard/SpecArgNorm.fst(N=12,--custard_norm_budget 20000; fails on master)tests/custard/pulse/PulseSpecArgNorm.fst(N=14 slprop and prop chains, budget 1e5); the pulse Makefile's%.custard.mlrule now passesFLAGS_$*.Also adds a note to
doc/ref/custard.md.