OpenCores
URL https://opencores.org/ocsvn/zipcpu/zipcpu/trunk

Subversion Repositories zipcpu

[/] [zipcpu/] [trunk/] [sw/] [gcc-zippatch.patch] - Diff between revs 122 and 124

Go to most recent revision | Show entire file | Details | Blame | View Log

Rev 122 Rev 124
Line 136... Line 136...
+#undef TARGET_OPTION_OPTIMIZATION_TABLE
+#undef TARGET_OPTION_OPTIMIZATION_TABLE
+#define        TARGET_OPTION_OPTIMIZATION_TABLE        zip_option_optimization_table
+#define        TARGET_OPTION_OPTIMIZATION_TABLE        zip_option_optimization_table
+
+
+struct gcc_targetm_common      targetm_common = TARGETM_COMMON_INITIALIZER;
+struct gcc_targetm_common      targetm_common = TARGETM_COMMON_INITIALIZER;
diff -Naur '--exclude=*.swp' gcc-5.3.0-original/gcc/config/aarch64/aarch64-linux.h gcc-5.3.0-zip/gcc/config/aarch64/aarch64-linux.h
diff -Naur '--exclude=*.swp' gcc-5.3.0-original/gcc/config/aarch64/aarch64-linux.h gcc-5.3.0-zip/gcc/config/aarch64/aarch64-linux.h
--- gcc-5.3.0-original/gcc/config/aarch64/aarch64-linux.h       2016-04-06 17:56:01.475918570 -0400
--- gcc-5.3.0-original/gcc/config/aarch64/aarch64-linux.h       2016-04-11 22:20:22.139907680 -0400
+++ gcc-5.3.0-zip/gcc/config/aarch64/aarch64-linux.h    2015-07-24 12:00:26.000000000 -0400
+++ gcc-5.3.0-zip/gcc/config/aarch64/aarch64-linux.h    2015-07-24 12:00:26.000000000 -0400
@@ -21,7 +21,7 @@
@@ -21,7 +21,7 @@
 #ifndef GCC_AARCH64_LINUX_H
 #ifndef GCC_AARCH64_LINUX_H
 #define GCC_AARCH64_LINUX_H
 #define GCC_AARCH64_LINUX_H
 
 
Line 148... Line 148...
+#define GLIBC_DYNAMIC_LINKER "/lib/ld-linux-aarch64%{mbig-endian:_be}%{mabi=ilp32:_ilp32}.so.1"
+#define GLIBC_DYNAMIC_LINKER "/lib/ld-linux-aarch64%{mbig-endian:_be}%{mabi=ilp32:_ilp32}.so.1"
 
 
 #undef  ASAN_CC1_SPEC
 #undef  ASAN_CC1_SPEC
 #define ASAN_CC1_SPEC "%{%:sanitize(address):-funwind-tables}"
 #define ASAN_CC1_SPEC "%{%:sanitize(address):-funwind-tables}"
diff -Naur '--exclude=*.swp' gcc-5.3.0-original/gcc/config/alpha/linux-elf.h gcc-5.3.0-zip/gcc/config/alpha/linux-elf.h
diff -Naur '--exclude=*.swp' gcc-5.3.0-original/gcc/config/alpha/linux-elf.h gcc-5.3.0-zip/gcc/config/alpha/linux-elf.h
--- gcc-5.3.0-original/gcc/config/alpha/linux-elf.h     2016-04-06 17:56:01.475918570 -0400
--- gcc-5.3.0-original/gcc/config/alpha/linux-elf.h     2016-04-11 22:20:22.143907624 -0400
+++ gcc-5.3.0-zip/gcc/config/alpha/linux-elf.h  2015-01-05 07:33:28.000000000 -0500
+++ gcc-5.3.0-zip/gcc/config/alpha/linux-elf.h  2015-01-05 07:33:28.000000000 -0500
@@ -23,8 +23,8 @@
@@ -23,8 +23,8 @@
 #define EXTRA_SPECS \
 #define EXTRA_SPECS \
 { "elf_dynamic_linker", ELF_DYNAMIC_LINKER },
 { "elf_dynamic_linker", ELF_DYNAMIC_LINKER },
 
 
Line 162... Line 162...
+#define UCLIBC_DYNAMIC_LINKER "/lib/ld-uClibc.so.0"
+#define UCLIBC_DYNAMIC_LINKER "/lib/ld-uClibc.so.0"
 #if DEFAULT_LIBC == LIBC_UCLIBC
 #if DEFAULT_LIBC == LIBC_UCLIBC
 #define CHOOSE_DYNAMIC_LINKER(G, U) "%{mglibc:" G ";:" U "}"
 #define CHOOSE_DYNAMIC_LINKER(G, U) "%{mglibc:" G ";:" U "}"
 #elif DEFAULT_LIBC == LIBC_GLIBC
 #elif DEFAULT_LIBC == LIBC_GLIBC
diff -Naur '--exclude=*.swp' gcc-5.3.0-original/gcc/config/arm/linux-eabi.h gcc-5.3.0-zip/gcc/config/arm/linux-eabi.h
diff -Naur '--exclude=*.swp' gcc-5.3.0-original/gcc/config/arm/linux-eabi.h gcc-5.3.0-zip/gcc/config/arm/linux-eabi.h
--- gcc-5.3.0-original/gcc/config/arm/linux-eabi.h      2016-04-06 17:56:01.475918570 -0400
--- gcc-5.3.0-original/gcc/config/arm/linux-eabi.h      2016-04-11 22:20:22.143907624 -0400
+++ gcc-5.3.0-zip/gcc/config/arm/linux-eabi.h   2015-01-05 07:33:28.000000000 -0500
+++ gcc-5.3.0-zip/gcc/config/arm/linux-eabi.h   2015-01-05 07:33:28.000000000 -0500
@@ -68,8 +68,8 @@
@@ -68,8 +68,8 @@
    GLIBC_DYNAMIC_LINKER_DEFAULT and TARGET_DEFAULT_FLOAT_ABI.  */
    GLIBC_DYNAMIC_LINKER_DEFAULT and TARGET_DEFAULT_FLOAT_ABI.  */
 
 
 #undef  GLIBC_DYNAMIC_LINKER
 #undef  GLIBC_DYNAMIC_LINKER
Line 176... Line 176...
+#define GLIBC_DYNAMIC_LINKER_HARD_FLOAT "/lib/ld-linux-armhf.so.3"
+#define GLIBC_DYNAMIC_LINKER_HARD_FLOAT "/lib/ld-linux-armhf.so.3"
 #define GLIBC_DYNAMIC_LINKER_DEFAULT GLIBC_DYNAMIC_LINKER_SOFT_FLOAT
 #define GLIBC_DYNAMIC_LINKER_DEFAULT GLIBC_DYNAMIC_LINKER_SOFT_FLOAT
 
 
 #define GLIBC_DYNAMIC_LINKER \
 #define GLIBC_DYNAMIC_LINKER \
diff -Naur '--exclude=*.swp' gcc-5.3.0-original/gcc/config/arm/linux-elf.h gcc-5.3.0-zip/gcc/config/arm/linux-elf.h
diff -Naur '--exclude=*.swp' gcc-5.3.0-original/gcc/config/arm/linux-elf.h gcc-5.3.0-zip/gcc/config/arm/linux-elf.h
--- gcc-5.3.0-original/gcc/config/arm/linux-elf.h       2016-04-06 17:56:01.475918570 -0400
--- gcc-5.3.0-original/gcc/config/arm/linux-elf.h       2016-04-11 22:20:22.143907624 -0400
+++ gcc-5.3.0-zip/gcc/config/arm/linux-elf.h    2015-06-23 05:26:54.000000000 -0400
+++ gcc-5.3.0-zip/gcc/config/arm/linux-elf.h    2015-06-23 05:26:54.000000000 -0400
@@ -62,7 +62,7 @@
@@ -62,7 +62,7 @@
 
 
 #define LIBGCC_SPEC "%{mfloat-abi=soft*:-lfloat} -lgcc"
 #define LIBGCC_SPEC "%{mfloat-abi=soft*:-lfloat} -lgcc"
 
 
Line 188... Line 188...
+#define GLIBC_DYNAMIC_LINKER "/lib/ld-linux.so.2"
+#define GLIBC_DYNAMIC_LINKER "/lib/ld-linux.so.2"
 
 
 #define LINUX_TARGET_LINK_SPEC  "%{h*} \
 #define LINUX_TARGET_LINK_SPEC  "%{h*} \
    %{static:-Bstatic} \
    %{static:-Bstatic} \
diff -Naur '--exclude=*.swp' gcc-5.3.0-original/gcc/config/bfin/linux.h gcc-5.3.0-zip/gcc/config/bfin/linux.h
diff -Naur '--exclude=*.swp' gcc-5.3.0-original/gcc/config/bfin/linux.h gcc-5.3.0-zip/gcc/config/bfin/linux.h
--- gcc-5.3.0-original/gcc/config/bfin/linux.h  2016-04-06 17:56:01.475918570 -0400
--- gcc-5.3.0-original/gcc/config/bfin/linux.h  2016-04-11 22:20:22.143907624 -0400
+++ gcc-5.3.0-zip/gcc/config/bfin/linux.h       2015-01-05 07:33:28.000000000 -0500
+++ gcc-5.3.0-zip/gcc/config/bfin/linux.h       2015-01-05 07:33:28.000000000 -0500
@@ -45,7 +45,7 @@
@@ -45,7 +45,7 @@
   %{shared:-G -Bdynamic} \
   %{shared:-G -Bdynamic} \
   %{!shared: %{!static: \
   %{!shared: %{!static: \
    %{rdynamic:-export-dynamic} \
    %{rdynamic:-export-dynamic} \
Line 200... Line 200...
+   -dynamic-linker /lib/ld-uClibc.so.0} \
+   -dynamic-linker /lib/ld-uClibc.so.0} \
    %{static}} -init __init -fini __fini"
    %{static}} -init __init -fini __fini"
 
 
 #undef TARGET_SUPPORTS_SYNC_CALLS
 #undef TARGET_SUPPORTS_SYNC_CALLS
diff -Naur '--exclude=*.swp' gcc-5.3.0-original/gcc/config/cris/linux.h gcc-5.3.0-zip/gcc/config/cris/linux.h
diff -Naur '--exclude=*.swp' gcc-5.3.0-original/gcc/config/cris/linux.h gcc-5.3.0-zip/gcc/config/cris/linux.h
--- gcc-5.3.0-original/gcc/config/cris/linux.h  2016-04-06 17:56:01.475918570 -0400
--- gcc-5.3.0-original/gcc/config/cris/linux.h  2016-04-11 22:20:22.143907624 -0400
+++ gcc-5.3.0-zip/gcc/config/cris/linux.h       2015-01-05 07:33:28.000000000 -0500
+++ gcc-5.3.0-zip/gcc/config/cris/linux.h       2015-01-05 07:33:28.000000000 -0500
@@ -102,7 +102,7 @@
@@ -102,7 +102,7 @@
 #undef CRIS_DEFAULT_CPU_VERSION
 #undef CRIS_DEFAULT_CPU_VERSION
 #define CRIS_DEFAULT_CPU_VERSION CRIS_CPU_NG
 #define CRIS_DEFAULT_CPU_VERSION CRIS_CPU_NG
 
 
Line 212... Line 212...
+#define GLIBC_DYNAMIC_LINKER "/lib/ld.so.1"
+#define GLIBC_DYNAMIC_LINKER "/lib/ld.so.1"
 
 
 #undef CRIS_LINK_SUBTARGET_SPEC
 #undef CRIS_LINK_SUBTARGET_SPEC
 #define CRIS_LINK_SUBTARGET_SPEC \
 #define CRIS_LINK_SUBTARGET_SPEC \
diff -Naur '--exclude=*.swp' gcc-5.3.0-original/gcc/config/freebsd-spec.h gcc-5.3.0-zip/gcc/config/freebsd-spec.h
diff -Naur '--exclude=*.swp' gcc-5.3.0-original/gcc/config/freebsd-spec.h gcc-5.3.0-zip/gcc/config/freebsd-spec.h
--- gcc-5.3.0-original/gcc/config/freebsd-spec.h        2016-04-06 17:56:01.475918570 -0400
--- gcc-5.3.0-original/gcc/config/freebsd-spec.h        2016-04-11 22:20:22.143907624 -0400
+++ gcc-5.3.0-zip/gcc/config/freebsd-spec.h     2015-06-25 13:53:14.000000000 -0400
+++ gcc-5.3.0-zip/gcc/config/freebsd-spec.h     2015-06-25 13:53:14.000000000 -0400
@@ -129,9 +129,9 @@
@@ -129,9 +129,9 @@
 #endif
 #endif
 
 
 #if FBSD_MAJOR < 6
 #if FBSD_MAJOR < 6
Line 227... Line 227...
+#define FBSD_DYNAMIC_LINKER "/libexec/ld-elf.so.1"
+#define FBSD_DYNAMIC_LINKER "/libexec/ld-elf.so.1"
 #endif
 #endif
 
 
 /* NOTE: The freebsd-spec.h header is included also for various
 /* NOTE: The freebsd-spec.h header is included also for various
diff -Naur '--exclude=*.swp' gcc-5.3.0-original/gcc/config/frv/linux.h gcc-5.3.0-zip/gcc/config/frv/linux.h
diff -Naur '--exclude=*.swp' gcc-5.3.0-original/gcc/config/frv/linux.h gcc-5.3.0-zip/gcc/config/frv/linux.h
--- gcc-5.3.0-original/gcc/config/frv/linux.h   2016-04-06 17:56:01.475918570 -0400
--- gcc-5.3.0-original/gcc/config/frv/linux.h   2016-04-11 22:20:22.143907624 -0400
+++ gcc-5.3.0-zip/gcc/config/frv/linux.h        2015-01-05 07:33:28.000000000 -0500
+++ gcc-5.3.0-zip/gcc/config/frv/linux.h        2015-01-05 07:33:28.000000000 -0500
@@ -34,7 +34,7 @@
@@ -34,7 +34,7 @@
 #define ENDFILE_SPEC \
 #define ENDFILE_SPEC \
   "%{shared|pie:crtendS.o%s;:crtend.o%s} crtn.o%s"
   "%{shared|pie:crtendS.o%s;:crtend.o%s} crtn.o%s"
 
 
Line 239... Line 239...
+#define GLIBC_DYNAMIC_LINKER "/lib/ld.so.1"
+#define GLIBC_DYNAMIC_LINKER "/lib/ld.so.1"
 
 
 #undef LINK_SPEC
 #undef LINK_SPEC
 #define LINK_SPEC "\
 #define LINK_SPEC "\
diff -Naur '--exclude=*.swp' gcc-5.3.0-original/gcc/config/i386/gnu.h gcc-5.3.0-zip/gcc/config/i386/gnu.h
diff -Naur '--exclude=*.swp' gcc-5.3.0-original/gcc/config/i386/gnu.h gcc-5.3.0-zip/gcc/config/i386/gnu.h
--- gcc-5.3.0-original/gcc/config/i386/gnu.h    2016-04-06 17:56:01.475918570 -0400
--- gcc-5.3.0-original/gcc/config/i386/gnu.h    2016-04-11 22:20:22.143907624 -0400
+++ gcc-5.3.0-zip/gcc/config/i386/gnu.h 2015-01-05 07:33:28.000000000 -0500
+++ gcc-5.3.0-zip/gcc/config/i386/gnu.h 2015-01-05 07:33:28.000000000 -0500
@@ -22,7 +22,7 @@
@@ -22,7 +22,7 @@
 #define GNU_USER_LINK_EMULATION "elf_i386"
 #define GNU_USER_LINK_EMULATION "elf_i386"
 
 
 #undef GNU_USER_DYNAMIC_LINKER
 #undef GNU_USER_DYNAMIC_LINKER
Line 251... Line 251...
+#define GNU_USER_DYNAMIC_LINKER "/lib/ld.so"
+#define GNU_USER_DYNAMIC_LINKER "/lib/ld.so"
 
 
 #undef STARTFILE_SPEC
 #undef STARTFILE_SPEC
 #if defined HAVE_LD_PIE
 #if defined HAVE_LD_PIE
diff -Naur '--exclude=*.swp' gcc-5.3.0-original/gcc/config/i386/kfreebsd-gnu64.h gcc-5.3.0-zip/gcc/config/i386/kfreebsd-gnu64.h
diff -Naur '--exclude=*.swp' gcc-5.3.0-original/gcc/config/i386/kfreebsd-gnu64.h gcc-5.3.0-zip/gcc/config/i386/kfreebsd-gnu64.h
--- gcc-5.3.0-original/gcc/config/i386/kfreebsd-gnu64.h 2016-04-06 17:56:01.475918570 -0400
--- gcc-5.3.0-original/gcc/config/i386/kfreebsd-gnu64.h 2016-04-11 22:20:22.143907624 -0400
+++ gcc-5.3.0-zip/gcc/config/i386/kfreebsd-gnu64.h      2015-01-05 07:33:28.000000000 -0500
+++ gcc-5.3.0-zip/gcc/config/i386/kfreebsd-gnu64.h      2015-01-05 07:33:28.000000000 -0500
@@ -22,6 +22,6 @@
@@ -22,6 +22,6 @@
 #define GNU_USER_LINK_EMULATION64 "elf_x86_64_fbsd"
 #define GNU_USER_LINK_EMULATION64 "elf_x86_64_fbsd"
 #define GNU_USER_LINK_EMULATIONX32 "elf32_x86_64_fbsd"
 #define GNU_USER_LINK_EMULATIONX32 "elf32_x86_64_fbsd"
 
 
Line 264... Line 264...
-#define GLIBC_DYNAMIC_LINKERX32 "/tools/lib/ld-kfreebsd-x32.so.1"
-#define GLIBC_DYNAMIC_LINKERX32 "/tools/lib/ld-kfreebsd-x32.so.1"
+#define GLIBC_DYNAMIC_LINKER32 "/lib/ld.so.1"
+#define GLIBC_DYNAMIC_LINKER32 "/lib/ld.so.1"
+#define GLIBC_DYNAMIC_LINKER64 "/lib/ld-kfreebsd-x86-64.so.1"
+#define GLIBC_DYNAMIC_LINKER64 "/lib/ld-kfreebsd-x86-64.so.1"
+#define GLIBC_DYNAMIC_LINKERX32 "/lib/ld-kfreebsd-x32.so.1"
+#define GLIBC_DYNAMIC_LINKERX32 "/lib/ld-kfreebsd-x32.so.1"
diff -Naur '--exclude=*.swp' gcc-5.3.0-original/gcc/config/i386/kfreebsd-gnu.h gcc-5.3.0-zip/gcc/config/i386/kfreebsd-gnu.h
diff -Naur '--exclude=*.swp' gcc-5.3.0-original/gcc/config/i386/kfreebsd-gnu.h gcc-5.3.0-zip/gcc/config/i386/kfreebsd-gnu.h
--- gcc-5.3.0-original/gcc/config/i386/kfreebsd-gnu.h   2016-04-06 17:56:01.475918570 -0400
--- gcc-5.3.0-original/gcc/config/i386/kfreebsd-gnu.h   2016-04-11 22:20:22.143907624 -0400
+++ gcc-5.3.0-zip/gcc/config/i386/kfreebsd-gnu.h        2015-01-05 07:33:28.000000000 -0500
+++ gcc-5.3.0-zip/gcc/config/i386/kfreebsd-gnu.h        2015-01-05 07:33:28.000000000 -0500
@@ -19,4 +19,4 @@
@@ -19,4 +19,4 @@
 <http://www.gnu.org/licenses/>.  */
 <http://www.gnu.org/licenses/>.  */
 
 
 #define GNU_USER_LINK_EMULATION "elf_i386_fbsd"
 #define GNU_USER_LINK_EMULATION "elf_i386_fbsd"
-#define GLIBC_DYNAMIC_LINKER "/tools/lib/ld.so.1"
-#define GLIBC_DYNAMIC_LINKER "/tools/lib/ld.so.1"
+#define GLIBC_DYNAMIC_LINKER "/lib/ld.so.1"
+#define GLIBC_DYNAMIC_LINKER "/lib/ld.so.1"
diff -Naur '--exclude=*.swp' gcc-5.3.0-original/gcc/config/i386/linux64.h gcc-5.3.0-zip/gcc/config/i386/linux64.h
diff -Naur '--exclude=*.swp' gcc-5.3.0-original/gcc/config/i386/linux64.h gcc-5.3.0-zip/gcc/config/i386/linux64.h
--- gcc-5.3.0-original/gcc/config/i386/linux64.h        2016-04-06 17:56:01.475918570 -0400
--- gcc-5.3.0-original/gcc/config/i386/linux64.h        2016-04-11 22:20:22.143907624 -0400
+++ gcc-5.3.0-zip/gcc/config/i386/linux64.h     2015-01-05 07:33:28.000000000 -0500
+++ gcc-5.3.0-zip/gcc/config/i386/linux64.h     2015-01-05 07:33:28.000000000 -0500
@@ -27,6 +27,6 @@
@@ -27,6 +27,6 @@
 #define GNU_USER_LINK_EMULATION64 "elf_x86_64"
 #define GNU_USER_LINK_EMULATION64 "elf_x86_64"
 #define GNU_USER_LINK_EMULATIONX32 "elf32_x86_64"
 #define GNU_USER_LINK_EMULATIONX32 "elf32_x86_64"
 
 
Line 286... Line 286...
-#define GLIBC_DYNAMIC_LINKERX32 "/tools/libx32/ld-linux-x32.so.2"
-#define GLIBC_DYNAMIC_LINKERX32 "/tools/libx32/ld-linux-x32.so.2"
+#define GLIBC_DYNAMIC_LINKER32 "/lib/ld-linux.so.2"
+#define GLIBC_DYNAMIC_LINKER32 "/lib/ld-linux.so.2"
+#define GLIBC_DYNAMIC_LINKER64 "/lib64/ld-linux-x86-64.so.2"
+#define GLIBC_DYNAMIC_LINKER64 "/lib64/ld-linux-x86-64.so.2"
+#define GLIBC_DYNAMIC_LINKERX32 "/libx32/ld-linux-x32.so.2"
+#define GLIBC_DYNAMIC_LINKERX32 "/libx32/ld-linux-x32.so.2"
diff -Naur '--exclude=*.swp' gcc-5.3.0-original/gcc/config/i386/linux.h gcc-5.3.0-zip/gcc/config/i386/linux.h
diff -Naur '--exclude=*.swp' gcc-5.3.0-original/gcc/config/i386/linux.h gcc-5.3.0-zip/gcc/config/i386/linux.h
--- gcc-5.3.0-original/gcc/config/i386/linux.h  2016-04-06 17:56:01.475918570 -0400
--- gcc-5.3.0-original/gcc/config/i386/linux.h  2016-04-11 22:20:22.143907624 -0400
+++ gcc-5.3.0-zip/gcc/config/i386/linux.h       2015-01-05 07:33:28.000000000 -0500
+++ gcc-5.3.0-zip/gcc/config/i386/linux.h       2015-01-05 07:33:28.000000000 -0500
@@ -20,4 +20,4 @@
@@ -20,4 +20,4 @@
 <http://www.gnu.org/licenses/>.  */
 <http://www.gnu.org/licenses/>.  */
 
 
 #define GNU_USER_LINK_EMULATION "elf_i386"
 #define GNU_USER_LINK_EMULATION "elf_i386"
-#define GLIBC_DYNAMIC_LINKER "/tools/lib/ld-linux.so.2"
-#define GLIBC_DYNAMIC_LINKER "/tools/lib/ld-linux.so.2"
+#define GLIBC_DYNAMIC_LINKER "/lib/ld-linux.so.2"
+#define GLIBC_DYNAMIC_LINKER "/lib/ld-linux.so.2"
diff -Naur '--exclude=*.swp' gcc-5.3.0-original/gcc/config/ia64/linux.h gcc-5.3.0-zip/gcc/config/ia64/linux.h
diff -Naur '--exclude=*.swp' gcc-5.3.0-original/gcc/config/ia64/linux.h gcc-5.3.0-zip/gcc/config/ia64/linux.h
--- gcc-5.3.0-original/gcc/config/ia64/linux.h  2016-04-06 17:56:01.475918570 -0400
--- gcc-5.3.0-original/gcc/config/ia64/linux.h  2016-04-11 22:20:22.143907624 -0400
+++ gcc-5.3.0-zip/gcc/config/ia64/linux.h       2015-01-05 07:33:28.000000000 -0500
+++ gcc-5.3.0-zip/gcc/config/ia64/linux.h       2015-01-05 07:33:28.000000000 -0500
@@ -55,7 +55,7 @@
@@ -55,7 +55,7 @@
 /* Define this for shared library support because it isn't in the main
 /* Define this for shared library support because it isn't in the main
    linux.h file.  */
    linux.h file.  */
 
 
Line 307... Line 307...
+#define GLIBC_DYNAMIC_LINKER "/lib/ld-linux-ia64.so.2"
+#define GLIBC_DYNAMIC_LINKER "/lib/ld-linux-ia64.so.2"
 
 
 #undef LINK_SPEC
 #undef LINK_SPEC
 #define LINK_SPEC "\
 #define LINK_SPEC "\
diff -Naur '--exclude=*.swp' gcc-5.3.0-original/gcc/config/knetbsd-gnu.h gcc-5.3.0-zip/gcc/config/knetbsd-gnu.h
diff -Naur '--exclude=*.swp' gcc-5.3.0-original/gcc/config/knetbsd-gnu.h gcc-5.3.0-zip/gcc/config/knetbsd-gnu.h
--- gcc-5.3.0-original/gcc/config/knetbsd-gnu.h 2016-04-06 17:56:01.475918570 -0400
--- gcc-5.3.0-original/gcc/config/knetbsd-gnu.h 2016-04-11 22:20:22.143907624 -0400
+++ gcc-5.3.0-zip/gcc/config/knetbsd-gnu.h      2015-01-05 07:33:28.000000000 -0500
+++ gcc-5.3.0-zip/gcc/config/knetbsd-gnu.h      2015-01-05 07:33:28.000000000 -0500
@@ -32,4 +32,4 @@
@@ -32,4 +32,4 @@
 
 
 
 
 #undef GNU_USER_DYNAMIC_LINKER
 #undef GNU_USER_DYNAMIC_LINKER
-#define GNU_USER_DYNAMIC_LINKER "/tools/lib/ld.so.1"
-#define GNU_USER_DYNAMIC_LINKER "/tools/lib/ld.so.1"
+#define GNU_USER_DYNAMIC_LINKER "/lib/ld.so.1"
+#define GNU_USER_DYNAMIC_LINKER "/lib/ld.so.1"
diff -Naur '--exclude=*.swp' gcc-5.3.0-original/gcc/config/kopensolaris-gnu.h gcc-5.3.0-zip/gcc/config/kopensolaris-gnu.h
diff -Naur '--exclude=*.swp' gcc-5.3.0-original/gcc/config/kopensolaris-gnu.h gcc-5.3.0-zip/gcc/config/kopensolaris-gnu.h
--- gcc-5.3.0-original/gcc/config/kopensolaris-gnu.h    2016-04-06 17:56:01.475918570 -0400
--- gcc-5.3.0-original/gcc/config/kopensolaris-gnu.h    2016-04-11 22:20:22.143907624 -0400
+++ gcc-5.3.0-zip/gcc/config/kopensolaris-gnu.h 2015-01-05 07:33:28.000000000 -0500
+++ gcc-5.3.0-zip/gcc/config/kopensolaris-gnu.h 2015-01-05 07:33:28.000000000 -0500
@@ -31,5 +31,4 @@
@@ -31,5 +31,4 @@
   while (0)
   while (0)
 
 
 #undef GNU_USER_DYNAMIC_LINKER
 #undef GNU_USER_DYNAMIC_LINKER
-#define GNU_USER_DYNAMIC_LINKER "/tools/lib/ld.so.1"
-#define GNU_USER_DYNAMIC_LINKER "/tools/lib/ld.so.1"
-
-
+#define GNU_USER_DYNAMIC_LINKER "/lib/ld.so.1"
+#define GNU_USER_DYNAMIC_LINKER "/lib/ld.so.1"
diff -Naur '--exclude=*.swp' gcc-5.3.0-original/gcc/config/linux.h gcc-5.3.0-zip/gcc/config/linux.h
diff -Naur '--exclude=*.swp' gcc-5.3.0-original/gcc/config/linux.h gcc-5.3.0-zip/gcc/config/linux.h
--- gcc-5.3.0-original/gcc/config/linux.h       2016-04-06 17:56:01.475918570 -0400
--- gcc-5.3.0-original/gcc/config/linux.h       2016-04-11 22:20:22.143907624 -0400
+++ gcc-5.3.0-zip/gcc/config/linux.h    2015-01-05 07:33:28.000000000 -0500
+++ gcc-5.3.0-zip/gcc/config/linux.h    2015-01-05 07:33:28.000000000 -0500
@@ -73,10 +73,10 @@
@@ -73,10 +73,10 @@
    GLIBC_DYNAMIC_LINKER must be defined for each target using them, or
    GLIBC_DYNAMIC_LINKER must be defined for each target using them, or
    GLIBC_DYNAMIC_LINKER32 and GLIBC_DYNAMIC_LINKER64 for targets
    GLIBC_DYNAMIC_LINKER32 and GLIBC_DYNAMIC_LINKER64 for targets
    supporting both 32-bit and 64-bit compilation.  */
    supporting both 32-bit and 64-bit compilation.  */
Line 344... Line 344...
+#define UCLIBC_DYNAMIC_LINKERX32 "/lib/ldx32-uClibc.so.0"
+#define UCLIBC_DYNAMIC_LINKERX32 "/lib/ldx32-uClibc.so.0"
 #define BIONIC_DYNAMIC_LINKER "/system/bin/linker"
 #define BIONIC_DYNAMIC_LINKER "/system/bin/linker"
 #define BIONIC_DYNAMIC_LINKER32 "/system/bin/linker"
 #define BIONIC_DYNAMIC_LINKER32 "/system/bin/linker"
 #define BIONIC_DYNAMIC_LINKER64 "/system/bin/linker64"
 #define BIONIC_DYNAMIC_LINKER64 "/system/bin/linker64"
diff -Naur '--exclude=*.swp' gcc-5.3.0-original/gcc/config/lm32/uclinux-elf.h gcc-5.3.0-zip/gcc/config/lm32/uclinux-elf.h
diff -Naur '--exclude=*.swp' gcc-5.3.0-original/gcc/config/lm32/uclinux-elf.h gcc-5.3.0-zip/gcc/config/lm32/uclinux-elf.h
--- gcc-5.3.0-original/gcc/config/lm32/uclinux-elf.h    2016-04-06 17:56:01.475918570 -0400
--- gcc-5.3.0-original/gcc/config/lm32/uclinux-elf.h    2016-04-11 22:20:22.143907624 -0400
+++ gcc-5.3.0-zip/gcc/config/lm32/uclinux-elf.h 2015-01-05 07:33:28.000000000 -0500
+++ gcc-5.3.0-zip/gcc/config/lm32/uclinux-elf.h 2015-01-05 07:33:28.000000000 -0500
@@ -67,7 +67,7 @@
@@ -67,7 +67,7 @@
    %{shared:-shared} \
    %{shared:-shared} \
    %{symbolic:-Bsymbolic} \
    %{symbolic:-Bsymbolic} \
    %{rdynamic:-export-dynamic} \
    %{rdynamic:-export-dynamic} \
Line 356... Line 356...
+   -dynamic-linker /lib/ld-linux.so.2"
+   -dynamic-linker /lib/ld-linux.so.2"
 
 
 #define TARGET_OS_CPP_BUILTINS() GNU_USER_TARGET_OS_CPP_BUILTINS()
 #define TARGET_OS_CPP_BUILTINS() GNU_USER_TARGET_OS_CPP_BUILTINS()
 
 
diff -Naur '--exclude=*.swp' gcc-5.3.0-original/gcc/config/m68k/linux.h gcc-5.3.0-zip/gcc/config/m68k/linux.h
diff -Naur '--exclude=*.swp' gcc-5.3.0-original/gcc/config/m68k/linux.h gcc-5.3.0-zip/gcc/config/m68k/linux.h
--- gcc-5.3.0-original/gcc/config/m68k/linux.h  2016-04-06 17:56:01.475918570 -0400
--- gcc-5.3.0-original/gcc/config/m68k/linux.h  2016-04-11 22:20:22.143907624 -0400
+++ gcc-5.3.0-zip/gcc/config/m68k/linux.h       2015-01-05 07:33:28.000000000 -0500
+++ gcc-5.3.0-zip/gcc/config/m68k/linux.h       2015-01-05 07:33:28.000000000 -0500
@@ -71,7 +71,7 @@
@@ -71,7 +71,7 @@
    When the -shared link option is used a final link is not being
    When the -shared link option is used a final link is not being
    done.  */
    done.  */
 
 
Line 368... Line 368...
+#define GLIBC_DYNAMIC_LINKER "/lib/ld.so.1"
+#define GLIBC_DYNAMIC_LINKER "/lib/ld.so.1"
 
 
 #undef LINK_SPEC
 #undef LINK_SPEC
 #define LINK_SPEC "-m m68kelf %{shared} \
 #define LINK_SPEC "-m m68kelf %{shared} \
diff -Naur '--exclude=*.swp' gcc-5.3.0-original/gcc/config/microblaze/linux.h gcc-5.3.0-zip/gcc/config/microblaze/linux.h
diff -Naur '--exclude=*.swp' gcc-5.3.0-original/gcc/config/microblaze/linux.h gcc-5.3.0-zip/gcc/config/microblaze/linux.h
--- gcc-5.3.0-original/gcc/config/microblaze/linux.h    2016-04-06 17:56:01.475918570 -0400
--- gcc-5.3.0-original/gcc/config/microblaze/linux.h    2016-04-11 22:20:22.143907624 -0400
+++ gcc-5.3.0-zip/gcc/config/microblaze/linux.h 2015-05-28 10:08:19.000000000 -0400
+++ gcc-5.3.0-zip/gcc/config/microblaze/linux.h 2015-05-28 10:08:19.000000000 -0400
@@ -28,7 +28,7 @@
@@ -28,7 +28,7 @@
 #undef TLS_NEEDS_GOT
 #undef TLS_NEEDS_GOT
 #define TLS_NEEDS_GOT 1
 #define TLS_NEEDS_GOT 1
 
 
Line 380... Line 380...
+#define DYNAMIC_LINKER "/lib/ld.so.1"
+#define DYNAMIC_LINKER "/lib/ld.so.1"
 #undef  SUBTARGET_EXTRA_SPECS
 #undef  SUBTARGET_EXTRA_SPECS
 #define SUBTARGET_EXTRA_SPECS \
 #define SUBTARGET_EXTRA_SPECS \
   { "dynamic_linker", DYNAMIC_LINKER }
   { "dynamic_linker", DYNAMIC_LINKER }
diff -Naur '--exclude=*.swp' gcc-5.3.0-original/gcc/config/mips/linux.h gcc-5.3.0-zip/gcc/config/mips/linux.h
diff -Naur '--exclude=*.swp' gcc-5.3.0-original/gcc/config/mips/linux.h gcc-5.3.0-zip/gcc/config/mips/linux.h
--- gcc-5.3.0-original/gcc/config/mips/linux.h  2016-04-06 17:56:01.479918541 -0400
--- gcc-5.3.0-original/gcc/config/mips/linux.h  2016-04-11 22:20:22.143907624 -0400
+++ gcc-5.3.0-zip/gcc/config/mips/linux.h       2015-01-05 07:33:28.000000000 -0500
+++ gcc-5.3.0-zip/gcc/config/mips/linux.h       2015-01-05 07:33:28.000000000 -0500
@@ -22,20 +22,20 @@
@@ -22,20 +22,20 @@
 #define GNU_USER_LINK_EMULATIONN32 "elf32%{EB:b}%{EL:l}tsmipn32"
 #define GNU_USER_LINK_EMULATIONN32 "elf32%{EB:b}%{EL:l}tsmipn32"
 
 
 #define GLIBC_DYNAMIC_LINKER32 \
 #define GLIBC_DYNAMIC_LINKER32 \
Line 410... Line 410...
+  "%{mnan=2008:/lib32/ld-uClibc-mipsn8.so.0;:/lib32/ld-uClibc.so.0}"
+  "%{mnan=2008:/lib32/ld-uClibc-mipsn8.so.0;:/lib32/ld-uClibc.so.0}"
 
 
 #define BIONIC_DYNAMIC_LINKERN32 "/system/bin/linker32"
 #define BIONIC_DYNAMIC_LINKERN32 "/system/bin/linker32"
 #define GNU_USER_DYNAMIC_LINKERN32 \
 #define GNU_USER_DYNAMIC_LINKERN32 \
diff -Naur '--exclude=*.swp' gcc-5.3.0-original/gcc/config/mn10300/linux.h gcc-5.3.0-zip/gcc/config/mn10300/linux.h
diff -Naur '--exclude=*.swp' gcc-5.3.0-original/gcc/config/mn10300/linux.h gcc-5.3.0-zip/gcc/config/mn10300/linux.h
--- gcc-5.3.0-original/gcc/config/mn10300/linux.h       2016-04-06 17:56:01.479918541 -0400
--- gcc-5.3.0-original/gcc/config/mn10300/linux.h       2016-04-11 22:20:22.143907624 -0400
+++ gcc-5.3.0-zip/gcc/config/mn10300/linux.h    2015-01-05 07:33:28.000000000 -0500
+++ gcc-5.3.0-zip/gcc/config/mn10300/linux.h    2015-01-05 07:33:28.000000000 -0500
@@ -32,7 +32,7 @@
@@ -32,7 +32,7 @@
 #undef  ASM_SPEC
 #undef  ASM_SPEC
 #define ASM_SPEC ""
 #define ASM_SPEC ""
 
 
Line 422... Line 422...
+#define GLIBC_DYNAMIC_LINKER "/lib/ld.so.1"
+#define GLIBC_DYNAMIC_LINKER "/lib/ld.so.1"
 
 
 #undef  LINK_SPEC
 #undef  LINK_SPEC
 #define LINK_SPEC "%{mrelax:--relax} %{shared:-shared} \
 #define LINK_SPEC "%{mrelax:--relax} %{shared:-shared} \
diff -Naur '--exclude=*.swp' gcc-5.3.0-original/gcc/config/pa/pa-linux.h gcc-5.3.0-zip/gcc/config/pa/pa-linux.h
diff -Naur '--exclude=*.swp' gcc-5.3.0-original/gcc/config/pa/pa-linux.h gcc-5.3.0-zip/gcc/config/pa/pa-linux.h
--- gcc-5.3.0-original/gcc/config/pa/pa-linux.h 2016-04-06 17:56:01.479918541 -0400
--- gcc-5.3.0-original/gcc/config/pa/pa-linux.h 2016-04-11 22:20:22.143907624 -0400
+++ gcc-5.3.0-zip/gcc/config/pa/pa-linux.h      2015-09-24 20:04:26.000000000 -0400
+++ gcc-5.3.0-zip/gcc/config/pa/pa-linux.h      2015-09-24 20:04:26.000000000 -0400
@@ -37,7 +37,7 @@
@@ -37,7 +37,7 @@
 /* Define this for shared library support because it isn't in the main
 /* Define this for shared library support because it isn't in the main
    linux.h file.  */
    linux.h file.  */
 
 
Line 434... Line 434...
+#define GLIBC_DYNAMIC_LINKER "/lib/ld.so.1"
+#define GLIBC_DYNAMIC_LINKER "/lib/ld.so.1"
 
 
 #undef LINK_SPEC
 #undef LINK_SPEC
 #define LINK_SPEC "\
 #define LINK_SPEC "\
diff -Naur '--exclude=*.swp' gcc-5.3.0-original/gcc/config/rs6000/linux64.h gcc-5.3.0-zip/gcc/config/rs6000/linux64.h
diff -Naur '--exclude=*.swp' gcc-5.3.0-original/gcc/config/rs6000/linux64.h gcc-5.3.0-zip/gcc/config/rs6000/linux64.h
--- gcc-5.3.0-original/gcc/config/rs6000/linux64.h      2016-04-06 17:56:01.479918541 -0400
--- gcc-5.3.0-original/gcc/config/rs6000/linux64.h      2016-04-11 22:20:22.143907624 -0400
+++ gcc-5.3.0-zip/gcc/config/rs6000/linux64.h   2015-03-09 19:18:57.000000000 -0400
+++ gcc-5.3.0-zip/gcc/config/rs6000/linux64.h   2015-03-09 19:18:57.000000000 -0400
@@ -357,14 +357,14 @@
@@ -357,14 +357,14 @@
 #undef LINK_OS_DEFAULT_SPEC
 #undef LINK_OS_DEFAULT_SPEC
 #define LINK_OS_DEFAULT_SPEC "%(link_os_linux)"
 #define LINK_OS_DEFAULT_SPEC "%(link_os_linux)"
 
 
Line 457... Line 457...
+#define UCLIBC_DYNAMIC_LINKER64 "/lib/ld64-uClibc.so.0"
+#define UCLIBC_DYNAMIC_LINKER64 "/lib/ld64-uClibc.so.0"
 #if DEFAULT_LIBC == LIBC_UCLIBC
 #if DEFAULT_LIBC == LIBC_UCLIBC
 #define CHOOSE_DYNAMIC_LINKER(G, U) "%{mglibc:" G ";:" U "}"
 #define CHOOSE_DYNAMIC_LINKER(G, U) "%{mglibc:" G ";:" U "}"
 #elif DEFAULT_LIBC == LIBC_GLIBC
 #elif DEFAULT_LIBC == LIBC_GLIBC
diff -Naur '--exclude=*.swp' gcc-5.3.0-original/gcc/config/rs6000/sysv4.h gcc-5.3.0-zip/gcc/config/rs6000/sysv4.h
diff -Naur '--exclude=*.swp' gcc-5.3.0-original/gcc/config/rs6000/sysv4.h gcc-5.3.0-zip/gcc/config/rs6000/sysv4.h
--- gcc-5.3.0-original/gcc/config/rs6000/sysv4.h        2016-04-06 17:56:01.479918541 -0400
--- gcc-5.3.0-original/gcc/config/rs6000/sysv4.h        2016-04-11 22:20:22.143907624 -0400
+++ gcc-5.3.0-zip/gcc/config/rs6000/sysv4.h     2015-09-24 09:46:45.000000000 -0400
+++ gcc-5.3.0-zip/gcc/config/rs6000/sysv4.h     2015-09-24 09:46:45.000000000 -0400
@@ -757,8 +757,8 @@
@@ -757,8 +757,8 @@
 
 
 #define LINK_START_LINUX_SPEC ""
 #define LINK_START_LINUX_SPEC ""
 
 
Line 471... Line 471...
+#define UCLIBC_DYNAMIC_LINKER "/lib/ld-uClibc.so.0"
+#define UCLIBC_DYNAMIC_LINKER "/lib/ld-uClibc.so.0"
 #if DEFAULT_LIBC == LIBC_UCLIBC
 #if DEFAULT_LIBC == LIBC_UCLIBC
 #define CHOOSE_DYNAMIC_LINKER(G, U) "%{mglibc:" G ";:" U "}"
 #define CHOOSE_DYNAMIC_LINKER(G, U) "%{mglibc:" G ";:" U "}"
 #elif !defined (DEFAULT_LIBC) || DEFAULT_LIBC == LIBC_GLIBC
 #elif !defined (DEFAULT_LIBC) || DEFAULT_LIBC == LIBC_GLIBC
diff -Naur '--exclude=*.swp' gcc-5.3.0-original/gcc/config/s390/linux.h gcc-5.3.0-zip/gcc/config/s390/linux.h
diff -Naur '--exclude=*.swp' gcc-5.3.0-original/gcc/config/s390/linux.h gcc-5.3.0-zip/gcc/config/s390/linux.h
--- gcc-5.3.0-original/gcc/config/s390/linux.h  2016-04-06 17:56:01.479918541 -0400
--- gcc-5.3.0-original/gcc/config/s390/linux.h  2016-04-11 22:20:22.143907624 -0400
+++ gcc-5.3.0-zip/gcc/config/s390/linux.h       2015-05-11 03:14:10.000000000 -0400
+++ gcc-5.3.0-zip/gcc/config/s390/linux.h       2015-05-11 03:14:10.000000000 -0400
@@ -60,8 +60,8 @@
@@ -60,8 +60,8 @@
 #define MULTILIB_DEFAULTS { "m31" }
 #define MULTILIB_DEFAULTS { "m31" }
 #endif
 #endif
 
 
Line 485... Line 485...
+#define GLIBC_DYNAMIC_LINKER64 "/lib/ld64.so.1"
+#define GLIBC_DYNAMIC_LINKER64 "/lib/ld64.so.1"
 
 
 #undef  LINK_SPEC
 #undef  LINK_SPEC
 #define LINK_SPEC \
 #define LINK_SPEC \
diff -Naur '--exclude=*.swp' gcc-5.3.0-original/gcc/config/sh/linux.h gcc-5.3.0-zip/gcc/config/sh/linux.h
diff -Naur '--exclude=*.swp' gcc-5.3.0-original/gcc/config/sh/linux.h gcc-5.3.0-zip/gcc/config/sh/linux.h
--- gcc-5.3.0-original/gcc/config/sh/linux.h    2016-04-06 17:56:01.479918541 -0400
--- gcc-5.3.0-original/gcc/config/sh/linux.h    2016-04-11 22:20:22.143907624 -0400
+++ gcc-5.3.0-zip/gcc/config/sh/linux.h 2015-01-05 07:33:28.000000000 -0500
+++ gcc-5.3.0-zip/gcc/config/sh/linux.h 2015-01-05 07:33:28.000000000 -0500
@@ -43,7 +43,7 @@
@@ -43,7 +43,7 @@
 
 
 #define TARGET_ASM_FILE_END file_end_indicate_exec_stack
 #define TARGET_ASM_FILE_END file_end_indicate_exec_stack
 
 
Line 497... Line 497...
+#define GLIBC_DYNAMIC_LINKER "/lib/ld-linux.so.2"
+#define GLIBC_DYNAMIC_LINKER "/lib/ld-linux.so.2"
 
 
 #undef SUBTARGET_LINK_EMUL_SUFFIX
 #undef SUBTARGET_LINK_EMUL_SUFFIX
 #define SUBTARGET_LINK_EMUL_SUFFIX "_linux"
 #define SUBTARGET_LINK_EMUL_SUFFIX "_linux"
diff -Naur '--exclude=*.swp' gcc-5.3.0-original/gcc/config/sparc/linux64.h gcc-5.3.0-zip/gcc/config/sparc/linux64.h
diff -Naur '--exclude=*.swp' gcc-5.3.0-original/gcc/config/sparc/linux64.h gcc-5.3.0-zip/gcc/config/sparc/linux64.h
--- gcc-5.3.0-original/gcc/config/sparc/linux64.h       2016-04-06 17:56:01.479918541 -0400
--- gcc-5.3.0-original/gcc/config/sparc/linux64.h       2016-04-11 22:20:22.143907624 -0400
+++ gcc-5.3.0-zip/gcc/config/sparc/linux64.h    2015-01-05 07:33:28.000000000 -0500
+++ gcc-5.3.0-zip/gcc/config/sparc/linux64.h    2015-01-05 07:33:28.000000000 -0500
@@ -84,8 +84,8 @@
@@ -84,8 +84,8 @@
    When the -shared link option is used a final link is not being
    When the -shared link option is used a final link is not being
    done.  */
    done.  */
 
 
Line 520... Line 520...
+#define LINK_SPEC "-m elf64_sparc -Y P,%R/usr/lib64 %{shared:-shared} \
+#define LINK_SPEC "-m elf64_sparc -Y P,%R/usr/lib64 %{shared:-shared} \
   %{!shared: \
   %{!shared: \
     %{!static: \
     %{!static: \
       %{rdynamic:-export-dynamic} \
       %{rdynamic:-export-dynamic} \
diff -Naur '--exclude=*.swp' gcc-5.3.0-original/gcc/config/sparc/linux.h gcc-5.3.0-zip/gcc/config/sparc/linux.h
diff -Naur '--exclude=*.swp' gcc-5.3.0-original/gcc/config/sparc/linux.h gcc-5.3.0-zip/gcc/config/sparc/linux.h
--- gcc-5.3.0-original/gcc/config/sparc/linux.h 2016-04-06 17:56:01.479918541 -0400
--- gcc-5.3.0-original/gcc/config/sparc/linux.h 2016-04-11 22:20:22.143907624 -0400
+++ gcc-5.3.0-zip/gcc/config/sparc/linux.h      2015-01-05 07:33:28.000000000 -0500
+++ gcc-5.3.0-zip/gcc/config/sparc/linux.h      2015-01-05 07:33:28.000000000 -0500
@@ -83,7 +83,7 @@
@@ -83,7 +83,7 @@
    When the -shared link option is used a final link is not being
    When the -shared link option is used a final link is not being
    done.  */
    done.  */
 
 
Line 532... Line 532...
+#define GLIBC_DYNAMIC_LINKER "/lib/ld-linux.so.2"
+#define GLIBC_DYNAMIC_LINKER "/lib/ld-linux.so.2"
 
 
 #undef  LINK_SPEC
 #undef  LINK_SPEC
 #define LINK_SPEC "-m elf32_sparc %{shared:-shared} \
 #define LINK_SPEC "-m elf32_sparc %{shared:-shared} \
diff -Naur '--exclude=*.swp' gcc-5.3.0-original/gcc/config/vax/linux.h gcc-5.3.0-zip/gcc/config/vax/linux.h
diff -Naur '--exclude=*.swp' gcc-5.3.0-original/gcc/config/vax/linux.h gcc-5.3.0-zip/gcc/config/vax/linux.h
--- gcc-5.3.0-original/gcc/config/vax/linux.h   2016-04-06 17:56:01.479918541 -0400
--- gcc-5.3.0-original/gcc/config/vax/linux.h   2016-04-11 22:20:22.147907567 -0400
+++ gcc-5.3.0-zip/gcc/config/vax/linux.h        2015-01-05 07:33:28.000000000 -0500
+++ gcc-5.3.0-zip/gcc/config/vax/linux.h        2015-01-05 07:33:28.000000000 -0500
@@ -41,7 +41,7 @@
@@ -41,7 +41,7 @@
   %{!shared: \
   %{!shared: \
     %{!static: \
     %{!static: \
       %{rdynamic:-export-dynamic} \
       %{rdynamic:-export-dynamic} \
Line 544... Line 544...
+      -dynamic-linker /lib/ld.so.1} \
+      -dynamic-linker /lib/ld.so.1} \
     %{static:-static}}"
     %{static:-static}}"
 
 
 #undef  WCHAR_TYPE
 #undef  WCHAR_TYPE
diff -Naur '--exclude=*.swp' gcc-5.3.0-original/gcc/config/xtensa/linux.h gcc-5.3.0-zip/gcc/config/xtensa/linux.h
diff -Naur '--exclude=*.swp' gcc-5.3.0-original/gcc/config/xtensa/linux.h gcc-5.3.0-zip/gcc/config/xtensa/linux.h
--- gcc-5.3.0-original/gcc/config/xtensa/linux.h        2016-04-06 17:56:01.479918541 -0400
--- gcc-5.3.0-original/gcc/config/xtensa/linux.h        2016-04-11 22:20:22.147907567 -0400
+++ gcc-5.3.0-zip/gcc/config/xtensa/linux.h     2015-01-05 07:33:28.000000000 -0500
+++ gcc-5.3.0-zip/gcc/config/xtensa/linux.h     2015-01-05 07:33:28.000000000 -0500
@@ -44,7 +44,7 @@
@@ -44,7 +44,7 @@
   %{mlongcalls:--longcalls} \
   %{mlongcalls:--longcalls} \
   %{mno-longcalls:--no-longcalls}"
   %{mno-longcalls:--no-longcalls}"
 
 
Line 694... Line 694...
+       # cat $(srcdir)/config/fp-bit.c >> fp-bit.c
+       # cat $(srcdir)/config/fp-bit.c >> fp-bit.c
+
+
+
+
diff -Naur '--exclude=*.swp' gcc-5.3.0-original/gcc/config/zip/zip.c gcc-5.3.0-zip/gcc/config/zip/zip.c
diff -Naur '--exclude=*.swp' gcc-5.3.0-original/gcc/config/zip/zip.c gcc-5.3.0-zip/gcc/config/zip/zip.c
--- gcc-5.3.0-original/gcc/config/zip/zip.c     1969-12-31 19:00:00.000000000 -0500
--- gcc-5.3.0-original/gcc/config/zip/zip.c     1969-12-31 19:00:00.000000000 -0500
+++ gcc-5.3.0-zip/gcc/config/zip/zip.c  2016-04-06 17:47:47.255349663 -0400
+++ gcc-5.3.0-zip/gcc/config/zip/zip.c  2016-04-07 16:23:35.651592937 -0400
@@ -0,0 +1,2099 @@
@@ -0,0 +1,2126 @@
+////////////////////////////////////////////////////////////////////////////////
+////////////////////////////////////////////////////////////////////////////////
+//
+//
+// Filename:   zip.c
+// Filename:   zip.c
+//
+//
+// Project:    Zip CPU backend for the GNU Compiler Collection
+// Project:    Zip CPU backend for the GNU Compiler Collection
Line 1118... Line 1118...
+ * prologue and epilogue.
+ * prologue and epilogue.
+ *
+ *
+ * Here's what we are looking at (top is the current, bottom is the last ...)
+ * Here's what we are looking at (top is the current, bottom is the last ...)
+ *
+ *
+ *     Stack Pointer ->
+ *     Stack Pointer ->
 
+ *                     Outgoing arguments
+ *                     Local variables (could be variable size)
+ *                     Local variables (could be variable size)
+ *     Frame Pointer ->        (= Stack Pointer + sp_fp_offset)
+ *     Frame Pointer ->        (= Stack Pointer + sp_fp_offset)
+ *                     Saved return address, if saved
+ *                     Saved return address, if saved
+ *                     Other Saved registers
+ *                     Other Saved registers
+ *                     Saved frame pointer (if used)
+ *                     Saved frame pointer (if used)
Line 1135... Line 1136...
+ */
+ */
+static void
+static void
+zip_compute_frame(void) {
+zip_compute_frame(void) {
+       int     regno;
+       int     regno;
+       int     args_size;
+       int     args_size;
 
+       const bool      dbg = ((ALL_DEBUG_ON)||(false))&&(!ALL_DEBUG_OFF);
+
+
 
+       if (dbg) fprintf(stderr, "ZIP-COMPUTE-FRAME\n");
+       // gcc_assert(crtl);
+       // gcc_assert(crtl);
+       gcc_assert(cfun);
+       gcc_assert(cfun);
+       gcc_assert(cfun->machine);
+       gcc_assert(cfun->machine);
+
+
+       args_size=(ACCUMULATE_OUTGOING_ARGS ? crtl->outgoing_args_size : 0);
+       args_size=(ACCUMULATE_OUTGOING_ARGS ? crtl->outgoing_args_size : 0);
Line 1169... Line 1172...
+
+
+       cfun->machine->sp_fp_offset = args_size + cfun->machine->local_vars_size;
+       cfun->machine->sp_fp_offset = args_size + cfun->machine->local_vars_size;
+       cfun->machine->size_for_adjusting_sp = cfun->machine->local_vars_size
+       cfun->machine->size_for_adjusting_sp = cfun->machine->local_vars_size
+                       + cfun->machine->saved_reg_size
+                       + cfun->machine->saved_reg_size
+                       + args_size;
+                       + args_size;
+
+       if(dbg) {
 
+               fprintf(stderr, "\tFRAME-POINTR: %s\n",
 
+                       cfun->machine->fp_needed?"Yes":"No");
 
+               fprintf(stderr, "\tARGS-SIZE   : %d\n",
 
+                       args_size);
 
+               fprintf(stderr, "\tLOCALS-SIZE : %d\n",
 
+                       cfun->machine->local_vars_size);
 
+               fprintf(stderr, "\tREGISTERS   : %d\n",
 
+                       cfun->machine->saved_reg_size);
 
+               fprintf(stderr, "\tSP_FP_OFFSET: %d\n",
 
+                       cfun->machine->sp_fp_offset);
 
+               fprintf(stderr, "\tSP-ADJUSTMNT: %d\n",
 
+                       cfun->machine->size_for_adjusting_sp);
 
+       }
+}
+}
+
+
+void
+void
+zip_expand_prologue(void) {
+zip_expand_prologue(void) {
+       rtx     insn;
+       rtx     insn;
+
+
+       const bool      dbg = ((ALL_DEBUG_ON)||(false))&&(!ALL_DEBUG_OFF);
+       const bool      dbg = ((ALL_DEBUG_ON)||(false))&&(!ALL_DEBUG_OFF);
+       zip_compute_frame();
+       zip_compute_frame();
+
+
+       if (dbg)  fprintf(stderr, "Computing Prologue instructions\n");
+       if (dbg)  fprintf(stderr, "PROLOGUE: Computing Prologue instructions\n");
+       if (cfun->machine->size_for_adjusting_sp != 0) {
+       if (cfun->machine->size_for_adjusting_sp != 0) {
+               insn = emit_insn(gen_subsi3(stack_pointer_rtx,
+               insn = emit_insn(gen_subsi3(stack_pointer_rtx,
+                               stack_pointer_rtx,
+                               stack_pointer_rtx,
+                       gen_int_mode(cfun->machine->size_for_adjusting_sp,
+                       gen_int_mode(cfun->machine->size_for_adjusting_sp,
+                               SImode)));
+                               SImode)));
Line 1194... Line 1210...
+
+
+       {
+       {
+               int offset = 0, regno;
+               int offset = 0, regno;
+               for(regno=0; regno < FIRST_PSEUDO_REGISTER; regno++) {
+               for(regno=0; regno < FIRST_PSEUDO_REGISTER; regno++) {
+                       if (zip_save_reg(regno)) {
+                       if (zip_save_reg(regno)) {
+                               insn=emit_insn(gen_movsi_sto(
+                               insn=emit_insn(gen_movsi_sto_off(
+                                       gen_rtx_MEM(SImode, plus_constant(
+                                       stack_pointer_rtx,
+                                               Pmode, stack_pointer_rtx,
+                                       GEN_INT(cfun->machine->sp_fp_offset
+                                               cfun->machine->sp_fp_offset
+                                               +offset++),
+                                               +offset++, true)),
 
+                                       gen_rtx_REG(SImode, regno)));
+                                       gen_rtx_REG(SImode, regno)));
+                               RTX_FRAME_RELATED_P(insn) = 1;
+                               RTX_FRAME_RELATED_P(insn) = 1;
+                       }
+                       }
+               }
+               }
+               if (dbg)  fprintf(stderr, "%d registers saved%s\n", offset,
+               if (dbg)  fprintf(stderr, "%d registers saved%s\n", offset,
Line 1211... Line 1226...
+
+
+       if (cfun->machine->fp_needed) {
+       if (cfun->machine->fp_needed) {
+               if (dbg) zip_debug_rtx(stack_pointer_rtx);
+               if (dbg) zip_debug_rtx(stack_pointer_rtx);
+               if (dbg) zip_debug_rtx(frame_pointer_rtx);
+               if (dbg) zip_debug_rtx(frame_pointer_rtx);
+               insn = emit_insn(gen_movsi_reg_off(frame_pointer_rtx,
+               insn = emit_insn(gen_movsi_reg_off(frame_pointer_rtx,
+                               stack_pointer_rtx, gen_int_mode(
+                               stack_pointer_rtx,
+                                               cfun->machine->sp_fp_offset,
+                               GEN_INT(cfun->machine->sp_fp_offset)));
+                                               SImode)));
 
+               RTX_FRAME_RELATED_P(insn) = 1;
+               RTX_FRAME_RELATED_P(insn) = 1;
+               if (dbg)  fprintf(stderr, "sp_fp_offset is %d\n", cfun->machine->sp_fp_offset);
+               if (dbg)  fprintf(stderr, "sp_fp_offset is %d\n", cfun->machine->sp_fp_offset);
+       }
+       }
+}
+}
+
+
Line 1278... Line 1292...
+
+
+       zip_compute_frame();
+       zip_compute_frame();
+
+
+       if (dbg) fprintf(stderr, "EPILOG::\n");
+       if (dbg) fprintf(stderr, "EPILOG::\n");
+       if (cfun->machine->fp_needed) {
+       if (cfun->machine->fp_needed) {
 
+               // This is done special--if you can't trust the stack pointer
 
+               // enough so that you must have a frame pointer, then you can't
 
+               // trust its offset enough to restore from it.  Hence, we start
 
+               // by moving the frame pointer to the stack pointer to recover
 
+               // the stack pointer back to a usable value.
+               if (dbg) fprintf(stderr, "EPILOG::Moving frame pointer to stack register\n");
+               if (dbg) fprintf(stderr, "EPILOG::Moving frame pointer to stack register\n");
+               emit_insn(gen_movsi_reg(stack_pointer_rtx, frame_pointer_rtx));
+               emit_insn(gen_movsi_reg(stack_pointer_rtx, frame_pointer_rtx));
+       }
+       }
+
+
+       if (cfun->machine->saved_reg_size != 0) {
+       if (cfun->machine->saved_reg_size != 0) {
+               offset =  (cfun->machine->size_for_adjusting_sp -
+               if (cfun->machine->fp_needed)
+                               cfun->machine->sp_fp_offset
+                       offset = 0;
+                       - cfun->machine->saved_reg_size);
+               else
 
+                       offset = cfun->machine->sp_fp_offset;
+               if (dbg) fprintf(stderr, "EPILOG::Saved_REG_Size = %d\n", cfun->machine->saved_reg_size);
+               if (dbg) fprintf(stderr, "EPILOG::Saved_REG_Size = %d\n", cfun->machine->saved_reg_size);
+               for(regno=0; regno < FIRST_PSEUDO_REGISTER; regno++) {
+               for(regno=0; regno < FIRST_PSEUDO_REGISTER; regno++) {
+                       if (zip_save_reg(regno)) {
+                       if (zip_save_reg(regno)) {
+                               if (dbg) fprintf(stderr, "EPILOG::RESTORING R%d\n", regno);
+                               if (dbg) fprintf(stderr, "EPILOG::RESTORING R%d\n", regno);
+                               emit_insn(gen_movsi_lod(
+                               emit_insn(gen_movsi_lod_off(
+                                               gen_rtx_REG(SImode, regno),
+                                               gen_rtx_REG(SImode, regno),
+                                       gen_rtx_MEM(SImode, plus_constant( SImode,
+                                               stack_pointer_rtx,
+                                               stack_pointer_rtx, offset++, true))));
+                                               GEN_INT(offset++)));
+                       }
+                       }
+               }
+               }
+       }
+       }
+
+
+       if (cfun->machine->size_for_adjusting_sp != 0) {
+       if (cfun->machine->fp_needed) {
 
+               // Restore the stack pointer back to the original, the
 
+               // difference being the difference from the frame pointer
 
+               // to the original stack
 
+               emit_insn(gen_addsi3(stack_pointer_rtx, stack_pointer_rtx,
 
+                       GEN_INT(cfun->machine->size_for_adjusting_sp
 
+                               -cfun->machine->sp_fp_offset)));
 
+       } else {
 
+               // else now the difference is between the stack pointer and
 
+               // the original stack pointer.
+               if (dbg) fprintf(stderr, "EPILOG::ADDSI3(StackPtr, %d)\n",
+               if (dbg) fprintf(stderr, "EPILOG::ADDSI3(StackPtr, %d)\n",
+                               cfun->machine->size_for_adjusting_sp);
+                               cfun->machine->size_for_adjusting_sp);
+               emit_insn(gen_addsi3(stack_pointer_rtx, stack_pointer_rtx,
+               emit_insn(gen_addsi3(stack_pointer_rtx, stack_pointer_rtx,
+                       gen_int_mode(
+                       GEN_INT(cfun->machine->size_for_adjusting_sp)));
+                               cfun->machine->size_for_adjusting_sp
 
+                               -cfun->machine->sp_fp_offset, SImode)));
 
+       }
+       }
+       if (dbg) fprintf(stderr, "EPILOG::EMITTING-RETURN\n");
+       if (dbg) fprintf(stderr, "EPILOG::EMITTING-RETURN\n");
+
+
+       emit_jump_insn(ret_rtx);
+       emit_jump_insn(ret_rtx);
+}
+}
Line 2297... Line 2324...
+       if (!zip_legitimate_opb(x, strict))
+       if (!zip_legitimate_opb(x, strict))
+               return false;
+               return false;
+       else if ((GET_CODE(x)==PLUS)&&(CONST_INT_P(XEXP(x,1)))) {
+       else if ((GET_CODE(x)==PLUS)&&(CONST_INT_P(XEXP(x,1)))) {
+               if ((INTVAL(XEXP(x, 1)) > zip_max_mov_offset)
+               if ((INTVAL(XEXP(x, 1)) > zip_max_mov_offset)
+                       ||(INTVAL(XEXP(x, 1)) < zip_min_mov_offset)) {
+                       ||(INTVAL(XEXP(x, 1)) < zip_min_mov_offset)) {
+                       if (dbg) fprintf(stderr, "ZIP-VALID-MOVE-OPERAND -> NO! (reg+int), int out of bounds: %d\n", INTVAL(XEXP(x,1)));
+                       if (dbg) fprintf(stderr, "ZIP-VALID-MOVE-OPERAND -> NO! (reg+int), int out of bounds: %ld\n", INTVAL(XEXP(x,1)));
+                       return false;
+                       return false;
+               }
+               }
+       }
+       }
+
+
+       if (dbg) fprintf(stderr, "ZIP-VALID-MOVE-OPERAND -> Yes\n");
+       if (dbg) fprintf(stderr, "ZIP-VALID-MOVE-OPERAND -> Yes\n");
Line 6784... Line 6811...
+
+
+#endif /* GCC_ZIP_H */
+#endif /* GCC_ZIP_H */
+
+
diff -Naur '--exclude=*.swp' gcc-5.3.0-original/gcc/config/zip/zip.md gcc-5.3.0-zip/gcc/config/zip/zip.md
diff -Naur '--exclude=*.swp' gcc-5.3.0-original/gcc/config/zip/zip.md gcc-5.3.0-zip/gcc/config/zip/zip.md
--- gcc-5.3.0-original/gcc/config/zip/zip.md    1969-12-31 19:00:00.000000000 -0500
--- gcc-5.3.0-original/gcc/config/zip/zip.md    1969-12-31 19:00:00.000000000 -0500
+++ gcc-5.3.0-zip/gcc/config/zip/zip.md 2016-04-06 17:47:12.387591487 -0400
+++ gcc-5.3.0-zip/gcc/config/zip/zip.md 2016-04-08 15:26:57.622343817 -0400
@@ -0,0 +1,2262 @@
@@ -0,0 +1,2422 @@
+;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;
+;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;
+;;
+;;
+;; Filename:   zip.md
+;; Filename:   zip.md
+;;
+;;
+;; Project:    Zip CPU -- a small, lightweight, RISC CPU soft core
+;; Project:    Zip CPU -- a small, lightweight, RISC CPU soft core
Line 7126... Line 7153...
+       [(set (match_operand:ZI 0 "register_operand" "=r")
+       [(set (match_operand:ZI 0 "register_operand" "=r")
+               (match_operand:ZI 1 "register_operand" "r"))]
+               (match_operand:ZI 1 "register_operand" "r"))]
+       ""
+       ""
+       "MOV    %1,%0"
+       "MOV    %1,%0"
+       [(set_attr "ccresult" "unchanged")])
+       [(set_attr "ccresult" "unchanged")])
+(define_insn "mov<mode>_reg_off"       ; Register to register move
+(define_insn "mov<mode>_reg_off" ; Register to register move, used by prologue
+       [(set (match_operand:ZI 0 "register_operand" "=r")
+       [(set (match_operand:ZI 0 "register_operand" "=r")
+               (plus:ZI (match_operand:ZI 1 "register_operand" "r")
+               (plus:ZI (match_operand:ZI 1 "register_operand" "r")
+                       (match_operand:ZI 2 "zip_mvimm_operand_p" "M")))
+                       (match_operand:ZI 2 "zip_mvimm_operand_p" "M")))
+               ]
+               ]
+       ""
+       ""
Line 7156... Line 7183...
+       [(set (match_operand:SI 0 "register_operand" "=r")
+       [(set (match_operand:SI 0 "register_operand" "=r")
+               (match_operand:SI 1 "zip_memory_operand_p" ""))]
+               (match_operand:SI 1 "zip_memory_operand_p" ""))]
+       ""
+       ""
+       "LOD\t%1,%0"
+       "LOD\t%1,%0"
+       [(set_attr "predicable" "yes") (set_attr "ccresult" "unchanged")])
+       [(set_attr "predicable" "yes") (set_attr "ccresult" "unchanged")])
+;(define_insn "*movsi_lod_off"
+(define_insn "movsi_lod_off" ; used by epilogue code
+       ;[(set (match_operand:SI 0 "register_operand" "=r")
+       [(set (match_operand:SI 0 "register_operand" "=r")
+               ;(mem:SI (plus:SI (match_operand:SI 1 "register_operand" "r")
+               (mem:SI (plus:SI (match_operand:SI 1 "register_operand" "r")
+                       ;(match_operand:SI 2 "const_int_operand" "N"))))]
+                       (match_operand:SI 2 "const_int_operand" "N"))))]
+       ;""
+       ""
+       ;"LOD\t%2(%1),%0"
+       "LOD\t%2(%1),%0"
+       ;[(set_attr "predicable" "yes") (set_attr "ccresult" "unchanged")])
+       [(set_attr "predicable" "yes") (set_attr "ccresult" "unchanged")])
+(define_expand "mov<mode>_sto" ; Store into memory
+(define_expand "mov<mode>_sto" ; Store into memory
+       [(set (match_operand:ZI 0 "zip_memory_operand_p" "=Q")
+       [(set (match_operand:ZI 0 "zip_memory_operand_p" "=Q")
+               (match_operand:ZI 1 "register_operand" "r"))]
+               (match_operand:ZI 1 "register_operand" "r"))]
+       "")
+       "")
+(define_insn "*movsi_sto"
+(define_insn "*movsi_sto"
+       [(set (match_operand:SI 0 "zip_memory_operand_p" "=Q")
+       [(set (match_operand:SI 0 "zip_memory_operand_p" "=Q")
+               (match_operand:SI 1 "register_operand" "r"))]
+               (match_operand:SI 1 "register_operand" "r"))]
+       ""
+       ""
+       "STO\t%1,%0"
+       "STO\t%1,%0"
+       [(set_attr "predicable" "yes") (set_attr "ccresult" "unchanged")])
+       [(set_attr "predicable" "yes") (set_attr "ccresult" "unchanged")])
+;(define_insn "*movsi_sto_off"
+(define_insn "movsi_sto_off" ; used by prologue code
+       ;[(set (mem:SI (plus:SI
+       [(set (mem:SI (plus:SI
+                       ;(match_operand:SI 0 "register_operand" "r")
+                       (match_operand:SI 0 "register_operand" "r")
+                       ;(match_operand:SI 1 "const_int_operand" "N")))
+                       (match_operand:SI 1 "const_int_operand" "N")))
+               ;(match_operand:SI 2 "register_operand" "r"))]
+               (match_operand:SI 2 "register_operand" "r"))]
+       ;""
+       ""
+       ;"STO\t%2,%1(%0)"
+       "STO\t%2,%1(%0)"
+       ;[(set_attr "predicable" "yes") (set_attr "ccresult" "unchanged")])
+       [(set_attr "predicable" "yes") (set_attr "ccresult" "unchanged")])
+(define_insn "mov<mode>_ldi"   ; Load immediate
+(define_insn "mov<mode>_ldi"   ; Load immediate
+       [(set (match_operand:ZI 0 "register_operand" "=r")
+       [(set (match_operand:ZI 0 "register_operand" "=r")
+               (match_operand:ZI 1 "immediate_operand" "ipU"))]
+               (match_operand:ZI 1 "immediate_operand" "ipU"))]
+       ""
+       ""
+       "LDI    %1,%0"
+       "LDI    %1,%0"
Line 8118... Line 8145...
+                       [(reg:CC CC_REG) (const_int 0)])
+                       [(reg:CC CC_REG) (const_int 0)])
+                       (label_ref (match_operand 3 "" ""))
+                       (label_ref (match_operand 3 "" ""))
+                       (pc)))]
+                       (pc)))]
+       ""
+       ""
+       {
+       {
 
+               if (false) {
+               extern void zip_debug_rtx_pfx(const char *, const_rtx);
+               extern void zip_debug_rtx_pfx(const char *, const_rtx);
+               //; Two branches give us no end of difficulty when implementing.
+               //; Two branches give us no end of difficulty when implementing.
+               //; Let's check for these two branch codes, and swap the
+               //; Let's check for these two branch codes, and swap the
+               //; comparison to simplify them.
+               //; comparison to simplify them.
+               //; fprintf(stderr, "CBRANCH\n");
+               //; fprintf(stderr, "CBRANCH\n");
Line 8204... Line 8232...
+                                       XEXP(operands[2],0),
+                                       XEXP(operands[2],0),
+                                       GEN_INT(INTVAL(XEXP(operands[2],1))+1)));
+                                       GEN_INT(INTVAL(XEXP(operands[2],1))+1)));
+                               emit_jump_insn(gen_cbranch_jmp_ltu(operands[3]));
+                               emit_jump_insn(gen_cbranch_jmp_ltu(operands[3]));
+                               DONE;
+                               DONE;
+                       }
+                       }
+               }
+               }}
+       })
+       })
+(define_insn "cbranch_jmp_eq"
+(define_insn "cbranch_jmp_eq"
+       [(set (pc) (if_then_else (eq (reg:CC CC_REG) (const_int 0))
+       [(set (pc) (if_then_else (eq (reg:CC CC_REG) (const_int 0))
+                (label_ref (match_operand 0 "" ""))
+                (label_ref (match_operand 0 "" ""))
+                (pc)))]
+                (pc)))]
Line 8861... Line 8889...
+;      "MOV    %1,%0
+;      "MOV    %1,%0
+;      XOR     -1,%0
+;      XOR     -1,%0
+;      ADD     1,%0
+;      ADD     1,%0
+;      BV      %2"
+;      BV      %2"
+;      "")
+;      "")
+
+;
 
+; Match:
 
+;      CMP     R1,R0
 
+;      BGTU    lbl
 
+; Transform to:
 
+;      CMP     R0,R1
 
+;      BC      lbl
 
+;
+(define_peephole2
+(define_peephole2
+       [(set (reg:CC CC_REG) (compare:CC
+       [(set (reg:CC CC_REG) (compare:CC
+               (match_operand:SI 0 "register_operand")
+               (match_operand:SI 0 "register_operand")
+               (match_operand:SI 1 "register_operand")))
+               (match_operand:SI 1 "register_operand")))
+       (set (pc) (if_then_else (gtu (reg:CC CC_REG) (const_int 0))
+       (set (pc) (if_then_else (gtu (reg:CC CC_REG) (const_int 0))
Line 8875... Line 8910...
+       [(set (reg:CC CC_REG) (compare:CC (match_dup 1) (match_dup 0)))
+       [(set (reg:CC CC_REG) (compare:CC (match_dup 1) (match_dup 0)))
+       (set (pc) (if_then_else (ltu (reg:CC CC_REG) (const_int 0))
+       (set (pc) (if_then_else (ltu (reg:CC CC_REG) (const_int 0))
+                       (label_ref (match_dup 2))
+                       (label_ref (match_dup 2))
+                       (pc)))]
+                       (pc)))]
+       "")
+       "")
 
+;
 
+;
 
+; Match:
 
+;      CMP     R1,R0
 
+;      BGEU    lbl
 
+; Transform to:
 
+;      CMP     1(R0),R1
 
+;      BC      lbl
 
+;
+(define_peephole2
+(define_peephole2
+       [(set (reg:CC CC_REG) (compare:CC
+       [(set (reg:CC CC_REG) (compare:CC
+               (match_operand:SI 0 "register_operand")
+               (match_operand:SI 0 "register_operand")
+               (match_operand:SI 1 "register_operand")))
+               (match_operand:SI 1 "register_operand")))
+       (set (pc) (if_then_else (geu (reg:CC CC_REG) (const_int 0))
+       (set (pc) (if_then_else (geu (reg:CC CC_REG) (const_int 0))
Line 8889... Line 8933...
+               (match_dup 1) (plus (match_dup 0) (const_int 1))))
+               (match_dup 1) (plus (match_dup 0) (const_int 1))))
+       (set (pc) (if_then_else (ltu (reg:CC CC_REG) (const_int 0))
+       (set (pc) (if_then_else (ltu (reg:CC CC_REG) (const_int 0))
+                       (label_ref (match_dup 2))
+                       (label_ref (match_dup 2))
+                       (pc)))]
+                       (pc)))]
+       "")
+       "")
 
+;
 
+;
 
+; Match:
 
+;      CMP     R1,R0
 
+;      BGE     lbl
 
+; Transform to:
 
+;      CMP     1(R0),R1
 
+;      BLT     lbl
 
+;
+(define_peephole2
+(define_peephole2
+       [(set (reg:CC CC_REG) (compare:CC
+       [(set (reg:CC CC_REG) (compare:CC
+               (match_operand:SI 0 "register_operand")
+               (match_operand:SI 0 "register_operand")
+               (match_operand:SI 1 "register_operand")))
+               (match_operand:SI 1 "register_operand")))
+       (set (pc) (if_then_else (ge (reg:CC CC_REG) (const_int 0))
+       (set (pc) (if_then_else (ge (reg:CC CC_REG) (const_int 0))
Line 8903... Line 8956...
+                       (plus:SI (match_dup 0) (const_int 1))))
+                       (plus:SI (match_dup 0) (const_int 1))))
+       (set (pc) (if_then_else (lt (reg:CC CC_REG) (const_int 0))
+       (set (pc) (if_then_else (lt (reg:CC CC_REG) (const_int 0))
+                       (label_ref (match_dup 2))
+                       (label_ref (match_dup 2))
+                       (pc)))]
+                       (pc)))]
+       "")
+       "")
 
+;
 
+;
 
+; Match:
 
+;      CMP     R1,R0
 
+;      BLEU    lbl
 
+; Transform to:
 
+;      CMP     1(R1),R0
 
+;      BLT     lbl
 
+;
+(define_peephole2
+(define_peephole2
+       [(set (reg:CC CC_REG) (compare:CC
+       [(set (reg:CC CC_REG) (compare:CC
+               (match_operand:SI 0 "register_operand" "")
+               (match_operand:SI 0 "register_operand" "")
+               (match_operand:SI 1 "register_operand" "")))
+               (match_operand:SI 1 "register_operand" "")))
+       (set (pc) (if_then_else (leu (reg:CC CC_REG) (const_int 0))
+       (set (pc) (if_then_else (leu (reg:CC CC_REG) (const_int 0))
Line 8949... Line 9011...
+;                      (pc)))]
+;                      (pc)))]
+;      "")
+;      "")
+;
+;
+;
+;
+;
+;
+; Need a peephole optimizer (not peephole2) for
 
+;      [(call ...
 
+;      (set (pc) (label))]
 
+;      To result with
 
+;      "MOV\tlabel,R0
 
+;      JMP\tsubroutine"
 
+;
 
+; and for
 
+;      BRA target
 
+;      BRA target ; two branches to the same identical target in a row ...
 
+;
 
+;
 
+;
+;
+; Match:
+; Match:
+;      MOV A(R1),R3
+;      MOV A(R1),R3
+;      CMP R3,R0
+;      CMP R3,R0
+;      (R3 is dead)
+;      (R3 is dead)
Line 8989... Line 9039...
+;      CMP 0,R0
+;      CMP 0,R0
+; Transform to:
+; Transform to:
+;      ALU OpB,R0
+;      ALU OpB,R0
+;
+;
+(define_peephole2
+(define_peephole2
+       [(parallel [(set (match_operand 0 "register_operand")
+       [(parallel [(set (match_operand:SI 0 "register_operand")
+                       (match_operand 1 ""))
+                       (match_operand:SI 1 ""))
+               (set (reg:CC CC_REG) (compare:CC (match_dup 0) (const_int 0)))])
+               (set (reg:CC CC_REG) (compare:CC (match_dup 0) (const_int 0)))])
+       (set (reg:CC CC_REG) (compare:CC (match_dup 0) (const_int 0)))]
+       (set (reg:CC CC_REG) (compare:CC (match_dup 0) (const_int 0)))]
+       ""
+       ""
+       [(parallel [(set (match_dup 0) (match_dup 1))
+       [(parallel [(set (match_dup 0) (match_dup 1))
+               (set (reg:CC CC_REG) (compare:CC (match_dup 0) (const_int 0)))])
+               (set (reg:CC CC_REG) (compare:CC (match_dup 0) (const_int 0)))])
Line 9008... Line 9058...
+; Transform to:
+; Transform to:
+;      ALU OpB,R0
+;      ALU OpB,R0
+;      MOV R0,R1
+;      MOV R0,R1
+;
+;
+(define_peephole2
+(define_peephole2
+       [(parallel [(set (match_operand 0 "register_operand")
+       [(parallel [(set (match_operand:SI 0 "register_operand")
+                       (match_operand 1 ""))
+                       (match_operand:SI 1 ""))
+               (set (reg:CC CC_REG) (compare:CC (match_dup 0) (const_int 0)))])
+               (set (reg:CC CC_REG) (compare:CC (match_dup 0) (const_int 0)))])
+       (set (match_operand 2 "nonimmediate_operand") (match_operand 3 ""))
+       (set (match_operand:SI 2 "nonimmediate_operand") (match_operand:SI 3 ""))
+       (set (reg:CC CC_REG) (compare:CC (match_dup 0) (const_int 0)))]
+       (set (reg:CC CC_REG) (compare:CC (match_dup 0) (const_int 0)))]
+       "(!REG_P(operands[2]))||((REGNO(operands[2])!=REGNO(operands[0]))&&((REGNO(operands[2])>FIRST_PSEUDO_REGISTER)||(REGNO(operands[2])<CC_REG)))"
+       "(!REG_P(operands[2]))||((REGNO(operands[2])!=REGNO(operands[0]))&&((REGNO(operands[2])>FIRST_PSEUDO_REGISTER)||(REGNO(operands[2])<CC_REG)))"
+       [(parallel [(set (match_dup 0) (match_dup 1))
+       [(parallel [(set (match_dup 0) (match_dup 1))
+               (set (reg:CC CC_REG) (compare:CC (match_dup 0) (const_int 0)))])
+               (set (reg:CC CC_REG) (compare:CC (match_dup 0) (const_int 0)))])
+       (set (match_dup 2) (match_dup 3))
+       (set (match_dup 2) (match_dup 3))
Line 9029... Line 9079...
+; Transform to:
+; Transform to:
+;      ALU OpB,R0
+;      ALU OpB,R0
+;      MOV R0,R1
+;      MOV R0,R1
+;
+;
+(define_peephole2
+(define_peephole2
+       [(parallel [(set (match_operand 0 "register_operand")
+       [(parallel [(set (match_operand:SI 0 "register_operand")
+                       (match_operand 1 ""))
+                       (match_operand:SI 1 ""))
+               (set (reg:CC CC_REG) (compare:CC (match_dup 0) (const_int 0)))])
+               (set (reg:CC CC_REG) (compare:CC (match_dup 0) (const_int 0)))])
+       (set (match_operand 2 "register_operand") (match_dup 0))
+       (set (match_operand:SI 2 "register_operand") (match_dup 0))
+       (set (reg:CC CC_REG) (compare:CC (match_dup 2) (const_int 0)))]
+       (set (reg:CC CC_REG) (compare:CC (match_dup 2) (const_int 0)))]
+       ""
+       ""
+       [(parallel [(set (match_dup 0) (match_dup 1))
+       [(parallel [(set (match_dup 0) (match_dup 1))
+               (set (reg:CC CC_REG) (compare:CC (match_dup 0) (const_int 0)))])
+               (set (reg:CC CC_REG) (compare:CC (match_dup 0) (const_int 0)))])
+       (set (match_dup 2) (match_dup 3))
+       (set (match_dup 2) (match_dup 3))
+       ])
+       ])
+
+;
 
+;
 
+; Match:
 
+;      MOV A(R0),R0
 
+;      ADD $x,R1
 
+;      (CCREG is dead, and (A+x) is within range ...)
 
+; Transform to:
 
+;      MOV (A+$x)(R1),R0
 
+; ... how do I do the plus?  Let's build it with a plus of zero, and work from
 
+; there
 
+;      MOV R1,R0
 
+;      ADD $x,R0
 
+;      (CCREG is dead, and x is within range ...)
 
+; Transform to:
 
+;      MOV (A+$x)(R1),R0
 
+(define_peephole2
 
+       [(set (match_operand:SI 0 "register_operand")
 
+               (match_operand:SI 1 "register_operand"))
 
+       (parallel [(set (match_dup 0) (plus:SI (match_dup 0)
 
+                               (match_operand 2 "zip_mvimm_operand_p")))
 
+               (set (reg:CC CC_REG) (compare:CC (match_dup 0) (const_int 0)))])
 
+       ]
 
+       "(peep2_regno_dead_p(2,CC_REG))"
 
+       [(set (match_dup 0) (plus:SI (match_dup 1) (match_dup 2)))])
 
+;
 
+;
 
+;
 
+; Match:
 
+;      ADD $x,R0
 
+;      MOV R0,R1
 
+;      (CCREG is dead, and R0 is dead)
 
+; Transform to:
 
+;      MOV (A+$x)(R0),R1
 
+; ... again, how do I build this plus?
 
+;
 
+(define_peephole2
 
+       [(parallel [(set (match_operand:SI 0 "register_operand")
 
+                       (plus:SI (match_dup 0)
 
+                               (match_operand 1 "zip_mvimm_operand_p")))
 
+               (set (reg:CC CC_REG) (compare:CC (match_dup 0) (const_int 0)))])
 
+       (set (match_operand:SI 2 "register_operand") (match_dup 0))]
 
+       "(peep2_regno_dead_p(2, REGNO(operands[0])))&&(peep2_regno_dead_p(2,CC_REG))"
 
+       [(set (match_dup 2) (plus:SI (match_dup 0) (match_dup 1)))])
 
+;
 
+;
 
+; Match:
 
+;      ADD     $x,R0
 
+;      ADD     R0,Rn
 
+;      (R0 is dead, if R0 is not Rn)
 
+; Transform to:
 
+;      ADD     $x(R0),Rn
 
+;
 
+(define_peephole2
 
+       [(parallel [(set (match_operand:SI 0 "register_operand")
 
+                       (plus:SI (match_dup 0)
 
+                               (match_operand 1 "zip_opb_immv_p")))
 
+               (set (reg:CC CC_REG) (compare:CC (match_dup 0) (const_int 0)))])
 
+       (parallel [(set (match_operand:SI 2 "register_operand")
 
+                       (plus:SI (match_dup 2) (match_dup 0)))
 
+               (set (reg:CC CC_REG) (compare:CC (match_dup 2) (const_int 0)))])
 
+       ]
 
+       "(REGNO(operands[0])!=REGNO(operands[2]))&&(peep2_regno_dead_p(2, REGNO(operands[0])))"
 
+       [(parallel [(set (match_dup 2)
 
+                       (plus:SI (match_dup 2)
 
+                               (plus:SI (match_dup 0)
 
+                                       (match_dup 1))))
 
+               (set (reg:CC CC_REG) (compare:CC (match_dup 2) (const_int 0)))])
 
+       ])
 
+;
 
+; Match:
 
+;      ADD     $x,R0
 
+;      LOD     -x(R0),R1
 
+; Transform to:
 
+;      LOD     (R0),R1
 
+;      ADD     $x,R0
 
+;
 
+(define_peephole2
 
+       [(parallel [(set (match_operand:SI 0 "register_operand")
 
+                       (plus:SI (match_dup 0)
 
+                               (match_operand 1 "zip_opb_immv_p")))
 
+               (set (reg:CC CC_REG) (compare:CC (match_dup 0) (const_int 0)))])
 
+       (set (match_operand:SI 3 "register_operand")
 
+               (mem:SI (plus:SI (match_dup 0)
 
+                       (match_operand 2 "zip_opb_immv_p"))))
 
+       ]
 
+       "(REGNO(operands[0])!=REGNO(operands[1]))&&(INTVAL(operands[1])==-INTVAL(operands[2]))"
 
+       [(set (match_dup 3) (mem:SI (match_dup 0)))
 
+       (parallel [(set (match_dup 0) (plus:SI (match_dup 0) (match_dup 1)))
 
+               (set (reg:CC CC_REG) (compare:CC (match_dup 0) (const_int 0)))])
 
+       ])
 
+;
 
+;
 
+;
 
+; Match:
 
+;      ADD     $x,R0
 
+;      STO     R1,-x(R0)
 
+; Transform to:
 
+;      STO     R1,(R0)
 
+;      ADD     $x,R0
 
+;
 
+(define_peephole2
 
+       [(parallel [(set (match_operand:SI 0 "register_operand")
 
+                       (plus:SI (match_dup 0)
 
+                               (match_operand 1 "zip_opb_immv_p")))
 
+               (set (reg:CC CC_REG) (compare:CC (match_dup 0) (const_int 0)))])
 
+       (set (mem:SI (plus:SI (match_dup 0) (match_operand 2 "zip_opb_immv_p")))
 
+               (match_operand:SI 3 "register_operand"))
 
+       ]
 
+       "(REGNO(operands[0])!=REGNO(operands[1]))&&(INTVAL(operands[1])==-INTVAL(operands[2]))"
 
+       [(set (mem:SI (match_dup 0)) (match_dup 3))
 
+       (parallel [(set (match_dup 0) (plus:SI (match_dup 0) (match_dup 1)))
 
+               (set (reg:CC CC_REG) (compare:CC (match_dup 0) (const_int 0)))])
 
+       ])
 
+;
 
+;
 
+; Match:
 
+;      ADD     $x,R0
 
+;      ANY     R1,R2 (destination is not R0, source does not reference R0)
 
+;      ADD     R0,Rn (could be 1 or 2, not 0)
 
+;      (R0 is dead)
 
+; Transform to:
 
+;      ANY     R1,R2
 
+;      ADD     $x(R0),Rn
 
+;
 
+;
 
+;
 
+; Need a peephole optimizer (not peephole2) for
 
+;      [(call ...
 
+;      (set (pc) (label))]
 
+;      To result with
 
+;      "MOV\tlabel,R0
 
+;      JMP\tsubroutine"
 
+;
 
+; and for
 
+;      BRA target
 
+;      BRA target ; two branches to the same identical target in a row ...
 
+;
 
+;
+;
+;
+; STILL MISSING:
+; STILL MISSING:
+;      SYSCALL(ID)
+;      SYSCALL(ID)
+;              MOV %ID,R0
+;              MOV %ID,R0
+;              CLR     CC
+;              CLR     CC
Line 10017... Line 10204...
 }
 }
 #endif /* HAVE_peephole2 */
 #endif /* HAVE_peephole2 */
 
 
diff -Naur '--exclude=*.swp' gcc-5.3.0-original/gcc/reload1.c gcc-5.3.0-zip/gcc/reload1.c
diff -Naur '--exclude=*.swp' gcc-5.3.0-original/gcc/reload1.c gcc-5.3.0-zip/gcc/reload1.c
--- gcc-5.3.0-original/gcc/reload1.c    2015-01-15 08:28:42.000000000 -0500
--- gcc-5.3.0-original/gcc/reload1.c    2015-01-15 08:28:42.000000000 -0500
+++ gcc-5.3.0-zip/gcc/reload1.c 2016-04-06 17:44:36.240674020 -0400
+++ gcc-5.3.0-zip/gcc/reload1.c 2016-04-08 18:48:36.995557279 -0400
@@ -72,6 +72,14 @@
@@ -72,6 +72,14 @@
 #include "dumpfile.h"
 #include "dumpfile.h"
 #include "rtl-iter.h"
 #include "rtl-iter.h"
 
 
+// #define     DO_ZIP_DEBUGS
+// #define     DO_ZIP_DEBUGS

powered by: WebSVN 2.1.0

© copyright 1999-2022 OpenCores.org, equivalent to Oliscience, all rights reserved. OpenCores®, registered trademark.