diff --git a/devito/passes/iet/mpi.py b/devito/passes/iet/mpi.py index 2de99ee002..a653d154b6 100644 --- a/devito/passes/iet/mpi.py +++ b/devito/passes/iet/mpi.py @@ -88,7 +88,7 @@ def _hoist_redundant_from_conditionals(iet): scope = Scope(e.expr for e in FindNodes(Expression).visit(it)) for hs0 in halo_spots: - conditions = cond_mapper[hs0] + conditions = cond_mapper.get(hs0) if not conditions: continue condition = conditions[-1] # Take the innermost Conditional