Skip to content

Conversation

ordinarymath
Copy link
Contributor

Note that reusing set from hyp_frees is actually slower.
times using time bin/build
before
real 10m37.510s
user 21m43.869s
sys 3m12.949s
reusing set from hyp_frees
real 10m40.847s
user 21m49.628s
sys 3m16.913s
without reusing set from hyp_frees
real 10m29.285s
user 21m9.849s
sys 3m10.606s
note depends on #1623

@ordinarymath
Copy link
Contributor Author

I think why reusing the set from hyp_frees is slower is that the vars from strip_forall is already guaranteed to be fresh in the term and that sorting the list makes it so that the loop check here https://github.com/HOL-Theorem-Prover/HOL/blob/24e40cd1c7f7e235a5c9f32f692c0d9ae04ddb2b/src/0/Term.sml#L345C1-L347C25 is slower

@ordinarymath
Copy link
Contributor Author

note time from docker-ci stdknl 3076.5s

@ordinarymath ordinarymath marked this pull request as draft August 25, 2025 04:08
Note that reusing set from hyp_frees is actually slower.
times using `time bin/build`
before
real 10m37.510s
user 21m43.869s
sys 3m12.949s
reusing set from hyp_frees
real 10m40.847s
user    21m49.628s
sys     3m16.913s
without reusing set from hyp_frees
real    10m29.285s
user    21m9.849s
sys 3m10.606s
@ordinarymath
Copy link
Contributor Author

I wanted to see if I could speed it up even more by using gen_variant with a predicate check but the issue is that you can't lookup a string using the HOLset produced by FVL and recreating a new set is slower. #1642 is going to be needed for the further improvement.

@ordinarymath ordinarymath marked this pull request as ready for review September 6, 2025 07:44
@ordinarymath ordinarymath requested a review from mn200 September 8, 2025 03:31
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

1 participant