Skip to content

Commit

Permalink
refactor[cartesian]: Replace is_start_state= with is_start_block=
Browse files Browse the repository at this point in the history
… when buiding the SDFG for DaCe (#1709)

When building an SDFG for DaCe it is sometimes necessary to specify the
starting point of the graph. In the past, `is_start_state=` was used for
this. In never versions of Dace, `is_start_state` has been deprecated
and replaced with `is_start_block`. This PR replaces the two occurrences
in the `cartesian/` folder and removes warnings generated during test
runs. It looks like the `next/` folder has already been cleaned.
  • Loading branch information
romanc authored Oct 28, 2024
1 parent db249bd commit 692c14b
Show file tree
Hide file tree
Showing 2 changed files with 2 additions and 2 deletions.
2 changes: 1 addition & 1 deletion src/gt4py/cartesian/gtc/dace/expansion/sdfg_builder.py
Original file line number Diff line number Diff line change
Expand Up @@ -323,7 +323,7 @@ def visit_NestedSDFG(
) -> dace.nodes.NestedSDFG:
sdfg = dace.SDFG(node.label)
inner_sdfg_ctx = StencilComputationSDFGBuilder.SDFGContext(
sdfg=sdfg, state=sdfg.add_state(is_start_state=True)
sdfg=sdfg, state=sdfg.add_state(is_start_block=True)
)
self.visit(
node.field_decls,
Expand Down
2 changes: 1 addition & 1 deletion src/gt4py/cartesian/gtc/dace/oir_to_dace.py
Original file line number Diff line number Diff line change
Expand Up @@ -39,7 +39,7 @@ class SDFGContext:

def __init__(self, stencil: oir.Stencil):
self.sdfg = dace.SDFG(stencil.name)
self.last_state = self.sdfg.add_state(is_start_state=True)
self.last_state = self.sdfg.add_state(is_start_block=True)
self.decls = {decl.name: decl for decl in stencil.params + stencil.declarations}
self.block_extents = compute_horizontal_block_extents(stencil)

Expand Down

0 comments on commit 692c14b

Please sign in to comment.