Go to file
Joseph Myers d3719ee2c0 Fix m68k-linux-gnu libgcc build for ColdFire (PR target/68467).
PR target/68467 is libgcc failing to build for m68k-linux-gnu
configured for ColdFire.

Jeff has an analysis in the PR identifying the problem as resulting
from the callers of libcalls with 1-byte or 2-byte arguments wanting
to push just 1 or 2 bytes on the stack, while the libcall
implementations have the normal C ABI and expect 4-byte arguments.
For normal C functions, I believe the TARGET_PROMOTE_PROTOTYPES
definition would ensure such arguments get passed as 4-byte, but that
does not apply for libcalls.

This patch fixes the issue by defining TARGET_PROMOTE_FUNCTION_MODE
for m68k.  The definition is conservative, only applying promotions in
the case of arguments to libcalls; otherwise it returns the unpromoted
type, which I believe matches what the default implementation of the
hook would have done on m68k.

I have tested that this fixes the libgcc build for ColdFire, and, in
conjunction with one glibc patch, this enables glibc to build cleanly
for ColdFire and to pass the compilation parts of the glibc testsuite
except for one test unrelated to this patch (while glibc and the
compilation parts of the testsuite continue to build OK for
non-ColdFire m68k, as expected).  I have *not* run any GCC tests for
this patch, or any execution tests for m68k.

	PR target/68467
	* config/m68k/m68k.c (m68k_promote_function_mode): New function.
	(TARGET_PROMOTE_FUNCTION_MODE): New macro.

From-SVN: r257032
2018-01-24 23:36:29 +00:00
config Plugin support on Windows/MinGW 2017-11-26 13:00:48 +00:00
contrib Fix usage of analyze_brprob.py script. 2018-01-19 12:03:24 +00:00
fixincludes
gcc Fix m68k-linux-gnu libgcc build for ColdFire (PR target/68467). 2018-01-24 23:36:29 +00:00
gnattools Update copyright years. 2018-01-03 11:03:58 +01:00
gotools Makefile.am (GOTOOLS_TEST_TIMEOUT): Define. 2018-01-19 05:04:51 +00:00
include Update copyright years. 2018-01-03 11:03:58 +01:00
INSTALL
intl
libada Update copyright years. 2018-01-03 11:03:58 +01:00
libatomic Update copyright years. 2018-01-03 11:03:58 +01:00
libbacktrace xcoff.c (xcoff_incl_compare): New function. 2018-01-19 17:45:24 +00:00
libcc1 Update copyright years. 2018-01-03 11:03:58 +01:00
libcpp Add ability to remap file names in __FILE__, etc (PR other/70268) 2018-01-18 13:17:37 +00:00
libdecnumber Update copyright years. 2018-01-03 11:03:58 +01:00
libffi
libgcc libgcc: xtensa: fix NaN return from add/sub/mul/div helpers 2018-01-23 21:42:52 +00:00
libgfortran re PR fortran/54613 ([F08] Add FINDLOC plus support MAXLOC/MINLOC with KIND=/BACK=) 2018-01-15 18:35:13 +00:00
libgo cmd/go: buildid support for AIX archives. 2018-01-23 04:44:12 +00:00
libgomp [nvptx, PR83589] Workaround for branch-around-nothing JIT bug 2018-01-24 13:52:12 +00:00
libhsail-rt Update copyright years. 2018-01-03 11:03:58 +01:00
libiberty simple-object-xcoff.c (simple_object_xcoff_find_sections): Use ulong_type to avoid warning about 32-bit shift. 2018-01-21 05:01:31 +00:00
libitm Update copyright years. 2018-01-03 11:03:58 +01:00
libmpx Enable building libmpx with Intel CET 2017-11-17 23:41:10 +01:00
libobjc Update copyright years. 2018-01-03 11:03:58 +01:00
liboffloadmic Update copyright years. 2018-01-03 11:03:58 +01:00
libquadmath Update copyright years. 2018-01-03 11:03:58 +01:00
libsanitizer Guard against undefined weak symbols before Mac OS X 10.9 (PR sanitizer/82825) 2018-01-17 19:31:43 +00:00
libssp Update copyright years. 2018-01-03 11:03:58 +01:00
libstdc++-v3 [libstdc++][testsuite] Fix dg-options/dg-add-options order 2018-01-19 11:17:34 +01:00
libvtv Update copyright years. 2018-01-03 11:03:58 +01:00
lto-plugin Update copyright years. 2018-01-03 11:03:58 +01:00
maintainer-scripts
zlib
.dir-locals.el
.gitattributes
.gitignore
ABOUT-NLS
ChangeLog Add Boris Kolpackov <boris@codesynthesis.com> to MAINTAINERS 2018-01-18 12:36:31 +00:00
ChangeLog.jit
ChangeLog.tree-ssa
compile
config-ml.in
config.guess config.guess: Import latest version. 2018-01-03 15:25:18 +11:00
config.rpath
config.sub config.guess: Import latest version. 2018-01-03 15:25:18 +11:00
configure configure.ac: Remove logic adding gdb to noconfigsdirs for or1k. 2017-12-12 14:23:05 +00:00
configure.ac configure.ac: Remove logic adding gdb to noconfigsdirs for or1k. 2017-12-12 14:23:05 +00:00
COPYING
COPYING3
COPYING3.LIB
COPYING.LIB
COPYING.RUNTIME
depcomp
install-sh
libtool-ldflags
libtool.m4
lt~obsolete.m4
ltgcc.m4
ltmain.sh
ltoptions.m4
ltsugar.m4
ltversion.m4
MAINTAINERS Add Boris Kolpackov <boris@codesynthesis.com> to MAINTAINERS 2018-01-18 12:36:31 +00:00
Makefile.def Remove Cilk Plus support. 2017-11-28 11:35:37 +01:00
Makefile.in Remove Cilk Plus support. 2017-11-28 11:35:37 +01:00
Makefile.tpl
missing
mkdep
mkinstalldirs
move-if-change
README
symlink-tree
ylwrap

This directory contains the GNU Compiler Collection (GCC).

The GNU Compiler Collection is free software.  See the files whose
names start with COPYING for copying permission.  The manuals, and
some of the runtime libraries, are under different terms; see the
individual source files for details.

The directory INSTALL contains copies of the installation information
as HTML and plain text.  The source of this information is
gcc/doc/install.texi.  The installation information includes details
of what is included in the GCC sources and what files GCC installs.

See the file gcc/doc/gcc.texi (together with other files that it
includes) for usage and porting information.  An online readable
version of the manual is in the files gcc/doc/gcc.info*.

See http://gcc.gnu.org/bugs/ for how to report bugs usefully.

Copyright years on GCC source files may be listed using range
notation, e.g., 1987-2012, indicating that every year in the range,
inclusive, is a copyrightable year that could otherwise be listed
individually.