This is the mail archive of the gcc@gcc.gnu.org mailing list for the GCC project.


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]
Other format: [Raw text]

How to configure a bi-arch PowerPC GCC?


Hello,

I would like to configure a bi-arch PowerPC GCC. My naive approach was simply:

diff --git a/gcc/config.gcc b/gcc/config.gcc
index 90308cd..228f941 100644
--- a/gcc/config.gcc
+++ b/gcc/config.gcc
@@ -2381,7 +2381,7 @@ powerpc-*-eabi*)
        use_gcc_stdint=wrap
        ;;
 powerpc-*-rtems*)
- tm_file="${tm_file} dbxelf.h elfos.h freebsd-spec.h newlib-stdint.h rs6000/sysv4.h rs6000/eabi.h rs6000/e500.h rs6000/rtems.h rtems.h" + tm_file="rs6000/biarch64.h ${tm_file} dbxelf.h elfos.h freebsd-spec.h newlib-stdint.h rs6000/sysv4.h rs6000/eabi.h rs6000/e500.h rs6000/rtems.h rtems.h"
        extra_options="${extra_options} rs6000/sysv4.opt"
tmake_file="${tmake_file} rs6000/t-fprules rs6000/t-rtems rs6000/t-ppccomm"
        ;;
diff --git a/gcc/config/rs6000/t-rtems b/gcc/config/rs6000/t-rtems
index 7c7637d..8ff0656 100644
--- a/gcc/config/rs6000/t-rtems
+++ b/gcc/config/rs6000/t-rtems
@@ -30,6 +30,9 @@ MULTILIB_DIRNAMES += m403 m505 m603e m604 m860 m7400 m8540 me6500
 MULTILIB_OPTIONS += m32
 MULTILIB_DIRNAMES += m32

+MULTILIB_OPTIONS += m64
+MULTILIB_DIRNAMES += m64
+
 MULTILIB_OPTIONS += msoft-float/mfloat-gprs=double
 MULTILIB_DIRNAMES += nof gprsdouble

@@ -77,3 +80,5 @@ MULTILIB_REQUIRED += mcpu=8540/mfloat-gprs=double
 MULTILIB_REQUIRED += mcpu=860
 MULTILIB_REQUIRED += mcpu=e6500/m32
 MULTILIB_REQUIRED += mcpu=e6500/m32/msoft-float/mno-altivec
+MULTILIB_REQUIRED += mcpu=e6500/m64
+MULTILIB_REQUIRED += mcpu=e6500/m64/msoft-float/mno-altivec

This leads to an ICE during libgcc configure:

configure:3660: checking for suffix of object files
configure:3682: /build/git-build/b-gcc-git-powerpc-rtems4.12/./gcc/xgcc -B/build/git-build/b-gcc-git-powerpc-rtems4.12/./gcc/ -nostdinc -B/build/git-build/b-gcc-git-powerpc-rtems4.12/powerpc-rtems4.12/me6500/m64/newlib/ -isystem /build/git-build/b-gcc-git-powerpc-rtems4.12/powerpc-rtems4.12/me6500/m64/newlib/targ-include -isystem /home/EB/sebastian_h/archive/gcc-git/newlib/libc/include -B/opt/rtems-4.12/powerpc-rtems4.12/bin/ -B/opt/rtems-4.12/powerpc-rtems4.12/lib/ -isystem /opt/rtems-4.12/powerpc-rtems4.12/include -isystem /opt/rtems-4.12/powerpc-rtems4.12/sys-include -mcpu=e6500 -m64 -c -g -O2 conftest.c >&5
conftest.c: In function 'main':
conftest.c:16:1: error: unrecognizable insn:
 }
 ^
(insn/f 22 21 23 2 (parallel [
            (set (reg/f:DI 1 1)
                (plus:SI (reg/f:DI 1 1)
                    (const_int 16 [0x10])))
            (set (mem:BLK (reg/f:DI 1 1) [0  A8])
                (const_int 0 [0]))
            (set (mem:BLK (reg/f:DI 1 1) [0  A8])
                (const_int 0 [0]))
        ]) "conftest.c":16 -1
     (expr_list:REG_CFA_DEF_CFA (reg/f:DI 1 1)
        (nil)))
conftest.c:16:1: internal compiler error: in extract_insn, at recog.c:2311
0x98ada5 _fatal_insn(char const*, rtx_def const*, char const*, int, char const*)
    /home/EB/sebastian_h/archive/gcc-git/gcc/rtl-error.c:108
0x98add9 _fatal_insn_not_found(rtx_def const*, char const*, int, char const*)
    /home/EB/sebastian_h/archive/gcc-git/gcc/rtl-error.c:116
0x95c397 extract_insn(rtx_insn*)
    /home/EB/sebastian_h/archive/gcc-git/gcc/recog.c:2311
0x95d3b8 extract_constrain_insn(rtx_insn*)
    /home/EB/sebastian_h/archive/gcc-git/gcc/recog.c:2211
0x9609a6 copyprop_hardreg_forward_1
    /home/EB/sebastian_h/archive/gcc-git/gcc/regcprop.c:794
0x961982 execute
    /home/EB/sebastian_h/archive/gcc-git/gcc/regcprop.c:1301
Please submit a full bug report,
with preprocessed source if appropriate.
Please include the complete backtrace with any bug report.
See <http://gcc.gnu.org/bugs.html> for instructions.
configure:3686: $? = 1
configure: failed program was:
| /* confdefs.h */
| #define PACKAGE_NAME "GNU C Runtime Library"
| #define PACKAGE_TARNAME "libgcc"
| #define PACKAGE_VERSION "1.0"
| #define PACKAGE_STRING "GNU C Runtime Library 1.0"
| #define PACKAGE_BUGREPORT ""
| #define PACKAGE_URL "http://www.gnu.org/software/libgcc/";
| /* end confdefs.h.  */
|
| int
| main ()
| {
|
|   ;
|   return 0;
| }
configure:3700: error: in `/build/git-build/b-gcc-git-powerpc-rtems4.12/powerpc-rtems4.12/me6500/m64/libgcc':
configure:3703: error: cannot compute suffix of object files: cannot compile

I would be happy for some hints how to fix this.

--
Sebastian Huber, embedded brains GmbH

Address : Dornierstr. 4, D-82178 Puchheim, Germany
Phone   : +49 89 189 47 41-16
Fax     : +49 89 189 47 41-09
E-Mail  : sebastian.huber@embedded-brains.de
PGP     : Public key available on request.

Diese Nachricht ist keine geschäftliche Mitteilung im Sinne des EHUG.


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]