Package: gfortran-4.4 Version: 4.4.3-3 Severity: important Tags: l10n I have compiled the following fortran 95 program program test double precision a(10000000) a(1)=1 write(6,*) a(1) stop end
with the command gfortran -fopenmp and I get the following error message (If I try to execute the program) stef...@debsim2:~/prova$ ./a.out Segmentation fault stef...@debsim2:~/prova$ ----------------------------------------------------------- If I reduce the dimension of the a array, for example program test1 double precision a(1000000) a(1)=1 write(6,*) a(1) stop end and I compile the program with the same flag -fopenmp the binary program can be execute stef...@debsim2:~/prova$ ./a.out 1.0000000000000000 stef...@debsim2:~/prova$ ---------------------------------------------------- If I use a dynamical allocation (the dimension of a is like the dimension in test) program test2 double precision,allocatable :: a(:) allocate(a(100000000)) a(1)=1 write(6,*) a(1) stop end the program can be compiled (with -fopenmp) and executed. ---------------------------------------------------------- I have not used the OMP directives in these programs but I observe the same behaviour with OMP commands. The program program test_omp double precision a(10000000) !$OMP PARALLEL DEFAULT(PRIVATE) a(1)=1 write(6,*) a(1) !$OMP END PARALLEL stop end segfaults when compiled with the option -fopenmp while the program program test_omp1 double precision a(100000) !$OMP PARALLEL DEFAULT(PRIVATE) a(1)=1 write(6,*) a(1) !$OMP END PARALLEL stop end gives the result stef...@debsim2:~/prova$ ./a.out 1.0000000000000000 1.0000000000000000 stef...@debsim2:~/prova$ ------------------------------------------- Analogously the program program test_omp2 double precision,allocatable :: a(:) !$OMP PARALLEL DEFAULT(PRIVATE) allocate(a(100000000)) a(1)=1 write(6,*) a(1) !$OMP END PARALLEL stop end runs correctly: stef...@debsim2:~/prova$ ./a.out 1.0000000000000000 1.0000000000000000 stef...@debsim2:~/prova$ Thank you -- System Information: Debian Release: squeeze/sid APT prefers unstable APT policy: (500, 'unstable'), (500, 'testing'), (500, 'stable') Architecture: amd64 (x86_64) Kernel: Linux 2.6.32-rc8-amd64 (SMP w/2 CPU cores) Locale: LANG=en_US, LC_CTYPE=en_US (charmap=ISO-8859-1) Shell: /bin/sh linked to /bin/bash Versions of packages gfortran-4.4 depends on: ii gcc-4.4 4.4.3-3 The GNU C compiler ii gcc-4.4-base 4.4.3-3 The GNU Compiler Collection (base ii libc6 2.9-23 GNU C Library: Shared libraries ii libc6-dev 2.9-23 GNU C Library: Development Librari ii libgfortran3 4.4.3-3 Runtime library for GNU Fortran ap ii libgmp3c2 2:4.3.2+dfsg-1 Multiprecision arithmetic library ii libmpfr1ldbl 2.4.2-3 multiple precision floating-point gfortran-4.4 recommends no packages. Versions of packages gfortran-4.4 suggests: pn gfortran-4.4-doc <none> (no description available) pn gfortran-4.4-multilib <none> (no description available) pn libgfortran3-dbg <none> (no description available) -- no debconf information -- To UNSUBSCRIBE, email to debian-gcc-requ...@lists.debian.org with a subject of "unsubscribe". Trouble? Contact listmas...@lists.debian.org Archive: http://lists.debian.org/20100306120940.13543.39051.report...@localhost.localdomain