From d77c2b76cfb1cb3cbd1ad6f7df951dad2630b580 Mon Sep 17 00:00:00 2001 From: Francesco Date: Mon, 4 Nov 2024 13:40:06 +0100 Subject: [PATCH] #94: Fixed an issue where an empty graph would be passed to the template manager --- sxpat/xplore.py | 2 ++ 1 file changed, 2 insertions(+) diff --git a/sxpat/xplore.py b/sxpat/xplore.py index 0f392634a..068feba87 100644 --- a/sxpat/xplore.py +++ b/sxpat/xplore.py @@ -376,6 +376,8 @@ def optimize_constants(specs_obj: Specifications, initial_error_threshold: int) # load graph for next iteration graph = AnnotatedGraph(verilog_filename, is_clean=False) + if graph.num_gates == 0: + break graph.extract_subgraph(specs_obj) # revert state