Skip to content

Commit

Permalink
AugAssignWCR: func tests updated
Browse files Browse the repository at this point in the history
  • Loading branch information
lukastruemper committed Sep 1, 2023
1 parent 5148896 commit 64df91f
Showing 1 changed file with 6 additions and 4 deletions.
10 changes: 6 additions & 4 deletions tests/transformations/wcr_conversion_test.py
Original file line number Diff line number Diff line change
Expand Up @@ -131,13 +131,14 @@ def sdfg_aug_assign_tasklet_rhs_brackets_cpp(A: dace.float64[32]):
def test_aug_assign_tasklet_func_lhs_cpp():

@dace.program
def sdfg_aug_assign_tasklet_func_lhs_cpp(A: dace.float64[32]):
def sdfg_aug_assign_tasklet_func_lhs_cpp(A: dace.float64[32], B: dace.float64[32]):
for i in range(32):
with dace.tasklet(language=dace.Language.CPP):
a << A[i]
c << B[i]
b >> A[i]
"""
b = min(a, 0);
b = min(a, c);
"""

sdfg = sdfg_aug_assign_tasklet_func_lhs_cpp.to_sdfg()
Expand All @@ -150,13 +151,14 @@ def sdfg_aug_assign_tasklet_func_lhs_cpp(A: dace.float64[32]):
def test_aug_assign_tasklet_func_rhs_cpp():

@dace.program
def sdfg_aug_assign_tasklet_func_rhs_cpp(A: dace.float64[32]):
def sdfg_aug_assign_tasklet_func_rhs_cpp(A: dace.float64[32], B: dace.float64[32]):
for i in range(32):
with dace.tasklet(language=dace.Language.CPP):
a << A[i]
c << B[i]
b >> A[i]
"""
b = min(0, a);
b = min(c, a);
"""

sdfg = sdfg_aug_assign_tasklet_func_rhs_cpp.to_sdfg()
Expand Down

0 comments on commit 64df91f

Please sign in to comment.