Skip to content

Commit

Permalink
add comment
Browse files Browse the repository at this point in the history
  • Loading branch information
n-io committed Nov 7, 2024
1 parent 3fbfe0b commit 587a69f
Showing 1 changed file with 4 additions and 2 deletions.
6 changes: 4 additions & 2 deletions xdsl/transforms/csl_stencil_bufferize.py
Original file line number Diff line number Diff line change
Expand Up @@ -415,9 +415,11 @@ def match_and_rewrite(self, op: csl_stencil.ApplyOp, rewriter: PatternRewriter,
arg.type, len(op.done_exchange.block.args)
)
arg_to_tensor = to_tensor_op(arg, writable=True)

# set offset going from a buf with ghost cells to one without, assuming symmetric ghost cells on all sides
symmetric_offsets = tuple(
(s - d) // 2
for s, d in zip(
(src - dst) // 2 # symmetric offset
for src, dst in zip(
arg_t.get_shape(), yld_arg.type.get_shape(), strict=True
)
)
Expand Down

0 comments on commit 587a69f

Please sign in to comment.