Intel® Fortran Compiler
Build applications that can scale for the future with optimized code designed for Intel® Xeon® and compatible processors.
29274 Discussions

ifx compiler crash when trying to ICHAR a string of dimension >1

Frankcombe__Kim
Beginner
894 Views

On compiling using ifx 2024.02 with debug settings

-c -m64 -check all -debug full -traceback -warn all -heap-arrays -stand -standard-semantics

I get the following

#0 0x000000000312d632
#1 0x0000000003191cf7
#2 0x000000000317d7d6
#3 0x000000000309da73
#4 0x00000000030a3951
#5 0x00000000030b4688
#6 0x00000000031a0f9e
#7 0x00000000031695b0
#8 0x00000000031a3cac
#9 0x00000000031695b0
#10 0x00000000031d6cd8
#11 0x00000000031e0db4
#12 0x00000000031e1335
#13 0x00000000031de5b0
#14 0x00000000031e0db4
#15 0x00000000031e1335
#16 0x00000000031de5e4
#17 0x00000000031e0db4
#18 0x00000000031e1335
#19 0x00000000031de5b0
#20 0x00000000031e0db4
#21 0x00000000031e1335
#22 0x0000000003166477
#23 0x0000000003166129
#24 0x0000000003167fee
#25 0x00000000031e0db4
#26 0x00000000031e1335
#27 0x00000000031de5e4
#28 0x00000000031e0db4
#29 0x00000000031e1335
#30 0x000000000313bcf4
#31 0x000000000313a31e
#32 0x000000000313ad85
#33 0x00000000031e0db4
#34 0x00000000031e1335
#35 0x00000000031681aa
#36 0x00000000031e0db4
#37 0x00000000031e1335
#38 0x00000000031e3d70
#39 0x00000000031e0db4
#40 0x00000000031e1335
#41 0x00000000031e3d70
#42 0x00000000031e0db4
#43 0x00000000031de22a
#44 0x00000000031e0db4
#45 0x0000000003078656
#46 0x0000000003077f36
#47 0x000000000324dd27
#48 0x0000788950c2a1ca
#49 0x0000788950c2a28b __libc_start_main + 139
#50 0x0000000002eb058a

/home/kim/code/gmagtool/gem19in.f90(442): error #5623: **Internal compiler error: internal abort** Please report this error along with the circumstances in which it occurred in a Software Problem Report. Note: File and line given may not be explicit cause of this error.
ZDATA(IMTRG2)=REAL(IACHAR(TRIM(TEMPSTR)))
-----------------------------------^
compilation aborted for /home/kim/code/gmagtool/gem19in.f90 (code 3)

TEMPSTR is declared as CHARACTER(LEN=80) BUT on this occasion I know it will only have a trimmed length of 1. I'm using the variable for many reads so would like it long enough for all occasions.

recasting to ZDATA(IMTRG2)=REAL(IACHAR(TEMPSTR(1:1)))

works and allows compilation.

I guess rather than a string of hex a simple warning that IACAR is meant for CHAR*1 would be nice.

0 Kudos
1 Solution
2 Replies
Ron_Green
Moderator
743 Views

Yes, same issue.  Thanks Andrew! 

0 Kudos
Reply