diff --git a/test/test_apps.py b/test/test_apps.py index 55eecdf2baa59d7a0477f4e6bba801d52610ae6e..3be133d94e821372dec2100a17c90f75e77b6301 100644 --- a/test/test_apps.py +++ b/test/test_apps.py @@ -197,7 +197,7 @@ def test_rob_stroud_bernstein(ctx_factory): for alpha2 tmp[el,alpha1,i2] = tmp[el,alpha1,i2] + w * coeffs[aind] \ - {id=write_tmp} + {id=write_tmp,dep=init_w:aind_init} w = w * r * ( deg - alpha1 - alpha2 ) / (1 + alpha2) \ {id=update_w,dep=init_w:write_tmp} aind = aind + 1 \ @@ -491,7 +491,8 @@ def test_lbm(ctx_factory): f_new[i, j, 11] = + 0.25*m[8] - 0.125*m[10] - 0.25*m[11] end end - """) + """, + lang_version=(2017, 2, 1)) knl = lp.add_and_infer_dtypes(knl, {"f": np.float32}) diff --git a/test/test_loopy.py b/test/test_loopy.py index d9bc3d271cb7a3de8e2d56f1dc267e1c90e9e3db..8229f613e7198984c301e332746499bc097dd2c1 100644 --- a/test/test_loopy.py +++ b/test/test_loopy.py @@ -1088,12 +1088,12 @@ def test_atomic_load(ctx_factory, dtype): "{ [i,j]: 0<=i,j<n}", """ for j - <> upper = 0 - <> lower = 0 + <> upper = 0 {id=init_upper} + <> lower = 0 {id=init_lower} temp = 0 {id=init, atomic} for i - upper = upper + i * a[i] {id=sum0} - lower = lower - b[i] {id=sum1} + upper = upper + i * a[i] {id=sum0,dep=init_upper} + lower = lower - b[i] {id=sum1,dep=init_lower} end temp = temp + lower {id=temp_sum, dep=sum*:init, atomic,\ nosync=init} @@ -2632,8 +2632,8 @@ def test_fixed_parameters(ctx_factory): knl = lp.make_kernel( "[n] -> {[i]: 0 <= i < n}", """ - <>tmp[i] = i - tmp[0] = 0 + <>tmp[i] = i {id=init} + tmp[0] = 0 {dep=init} """, fixed_parameters=dict(n=1)) diff --git a/test/test_numa_diff.py b/test/test_numa_diff.py index a5c69020af58926846545e64f3550e7b6953c671..7bacad75f5653b99d0111752dbcbfd27d6795127 100644 --- a/test/test_numa_diff.py +++ b/test/test_numa_diff.py @@ -60,13 +60,14 @@ def test_gnuma_horiz_kernel(ctx_factory, ilp_multiple, Nq, opt_level): # noqa source = source.replace("datafloat", "real*4") hsv_r, hsv_s = [ - knl for knl in lp.parse_fortran(source, filename, auto_dependencies=False) + knl for knl in lp.parse_fortran(source, filename, seq_dependencies=False) if "KernelR" in knl.name or "KernelS" in knl.name ] hsv_r = lp.tag_instructions(hsv_r, "rknl") hsv_s = lp.tag_instructions(hsv_s, "sknl") hsv = lp.fuse_kernels([hsv_r, hsv_s], ["_r", "_s"]) #hsv = hsv_s + hsv = lp.add_nosync(hsv, "any", "writes:rhsQ", "writes:rhsQ", force=True) from gnuma_loopy_transforms import ( fix_euler_parameters, diff --git a/test/test_target.py b/test/test_target.py index 8fd565a8158db988039aae94babd8b865e495077..71a2548c1f20e4d1277b96568649acda4a78aa21 100644 --- a/test/test_target.py +++ b/test/test_target.py @@ -206,8 +206,8 @@ def test_random123(ctx_factory, tp): <> key2 = make_uint2(i, 324830944) {inames=i} <> key4 = make_uint4(i, 324830944, 234181, 2233) {inames=i} <> ctr = make_uint4(0, 1, 2, 3) {inames=i,id=init_ctr} - <> real, ctr = philox4x32_TYPE(ctr, key2) {dep=init_ctr} - <> imag, ctr = threefry4x32_TYPE(ctr, key4) {dep=init_ctr} + <> real, ctr = philox4x32_TYPE(ctr, key2) {id=realpart,dep=init_ctr} + <> imag, ctr = threefry4x32_TYPE(ctr, key4) {dep=init_ctr:realpart} out[i, 0] = real.s0 + 1j * imag.s0 out[i, 1] = real.s1 + 1j * imag.s1 @@ -215,6 +215,8 @@ def test_random123(ctx_factory, tp): out[i, 3] = real.s3 + 1j * imag.s3 """.replace("TYPE", tp)) + knl = lp.add_nosync(knl, "any", "writes:out", "writes:out", force=True) + knl = lp.split_iname(knl, "i", 128, outer_tag="g.0", inner_tag="l.0") knl = lp.set_options(knl, write_cl=True) diff --git a/test/test_transform.py b/test/test_transform.py index feb8bf9df5e31a1017efc1eca3fdf872f0e9ab96..d9ad97240d8f601ff6755c379c7c8f993f7fa216 100644 --- a/test/test_transform.py +++ b/test/test_transform.py @@ -78,7 +78,7 @@ def test_collect_common_factors(ctx_factory): """ <float32> out_tmp = 0 {id=out_init,inames=i} out_tmp = out_tmp + alpha[i]*a[i,j]*b1[j] {id=out_up1,dep=out_init} - out_tmp = out_tmp + alpha[i]*a[j,i]*b2[j] {id=out_up2,dep=out_init} + out_tmp = out_tmp + alpha[i]*a[j,i]*b2[j] {id=out_up2,dep=out_init,nosync=} out[i] = out_tmp {dep=out_up1:out_up2} """) knl = lp.add_and_infer_dtypes(knl,