Skip to content

Commit 183f1eb

Browse files
author
neok-m4700
committed
Build fixes:
Arithmetic overflow gcc-7 on test Build failure with gcc-7 Runtim failure with gcc-9 on debug output
1 parent bb55753 commit 183f1eb

File tree

2 files changed

+11
-10
lines changed

2 files changed

+11
-10
lines changed

src/mpi/mpi_caf.c

Lines changed: 10 additions & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -5115,7 +5115,6 @@ send_for_ref(caf_reference_t *ref, size_t *i, size_t src_index,
51155115
gfc_max_dim_descriptor_t dst_desc_data;
51165116
caf_ref_type_t ref_type = ref->type;
51175117
caf_array_ref_t array_ref_src = ref->u.a.mode[src_dim];
5118-
caf_array_ref_t array_ref_dst = ref->u.a.mode[dst_dim];
51195118
int ierr;
51205119

51215120
if (unlikely(ref == NULL))
@@ -5133,10 +5132,8 @@ send_for_ref(caf_reference_t *ref, size_t *i, size_t src_index,
51335132
if (ref->next == NULL)
51345133
{
51355134
size_t src_size = GFC_DESCRIPTOR_SIZE(src);
5136-
dprint("[next == NULL]: src_size = %zd, ref_type = %s, "
5137-
"array_ref_src = %s\n",
5138-
src_size, caf_ref_type_str[ref_type],
5139-
caf_array_ref_str[array_ref_src]);
5135+
dprint("[next == NULL]: src_size = %zd, ref_type = %s\n",
5136+
src_size, caf_ref_type_str[ref_type]);
51405137

51415138
switch (ref_type)
51425139
{
@@ -5225,10 +5222,15 @@ send_for_ref(caf_reference_t *ref, size_t *i, size_t src_index,
52255222
caf_runtime_error(unreachable);
52265223
}
52275224
}
5225+
caf_array_ref_t array_ref_dst = ref->u.a.mode[dst_dim];
52285226

5229-
dprint("image_index = %d, num = %zd, "
5230-
"src_dim = %zd, dst_dim = %zd, ref_type = %s\n",
5231-
image_index, num, src_dim, dst_dim, caf_ref_type_str[ref_type]);
5227+
#if 0
5228+
dprint("image_index = %d, num = %zd, src_dim = %zd, dst_dim = %zd, "
5229+
"ref_type = %s, array_ref_src = %s\n",
5230+
image_index, num, src_dim, dst_dim,
5231+
caf_ref_type_str[ref_type],
5232+
caf_array_ref_str[array_ref_src]);
5233+
#endif
52325234

52335235
switch (ref_type)
52345236
{

src/tests/regression/reported/issue-552-send_by_ref-singleton.f90

Lines changed: 1 addition & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -30,7 +30,7 @@ program main
3030
co % c(1, :, :) = co % a(1, :, :)[remote] ! getter
3131

3232
sync all
33-
co % e(1, :, :) = dble(1111111111111111_8 * me) / 10**12
33+
co % e(1, :, :) = dble(111111111111111_8 * me) / 10**8
3434
co % a(1, :, :) = co % e(1, :, :)
3535

3636
sync all
@@ -67,7 +67,6 @@ program main
6767
sync all
6868

6969
fail = any(abs(co % b(1, :, :) - co % d(1, :, :)) > epsilon(0.))
70-
! fail = .false. ! <== FIXME: this test is still failing, comment when bug in put_data is found !
7170

7271
if (fail) then
7372
write(*, *) 'Test failed!'

0 commit comments

Comments
 (0)