Skip to content

Conversation

daniel-raffler
Copy link
Contributor

Hello everyone,
this will update Princesss to version 2025-06-25 and Ostrich to 2.0. Our current version is still from the end of last year and there have been several improvements since then. Specifically, Princess now has special IFunctions for rational operations like additional or division. The old version would rewrite rational formulas as integer-only formulas, which makes it hard to restore the original formula for the visitor. In Ostrich one of our bugs was closed, and str_from_code is now supported.

@kfriedberger: Could you please upload the packages from Maven? Here is what I used locally for testing:

ant install -Dorganisation=io.github.uuverifiers -Dmodule=princess_2.13 -Drevision=2025-06-25
ant install -Dorganisation=io.github.uuverifiers -Dmodule=ostrich_2.13 -Drevision=2.0

kfriedberger
kfriedberger previously approved these changes Sep 6, 2025
Copy link
Member

@kfriedberger kfriedberger left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Overall valid.

Princess comes already from Maven. We (aka SosyLab) just upload it to the SosyLab-Ivy (I will check this ... upload done ✔️ ).

@kfriedberger
Copy link
Member

@daniel-raffler You could ask @PhilippWendler for an SVN account to upload such files directly in the future. Sosy-Ivy has strict rules, e.g., it is append-only and quite strcitly structured, and commits follow a specific pattern.

@daniel-raffler
Copy link
Contributor Author

@daniel-raffler You could ask @PhilippWendler for an SVN account to upload such files directly in the future. Sosy-Ivy has strict rules, e.g., it is append-only and quite strcitly structured, and commits follow a specific pattern.

Thanks for your help with the binaries! I already have an account from when CPAchecker still used svn, but last time I tried to upload binaries to the Ivy repository it was still rejected. However, this could just be a problem with my configuration, so I'll try again next time

The rest still seem to have issues on Princess
Princess no longer rewrites the formula and will now return the correct result
private static boolean isValue(IFunApp pExpr) {
if (!pExpr.fun().equals(Rationals.frac()) && !pExpr.fun().equals(Rationals.fromRing())) {
return false;
}
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Does this work for non-rational numbers? I would assume that Intgers are not longer handled here.

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

No, it will only detect rational number literals. Other types of literals were handled separately in the visitor and have their own tests. However, since the name was a little confusing I reorganized the code in 8d5fcd1 and all literals are now handled by isValue

kfriedberger
kfriedberger previously approved these changes Sep 14, 2025
Copy link
Member

@kfriedberger kfriedberger left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

can be merged

requireRationals();
requireRationalFloor();
// TODO Princess will rewrite floor. Add backtranslation in the visitor
// TODO Princess will rewrite floor. Add back translation in the visitor
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

No, we do not need to add a precise backwards-mapping. The solver is allowed to rewrite the formula.

Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

The issue here is that Princess uses quantifiers and we do not handle quantified formulas correctly in some cases.

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Yes, the comment was about quantifiers and/or epsilon terms that Princess likes to introduce for operations like these

requireRationals();
requireRationalFloor();
// TODO Princess will rewrite floor. Add backtranslation in the visitor
// TODO Princess will rewrite floor. Add back translation in the visitor
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

The issue here is that Princess uses quantifiers and we do not handle quantified formulas correctly in some cases.

@kfriedberger kfriedberger merged commit 8224006 into master Sep 14, 2025
1 of 3 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Development

Successfully merging this pull request may close these issues.

2 participants