From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: (qmail 5680 invoked by alias); 8 Jan 2010 21:07:55 -0000 Received: (qmail 5635 invoked by uid 48); 8 Jan 2010 21:07:44 -0000 Date: Fri, 08 Jan 2010 21:07:00 -0000 Subject: [Bug lto/42665] New: Internal compiler exception in with gfortran when using -fwhole-program -flto -fopenmp X-Bugzilla-Reason: CC Message-ID: Reply-To: gcc-bugzilla@gcc.gnu.org To: gcc-bugs@gcc.gnu.org From: "jjcogliati-r1 at yahoo dot com" Mailing-List: contact gcc-bugs-help@gcc.gnu.org; run by ezmlm Precedence: bulk List-Id: List-Archive: List-Post: List-Help: Sender: gcc-bugs-owner@gcc.gnu.org X-SW-Source: 2010-01/txt/msg00991.txt.bz2 When using -fwhole-program -flto -fopenmp on a program with gcc-4.5-20100107, I get an internal compiler exception. If I remove the -fopenmp, the program compiles fine. If I remove the -flto -fwhole-program, the program compiles fine. I have only been able to trigger this in a multi-thousand line program proprietary program, and have not yet figured out a small test case that causes this. If you have any hints as to how to create a small test case, I will try them. I cannot provide the full program source code. Approximate command line: gfortran -march=native -std=f95 -g -Wall -pedantic -O3 -Wline-truncation -fopenmp -fbounds-check -fwhole-program -flto -o program lots.o of.o dot.o files.o Error: lto1: internal compiler error: in iterative_hash_expr, at tree.c:6592 Relevant portion of gcc/tree.c: /* FALL THROUGH */ default: tclass = TREE_CODE_CLASS (code); if (tclass == tcc_declaration) { /* DECL's have a unique ID */ val = iterative_hash_host_wide_int (DECL_UID (t), val); } else { gcc_assert (IS_EXPR_CODE_CLASS (tclass)); val = iterative_hash_object (code, val); $ gcc -v Using built-in specs. COLLECT_GCC=gcc COLLECT_LTO_WRAPPER=/home/jjc/gcc/gcc45/libexec/gcc/x86_64-unknown-linux-gnu/4.5.0/lto-wrapper Target: x86_64-unknown-linux-gnu Configured with: ../gcc-4.5-20100107/configure --prefix=/home/jjc/gcc/gcc45 --enable-languages=c,c++,fortran,lto,objc --disable-multilib Thread model: posix gcc version 4.5.0 20100107 (experimental) (GCC) -- Summary: Internal compiler exception in with gfortran when using -fwhole-program -flto -fopenmp Product: gcc Version: 4.5.0 Status: UNCONFIRMED Severity: normal Priority: P3 Component: lto AssignedTo: unassigned at gcc dot gnu dot org ReportedBy: jjcogliati-r1 at yahoo dot com GCC build triplet: x86_64-unknown-linux-gnu GCC host triplet: x86_64-unknown-linux-gnu GCC target triplet: x86_64-unknown-linux-gnu http://gcc.gnu.org/bugzilla/show_bug.cgi?id=42665