Intel® Fortran Compiler
Build applications that can scale for the future with optimized code designed for Intel® Xeon® and compatible processors.
29228 ディスカッション

Bug: ifort and ifx crash when compiling a piece of (invalid) code involving ieee_arithmetic

Zaikun
新規コントリビューター I
1,606件の閲覧回数

This is a bug of Intel oneAPI 2022.0.2: ifort and ifx crash when compiling the code posted below. Even though the code itself is NOT valid Fortan, compilers should not crash. 

 

The latest version of the code is available in my GitHub repo dedicated to testing Fortran compilers.

 

System: Ubuntu 20.04

 

Error messages:

 

$ ifort --version && ifort -c test_ieee.f90
ifort (IFORT) 2021.5.0 20211109
Copyright (C) 1985-2021 Intel Corporation.  All rights reserved.
test_ieee.f90: catastrophic error: **Internal compiler error: segmentation violation signal raised** 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.
compilation aborted for test_ieee.f90 (code 1)

$ ifx --version && ifx -c test_ieee.f90
ifx (IFORT) 2022.0.0 20211123
Copyright (C) 1985-2021 Intel Corporation. All rights reserved.
/opt/intel/oneapi/compiler/2022.0.2/linux/bin-llvm/xfortcom[0x1362f1a]
/opt/intel/oneapi/compiler/2022.0.2/linux/bin-llvm/xfortcom[0x102d09d]
/opt/intel/oneapi/compiler/2022.0.2/linux/bin-llvm/xfortcom[0x1084382]
/opt/intel/oneapi/compiler/2022.0.2/linux/bin-llvm/xfortcom[0x10844b0]
/usr/lib/x86_64-linux-gnu/libc.so.6(+0x430c0)[0x7ff4367dd0c0]
/opt/intel/oneapi/compiler/2022.0.2/linux/bin-llvm/xfortcom[0xf1f9cf]
/opt/intel/oneapi/compiler/2022.0.2/linux/bin-llvm/xfortcom[0xf3e3a6]
/opt/intel/oneapi/compiler/2022.0.2/linux/bin-llvm/xfortcom[0xe30ad8]
/opt/intel/oneapi/compiler/2022.0.2/linux/bin-llvm/xfortcom[0xf52c09]
/opt/intel/oneapi/compiler/2022.0.2/linux/bin-llvm/xfortcom[0xf529f4]
/opt/intel/oneapi/compiler/2022.0.2/linux/bin-llvm/xfortcom[0xe021e9]
/opt/intel/oneapi/compiler/2022.0.2/linux/bin-llvm/xfortcom[0xe787c8]
/opt/intel/oneapi/compiler/2022.0.2/linux/bin-llvm/xfortcom[0xe86cc0]
/opt/intel/oneapi/compiler/2022.0.2/linux/bin-llvm/xfortcom[0xe7f520]
/opt/intel/oneapi/compiler/2022.0.2/linux/bin-llvm/xfortcom[0xeaed14]
/opt/intel/oneapi/compiler/2022.0.2/linux/bin-llvm/xfortcom[0xeaff35]
/opt/intel/oneapi/compiler/2022.0.2/linux/bin-llvm/xfortcom[0x10737be]
/opt/intel/oneapi/compiler/2022.0.2/linux/bin-llvm/xfortcom[0xf9c865]
/opt/intel/oneapi/compiler/2022.0.2/linux/bin-llvm/xfortcom[0x1116541]
/usr/lib/x86_64-linux-gnu/libc.so.6(__libc_start_main+0xf3)[0x7ff4367be0b3]
/opt/intel/oneapi/compiler/2022.0.2/linux/bin-llvm/xfortcom[0xde27a9]
test_ieee.f90: error #5633: **Internal compiler error: segmentation violation signal raised** 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.
compilation aborted for test_ieee.f90 (code 3)

 

 

Code:

 

module test_ieee_mod
! test_ieee.f90
! N.B.:
! 1. This piece of code crashes ifort (IFORT) 2021.5.0 20211109 and ifx (IFORT) 2022.0.0 20211123
! 2. The following code is NOT standard-conforming, because IEEE_VALUE cannot be used in the
! initialization. However, compilers should raise an error instead of crashing.

use, intrinsic :: ieee_arithmetic, only : ieee_value, &
    & ieee_quiet_nan, ieee_signaling_nan, ieee_positive_inf, ieee_negative_inf

implicit none

private
public :: ieeenan, ieeenan_q, ieeenan_s, ieeeinf, ieeeinf_p, ieeeinf_n

real, parameter :: ieeenan_q = ieee_value(1.0, ieee_quiet_nan)
real, parameter :: ieeenan_s = ieee_value(1.0, ieee_signaling_nan)
real, parameter :: ieeenan = ieeenan_q

real, parameter :: ieeeinf_p = ieee_value(1.0, ieee_positive_inf)
real, parameter :: ieeeinf_n = ieee_value(1.0, ieee_negative_inf)
real, parameter :: ieeeinf = ieeeinf_p

end module test_ieee_mod

 

 

 

 

 

 

0 件の賞賛
5 返答(返信)
Zaikun
新規コントリビューター I
1,597件の閲覧回数

@Barbara_P_Intel Sorry for bothering you with another bug of Intel oneAPI. Thank you for having a look. 

Zaikun
新規コントリビューター I
1,392件の閲覧回数

@Devorah_H_Intel Sorry for bothering you, but it would be great if you could have a look at this bug. Thanks. 

Barbara_P_Intel
従業員
1,348件の閲覧回数

I filed a bug report for you, CMPLRLLVM-35795. I'll post when a fix is available.



Zaikun
新規コントリビューター I
1,331件の閲覧回数
Devorah_H_Intel
モデレーター
1,113件の閲覧回数

The fix for this issue will be available in the next release. 

返信