- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
ifx (IFX) 2024.0.0 20231017 has a bug where an associate-name created from slice of assumed character length variable has no length. The bug has been posted in HPC-Bugs/reproducers repo: https://github.com/HPC-Bugs/reproducers/tree/main/compiler/Fortran/ifx/associate-stmt. There is more information on the bug there, but the basics are also below.
Reproducer:
module mod_m
implicit none
contains
function func(line) result(returnVal)
character(len=*) :: line
integer :: returnVal
associate(associateName => line(2:))
returnVal = index(associateName, '"')
end associate
end function func
end module
Compiler error caused by above:
~/reproducers$ ifx example.f90
example.f90(11): error #5529: CHARACTER variable 'ASSOCIATENAME' has no length argument in routines with C or STDCALL attribute
returnVal = index(associateName, '"')
--------------------------^
compilation aborted for example.f90 (code 1)
Thanks.
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
@much_ado, I get the same error message that you do with ifx 2024.0.0.
The good news is that with a preview of ifx version 2024.1.0 I do not get the message. I just typed "ifx -c much.f90". That release is planned to be available around the end of March or early April.
@jdelia, that's A LOT of compiler options! tried those and I still got the error message.
Link Copied
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
Hi much_ado:
Try with:
$ ifx (IFX) 2024.0.2 20231213
Copyright (C) 1985-2023 Intel Corporation. All rights reserved.
Then,
$ ifx -O2 -error-limit 4 -e03 -fimf-arch-consistency=true -fimf-precision=high -finline-functions -fp-model consistent -fpp -fpe-all=1 -ipo -mavx -mtune=generic -m64 -parallel-source-info=1 -qmkl -qopenmp -qopt-report=3 -standard-semantics -std18 -traceback -WB -warn all -xHost -c testcase-0197.f90 # (your source module)
$
i.e. it is successfully compiled. The same with gfortran:
$ gfortran --version
GNU Fortran (GCC) 13.2.1 20231205 (Red Hat 13.2.1-6)
Copyright (C) 2023 Free Software Foundation, Inc.
$ gfortran -march=native -mtune=native -m64 -fall-intrinsics -fcheck=all -fimplicit-none -fmax-errors=4 -fPIC -std=f2018 -Wall -Waliasing -Wrealloc-lhs-all -Wno-array-temporaries -Wcharacter-truncation -Wextra -Wimplicit-interface -Wimplicit-procedure -Wintrinsic-shadow -Wline-truncation -Wsurprising -Wtabs -Wunused-parameter -Wno-unused-function -flto -fgraphite-identity -O2 -c testcase-0197.f90 # (your source module)
$
i.e. is also successfully compiled.
Regards.
Jorge D'Elia.
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
@much_ado, I get the same error message that you do with ifx 2024.0.0.
The good news is that with a preview of ifx version 2024.1.0 I do not get the message. I just typed "ifx -c much.f90". That release is planned to be available around the end of March or early April.
@jdelia, that's A LOT of compiler options! tried those and I still got the error message.
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
Thank you @Barbara_P_Intel for trying this out and letting me know that the upcoming version fixes this. That is great! Thanks!
- Subscribe to RSS Feed
- Mark Topic as New
- Mark Topic as Read
- Float this Topic for Current User
- Bookmark
- Subscribe
- Printer Friendly Page