Source-Changes-HG archive

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

[src/trunk]: src/external/gpl3/gcc/dist merge gcc 4.8.2 r206687 (part 3).



details:   https://anonhg.NetBSD.org/src/rev/dc8aa234698e
branches:  trunk
changeset: 327182:dc8aa234698e
user:      mrg <mrg%NetBSD.org@localhost>
date:      Sat Mar 01 09:26:00 2014 +0000

description:
merge gcc 4.8.2 r206687 (part 3).

diffstat:

 external/gpl3/gcc/dist/gcc/config/arm/t-netbsd-eabi       |  40 -------
 external/gpl3/gcc/dist/gcc/config/host-netbsd.c           |  85 +++++++++++++++
 external/gpl3/gcc/dist/gcc/config/netbsd-stdint.h         |  56 +++++++++
 external/gpl3/gcc/dist/gcc/config/x-netbsd                |   4 +
 external/gpl3/gcc/dist/libgcc/config/arm/t-netbsd-eabi    |  19 +++
 external/gpl3/gcc/dist/libgcc/config/m68k/t-netbsd-m68010 |   5 +
 external/gpl3/gcc/dist/libgcc/config/pa/t-netbsd          |   9 +
 7 files changed, 178 insertions(+), 40 deletions(-)

diffs (246 lines):

diff -r 819b9a16218d -r dc8aa234698e external/gpl3/gcc/dist/gcc/config/arm/t-netbsd-eabi
--- a/external/gpl3/gcc/dist/gcc/config/arm/t-netbsd-eabi       Sat Mar 01 09:04:12 2014 +0000
+++ /dev/null   Thu Jan 01 00:00:00 1970 +0000
@@ -1,40 +0,0 @@
-# Copyright (C) 2005, 2009 Free Software Foundation, Inc.
-#
-# This file is part of GCC.
-#
-# GCC is free software; you can redistribute it and/or modify
-# it under the terms of the GNU General Public License as published by
-# the Free Software Foundation; either version 3, or (at your option)
-# any later version.
-#
-# GCC is distributed in the hope that it will be useful,
-# but WITHOUT ANY WARRANTY; without even the implied warranty of
-# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
-# GNU General Public License for more details.
-#
-# You should have received a copy of the GNU General Public License
-# along with GCC; see the file COPYING3.  If not see
-# <http://www.gnu.org/licenses/>.
-
-# Use a version of div0 which raises SIGFPE, and a special __clear_cache.
-
-LIB1ASMFUNCS += \
-       _dvmd_tls _bb_init_func _call_via_rX _interwork_call_via_rX \
-       _clzsi2 _clzdi2
-
-# Add the BPABI C functions that aren't already in libc
-LIB2FUNCS_EXTRA = $(srcdir)/config/arm/unaligned-funcs.c
-
-LIB2FUNCS_STATIC_EXTRA =
-
-UNWIND_H = $(srcdir)/config/arm/unwind-arm.h
-LIB2ADDEH = $(srcdir)/config/arm/unwind-arm.c \
-  $(srcdir)/config/arm/libunwind.S \
-  $(srcdir)/config/arm/pr-support.c $(srcdir)/unwind-c.c
-LIB2ADDEHDEP = $(UNWIND_H) $(srcdir)/config/$(LIB1ASMSRC)
-
-SHLIB_MAPFILES += $(srcdir)/config/arm/libgcc-bpabi.ver
-
-MULTILIB_OPTIONS = mabi=aapcs-linux/mabi=aapcs/mabi=atpcs/mabi=apcs-gnu/mabi=iwmmxt
-MULTILIB_DIRNAMES = aapcs-linux aapcs atpcs oabi iwmmxt
-MULTILIB_OSDIRNAMES = . ../lib/aapcs ../lib/atpcs ../lib/oabi ../lib/iwmmxt
diff -r 819b9a16218d -r dc8aa234698e external/gpl3/gcc/dist/gcc/config/host-netbsd.c
--- /dev/null   Thu Jan 01 00:00:00 1970 +0000
+++ b/external/gpl3/gcc/dist/gcc/config/host-netbsd.c   Sat Mar 01 09:26:00 2014 +0000
@@ -0,0 +1,85 @@
+/* NetBSD host-specific hook definitions.
+   Copyright (C) 2004-2013 Free Software Foundation, Inc.
+
+   This file is part of GCC.
+
+   GCC is free software; you can redistribute it and/or modify it
+   under the terms of the GNU General Public License as published
+   by the Free Software Foundation; either version 3, or (at your
+   option) any later version.
+
+   GCC is distributed in the hope that it will be useful, but WITHOUT
+   ANY WARRANTY; without even the implied warranty of MERCHANTABILITY
+   or FITNESS FOR A PARTICULAR PURPOSE.  See the GNU General Public
+   License for more details.
+
+   You should have received a copy of the GNU General Public License
+   along with GCC; see the file COPYING3.  If not see
+   <http://www.gnu.org/licenses/>.  */
+
+#include "config.h"
+#include "system.h"
+#include "coretypes.h"
+#include "hosthooks.h"
+#include "hosthooks-def.h"
+
+
+#undef HOST_HOOKS_GT_PCH_GET_ADDRESS
+#define HOST_HOOKS_GT_PCH_GET_ADDRESS netbsd_gt_pch_get_address
+#undef HOST_HOOKS_GT_PCH_USE_ADDRESS
+#define HOST_HOOKS_GT_PCH_USE_ADDRESS netbsd_gt_pch_use_address
+
+/* For various ports, try to guess a fixed spot in the vm space
+   that's probably free.  */
+#if defined(__sparc64__)
+# define TRY_EMPTY_VM_SPACE    0x40000000000
+#elif defined(_LP64)
+# define TRY_EMPTY_VM_SPACE    0x400000000000
+#elif defined(__mips__) || defined(__vax__)
+# define TRY_EMPTY_VM_SPACE    0x60000000
+#else
+# define TRY_EMPTY_VM_SPACE    0xb0000000
+#endif
+
+/* Determine a location where we might be able to reliably allocate
+   SIZE bytes.  FD is the PCH file, though we should return with the
+   file unmapped.  */
+
+static void *
+netbsd_gt_pch_get_address (size_t size, int fd)
+{
+  void *addr;
+
+  addr = mmap ((void *) TRY_EMPTY_VM_SPACE, size, PROT_READ | PROT_WRITE,
+              MAP_PRIVATE | MAP_FIXED, fd, 0);
+
+  /* If we failed the map, that means there's *no* free space.  */
+  if (addr == (void *) MAP_FAILED)
+    return NULL;
+  /* Unmap the area before returning.  */
+  munmap (addr, size);
+
+  return addr;
+}
+
+/* Map SIZE bytes of FD+OFFSET at BASE.  Return 1 if we succeeded at 
+   mapping the data at BASE, -1 if we couldn't.  */
+
+static int
+netbsd_gt_pch_use_address (void *base, size_t size, int fd, size_t offset)
+{
+  void *addr;
+
+  /* We're called with size == 0 if we're not planning to load a PCH
+     file at all.  This allows the hook to free any static space that
+     we might have allocated at link time.  */
+  if (size == 0)
+    return -1;
+
+  addr = mmap (base, size, PROT_READ | PROT_WRITE, MAP_PRIVATE | MAP_FIXED, fd, offset);
+
+  return addr == base ? 1 : -1;
+}
+
+
+const struct host_hooks host_hooks = HOST_HOOKS_INITIALIZER;
diff -r 819b9a16218d -r dc8aa234698e external/gpl3/gcc/dist/gcc/config/netbsd-stdint.h
--- /dev/null   Thu Jan 01 00:00:00 1970 +0000
+++ b/external/gpl3/gcc/dist/gcc/config/netbsd-stdint.h Sat Mar 01 09:26:00 2014 +0000
@@ -0,0 +1,56 @@
+/* Definitions for <stdint.h> types for NetBSD systems.
+   Copyright (C) 2009 Free Software Foundation, Inc.
+   Contributed by Gerald Pfeifer <gerald%pfeifer.com@localhost>.
+
+This file is part of GCC.
+
+GCC is free software; you can redistribute it and/or modify
+it under the terms of the GNU General Public License as published by
+the Free Software Foundation; either version 3, or (at your option)
+any later version.
+
+GCC is distributed in the hope that it will be useful,
+but WITHOUT ANY WARRANTY; without even the implied warranty of
+MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
+GNU General Public License for more details.
+
+Under Section 7 of GPL version 3, you are granted additional
+permissions described in the GCC Runtime Library Exception, version
+3.1, as published by the Free Software Foundation.
+
+You should have received a copy of the GNU General Public License and
+a copy of the GCC Runtime Library Exception along with this program;
+see the files COPYING3 and COPYING.RUNTIME respectively.  If not, see
+<http://www.gnu.org/licenses/>.  */
+
+#define SIG_ATOMIC_TYPE   "int"
+
+#define INT8_TYPE         "signed char"
+#define INT16_TYPE        "short int"
+#define INT32_TYPE        "int"
+#define INT64_TYPE        (LONG_TYPE_SIZE == 64 ? "long int" : "long long int")
+#define UINT8_TYPE        "unsigned char"
+#define UINT16_TYPE       "short unsigned int"
+#define UINT32_TYPE       "unsigned int"
+#define UINT64_TYPE       (LONG_TYPE_SIZE == 64 ? "long unsigned int" : "long long unsigned int")
+
+#define INT_LEAST8_TYPE   "signed char"
+#define INT_LEAST16_TYPE  "short int"
+#define INT_LEAST32_TYPE  "int"
+#define INT_LEAST64_TYPE  (LONG_TYPE_SIZE == 64 ? "long int" : "long long int")
+#define UINT_LEAST8_TYPE  "unsigned char"
+#define UINT_LEAST16_TYPE "short unsigned int"
+#define UINT_LEAST32_TYPE "unsigned int"
+#define UINT_LEAST64_TYPE (LONG_TYPE_SIZE == 64 ? "long unsigned int" : "long long unsigned int")
+
+#define INT_FAST8_TYPE    "int"
+#define INT_FAST16_TYPE   "int"
+#define INT_FAST32_TYPE   "int"
+#define INT_FAST64_TYPE   (LONG_TYPE_SIZE == 64 ? "long int" : "long long int")
+#define UINT_FAST8_TYPE   "unsigned int"
+#define UINT_FAST16_TYPE  "unsigned int"
+#define UINT_FAST32_TYPE  "unsigned int"
+#define UINT_FAST64_TYPE  (LONG_TYPE_SIZE == 64 ? "long unsigned int" : "long long unsigned int")
+
+#define INTPTR_TYPE       (LONG_TYPE_SIZE == 64 ? "long int" : "int")
+#define UINTPTR_TYPE      (LONG_TYPE_SIZE == 64 ? "long unsigned int" : "unsigned int")
diff -r 819b9a16218d -r dc8aa234698e external/gpl3/gcc/dist/gcc/config/x-netbsd
--- /dev/null   Thu Jan 01 00:00:00 1970 +0000
+++ b/external/gpl3/gcc/dist/gcc/config/x-netbsd        Sat Mar 01 09:26:00 2014 +0000
@@ -0,0 +1,4 @@
+host-netbsd.o : $(srcdir)/config/host-netbsd.c $(CONFIG_H) $(SYSTEM_H) \
+  coretypes.h hosthooks.h hosthooks-def.h $(HOOKS_H)
+       $(COMPILER) -c $(ALL_COMPILERFLAGS) $(ALL_CPPFLAGS) $(INCLUDES) \
+               $(srcdir)/config/host-netbsd.c
diff -r 819b9a16218d -r dc8aa234698e external/gpl3/gcc/dist/libgcc/config/arm/t-netbsd-eabi
--- /dev/null   Thu Jan 01 00:00:00 1970 +0000
+++ b/external/gpl3/gcc/dist/libgcc/config/arm/t-netbsd-eabi    Sat Mar 01 09:26:00 2014 +0000
@@ -0,0 +1,19 @@
+# This list is from t-elf, but with lots removed.
+LIB1ASMFUNCS += _dvmd_tls _bb_init_func _call_via_rX _interwork_call_via_rX \
+        _clzsi2 _clzdi2 _ctzsi2
+
+# Derived from t-bpabi
+# Add the BPABI C functions.
+LIB2ADD +=    $(srcdir)/config/arm/unaligned-funcs.c
+
+LIB2ADDEH = $(srcdir)/config/arm/unwind-arm.c \
+  $(srcdir)/config/arm/libunwind.S \
+  $(srcdir)/config/arm/pr-support.c $(srcdir)/unwind-c.c
+
+# Add the BPABI names.
+SHLIB_MAPFILES += $(srcdir)/config/arm/libgcc-bpabi.ver
+
+# On ARM, specifying -fnon-call-exceptions will needlessly pull in
+# the unwinder in simple programs which use 64-bit division.  Omitting
+# the option is safe.
+LIB2_DIVMOD_EXCEPTION_FLAGS := -fexceptions
diff -r 819b9a16218d -r dc8aa234698e external/gpl3/gcc/dist/libgcc/config/m68k/t-netbsd-m68010
--- /dev/null   Thu Jan 01 00:00:00 1970 +0000
+++ b/external/gpl3/gcc/dist/libgcc/config/m68k/t-netbsd-m68010 Sat Mar 01 09:26:00 2014 +0000
@@ -0,0 +1,5 @@
+LIB1ASMSRC = m68k/lb1sf68.S
+LIB1ASMFUNCS = _mulsi3 _udivsi3 _divsi3 _umodsi3 _modsi3 \
+   _double _float _floatex \
+   _eqdf2 _nedf2 _gtdf2 _gedf2 _ltdf2 _ledf2 \
+   _eqsf2 _nesf2 _gtsf2 _gesf2 _ltsf2 _lesf2
diff -r 819b9a16218d -r dc8aa234698e external/gpl3/gcc/dist/libgcc/config/pa/t-netbsd
--- /dev/null   Thu Jan 01 00:00:00 1970 +0000
+++ b/external/gpl3/gcc/dist/libgcc/config/pa/t-netbsd  Sat Mar 01 09:26:00 2014 +0000
@@ -0,0 +1,9 @@
+#Plug millicode routines into libgcc.a  We want these on both native and
+#cross compiles.  We use the "64-bit" routines because the "32-bit" code
+#is broken for certain corner cases.
+LIB1ASMSRC = pa/milli64.S
+LIB1ASMFUNCS = _divI _divU _remI _remU _div_const _mulI _dyncall
+
+HOST_LIBGCC2_CFLAGS += -DELF=1 -DLINUX=1
+
+LIB2ADD = $(srcdir)/config/pa/fptr.c



Home | Main Index | Thread Index | Old Index