You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
I am reporting a bug others will be able to reproduce and not asking a question or requesting a new feature.
System information including:
OpenCoarrays Version: 2.7.1
Fortran Compiler: gfortran 9.2.0
C compiler used for building lib: gcc 9.2.0
Installation method: cmake
All flags & options passed to the installer
CC=gcc FC="gfortran -I$MPI_BASE/include/gfortran/9.1.0" cmake /dss/dsshome1/lrz/noarch/src/compilers/gcc/opencoarrays/OpenCoarrays-2.7.1 -DCMAKE_INSTALL_PREFIX=${PWD}
Output of uname -a:
Linux mpp2-login5 4.4.180-94.100-default tests dis_transpose: test passed #1 SMP Tue Jul 9 19:57:20 UTC 2019 (1569ffb) x86_64 x86_64 x86_64 GNU/Linux
MPI library being used: Intel MPI 2019 update 5
Machine architecture and number of physical cores: Haswell 28 core
Version of CMake: 3.10 (self-installed)
To help us debug your issue please explain:
What you were trying to do (and why)
assign to an array constructor:
a = (/ this_image(), 5*this_image() /)
What happened (include command output, screenshots, logs, etc.)
resulting value of a after the statement is [ 0,0 ]
What you expected to happen
resulting value of a after statement is [ 1,5 ] on image 1
Step-by-step reproduction instructions to reproduce the error/bug
Use the following code:
program test_constr
use, intrinsic :: iso_fortran_env
implicit none
real :: a(2), temp
a = (/ this_image(), 5*this_image() /)
write(output_unit,*) "first a is: ", a
sync all
a = this_image()
write(output_unit,*) "second a is: ", a
end program
build it with
caf tu.f90
execute with
cafrun -n 1 ./a.out
Notes:
more than 1 image also gives wrong results on the other images.
building with -fcoarray=single produces the expected result.
assigning a scalar that is broadcast to the array works as expected.
The text was updated successfully, but these errors were encountered:
Thanks for reporting this. This smells like a GFortran front-end/IR problem to me. I'll try to investigate and if I confirm that to be the case we should open an issue upstream.
System information including:
CC=gcc FC="gfortran -I$MPI_BASE/include/gfortran/9.1.0" cmake /dss/dsshome1/lrz/noarch/src/compilers/gcc/opencoarrays/OpenCoarrays-2.7.1 -DCMAKE_INSTALL_PREFIX=${PWD}
uname -a
:Linux mpp2-login5 4.4.180-94.100-default tests dis_transpose: test passed #1 SMP Tue Jul 9 19:57:20 UTC 2019 (1569ffb) x86_64 x86_64 x86_64 GNU/Linux
To help us debug your issue please explain:
What you were trying to do (and why)
assign to an array constructor:
a = (/ this_image(), 5*this_image() /)
What happened (include command output, screenshots, logs, etc.)
resulting value of a after the statement is [ 0,0 ]
What you expected to happen
resulting value of a after statement is [ 1,5 ] on image 1
Step-by-step reproduction instructions to reproduce the error/bug
Use the following code:
build it with
caf tu.f90
execute with
cafrun -n 1 ./a.out
Notes:
The text was updated successfully, but these errors were encountered: