[Bug fortran/50774] New: Internal Compiler Error when march=bdver1

2011-10-18 Thread ibethune at epcc dot ed.ac.uk
http://gcc.gnu.org/bugzilla/show_bug.cgi?id=50774

 Bug #: 50774
   Summary: Internal Compiler Error when march=bdver1
Classification: Unclassified
   Product: gcc
   Version: 4.6.1
Status: UNCONFIRMED
  Severity: normal
  Priority: P3
 Component: fortran
AssignedTo: unassig...@gcc.gnu.org
ReportedBy: ibeth...@epcc.ed.ac.uk


Created attachment 25539
  --> http://gcc.gnu.org/bugzilla/attachment.cgi?id=25539
Source file which triggers the ICE

In the attached simple code, compilation fails when using the -march=bdver1
flag:


ibethune@login3:~/gcc46_test> gfortran -c -O3 -ffast-math -g -march=bdver1 
helium_interactions.f90
gfortran: internal compiler error: Segmentation fault (program f951)
Please submit a full bug report,
with preprocessed source if appropriate.
See  for instructions.


Without the -march file compilation completes successfully.

Gfortran version infromation below:

ibethune@login3:~/gcc46_test> gfortran -v
Using built-in specs.
COLLECT_GCC=/opt/gcc/4.6.1/bin/../snos/bin/gfortran
COLLECT_LTO_WRAPPER=/opt/gcc/4.6.1/snos/libexec/gcc/x86_64-suse-linux/4.6.1/lto-wrapper
Target: x86_64-suse-linux
Configured with: ../xt-gcc-4.6.1/configure --prefix=/opt/gcc/4.6.1/snos
--disable-nls --libdir=/opt/gcc/4.6.1/snos/lib --enable-languages=c,c++,fortran
--with-gxx-include-dir=/opt/gcc/4.6.1/snos/include/g++
--with-slibdir=/opt/gcc/4.6.1/snos/lib --with-system-zlib --enable-shared
--enable-__cxa_atexit x86_64-suse-linux --with-mpc=/opt/gcc/mpc/0.8.1
--with-mpfr=/opt/gcc/mpfr/2.4.2 --with-gmp=/opt/gcc/gmp/4.3.2 --with-sysroot=
Thread model: posix
gcc version 4.6.1 20110627 (Cray Inc.) (GCC)

Cheers

- Iain


[Bug fortran/77870] New: Valid OpenMP reduction of allocatable array produces a warning with -Wrealloc-lhs

2016-10-05 Thread ibethune at epcc dot ed.ac.uk
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=77870

Bug ID: 77870
   Summary: Valid OpenMP reduction of allocatable array produces a
warning with -Wrealloc-lhs
   Product: gcc
   Version: 6.1.0
Status: UNCONFIRMED
  Severity: normal
  Priority: P3
 Component: fortran
  Assignee: unassigned at gcc dot gnu.org
  Reporter: ibethune at epcc dot ed.ac.uk
  Target Milestone: ---

An OpenMP fortran code which declares an allocatable array as an OpenMP
reduction variable generates a warning when compiled with -Wrealloc-lhs. I have
observed this with gfortran 6.1.0.

A simple example to show this:

mbp-ib:reduction ibethune$ cat reduction.f90 
program reduction
double precision, dimension(:), allocatable :: a
allocate(a(3))
!$OMP PARALLEL REDUCTION(+:a)
!$OMP END PARALLEL
deallocate(a)
end program
mbp-ib:reduction ibethune$ gfortran -Wrealloc-lhs -fopenmp -o reduction
reduction.f90
reduction.f90:4:29:

 !$OMP PARALLEL REDUCTION(+:a)
 1
Warning: Code for reallocating the allocatable array at (1) will be added
[-Wrealloc-lhs]
mbp-ib:reduction ibethune$ gfortran -Wrealloc-lhs -o reduction reduction.f90
mbp-ib:reduction ibethune$

It's desirable to have this warning flag enabled to guard against poor code
style elswhere in the codebase e.g. array assignment without (:) notation. 
Would it be possible to either:

* Have the OpenMP directives translated into code which does not trigger this
warning

or

* Have the warning silenced when it comes from OpenMP-generated code rather
than user code.

Thanks!

[Bug fortran/77878] New: Valid OpenMP reduction of allocatable array produces a warning with -Wrealloc-lhs

2016-10-05 Thread ibethune at epcc dot ed.ac.uk
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=77878

Bug ID: 77878
   Summary: Valid OpenMP reduction of allocatable array produces a
warning with -Wrealloc-lhs
   Product: gcc
   Version: 6.1.0
Status: UNCONFIRMED
  Severity: normal
  Priority: P3
 Component: fortran
  Assignee: unassigned at gcc dot gnu.org
  Reporter: ibethune at epcc dot ed.ac.uk
  Target Milestone: ---

An OpenMP fortran code which declares an allocatable array as an OpenMP
reduction variable generates a warning when compiled with -Wrealloc-lhs. I have
observed this with gfortran 6.1.0.

A simple example to show this:

mbp-ib:reduction ibethune$ cat reduction.f90 
program reduction
double precision, dimension(:), allocatable :: a
allocate(a(3))
!$OMP PARALLEL REDUCTION(+:a)
!$OMP END PARALLEL
deallocate(a)
end program
mbp-ib:reduction ibethune$ gfortran -Wrealloc-lhs -fopenmp -o reduction
reduction.f90
reduction.f90:4:29:

 !$OMP PARALLEL REDUCTION(+:a)
 1
Warning: Code for reallocating the allocatable array at (1) will be added
[-Wrealloc-lhs]
mbp-ib:reduction ibethune$ gfortran -Wrealloc-lhs -o reduction reduction.f90
mbp-ib:reduction ibethune$

It's desirable to have this warning flag enabled to guard against poor code
style elswhere in the codebase e.g. array assignment without (:) notation. 
Would it be possible to either:

* Have the OpenMP directives translated into code which does not trigger this
warning

or

* Have the warning silenced when it comes from OpenMP-generated code rather
than user code.

Thanks!

[Bug fortran/77870] Valid OpenMP reduction of allocatable array produces a warning with -Wrealloc-lhs

2016-10-05 Thread ibethune at epcc dot ed.ac.uk
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=77870

--- Comment #2 from Iain Bethune  ---
*** Bug 77878 has been marked as a duplicate of this bug. ***

[Bug fortran/77878] Valid OpenMP reduction of allocatable array produces a warning with -Wrealloc-lhs

2016-10-05 Thread ibethune at epcc dot ed.ac.uk
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=77878

Iain Bethune  changed:

   What|Removed |Added

 Status|UNCONFIRMED |RESOLVED
 Resolution|--- |DUPLICATE

--- Comment #1 from Iain Bethune  ---
Submitted twice, my mistake.

*** This bug has been marked as a duplicate of bug 77870 ***