-
Notifications
You must be signed in to change notification settings - Fork 634
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Code factorization around Evarutil.finalize and prepare_obligations #19050
Merged
coqbot-app
merged 3 commits into
coq:master
from
herbelin:master+prepare_obligation-in-program-fixpoint-wf
May 24, 2024
Merged
Code factorization around Evarutil.finalize and prepare_obligations #19050
coqbot-app
merged 3 commits into
coq:master
from
herbelin:master+prepare_obligation-in-program-fixpoint-wf
May 24, 2024
Conversation
This file contains 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
This ensures a similar treatment as in other places, e.g. that universes are minimized and restricted in the main obligations-based constant as done for definitions.
71da4bb
to
dfb1448
Compare
@coqbot run full ci |
SkySkimmer
reviewed
May 23, 2024
@coqbot bench |
Co-authored-by: Gaëtan Gilbert <gaetan.gilbert@skyskimmer.net>
🏁 Bench results:
INFO: failed to install 🐢 Top 25 slow downs┌───────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────┐ │ TOP 25 SLOW DOWNS │ │ │ │ OLD NEW DIFF %DIFF Ln FILE │ ├───────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────┤ │ 215.8670 221.4600 5.5930 2.59% 103 coq-fiat-crypto-with-bedrock/src/Arithmetic/BarrettReduction.v.html │ │ 180.4470 184.0040 3.5570 1.97% 233 coq-fiat-crypto-with-bedrock/rupicola/bedrock2/deps/riscv-coq/src/riscv/Proofs/DecodeByExtension.v.html │ │ 254.8370 257.7240 2.8870 1.13% 1629 coq-metacoq-pcuic/pcuic/theories/PCUICSR.v.html │ │ 255.7150 257.4500 1.7350 0.68% 8 coq-neural-net-interp-computed-lite/theories/MaxOfTwoNumbersSimpler/Computed/AllLogits.v.html │ │ 241.8400 243.4990 1.6590 0.69% 141 coq-fiat-crypto-with-bedrock/src/UnsaturatedSolinasHeuristics/Tests.v.html │ │ 25.6130 26.7610 1.1480 4.48% 129 coq-fiat-crypto-with-bedrock/src/Curves/Weierstrass/Projective.v.html │ │ 138.5450 139.5980 1.0530 0.76% 155 coq-fiat-crypto-with-bedrock/src/UnsaturatedSolinasHeuristics/Tests.v.html │ │ 27.1580 28.1000 0.9420 3.47% 68 coq-fiat-crypto-with-bedrock/rupicola/bedrock2/deps/riscv-coq/src/riscv/Proofs/VerifyDecode.v.html │ │ 72.8130 73.4860 0.6730 0.92% 905 coq-unimath/UniMath/ModelCategories/Generated/LNWFSCocomplete.v.html │ │ 11.9160 12.5230 0.6070 5.09% 194 coq-fiat-crypto-with-bedrock/src/Fancy/Barrett256.v.html │ │ 22.6470 23.2300 0.5830 2.57% 1073 coq-metacoq-safechecker/safechecker/theories/PCUICSafeReduce.v.html │ │ 3.3090 3.7590 0.4500 13.60% 490 coq-stdlib/Reals/Cauchy/ConstructiveCauchyRealsMult.v.html │ │ 17.8570 18.2600 0.4030 2.26% 708 coq-fiat-crypto-with-bedrock/src/Rewriter/RulesProofs.v.html │ │ 29.8580 30.2590 0.4010 1.34% 194 coq-vst/veric/expr_lemmas4.v.html │ │ 44.2340 44.6200 0.3860 0.87% 827 coq-vst/veric/binop_lemmas4.v.html │ │ 30.7120 31.0560 0.3440 1.12% 147 coq-vst/veric/expr_lemmas4.v.html │ │ 14.1570 14.4860 0.3290 2.32% 1204 coq-vst/floyd/Component.v.html │ │ 14.1550 14.4780 0.3230 2.28% 1505 coq-vst/floyd/VSU.v.html │ │ 26.6130 26.9080 0.2950 1.11% 17 coq-fiat-crypto-with-bedrock/src/Spec/Test/X25519.v.html │ │ 14.1740 14.4490 0.2750 1.94% 1218 coq-vst/floyd/Component.v.html │ │ 26.6230 26.8960 0.2730 1.03% 22 coq-fiat-crypto-with-bedrock/src/Spec/Test/X25519.v.html │ │ 0.5210 0.7920 0.2710 52.02% 200 coq-stdlib/Numbers/HexadecimalNat.v.html │ │ 0.3190 0.5850 0.2660 83.39% 868 coq-stdlib/MSets/MSetRBT.v.html │ │ 7.8820 8.1250 0.2430 3.08% 1265 coq-verdi-raft/theories/Raft/CommonTheorems.v.html │ │ 24.1130 24.3500 0.2370 0.98% 85 coq-fiat-crypto-with-bedrock/src/Curves/Montgomery/AffineProofs.v.html │ └───────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────┘ 🐇 Top 25 speed ups┌──────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────┐ │ TOP 25 SPEED UPS │ │ │ │ OLD NEW DIFF %DIFF Ln FILE │ ├──────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────┤ │ 82.6910 76.9970 -5.6940 -6.89% 365 coq-mathcomp-odd-order/theories/PFsection4.v.html │ │ 68.5080 63.8770 -4.6310 -6.76% 368 coq-mathcomp-odd-order/theories/PFsection4.v.html │ │ 47.7660 46.4590 -1.3070 -2.74% 110 coq-bedrock2/bedrock2/src/bedrock2Examples/full_mul.v.html │ │ 62.2180 61.0270 -1.1910 -1.91% 609 coq-bedrock2/bedrock2/src/bedrock2Examples/lightbulb.v.html │ │ 63.0480 62.1190 -0.9290 -1.47% 609 coq-fiat-crypto-with-bedrock/rupicola/bedrock2/bedrock2/src/bedrock2Examples/lightbulb.v.html │ │ 3.2960 2.4320 -0.8640 -26.21% 487 coq-stdlib/Numbers/HexadecimalFacts.v.html │ │ 17.4940 16.6620 -0.8320 -4.76% 607 coq-mathcomp-odd-order/theories/PFsection9.v.html │ │ 100.3310 99.6280 -0.7030 -0.70% 20 coq-fiat-crypto-with-bedrock/src/Rewriter/Passes/NBE.v.html │ │ 81.5320 80.9190 -0.6130 -0.75% 48 coq-fiat-crypto-with-bedrock/src/Curves/Weierstrass/AffineProofs.v.html │ │ 7.1180 6.5440 -0.5740 -8.06% 1933 coq-unimath/UniMath/CategoryTheory/EnrichedCats/Profunctors/Composition/CompositionProf.v.html │ │ 46.6570 46.0930 -0.5640 -1.21% 110 coq-fiat-crypto-with-bedrock/rupicola/bedrock2/bedrock2/src/bedrock2Examples/full_mul.v.html │ │ 47.8380 47.2820 -0.5560 -1.16% 558 coq-fiat-crypto-with-bedrock/rupicola/bedrock2/bedrock2/src/bedrock2Examples/insertionsort.v.html │ │ 98.3080 97.7600 -0.5480 -0.56% 376 coq-unimath/UniMath/ModelCategories/Generated/LNWFSMonoidalStructure.v.html │ │ 20.1930 19.6520 -0.5410 -2.68% 214 coq-engine-bench-lite/coq/PerformanceDemos/one_step_reduction.v.html │ │ 27.8990 27.3730 -0.5260 -1.89% 12 coq-fourcolor/theories/job287to290.v.html │ │ 24.2560 23.7640 -0.4920 -2.03% 49 coq-fiat-crypto-with-bedrock/src/Curves/Weierstrass/AffineProofs.v.html │ │ 12.0190 11.5320 -0.4870 -4.05% 2103 coq-mathcomp-ssreflect/mathcomp/ssreflect/order.v.html │ │ 25.5630 25.0800 -0.4830 -1.89% 12 coq-fourcolor/theories/job299to302.v.html │ │ 1.4320 0.9950 -0.4370 -30.52% 854 coq-stdlib/FSets/FMapAVL.v.html │ │ 19.6430 19.2180 -0.4250 -2.16% 957 coq-unimath/UniMath/CategoryTheory/Monoidal/Examples/DisplayedCartesianMonoidal.v.html │ │ 36.3460 35.9300 -0.4160 -1.14% 2 coq-fiat-crypto-with-bedrock/src/ExtractionJsOfOCaml/fiat_crypto.v.html │ │ 27.1890 26.7760 -0.4130 -1.52% 12 coq-fourcolor/theories/job611to617.v.html │ │ 22.8550 22.4630 -0.3920 -1.72% 12 coq-fourcolor/theories/job303to306.v.html │ │ 13.0730 12.6960 -0.3770 -2.88% 1555 coq-fiat-crypto-with-bedrock/src/Util/FSets/FMapTrie.v.html │ │ 29.8130 29.4440 -0.3690 -1.24% 12 coq-fourcolor/theories/job323to383.v.html │ └──────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────┘ |
SkySkimmer
approved these changes
May 24, 2024
@coqbot merge now |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Labels
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.
The PR experiments:
Evarutil.finalize
in.wf
-basedProgram Fixpoint
(what ensures minimization of universes of the main obligation-based constant)finalize
for definition is called without theabort
flag to falseI suspect 1.a. to be observable but I don't know well how to build an example (is there a standard example to observe minimization?)
Note also that this is only an intermediate step. See coq/ceps#89 for further possible steps.