mirror of
https://github.com/hneemann/Digital.git
synced 2025-09-17 08:55:05 -04:00
fixed a bug in max path len calculation
This commit is contained in:
parent
12e85e62f9
commit
10103a3c74
@ -48,7 +48,7 @@ public final class CycleDetector {
|
|||||||
traverse(root, s.getValue(), nodes, visited);
|
traverse(root, s.getValue(), nodes, visited);
|
||||||
}
|
}
|
||||||
|
|
||||||
// Turned of for now because if it is used you can build circuits with a state
|
// Turned off for now because if it is used you can build circuits with a cycle
|
||||||
// which are not detected as such.
|
// which are not detected as such.
|
||||||
//removeSwitchCycles(nodes.values());
|
//removeSwitchCycles(nodes.values());
|
||||||
|
|
||||||
|
@ -319,11 +319,8 @@ public class ModelAnalyser {
|
|||||||
* @throws AnalyseException AnalyseException
|
* @throws AnalyseException AnalyseException
|
||||||
*/
|
*/
|
||||||
public int calcMaxPathLen() throws PinException, BacktrackException, AnalyseException {
|
public int calcMaxPathLen() throws PinException, BacktrackException, AnalyseException {
|
||||||
LOGGER.debug("start to calculate the depth of the model...");
|
LOGGER.debug("start to calculate the max path len of the model...");
|
||||||
|
CycleDetector.checkForCycles(inputs);
|
||||||
if (!Main.isExperimentalMode() && !modelContainsSwitches())
|
|
||||||
CycleDetector.checkForCycles(inputs);
|
|
||||||
|
|
||||||
PathLenAnalyser da = new PathLenAnalyser(this);
|
PathLenAnalyser da = new PathLenAnalyser(this);
|
||||||
return da.getMaxPathLen();
|
return da.getMaxPathLen();
|
||||||
}
|
}
|
||||||
|
Loading…
x
Reference in New Issue
Block a user