Skip to content
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

FMB max sort size detection via X = t_1 | ... | X = t_n #398

Open
quickbeam123 opened this issue Jul 20, 2022 · 4 comments
Open

FMB max sort size detection via X = t_1 | ... | X = t_n #398

quickbeam123 opened this issue Jul 20, 2022 · 4 comments

Comments

@quickbeam123
Copy link
Collaborator

quickbeam123 commented Jul 20, 2022

As Andrei pointed out, the check in SortInference.cpp could be stronger:

(2) If some of the t_i's are unifiable, the bound can be made lower.
You discussed below an example: X = Y | X = c, for which the bound is
1 since one can derive X = c from it.

However, this is further complicated by the fact that SortInference sees the FMB-proprocessed clauses. Often general splitting destroys the necessary structure as with, e.g.
cnf(a,axiom,Y = Z | e = Z | f(X) = Z ).
which may reach the relevant place as, e.g.,
16. f(X0) = X1 | sP0(X1) [general splitting component introduction]
and
17. e = X0 | X0 = X1 | ~sP0(X0) [general splitting 1,16]

@easychair
Copy link
Contributor

easychair commented Jul 20, 2022 via email

@quickbeam123
Copy link
Collaborator Author

quickbeam123 commented Jul 20, 2022

I just pressed Enter too early. Now, the example is in there. Sure the main trick will be to move upper bound detection after clausification but before general splitting, but with that I kind of wanted to pass the ball to @selig who knows the FMB pipeline better than me.

@easychair
Copy link
Contributor

easychair commented Jul 20, 2022 via email

@selig
Copy link
Contributor

selig commented Jul 24, 2022

I agree it could be stronger but the current implementation should at least capture the common case, which is an explicit domain axiom using constants (e.g. X = a | X = b | X = c). Previously I tried to write a general solution and there was a bug and we removed it, leaving us without support for this simple common case (for many years).

Before we make changes I'd want to do an analysis of some real problems to see if the more general case actually occurs with any frequency.

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

No branches or pull requests

4 participants