def METHOD_NAME(dtype):
    n = dace.symbol("n")
    sdfg = dace.SDFG("mpi_send_recv")
    state = sdfg.add_state("dataflow")
    sdfg.add_array("x", [n], dtype, transient=False)
    sdfg.add_array("y", [n], dtype, transient=False)
    sdfg.add_array("src", [1], dace.dtypes.int32, transient=False)
    sdfg.add_array("dest", [1], dace.dtypes.int32, transient=False)
    sdfg.add_array("tag", [1], dace.dtypes.int32, transient=False)
    sdfg.add_array("send_req", [1], dace.dtypes.opaque("MPI_Request"), transient=True)
    sdfg.add_array("recv_req", [1], dace.dtypes.opaque("MPI_Request"), transient=True)
    sdfg.add_array("stat_source", [1], dace.dtypes.int32, transient=True)
    sdfg.add_array("stat_count", [1], dace.dtypes.int32, transient=True)
    sdfg.add_array("stat_tag", [1], dace.dtypes.int32, transient=True)
    sdfg.add_array("stat_cancelled", [1], dace.dtypes.int32, transient=True)
    x = state.add_access("x")
    y = state.add_access("y")
    src = state.add_access("src")
    dest = state.add_access("dest")
    tag = state.add_access("tag")
    send_req = state.add_access("send_req")
    recv_req = state.add_access("recv_req")
    stat_source = state.add_access("stat_source")
    stat_tag = state.add_access("stat_tag")
    send_node = mpi.nodes.isend.Isend("isend")
    recv_node = mpi.nodes.irecv.Irecv("irecv")
    wait_node = mpi.nodes.wait.Wait("wait")
    state.add_memlet_path(x, send_node, dst_conn="_buffer", memlet=Memlet.simple(x, "0:n", num_accesses=n))
    state.add_memlet_path(send_node,
                          send_req,
                          src_conn="_request",
                          memlet=Memlet.simple(send_req, "0:1", num_accesses=1))
    state.add_memlet_path(dest, send_node, dst_conn="_dest", memlet=Memlet.simple(dest, "0:1", num_accesses=1))
    state.add_memlet_path(tag, send_node, dst_conn="_tag", memlet=Memlet.simple(tag, "0:1", num_accesses=1))
    state.add_memlet_path(recv_node, y, src_conn="_buffer", memlet=Memlet.simple(y, "0:n", num_accesses=n))
    state.add_memlet_path(recv_node,
                          recv_req,
                          src_conn="_request",
                          memlet=Memlet.simple(recv_req, "0:1", num_accesses=1))
    state.add_memlet_path(recv_req,
                          wait_node,
                          dst_conn="_request",
                          memlet=Memlet.simple(recv_req, "0:1", num_accesses=1))
    state.add_memlet_path(wait_node,
                          stat_tag,
                          src_conn="_stat_tag",
                          memlet=Memlet.simple(stat_tag, "0:1", num_accesses=1))
    state.add_memlet_path(wait_node,
                          stat_source,
                          src_conn="_stat_source",
                          memlet=Memlet.simple(stat_source, "0:1", num_accesses=1))
    state.add_memlet_path(src, recv_node, dst_conn="_src", memlet=Memlet.simple(src, "0:1", num_accesses=1))
    state.add_memlet_path(tag, recv_node, dst_conn="_tag", memlet=Memlet.simple(tag, "0:1", num_accesses=1))
    return sdfg