Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

ffte4X.F90 passes COMPLEX(8) to a function expecting REAL(8) #214

Open
BenWibking opened this issue May 26, 2023 · 2 comments
Open

ffte4X.F90 passes COMPLEX(8) to a function expecting REAL(8) #214

BenWibking opened this issue May 26, 2023 · 2 comments

Comments

@BenWibking
Copy link

There are bugs in the usage of the fft2 function:

Compiling ffte4X.F90

mpif90 -c -o ffte4X.o -DLINUX -DH5_USE_16_API   -D__max_subgrids=100000 -D__max_baryons=30 -D__max_cpu_per_node=8 -D__memory_pool_size=100000 -DINITS64 -DSMALL_INTS -DCONFIG_PINT_8 -DIO_32    -DUSE_MPI   -DCONFIG_PFLOAT_8 -DCONFIG_BFLOAT_8  -DUSE_HDF5_GROUPS   -DTRANSFER   -DNEW_GRID_IO -DFAST_SIB      -DENZO_PERFORMANCE    -DUSE_UUID -DSAB -extend-source -O2 ffte4X.F90

ffte4X.F90:673:26:

  673 |           call fft2(a,a,m)
      |                          1
Error: Type mismatch in argument ‘a’ at (1); passed COMPLEX(8) to REAL(8)
ffte4X.F90:675:26:

  675 |           call fft2(b,a,m)
      |                          1
Error: Type mismatch in argument ‘a’ at (1); passed COMPLEX(8) to REAL(8)
ffte4X.F90:787:36:

  787 |         call settbl0(w(j),8_IKIND,l)
      |                                    1
Error: Type mismatch in argument ‘w’ at (1); passed COMPLEX(8) to REAL(8)
ffte4X.F90:793:36:

  793 |         call settbl0(w(j),5_IKIND,l)
      |                                    1
Error: Type mismatch in argument ‘w’ at (1); passed COMPLEX(8) to REAL(8)
ffte4X.F90:799:36:

  799 |         call settbl0(w(j),4_IKIND,l)
      |                                    1
Error: Type mismatch in argument ‘w’ at (1); passed COMPLEX(8) to REAL(8)
ffte4X.F90:805:36:

  805 |         call settbl0(w(j),3_IKIND,l)
      |                                    1
Error: Type mismatch in argument ‘w’ at (1); passed COMPLEX(8) to REAL(8)
ffte4X.F90:693:27:

  693 |         call fft3a(a,b,w,l)
      |                           1
Error: Type mismatch in argument ‘a’ at (1); passed COMPLEX(8) to REAL(8)
ffte4X.F90:695:29:

  695 |         call fft3b(a,b,w,m,l)
      |                             1
Error: Type mismatch in argument ‘a’ at (1); passed COMPLEX(8) to REAL(8)
ffte4X.F90:712:27:

  712 |         call fft4a(a,b,w,l)
      |                           1
Error: Type mismatch in argument ‘a’ at (1); passed COMPLEX(8) to REAL(8)
ffte4X.F90:714:29:

  714 |         call fft4b(a,b,w,m,l)
      |                             1
Error: Type mismatch in argument ‘a’ at (1); passed COMPLEX(8) to REAL(8)
ffte4X.F90:731:27:

  731 |         call fft5a(a,b,w,l)
      |                           1
Error: Type mismatch in argument ‘a’ at (1); passed COMPLEX(8) to REAL(8)
ffte4X.F90:733:29:

  733 |         call fft5b(a,b,w,m,l)
      |                             1
Error: Type mismatch in argument ‘a’ at (1); passed COMPLEX(8) to REAL(8)
ffte4X.F90:750:27:

  750 |         call fft8a(a,b,w,l)
      |                           1
Error: Type mismatch in argument ‘a’ at (1); passed COMPLEX(8) to REAL(8)
ffte4X.F90:752:29:

  752 |         call fft8b(a,b,w,m,l)
      |                             1
Error: Type mismatch in argument ‘a’ at (1); passed COMPLEX(8) to REAL(8)
ffte4X.F90:136:68:

  136 |           call settbls(ww,ww(nw2+1),ww(nw3+1),ww(nw4+1),n1,n2,m1,m2)
      |                                                                    1
Error: Type mismatch in argument ‘w1’ at (1); passed COMPLEX(8) to REAL(8)
@clairekope
Copy link
Contributor

Related(ish) to #224. It will compile anyway if you specify -std=legacy in the fortran flags of your machine file.

That said, does this type change impact results? In that case, obviously it should be fixed and it shouldn't just be glossed over with -std=legacy

@BenWibking
Copy link
Author

I don't know. I tested this out to provide a build recipe to new students. I probably don't have time to pursue this further.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants