From 9e5d78cfc27c8981ed21cc5fcf840c4c790dbf7a Mon Sep 17 00:00:00 2001 From: Matt Guthaus Date: Thu, 25 Oct 2018 14:40:39 -0700 Subject: [PATCH] Fix bug in duplicate remove indices --- compiler/router/router.py | 5 ++--- 1 file changed, 2 insertions(+), 3 deletions(-) diff --git a/compiler/router/router.py b/compiler/router/router.py index cc6a7944..3019180a 100644 --- a/compiler/router/router.py +++ b/compiler/router/router.py @@ -167,7 +167,7 @@ class router(router_tech): # Make a copy since we are going to reduce this list pin_groups = self.pin_groups[pin_name].copy() - remove_indices = [] + remove_indices = set() for index1,pg1 in enumerate(self.pin_groups[pin_name]): for index2,pg2 in enumerate(self.pin_groups[pin_name]): @@ -180,8 +180,7 @@ class router(router_tech): combined.grids = pg1.grids | pg2.grids # check if there are any blockage problems?? - remove_indices.append(index1) - remove_indices.append(index2) + remove_indices.update([index1,index2]) pin_groups.append(combined) # Remove them in decreasing order to not invalidate the indices