From db231d0d03207941e60abfba40f6411f6c5d4bcb Mon Sep 17 00:00:00 2001 From: Edward Caunt Date: Tue, 30 Jul 2024 13:22:10 +0100 Subject: [PATCH] misc: Tidy up --- devito/ir/equations/algorithms.py | 2 -- devito/passes/iet/engine.py | 1 + tests/test_pickle.py | 6 ------ 3 files changed, 1 insertion(+), 8 deletions(-) diff --git a/devito/ir/equations/algorithms.py b/devito/ir/equations/algorithms.py index 3e1ed59b1e..d6a4f7e131 100644 --- a/devito/ir/equations/algorithms.py +++ b/devito/ir/equations/algorithms.py @@ -247,8 +247,6 @@ def _(d, mapper, rebuilt, sregistry): # Already have a substitution for this dimension return - # name = sregistry.make_name(prefix=d.name) - # ltkn, rtkn = MultiSubDimension._symbolic_thickness(name) tkns0 = MultiSubDimension._symbolic_thickness(d.name) tkns1 = [tkn._rebuild(name=sregistry.make_name(prefix=tkn.name)) for tkn in tkns0] diff --git a/devito/passes/iet/engine.py b/devito/passes/iet/engine.py index d71bf6d941..7e95a99220 100644 --- a/devito/passes/iet/engine.py +++ b/devito/passes/iet/engine.py @@ -606,6 +606,7 @@ def update_args(root, efuncs, dag): # The parameters/arguments lists may have changed since a pass may have: # 1) introduced a new symbol new_params = derive_parameters(root) + # 2) defined a symbol for which no definition was available yet (e.g. # via a malloc, or a Dereference) defines = FindSymbols('defines').visit(root.body) diff --git a/tests/test_pickle.py b/tests/test_pickle.py index 977477a7ad..6228be2e99 100644 --- a/tests/test_pickle.py +++ b/tests/test_pickle.py @@ -350,12 +350,6 @@ def test_findexed(self, pickle): assert new_fi.name == fi.name assert new_fi.accessor == 'fL' - from sympy import preorder_traversal - import sympy as sp - for i, j in zip(fi.indices, new_fi.indices): - for ia, ja in zip(preorder_traversal(i), preorder_traversal(j)): - print(ia, ja, type(ia), type(ja), ia == ja, - isinstance(ia, sp.core.Basic), isinstance(ja, sp.core.Basic)) assert new_fi.indices == (x+1, y, z-2) assert new_fi.strides_map == fi.strides_map