From fbd2142654f05f570e87100851f01e056b239db4 Mon Sep 17 00:00:00 2001 From: Joachim Klein Date: Tue, 28 Jul 2015 12:31:17 +0000 Subject: [PATCH] LTLModelChecker(product DTMC): replace module var refAll with array copy git-svn-id: https://www.prismmodelchecker.org/svn/prism/prism/trunk@10436 bbc10eb1-c90d-0410-af57-cb519fbb1720 --- prism/src/prism/LTLModelChecker.java | 11 ++++------- 1 file changed, 4 insertions(+), 7 deletions(-) diff --git a/prism/src/prism/LTLModelChecker.java b/prism/src/prism/LTLModelChecker.java index 3b6cd5e8..fbc9c539 100644 --- a/prism/src/prism/LTLModelChecker.java +++ b/prism/src/prism/LTLModelChecker.java @@ -278,12 +278,6 @@ public class LTLModelChecker extends PrismComponent Declaration decl = new Declaration(daVar, new DeclarationInt(Expression.Int(0), Expression.Int(Math.max(da.size() - 1, 1)))); newVarList.addVar(before ? 0 : varList.getNumVars(), decl, 1, model.getConstantValues()); - // Extra references (because will get derefed when new model is done with) - for (i = 0; i < model.getNumModules(); i++) { - model.getModuleDDRowVars(i).refAll(); - model.getModuleDDColVars(i).refAll(); - } - // Build transition matrix for product newTrans = buildTransMask(da, labelDDs, allDDRowVars, allDDColVars, daDDRowVars, daDDColVars); JDD.Ref(model.getTrans()); @@ -312,7 +306,10 @@ public class LTLModelChecker extends PrismComponent // New list of var names newDDVarNames, // Module info (unchanged) - model.getNumModules(), model.getModuleNames(), model.getModuleDDRowVars(), model.getModuleDDColVars(), + model.getNumModules(), + model.getModuleNames(), + JDDVars.copyArray(model.getModuleDDRowVars()), + JDDVars.copyArray(model.getModuleDDColVars()), // New var info model.getNumVars() + 1, newVarList, newVarDDRowVars, newVarDDColVars, // Constants (no change)