From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: (qmail 15725 invoked by alias); 3 Dec 2010 20:21:04 -0000 Received: (qmail 15717 invoked by uid 22791); 3 Dec 2010 20:21:03 -0000 X-SWARE-Spam-Status: No, hits=-2.8 required=5.0 tests=ALL_TRUSTED,AWL,BAYES_00,TW_BF X-Spam-Check-By: sourceware.org Received: from localhost (HELO gcc.gnu.org) (127.0.0.1) by sourceware.org (qpsmtpd/0.43rc1) with ESMTP; Fri, 03 Dec 2010 20:20:58 +0000 From: "hp at gcc dot gnu.org" To: gcc-bugs@gcc.gnu.org Subject: [Bug libffi/46792] New: libffi fails building for cris-elf X-Bugzilla-Reason: CC X-Bugzilla-Type: new X-Bugzilla-Watch-Reason: None X-Bugzilla-Product: gcc X-Bugzilla-Component: libffi X-Bugzilla-Keywords: X-Bugzilla-Severity: normal X-Bugzilla-Who: hp at gcc dot gnu.org X-Bugzilla-Status: UNCONFIRMED X-Bugzilla-Priority: P3 X-Bugzilla-Assigned-To: unassigned at gcc dot gnu.org X-Bugzilla-Target-Milestone: --- X-Bugzilla-Changed-Fields: Message-ID: X-Bugzilla-URL: http://gcc.gnu.org/bugzilla/ Auto-Submitted: auto-generated Content-Type: text/plain; charset="UTF-8" MIME-Version: 1.0 Date: Fri, 03 Dec 2010 20:21:00 -0000 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-12/txt/msg00358.txt.bz2 http://gcc.gnu.org/bugzilla/show_bug.cgi?id=46792 Summary: libffi fails building for cris-elf Product: gcc Version: 4.6.0 Status: UNCONFIRMED Severity: normal Priority: P3 Component: libffi AssignedTo: unassigned@gcc.gnu.org ReportedBy: hp@gcc.gnu.org Target: cris-axis-elf When support for CRIS v32 was added to the CRIS port, a "v32" multilib was added to cris-elf. Unfortunately, libffi wasn't updated, resulting in build failure for the whole of gcc without special configure options: libtool: compile: /tmp/hpautotest-gcc1/cris-elf/gccobj/./gcc/xgcc -B/tmp/hpautotest-gcc1/cris-elf/gccobj/./gcc/ -nostd\ inc -B/tmp/hpautotest-gcc1/cris-elf/gccobj/cris-elf/v32/newlib/ -isystem /tmp/hpautotest-gcc1/cris-elf/gccobj/cris-elf/\ v32/newlib/targ-include -isystem /tmp/hpautotest-gcc1/gcc/newlib/libc/include -B/tmp/hpautotest-gcc1/cris-elf/gccobj/cr\ is-elf/v32/libgloss/cris -L/tmp/hpautotest-gcc1/cris-elf/gccobj/cris-elf/v32/libgloss/libnosys -L/tmp/hpautotest-gcc1/g\ cc/libgloss/cris -B/tmp/hpautotest-gcc1/cris-elf/pre/cris-elf/bin/ -B/tmp/hpautotest-gcc1/cris-elf/pre/cris-elf/lib/ -i\ system /tmp/hpautotest-gcc1/cris-elf/pre/cris-elf/include -isystem /tmp/hpautotest-gcc1/cris-elf/pre/cris-elf/sys-inclu\ de -march=v32 -mbest-lib-options -DHAVE_CONFIG_H -I. -I/tmp/hpautotest-gcc1/gcc/libffi -I. -I/tmp/hpautotest-gcc1/gcc/l\ ibffi/include -Iinclude -I/tmp/hpautotest-gcc1/gcc/libffi/src -I. -I/tmp/hpautotest-gcc1/gcc/libffi/include -Iinclude -\ I/tmp/hpautotest-gcc1/gcc/libffi/src -g -O2 -MT src/cris/sysv.lo -MD -MP -MF src/cris/.deps/sysv.Tpo -c /tmp/hpautotest\ -gcc1/gcc/libffi/src/cris/sysv.S -o src/cris/sysv.o /tmp/hpautotest-gcc1/gcc/libffi/src/cris/sysv.S: Assembler messages: /tmp/hpautotest-gcc1/gcc/libffi/src/cris/sysv.S:51: Error: Unknown opcode: `push' A temporary fix is to disable libffi for cris-elf. (No other action should be necessary: cris-linux doesn't have a v32 multilib and the crisv32-* tuples aren't matched by libffi configure.) The correct fix is not that hard; there's a common assembly-language subset used in other assembly codes, for example newlib+libgloss. E.g. push R -> subq 4,$sp / move.d R,[$sp] (equivalent in function, size and cycles except when condition codes need to be preserved.) I'll fix this the temporary way, then suspend the PR.