Skip to content

Commit e952f34

Browse files
Possible MPI driver bugfix
1 parent 74e48e1 commit e952f34

File tree

2 files changed

+9
-9
lines changed

2 files changed

+9
-9
lines changed

examples/hybrid/driver.jl

Lines changed: 8 additions & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -194,14 +194,14 @@ if is_distributed # replace sol.u on the root processor with the global sol.u
194194
)
195195
global_center_space, global_face_space =
196196
make_hybrid_spaces(global_h_space, z_max, z_elem; z_stretch)
197-
global_Y_c_type = Fields.Field{
198-
typeof(Fields.field_values(Y.c)),
199-
typeof(global_center_space),
200-
}
201-
global_Y_f_type = Fields.Field{
202-
typeof(Fields.field_values(Y.f)),
203-
typeof(global_face_space),
204-
}
197+
global_Y_c_1 =
198+
DataLayouts.gather(comms_ctx, Fields.field_values(sol.u[1].c))
199+
global_Y_f_1 =
200+
DataLayouts.gather(comms_ctx, Fields.field_values(sol.u[1].f))
201+
global_Y_c_type =
202+
Fields.Field{typeof(global_Y_c_1), typeof(global_center_space)}
203+
global_Y_f_type =
204+
Fields.Field{typeof(global_Y_f_1), typeof(global_face_space)}
205205
global_Y_type = Fields.FieldVector{
206206
FT,
207207
NamedTuple{(:c, :f), Tuple{global_Y_c_type, global_Y_f_type}},

ext/cuda/data_layouts_copyto.jl

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -112,7 +112,7 @@ Base.copyto!(dest::IFH{S, Ni, Nh}, bc::DataLayouts.BroadcastedUnionIFH{S,
112112
Base.copyto!(dest::IJF{S, Nij}, bc::DataLayouts.BroadcastedUnionIJF{S, Nij}, ::ToCUDA) where {S, Nij} = cuda_copyto!(dest, bc)
113113
Base.copyto!(dest::IF{S, Ni}, bc::DataLayouts.BroadcastedUnionIF{S, Ni}, ::ToCUDA) where {S, Ni} = cuda_copyto!(dest, bc)
114114
Base.copyto!(dest::VIFH{S, Nv, Ni, Nh}, bc::DataLayouts.BroadcastedUnionVIFH{S, Nv, Ni, Nh}, ::ToCUDA) where {S, Nv, Ni, Nh} = cuda_copyto!(dest, bc)
115-
# Base.copyto!(dest::VIJFH{S, Nv, Nij}, bc::DataLayouts.BroadcastedUnionVIJFH{S, Nv, Nij, Nh}, ::ToCUDA) where {S, Nv, Nij, Nh} = cuda_copyto!(dest, bc)
115+
# Base.copyto!(dest::VIJFH{S, Nv, Nij, Nh}, bc::DataLayouts.BroadcastedUnionVIJFH{S, Nv, Nij, Nh}, ::ToCUDA) where {S, Nv, Nij, Nh} = cuda_copyto!(dest, bc)
116116
# Base.copyto!(dest::VF{S, Nv}, bc::DataLayouts.BroadcastedUnionVF{S, Nv}, ::ToCUDA) where {S, Nv} = cuda_copyto!(dest, bc)
117117
# Base.copyto!(dest::DataF{S}, bc::DataLayouts.BroadcastedUnionDataF{S}, ::ToCUDA) where {S} = cuda_copyto!(dest, bc)
118118
#! format: on

0 commit comments

Comments
 (0)