diff --git a/pytential/qbx/interactions.py b/pytential/qbx/interactions.py index 470151f3018099a5ac336c09a4ccec52a43a2539..0cca9f170eb5ecc13bbf8166673cc13318b74150 100644 --- a/pytential/qbx/interactions.py +++ b/pytential/qbx/interactions.py @@ -32,8 +32,7 @@ from sumpy.p2e import P2EBase from sumpy.e2e import E2EBase from sumpy.e2p import E2PBase - -PYTENTIAL_KERNEL_VERSION = 7 +from pytential.version import PYTENTIAL_KERNEL_VERSION # {{{ form qbx expansions from points @@ -106,10 +105,8 @@ class P2QBXLFromCSR(P2EBase): """] + [""" qbx_expansions[tgt_icenter, {i}] = \ simul_reduce(sum, (isrc_box, isrc), strength*coeff{i}) \ - {{id_prefix=write_expn{nosync}}} - """.format(i=i, - nosync=",nosync=write_expn*" - if ncoeffs > 1 else "") + {{id_prefix=write_expn}} + """.format(i=i) for i in range(ncoeffs)] + [""" end @@ -191,10 +188,8 @@ class M2QBXL(E2EBase): """] + [""" qbx_expansions[icenter, {i}] = qbx_expansions[icenter, {i}] + \ simul_reduce(sum, isrc_box, coeff{i}) \ - {{id_prefix=write_expn{nosync}}} - """.format(i=i, - nosync=",nosync=write_expn*" - if ncoeff_tgt > 1 else "") + {{id_prefix=write_expn}} + """.format(i=i) for i in range(ncoeff_tgt)] + [""" end @@ -297,10 +292,8 @@ class L2QBXL(E2EBase): ] + self.get_translation_loopy_insns() + [""" qbx_expansions[icenter, {i}] = \ qbx_expansions[icenter, {i}] + coeff{i} \ - {{id_prefix=write_expn{nosync}}} - """.format(i=i, - nosync=",nosync=write_expn*" - if ncoeff_tgt > 1 else "") + {{id_prefix=write_expn}} + """.format(i=i) for i in range(ncoeff_tgt)] + [""" end end @@ -396,10 +389,8 @@ class QBXL2P(E2PBase): ] + loopy_insns + [""" result[{i},center_itgt] = kernel_scaling * result_{i}_p \ - {{id_prefix=write_result{nosync}}} - """.format(i=i, - nosync=",nosync=write_result*" - if len(result_names) > 1 else "") + {{id_prefix=write_result}} + """.format(i=i) for i in range(len(result_names))] + [""" end end diff --git a/pytential/version.py b/pytential/version.py index d26fbc2f9341a880b1119e7e6079bd51e59e11b9..0118173ddf0d458d695cc2501d7f1ee7c0569c34 100644 --- a/pytential/version.py +++ b/pytential/version.py @@ -1,2 +1,8 @@ VERSION = (2016, 1) VERSION_TEXT = ".".join(str(i) for i in VERSION) + +# When developing on a branch, set the first element of this tuple to your +# branch name, so as to avoid conflicts with the master branch. Make sure +# to reset this to the next number up with "master" before merging into +# master. +PYTENTIAL_KERNEL_VERSION = ("master", 9)