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

Bug report ICE with OpenMP

Jonathan_Hogg
Beginner
650 Views
The following code generates a segfault in ifort (IFORT) 12.0.0 20101006 when compiled with ifort -c -openmp code.f90

[bash]module hsl_ma97_double
   implicit none

contains

subroutine inner_factor(n, scale)
   integer, intent(in) :: n
   double precision, dimension(n), optional, intent(in) :: scale

!$OMP TASK DEFAULT(NONE) SHARED(scale)
   if(present(scale)) call subtree_factor(scale)
!$OMP END TASK

!$OMP TASKWAIT

end subroutine inner_factor

subroutine subtree_factor(scale)
   double precision, dimension(*), intent(in) :: scale
end subroutine subtree_factor

end module hsl_ma97_double[/bash]

I have no access to more recent versions to confirm if the bug is present therein.
Changing scale to assumed size or non-optional eliminates the problem.
0 Kudos
1 Reply
Kevin_D_Intel
Employee
650 Views
Thank you for notifying us about this internal compiler error.

I confirmed this defect still exists in the latest Intel Fortran Composer XE 2011 Update 5 (2011.2.220 - Linux) and that is fixed in the coming Update 6 that is tentatively due out within the coming week. You can obtain the fix at your convenience once Update 6 is available. Thanks again.
0 Kudos
Reply