Commit bdf7f0ad authored by leberre's avatar leberre
Browse files

Added verbose output for mss computation.

git-svn-id: svn+ssh://svn.forge.ow2.org/svnroot/sat4j/maven/trunk@1686 ba638df5-4473-46d1-82f8-c3ae2a17a6e1
parent fe07ce51
...@@ -153,7 +153,25 @@ public class MUSLauncher extends AbstractLauncher { ...@@ -153,7 +153,25 @@ public class MUSLauncher extends AbstractLauncher {
+ wallclocktime); + wallclocktime);
double beginmus = System.currentTimeMillis(); double beginmus = System.currentTimeMillis();
if (allMuses != null) { if (allMuses != null) {
SolutionFoundListener listener = new SolutionFoundListener() { SolutionFoundListener mssListener = new SolutionFoundListener() {
private int msscount = 0;
public void onUnsatTermination() {
throw new UnsupportedOperationException(
"Not implemented yet!");
}
public void onSolutionFound(IVecInt solution) {
System.out.print("\r" + solver.getLogPrefix()
+ "found mss number " + ++msscount);
}
public void onSolutionFound(int[] solution) {
throw new UnsupportedOperationException(
"Not implemented yet!");
}
};
SolutionFoundListener musListener = new SolutionFoundListener() {
public void onSolutionFound(int[] solution) { public void onSolutionFound(int[] solution) {
} }
...@@ -170,10 +188,11 @@ public class MUSLauncher extends AbstractLauncher { ...@@ -170,10 +188,11 @@ public class MUSLauncher extends AbstractLauncher {
public void onUnsatTermination() { public void onUnsatTermination() {
} }
}; };
allMuses.computeAllMSS(mssListener);
if ("card".equals(System.getProperty("min"))) { if ("card".equals(System.getProperty("min"))) {
allMuses.computeAllMUSesOrdered(listener); allMuses.computeAllMUSesOrdered(musListener);
} else { } else {
allMuses.computeAllMUSes(listener); allMuses.computeAllMUSes(musListener);
} }
log("All MUSes computation wall clock time (in seconds) : " log("All MUSes computation wall clock time (in seconds) : "
+ (System.currentTimeMillis() - beginmus) / 1000.0); + (System.currentTimeMillis() - beginmus) / 1000.0);
......
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment