Hi, I found that the version from SV-Comp classifies this program as non-terminating (printing RESULT: Ultimate proved your program to be incorrect!):
extern int __VERIFIER_assume(int cond);
extern int __VERIFIER_nondet_int(void);
int main() {
int n = __VERIFIER_nondet_int();
__VERIFIER_assume(n >= 1);
long nlng = (long) n;
int nint = (int) nlng;
while(nint <= 0) {
}
return 0;
}
However if we encode the loop condition with __ULTIMATE_assert(!(nint <= 0)); and use --spec unreach-call.prp Ultimate sees that the loop condition is always false, so I'd expect to see that the program below is terminating.
I am using the setup from SV-Comp, specifically Ultimate 0.3.0-dev-d790fec and used the following command for the termination analysis:
"/usr/bin/java" "-Dosgi.configuration.area=/home/UAutomizer-linux/data/config" "-Xmx15G" "-Xms4m" "-jar" "/home/UAutomizer-linux/plugins/org.eclipse.equinox.launcher_1.6.800.v20240513-1750.jar" "-data" "@noDefault" "-ultimatedata" "/home/UAutomizer-linux/data" "-tc" "/home/UAutomizer-linux/config/AutomizerTermination.xml" "-s" "/home/UAutomizer-linux/config/svcomp-Termination-64bit-Automizer_Default.epf" "--cacsl2boogietranslator.entry.function" "main" "--witnessprinter.witness.directory" "/home/UAutomizer-linux" "--witnessprinter.witness.filename" "witness" "--witnessprinter.write.witness.besides.input.file" "false" "--witnessprinter.graph.data.specification" "CHECK( init(main()), LTL(F end) )" "--witnessprinter.graph.data.producer" "Automizer" "--witnessprinter.graph.data.architecture" "64bit" "--witnessprinter.graph.data.programhash" "2c49b87410271d55416f5a5bc7d2a9ffd85bb848b87c5b0387334a9de7ab45eb" "-i" test.c
Additionally, I wanted to ask if Ultimate is able to emit inferred ranking functions (apart from the incomplete info the log)?
Thanks in advance!
Hi, I found that the version from SV-Comp classifies this program as non-terminating (printing
RESULT: Ultimate proved your program to be incorrect!):However if we encode the loop condition with
__ULTIMATE_assert(!(nint <= 0));and use--spec unreach-call.prpUltimate sees that the loop condition is always false, so I'd expect to see that the program below is terminating.I am using the setup from SV-Comp, specifically Ultimate 0.3.0-dev-d790fec and used the following command for the termination analysis:
"/usr/bin/java" "-Dosgi.configuration.area=/home/UAutomizer-linux/data/config" "-Xmx15G" "-Xms4m" "-jar" "/home/UAutomizer-linux/plugins/org.eclipse.equinox.launcher_1.6.800.v20240513-1750.jar" "-data" "@noDefault" "-ultimatedata" "/home/UAutomizer-linux/data" "-tc" "/home/UAutomizer-linux/config/AutomizerTermination.xml" "-s" "/home/UAutomizer-linux/config/svcomp-Termination-64bit-Automizer_Default.epf" "--cacsl2boogietranslator.entry.function" "main" "--witnessprinter.witness.directory" "/home/UAutomizer-linux" "--witnessprinter.witness.filename" "witness" "--witnessprinter.write.witness.besides.input.file" "false" "--witnessprinter.graph.data.specification" "CHECK( init(main()), LTL(F end) )" "--witnessprinter.graph.data.producer" "Automizer" "--witnessprinter.graph.data.architecture" "64bit" "--witnessprinter.graph.data.programhash" "2c49b87410271d55416f5a5bc7d2a9ffd85bb848b87c5b0387334a9de7ab45eb" "-i" test.cAdditionally, I wanted to ask if Ultimate is able to emit inferred ranking functions (apart from the incomplete info the log)?
Thanks in advance!