Source-Changes-HG archive

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index][Old Index]

[src/trunk]: src/external/gpl3/gcc - define __riscv__ again



details:   https://anonhg.NetBSD.org/src/rev/f596bad17c6d
branches:  trunk
changeset: 455904:f596bad17c6d
user:      mrg <mrg%NetBSD.org@localhost>
date:      Wed Apr 17 10:07:00 2019 +0000

description:
- define __riscv__ again
- define *intptr_t in terms of 'long int' always
- move fixtfdi.c, fixunstfdi.c, floatditf.c, and floatunditf.c into t-netbsd64
- remove duplicated riscv case in config.gcc, reducing upstream diff as well
- regen riscv64 mknative

diffstat:

 external/gpl3/gcc/dist/gcc/config/riscv/netbsd.h      |  7 +++++++
 external/gpl3/gcc/dist/libgcc/config.host             |  8 +++++---
 external/gpl3/gcc/dist/libgcc/config/riscv/t-netbsd   |  4 ----
 external/gpl3/gcc/dist/libgcc/config/riscv/t-netbsd64 |  4 ++++
 external/gpl3/gcc/lib/libgcc/arch/riscv64/defs.mk     |  2 +-
 5 files changed, 17 insertions(+), 8 deletions(-)

diffs (80 lines):

diff -r 11662f1d796b -r f596bad17c6d external/gpl3/gcc/dist/gcc/config/riscv/netbsd.h
--- a/external/gpl3/gcc/dist/gcc/config/riscv/netbsd.h  Wed Apr 17 09:37:49 2019 +0000
+++ b/external/gpl3/gcc/dist/gcc/config/riscv/netbsd.h  Wed Apr 17 10:07:00 2019 +0000
@@ -32,6 +32,7 @@
 #define TARGET_OS_CPP_BUILTINS()                               \
   do {                                                         \
     NETBSD_OS_CPP_BUILTINS_ELF();                              \
+    builtin_define ("__riscv__");                              \
     /* The GNU C++ standard library requires this.  */         \
     if (c_dialect_cxx ())                                      \
       builtin_define ("_GNU_SOURCE");                          \
@@ -62,3 +63,9 @@
 
 #undef NETBSD_ENTRY_POINT
 #define NETBSD_ENTRY_POINT     "_start"
+
+#undef UINTPTR_TYPE
+#define UINTPTR_TYPE "long unsigned int"
+
+#undef INTPTR_TYPE
+#define INTPTR_TYPE "long int"
diff -r 11662f1d796b -r f596bad17c6d external/gpl3/gcc/dist/libgcc/config.host
--- a/external/gpl3/gcc/dist/libgcc/config.host Wed Apr 17 09:37:49 2019 +0000
+++ b/external/gpl3/gcc/dist/libgcc/config.host Wed Apr 17 10:07:00 2019 +0000
@@ -168,9 +168,6 @@
 powerpc*-*-*)
        cpu_type=rs6000
        ;;
-riscv*-*-*)
-       cpu_type=riscv
-       ;;
 rs6000*-*-*)
        ;;
 riscv*-*-*)
@@ -1158,6 +1155,11 @@
        ;;
 riscv*-*-netbsd*)
        tmake_file="${tmake_file} riscv/t-netbsd"
+       case ${host} in
+       riscv64*)
+               tmake_file="${tmake_file} riscv/t-netbsd64"
+               ;;
+       esac
        ;;
 riscv*-*-*)
        tmake_file="${tmake_file} riscv/t-softfp${host_address} t-softfp riscv/t-elf riscv/t-elf${host_address}"
diff -r 11662f1d796b -r f596bad17c6d external/gpl3/gcc/dist/libgcc/config/riscv/t-netbsd
--- a/external/gpl3/gcc/dist/libgcc/config/riscv/t-netbsd       Wed Apr 17 09:37:49 2019 +0000
+++ b/external/gpl3/gcc/dist/libgcc/config/riscv/t-netbsd       Wed Apr 17 10:07:00 2019 +0000
@@ -11,10 +11,6 @@
           $(srcdir)/soft-fp/fixunstfsi.c \
           $(srcdir)/soft-fp/floatsitf.c \
           $(srcdir)/soft-fp/floatunsitf.c \
-          $(srcdir)/soft-fp/fixtfdi.c \
-          $(srcdir)/soft-fp/fixunstfdi.c \
-          $(srcdir)/soft-fp/floatditf.c \
-          $(srcdir)/soft-fp/floatunditf.c \
           $(srcdir)/soft-fp/extendsftf2.c \
           $(srcdir)/soft-fp/extenddftf2.c \
           $(srcdir)/soft-fp/trunctfsf2.c \
diff -r 11662f1d796b -r f596bad17c6d external/gpl3/gcc/dist/libgcc/config/riscv/t-netbsd64
--- /dev/null   Thu Jan 01 00:00:00 1970 +0000
+++ b/external/gpl3/gcc/dist/libgcc/config/riscv/t-netbsd64     Wed Apr 17 10:07:00 2019 +0000
@@ -0,0 +1,4 @@
+LIB2ADD += $(srcdir)/soft-fp/fixtfdi.c \
+          $(srcdir)/soft-fp/fixunstfdi.c \
+          $(srcdir)/soft-fp/floatditf.c \
+          $(srcdir)/soft-fp/floatunditf.c
diff -r 11662f1d796b -r f596bad17c6d external/gpl3/gcc/lib/libgcc/arch/riscv64/defs.mk
--- a/external/gpl3/gcc/lib/libgcc/arch/riscv64/defs.mk Wed Apr 17 09:37:49 2019 +0000
+++ b/external/gpl3/gcc/lib/libgcc/arch/riscv64/defs.mk Wed Apr 17 10:07:00 2019 +0000
@@ -4,7 +4,7 @@
 #
 G_INCLUDES=-I. -I. -I../.././gcc -I${GNUHOSTDIST}/libgcc -I${GNUHOSTDIST}/libgcc/. -I${GNUHOSTDIST}/libgcc/../gcc -I${GNUHOSTDIST}/libgcc/../include 
 G_INTERNAL_CFLAGS=-g -O2 -O2  -DIN_GCC    -W -Wall -Wno-narrowing -Wwrite-strings -Wcast-qual -Wstrict-prototypes -Wmissing-prototypes -Wold-style-definition  -isystem ./include   -fPIC -g 
-DIN_LIBGCC2 -fbuilding-libgcc -fno-stack-protector   -fPIC -I. -I. -I../.././gcc -I${GNUHOSTDIST}/libgcc -I${GNUHOSTDIST}/libgcc/. -I${GNUHOSTDIST}/libgcc/../gcc -I${GNUHOSTDIST}/libgcc/../include  
-DHAVE_CC_TLS 
-G_LIB2ADD= ${GNUHOSTDIST}/libgcc/soft-fp/addtf3.c ${GNUHOSTDIST}/libgcc/soft-fp/divtf3.c ${GNUHOSTDIST}/libgcc/soft-fp/eqtf2.c ${GNUHOSTDIST}/libgcc/soft-fp/getf2.c 
${GNUHOSTDIST}/libgcc/soft-fp/letf2.c ${GNUHOSTDIST}/libgcc/soft-fp/multf3.c ${GNUHOSTDIST}/libgcc/soft-fp/negtf2.c ${GNUHOSTDIST}/libgcc/soft-fp/subtf3.c ${GNUHOSTDIST}/libgcc/soft-fp/unordtf2.c 
${GNUHOSTDIST}/libgcc/soft-fp/fixtfsi.c ${GNUHOSTDIST}/libgcc/soft-fp/fixunstfsi.c ${GNUHOSTDIST}/libgcc/soft-fp/floatsitf.c ${GNUHOSTDIST}/libgcc/soft-fp/floatunsitf.c 
${GNUHOSTDIST}/libgcc/soft-fp/fixtfdi.c ${GNUHOSTDIST}/libgcc/soft-fp/fixunstfdi.c ${GNUHOSTDIST}/libgcc/soft-fp/floatditf.c ${GNUHOSTDIST}/libgcc/soft-fp/floatunditf.c 
${GNUHOSTDIST}/libgcc/soft-fp/extendsftf2.c ${GNUHOSTDIST}/libgcc/soft-fp/extenddftf2.c ${GNUHOSTDIST}/libgcc/soft-fp/trunctfsf2.c ${GNUHOSTDIST}/libgcc/soft-fp/trunctfdf2.c enable-execute-stack.c
+G_LIB2ADD= ${GNUHOSTDIST}/libgcc/soft-fp/addtf3.c ${GNUHOSTDIST}/libgcc/soft-fp/divtf3.c ${GNUHOSTDIST}/libgcc/soft-fp/eqtf2.c ${GNUHOSTDIST}/libgcc/soft-fp/getf2.c 
${GNUHOSTDIST}/libgcc/soft-fp/letf2.c ${GNUHOSTDIST}/libgcc/soft-fp/multf3.c ${GNUHOSTDIST}/libgcc/soft-fp/negtf2.c ${GNUHOSTDIST}/libgcc/soft-fp/subtf3.c ${GNUHOSTDIST}/libgcc/soft-fp/unordtf2.c 
${GNUHOSTDIST}/libgcc/soft-fp/fixtfsi.c ${GNUHOSTDIST}/libgcc/soft-fp/fixunstfsi.c ${GNUHOSTDIST}/libgcc/soft-fp/floatsitf.c ${GNUHOSTDIST}/libgcc/soft-fp/floatunsitf.c 
${GNUHOSTDIST}/libgcc/soft-fp/extendsftf2.c ${GNUHOSTDIST}/libgcc/soft-fp/extenddftf2.c ${GNUHOSTDIST}/libgcc/soft-fp/trunctfsf2.c ${GNUHOSTDIST}/libgcc/soft-fp/trunctfdf2.c 
${GNUHOSTDIST}/libgcc/soft-fp/fixtfdi.c ${GNUHOSTDIST}/libgcc/soft-fp/fixunstfdi.c ${GNUHOSTDIST}/libgcc/soft-fp/floatditf.c ${GNUHOSTDIST}/libgcc/soft-fp/floatunditf.c enable-execute-stack.c
 G_LIB2ADDEH=${GNUHOSTDIST}/libgcc/unwind-dw2.c ${GNUHOSTDIST}/libgcc/unwind-dw2-fde-dip.c ${GNUHOSTDIST}/libgcc/unwind-sjlj.c ${GNUHOSTDIST}/libgcc/unwind-c.c ${GNUHOSTDIST}/libgcc/emutls.c
 G_LIB2ADD_ST=
 G_LIB1ASMFUNCS=



Home | Main Index | Thread Index | Old Index