M7350v1_en_gpl

This commit is contained in:
T
2024-09-09 08:52:07 +00:00
commit f9cc65cfda
65988 changed files with 26357421 additions and 0 deletions

View File

@@ -0,0 +1,25 @@
Upstream-Status: Pending
# Dimitry Andric <dimitry@andric.com>, 2004-05-01
#
# * Removed the extra -lfloat option from LIBGCC_SPEC, since it isn't needed
# anymore. (The required functions are now in libgcc.)
#
# Fixes errors like
# arm-softfloat-linux-gnu/3.4.0/../../../../arm-softfloat-linux-gnu/bin/ld: cannot find -lfloat
# collect2: ld returned 1 exit status
# make[2]: *** [arm-softfloat-linux-gnu/gcc-3.4.0-glibc-2.3.2/build-glibc/iconvdata/ISO8859-1.so] Error 1
# when building glibc-2.3.3 with gcc-3.4.0 for arm-softfloat
Index: gcc-4.0.2/gcc/config/arm/linux-elf.h
===================================================================
--- gcc-4.0.2.orig/gcc/config/arm/linux-elf.h 2005-03-04 16:14:01.000000000 +0000
+++ gcc-4.0.2/gcc/config/arm/linux-elf.h 2005-11-11 18:02:54.000000000 +0000
@@ -56,7 +56,7 @@
%{shared:-lc} \
%{!shared:%{profile:-lc_p}%{!profile:-lc}}"
-#define LIBGCC_SPEC "%{msoft-float:-lfloat} %{mfloat-abi=soft*:-lfloat} -lgcc"
+#define LIBGCC_SPEC "-lgcc"
/* Provide a STARTFILE_SPEC appropriate for GNU/Linux. Here we add
the GNU/Linux magical crtbegin.o file (see crtstuff.c) which

View File

@@ -0,0 +1,17 @@
Upstream-Status: Pending
Index: gcc-4.0.2/gcc/config/arm/t-linux
===================================================================
--- gcc-4.0.2.orig/gcc/config/arm/t-linux 2004-05-15 12:41:35.000000000 +0000
+++ gcc-4.0.2/gcc/config/arm/t-linux 2005-11-11 16:07:53.000000000 +0000
@@ -4,7 +4,10 @@
LIBGCC2_DEBUG_CFLAGS = -g0
LIB1ASMSRC = arm/lib1funcs.asm
-LIB1ASMFUNCS = _udivsi3 _divsi3 _umodsi3 _modsi3 _dvmd_lnx
+LIB1ASMFUNCS = _udivsi3 _divsi3 _umodsi3 _modsi3 _dvmd_lnx \
+ _negdf2 _addsubdf3 _muldivdf3 _cmpdf2 _unorddf2 _fixdfsi _fixunsdfsi \
+ _truncdfsf2 _negsf2 _addsubsf3 _muldivsf3 _cmpsf2 _unordsf2 \
+ _fixsfsi _fixunssfsi _floatdidf _floatdisf _floatundisf _floatundidf
# MULTILIB_OPTIONS = mhard-float/msoft-float
# MULTILIB_DIRNAMES = hard-float soft-float

View File

@@ -0,0 +1,13 @@
Upstream-Status: Pending
--- gcc-2005q3/gcc/config/arm/linux-eabi.h~ 2007-07-10 09:19:47.000000000 +0930
+++ gcc-2005q3/gcc/config/arm/linux-eabi.h 2007-07-10 10:42:37.000000000 +0930
@@ -48,7 +48,8 @@
#define SUBTARGET_CPU_DEFAULT TARGET_CPU_arm10tdmi
#undef SUBTARGET_EXTRA_LINK_SPEC
-#define SUBTARGET_EXTRA_LINK_SPEC " -m armelf_linux_eabi"
+#define SUBTARGET_EXTRA_LINK_SPEC \
+ " %{mbig-endian:-m armelfb_linux_eabi} %{mlittle-endian:-m armelf_linux_eabi} "
/* Use ld-linux.so.3 so that it will be possible to run "classic"
GNU/Linux binaries on an EABI system. */

View File

@@ -0,0 +1,30 @@
Upstream-Status: Pending
--- gcc-3.4.4/gcc/Makefile.in.orig 2005-07-25 21:00:37 +0200
+++ gcc-3.4.4/gcc/Makefile.in 2005-07-25 21:01:19 +0200
@@ -304,7 +304,7 @@
if [ "$(host)" = "$(target)" ] ; then \
echo ar; \
else \
- t='$(program_transform_name)'; echo ar | sed -e $$t ; \
+ t='$(program_transform_name)'; echo ar | sed -e "$$t" ; \
fi; \
fi`
AR_FLAGS_FOR_TARGET =
@@ -317,7 +317,7 @@
if [ "$(host)" = "$(target)" ] ; then \
echo $(RANLIB); \
else \
- t='$(program_transform_name)'; echo ranlib | sed -e $$t ; \
+ t='$(program_transform_name)'; echo ranlib | sed -e "$$t" ; \
fi; \
fi`
NM_FOR_TARGET = ` \
@@ -329,7 +329,7 @@
if [ "$(host)" = "$(target)" ] ; then \
echo nm; \
else \
- t='$(program_transform_name)'; echo nm | sed -e $$t ; \
+ t='$(program_transform_name)'; echo nm | sed -e "$$t" ; \
fi; \
fi`

File diff suppressed because it is too large Load Diff

View File

@@ -0,0 +1,36 @@
Upstream-Status: Inappropriate [embedded specific]
---
configure | 2 +-
configure.in | 2 +-
2 files changed, 2 insertions(+), 2 deletions(-)
--- gcc-2006q1.orig/configure
+++ gcc-2006q1/configure
@@ -3453,11 +3453,11 @@ case " $build_configdirs " in
*)
# For an installed makeinfo, we require it to be from texinfo 4.2 or
# higher, else we use the "missing" dummy.
if ${MAKEINFO} --version \
- | egrep 'texinfo[^0-9]*([1-3][0-9]|4\.[2-9]|[5-9])' >/dev/null 2>&1; then
+ | egrep 'texinfo[^0-9]*(4\.([6-9]|[1-9][0-9])|[5-9]|[1-9][0-9])' >/dev/null 2>&1; then
:
else
MAKEINFO="$MISSING makeinfo"
fi
;;
--- gcc-2006q1.orig/configure.in
+++ gcc-2006q1/configure.in
@@ -2078,11 +2078,11 @@ case " $build_configdirs " in
*)
changequote(,)
# For an installed makeinfo, we require it to be from texinfo 4.2 or
# higher, else we use the "missing" dummy.
if ${MAKEINFO} --version \
- | egrep 'texinfo[^0-9]*([1-3][0-9]|4\.[2-9]|[5-9])' >/dev/null 2>&1; then
+ | egrep 'texinfo[^0-9]*(4\.([6-9]|[1-9][0-9])|[5-9]|[1-9][0-9])' >/dev/null 2>&1; then
:
else
MAKEINFO="$MISSING makeinfo"
fi
;;

View File

@@ -0,0 +1,24 @@
Upstream-Status: Inappropriate [embedded specific]
--- gcc-3.4.4/configure.in.orig 2005-08-09 19:57:51.504323183 -0700
+++ gcc-3.4.4/configure.in 2005-08-09 20:00:12.073168623 -0700
@@ -1907,7 +1907,7 @@
*) gxx_include_dir=${with_gxx_include_dir} ;;
esac
-FLAGS_FOR_TARGET=
+FLAGS_FOR_TARGET="$ARCH_FLAGS_FOR_TARGET"
case " $target_configdirs " in
*" newlib "*)
case " $target_configargs " in
--- gcc-3.4.4/configure.orig 2005-08-09 21:02:29.668360660 -0700
+++ gcc-3.4.4/configure 2005-08-09 21:02:50.157649970 -0700
@@ -2669,7 +2669,7 @@
*) gxx_include_dir=${with_gxx_include_dir} ;;
esac
-FLAGS_FOR_TARGET=
+FLAGS_FOR_TARGET="$ARCH_FLAGS_FOR_TARGET"
case " $target_configdirs " in
*" newlib "*)
case " $target_configargs " in

View File

@@ -0,0 +1,97 @@
Upstream-Status: Pending
ARM is the only architecture that has a helper function that returns
an unbiased result. This fix is trivial enough that we can show it
doesn't effect any of the other arches. Can we consider this a
regression fix since it used to work until the helper was added :}
Tested with no regressions on x86_64-pc-linux-gnu and arm-none-eabi.
Cheers,
Carlos.
--
Carlos O'Donell
CodeSourcery
carlos@codesourcery.com
(650) 331-3385 x716
gcc/
2006-01-27 Carlos O'Donell <carlos@codesourcery.com>
* optabs.c (prepare_cmp_insn): If unbaised and unsigned then bias
the comparison routine return.
gcc/testsuite/
2006-01-27 Carlos O'Donell <carlos@codesourcery.com>
* gcc.dg/unsigned-long-compare.c: New test.
Index: gcc/optabs.c
===================================================================
--- 1/gcc/optabs.c (revision 110300)
+++ 2/gcc/optabs.c (working copy)
@@ -3711,18 +3711,24 @@
result = emit_library_call_value (libfunc, NULL_RTX, LCT_CONST_MAKE_BLOCK,
word_mode, 2, x, mode, y, mode);
+ /* There are two kinds of comparison routines. Biased routines
+ return 0/1/2, and unbiased routines return -1/0/1. Other parts
+ of gcc expect that the comparison operation is equivalent
+ to the modified comparison. For signed comparisons compare the
+ result against 1 in the unbiased case, and zero in the biased
+ case. For unsigned comparisons always compare against 1 after
+ biasing the unbased result by adding 1. This gives us a way to
+ represent LTU. */
*px = result;
*pmode = word_mode;
- if (TARGET_LIB_INT_CMP_BIASED)
- /* Integer comparison returns a result that must be compared
- against 1, so that even if we do an unsigned compare
- afterward, there is still a value that can represent the
- result "less than". */
- *py = const1_rtx;
- else
+ *py = const1_rtx;
+
+ if (!TARGET_LIB_INT_CMP_BIASED)
{
- *py = const0_rtx;
- *punsignedp = 1;
+ if (*punsignedp)
+ *px = plus_constant (result, 1);
+ else
+ *py = const0_rtx;
}
return;
}
Index: gcc/testsuite/gcc.dg/unsigned-long-compare.c
===================================================================
--- 1/gcc/testsuite/gcc.dg/unsigned-long-compare.c (revision 0)
+++ 2/gcc/testsuite/gcc.dg/unsigned-long-compare.c (revision 0)
@@ -0,0 +1,24 @@
+/* Copyright (C) 2006 Free Software Foundation, Inc. */
+/* Contributed by Carlos O'Donell on 2006-01-27 */
+
+/* Test a division corner case where the expression simplifies
+ to a comparison, and the optab expansion is wrong. The optab
+ expansion emits a function whose return is unbiased and needs
+ adjustment. */
+/* Origin: Carlos O'Donell <carlos@codesourcery.com> */
+/* { dg-do run { target arm-*-*eabi* } } */
+/* { dg-options "" } */
+#include <stdlib.h>
+
+#define BIG_CONSTANT 0xFFFFFFFF80000000ULL
+
+int main (void)
+{
+ unsigned long long OneULL = 1ULL;
+ unsigned long long result;
+
+ result = OneULL / BIG_CONSTANT;
+ if (result)
+ abort ();
+ exit (0);
+}

View File

@@ -0,0 +1,42 @@
Upstream-Status: Pending
The patch below fixes a crash building libgfortran on arm-linux-gnueabi.
This target doesn't really have a 128-bit integer type, however it does use
TImode to represent the return value of certain special ABI defined library
functions. This results in type_for_size(TImode) being called.
Because TImode deosn't correspond to any gfortran integer kind
gfc_type_for_size returns NULL and we segfault shortly after.
The patch below fixes this by making gfc_type_for_size handle TImode in the
same way as the C frontend.
Tested on x86_64-linux and arm-linux-gnueabi.
Applied to trunk.
Paul
2007-05-15 Paul Brook <paul@codesourcery.com>
gcc/fortran/
* trans-types.c (gfc_type_for_size): Handle signed TImode.
Index: gcc-4.2.1/gcc/fortran/trans-types.c
===================================================================
--- gcc-4.2.1/gcc/fortran/trans-types.c (revision 170435)
+++ gcc-4.2.1/gcc/fortran/trans-types.c (working copy)
@@ -1800,6 +1800,13 @@ gfc_type_for_size (unsigned bits, int un
if (type && bits == TYPE_PRECISION (type))
return type;
}
+
+ /* Handle TImode as a special case because it is used by some backends
+ (eg. ARM) even though it is not available for normal use. */
+#if HOST_BITS_PER_WIDE_INT >= 64
+ if (bits == TYPE_PRECISION (intTI_type_node))
+ return intTI_type_node;
+#endif
}
else
{

View File

@@ -0,0 +1,33 @@
Upstream-Status: Pending
Index: gcc-4.0.2/gcc/c-incpath.c
===================================================================
--- gcc-4.0.2.orig/gcc/c-incpath.c 2005-01-23 16:05:27.000000000 +0100
+++ gcc-4.0.2/gcc/c-incpath.c 2006-05-15 21:23:02.000000000 +0200
@@ -350,6 +350,26 @@
p->construct = 0;
p->user_supplied_p = user_supplied_p;
+#ifdef CROSS_COMPILE
+ /* A common error when cross compiling is including
+ host headers. This code below will try to fail fast
+ for cross compiling. Currently we consider /usr/include,
+ /opt/include and /sw/include as harmful. */
+ {
+ /* printf("Adding Path: %s\n", p->name ); */
+ if( strstr(p->name, "/usr/include" ) == p->name ) {
+ fprintf(stderr, _("BUILD ISOLATION FAILURE: /usr/include in INCLUDEPATH: %s\n Please fix the flags passed to the compiler to use the correct prefix.\n"), p->name);
+ abort();
+ } else if( strstr(p->name, "/sw/include") == p->name ) {
+ fprintf(stderr, _("BUILD ISOLATION FAILURE: /sw/include in INCLUDEPATH: %s\n Please fix the flags passed to the compiler to use the correct prefix.\n"), p->name);
+ abort();
+ } else if( strstr(p->name, "/opt/include") == p->name ) {
+ fprintf(stderr, _("BUILD ISOLATION FAILURE: /opt/include in INCLUDEPATH: %s\n Please fix the flags passed to the compiler to use the correct prefix.\n"), p->name);
+ abort();
+ }
+ }
+#endif
+
add_cpp_dir_path (p, chain);
}

View File

@@ -0,0 +1,17 @@
Upstream-Status: Inappropriate [embedded specific]
upstream: n/a
comment: Use the preprocessor we have just compiled instead the one of
the system. There might be incompabilities between us and them.
Index: gcc-4.1.1/Makefile.in
===================================================================
--- gcc-4.1.1.orig/Makefile.in 2006-08-06 13:32:44.000000000 +0200
+++ gcc-4.1.1/Makefile.in 2006-08-06 13:32:46.000000000 +0200
@@ -194,6 +194,7 @@
AS="$(COMPILER_AS_FOR_TARGET)"; export AS; \
CC="$(CC_FOR_TARGET)"; export CC; \
CFLAGS="$(CFLAGS_FOR_TARGET)"; export CFLAGS; \
+ CPP="$(CC_FOR_TARGET) -E"; export CCP; \
CONFIG_SHELL="$(SHELL)"; export CONFIG_SHELL; \
CPPFLAGS="$(CPPFLAGS_FOR_TARGET)"; export CPPFLAGS; \
CXXFLAGS="$(CXXFLAGS_FOR_TARGET)"; export CXXFLAGS; \