aboutsummaryrefslogtreecommitdiff
path: root/libgcc/config.host
AgeCommit message (Collapse)AuthorFilesLines
2022-10-19gcc: Add 'mcf' thread model support from mcfgthreadLIU Hao1-0/+6
This patch adds the new thread model `mcf`, which implements mutexes and condition variables with the mcfgthread library. Source code for mcfgthread is available at <https://github.com/lhmouse/mcfgthread>. config/ChangeLog: * gthr.m4 (GCC_AC_THREAD_HEADER): Add new case for `mcf` thread model gcc/ChangeLog: * config/i386/mingw-mcfgthread.h: New file * config/i386/mingw32.h: Add builtin macro and default libraries for mcfgthread when thread model is `mcf` * config.gcc: Include 'i386/mingw-mcfgthread.h' when thread model is `mcf` * configure.ac: Recognize `mcf` as a valid thread model * config.in: Regenerate * configure: Regenerate libatomic/ChangeLog: * configure.tgt: Add new case for `mcf` thread model libgcc/ChangeLog: * config.host: Add new cases for `mcf` thread model * config/i386/gthr-mcf.h: New file * config/i386/t-mingw-mcfgthread: New file * config/i386/t-slibgcc-cygming: Add mcfgthread for libgcc DLL * configure: Regenerate libstdc++-v3/ChangeLog: * libsupc++/atexit_thread.cc (__cxa_thread_atexit): Use implementation from mcfgthread if available * libsupc++/guard.cc (__cxa_guard_acquire, __cxa_guard_release, __cxa_guard_abort): Use implementations from mcfgthread if available * configure: Regenerate
2022-10-11Generic configury support for shared libs on VxWorksOlivier Hainque1-1/+30
This change adds the configury bits to activate the build of shared libs on VxWorks ports configured with --enable-shared, for libraries variants where this is generally supported (rtp, code model !large - currently not compatible with -fPIC). Set lt_cv_deplibs_check_method in libtool.m4, so the build of libraries know how to establish dependencies. This is useful in configurations such as aarch64 where proper support of LSE relies on accurate dependency information between libstdc++ and libgcc_s to begin with. Regenerate configure scripts to reflect libtool.m4 change. 2022-10-09 Olivier Hainque <hainque@adacore.com> * libtool.m4 (*vxworks*): When enable_shared, set dynamic_linker and friends for rtp !large. Assume the linker has the required abilities and set lt_cv_deplibs_check_method. gcc/ * config.gcc (*vxworks*): Add t-slibgcc fragment if enable_shared. libgcc/ * config.host (*vxworks*): When enable_shared, add libgcc and crtstuff "shared" fragments for rtp except large code model. (aarch64*-wrs-vxworks7*): Remove t-slibgcc-libgcc from the list of fragments. 2022-10-09 Olivier Hainque <hainque@adacore.com> gcc/ * configure: Regenerate. libatomic/ * configure: Regenerate. libbacktrace/ * configure: Regenerate. libcc1/ * configure: Regenerate. libffi/ * configure: Regenerate. libgfortran/ * configure: Regenerate. libgomp/ * configure: Regenerate. libitm/ * configure: Regenerate. libobjc/ * configure: Regenerate. liboffloadmic/ * configure: Regenerate. liboffloadmic/ * plugin/configure: Regenerate. libphobos/ * configure: Regenerate. libquadmath/ * configure: Regenerate. libsanitizer/ * configure: Regenerate. libssp/ * configure: Regenerate. libstdc++-v3/ * configure: Regenerate. libvtv/ * configure: Regenerate. lto-plugin/ * configure: Regenerate. zlib/ * configure: Regenerate.
2022-08-3132-bit PA-RISC with HP-UX: remove deprecated portsMartin Liska1-22/+0
ChangeLog: * configure: Regenerate. * configure.ac: Delete hpux9 and hpux10. config/ChangeLog: * mh-pa-hpux10: Removed. contrib/ChangeLog: * config-list.mk: Remove deprecated ports. contrib/header-tools/ChangeLog: * README: Remove deprecated ports. * reduce-headers: Likewise. gcc/ChangeLog: * config.build: Remove deprecated ports. * config.gcc: Likewise. * config.host: Likewise. * configure.ac: Likewise. * configure: Regenerate. * config/pa/pa-hpux10.h: Removed. * config/pa/pa-hpux10.opt: Removed. * config/pa/t-dce-thr: Removed. gnattools/ChangeLog: * configure.ac: Remove deprecated ports. * configure: Regenerate. libstdc++-v3/ChangeLog: * configure: Regenerate. * crossconfig.m4: Remove deprecated ports. gcc/testsuite/ChangeLog: * g++.dg/cpp0x/lambda/lambda-conv.C: Remove useless test. * gcc.c-torture/execute/ieee/hugeval.x: Likewise. * gcc.dg/torture/pr47917.c: Likewise. * lib/target-supports.exp: Likewise. libgcc/ChangeLog: * config.host: Remove hppa. libitm/ChangeLog: * configure: Regenerate. fixincludes/ChangeLog: * configure: Regenerate.
2022-08-30m32c-rtems: remove obsoleted portMartin Liska1-1/+1
contrib/ChangeLog: * config-list.mk: Remove the port. gcc/ChangeLog: * config.gcc: Remove the port. * config/m32c/rtems.h: Removed. libgcc/ChangeLog: * config.host: Remove the port.
2022-08-26cr16: remove obsoleted portMartin Liska1-6/+0
contrib/ChangeLog: * config-list.mk: Remove cr16. gcc/ChangeLog: * doc/extend.texi: Remove cr16 related stuff. * doc/install.texi: Likewise. * doc/invoke.texi: Likewise. * doc/md.texi: Likewise. * function-tests.cc (test_expansion_to_rtl): Likewise. * common/config/cr16/cr16-common.cc: Removed. * config/cr16/constraints.md: Removed. * config/cr16/cr16-protos.h: Removed. * config/cr16/cr16.cc: Removed. * config/cr16/cr16.h: Removed. * config/cr16/cr16.md: Removed. * config/cr16/cr16.opt: Removed. * config/cr16/predicates.md: Removed. * config/cr16/t-cr16: Removed. libgcc/ChangeLog: * config.host: Remove cr16 related stuff. * config/cr16/crti.S: Removed. * config/cr16/crtlibid.S: Removed. * config/cr16/crtn.S: Removed. * config/cr16/divmodhi3.c: Removed. * config/cr16/lib1funcs.S: Removed. * config/cr16/t-cr16: Removed. * config/cr16/t-crtlibid: Removed. * config/cr16/unwind-cr16.c: Removed. * config/cr16/unwind-dw2.h: Removed. gcc/testsuite/ChangeLog: * lib/target-supports.exp: Remove cr16 related stuff.
2022-06-25Remove long deprecated tilegx and tilepro portsJeff Law1-17/+0
/ * MAINTAINERS: Remove tilegx and tilepro entries. * configure.ac: Remove tilegx and tilepro stanzas. * configure: Rebuilt. contrib/ * config-list.mk: Remove tilegx and tilepro entries. * gcc_update: Remove tilegx and tilepro entries. gcc/ * common/config/tilegx/tilegx-common.cc: Removed. * common/config/tilepro/tilepro-common.cc: Removed. * config.gcc: Remove tilegx and tilepro entries. * config/tilegx/constraints.md: Removed. * config/tilegx/feedback.h: Removed. * config/tilegx/linux.h: Removed. * config/tilegx/mul-tables.cc: Removed. * config/tilegx/predicates.md: Removed. * config/tilegx/sync.md: Removed. * config/tilegx/t-tilegx: Removed. * config/tilegx/tilegx-builtins.h: Removed. * config/tilegx/tilegx-c.cc: Removed. * config/tilegx/tilegx-generic.md: Removed. * config/tilegx/tilegx-modes.def: Removed. * config/tilegx/tilegx-multiply.h: Removed. * config/tilegx/tilegx-opts.h: Removed. * config/tilegx/tilegx-protos.h: Removed. * config/tilegx/tilegx.cc: Removed. * config/tilegx/tilegx.h: Removed. * config/tilegx/tilegx.md: Removed. * config/tilegx/tilegx.opt: Removed. * config/tilepro/constraints.md: Removed. * config/tilepro/feedback.h: Removed. * config/tilepro/gen-mul-tables.cc: Removed. * config/tilepro/linux.h: Removed. * config/tilepro/mul-tables.cc: Removed. * config/tilepro/predicates.md: Removed. * config/tilepro/t-tilepro: Removed. * config/tilepro/tilepro-builtins.h: Removed. * config/tilepro/tilepro-c.cc: Removed. * config/tilepro/tilepro-generic.md: Removed. * config/tilepro/tilepro-modes.def: Removed. * config/tilepro/tilepro-multiply.h: Removed. * config/tilepro/tilepro-protos.h: Removed. * config/tilepro/tilepro.cc: Removed. * config/tilepro/tilepro.h: Removed. * config/tilepro/tilepro.md: Removed. * config/tilepro/tilepro.opt: Removed. * configure.ac: Remove tilegx and tilepro entries. * configure: Rebuilt. * doc/extend.texi: Remove tilegx and tilepro entries. * doc/install.texi: Remove tilegx and tilepro entries. * doc/invoke.texi: Remove tilegx and tilepro entries. * doc/md.texi: Remove tilegx and tilepro entries. gcc/testsuite/ * gcc.dg/lower-subreg-1.c: Remove tilegx and tilepro entries. * gcc.misc-tests/linkage.exp: Remove tilegx and tilepro entries. libgcc/ * config.host: Removed tilegx and tilepro entries. * config/tilegx/sfp-machine.h: Removed. * config/tilegx/sfp-machine32.h: Removed. * config/tilegx/sfp-machine64.h: Removed. * config/tilegx/t-crtstuff: Removed. * config/tilegx/t-softfp: Removed. * config/tilegx/t-tilegx: Removed. * config/tilepro/atomic.c: Removed. * config/tilepro/atomic.h: Removed. * config/tilepro/linux-unwind.h: Removed. * config/tilepro/sfp-machine.h: Removed. * config/tilepro/softdivide.c: Removed. * config/tilepro/softmpy.S: Removed. * config/tilepro/t-crtstuff: Removed. * config/tilepro/t-tilepro: Removed.
2022-05-20libgcc: enable DFP for AArch64Christophe Lyon1-0/+6
DFP support on AArch64 relies on libgcc, so enable its DFP routines for all AArch64 targets. 2022-03-31 Christophe Lyon <christophe.lyon@arm.com> libgcc/ * config.host: Add t-dfprules to AArch64 targets.
2022-03-29LoongArch Port: libgccchenglulu1-1/+27
2022-03-29 Chenghua Xu <xuchenghua@loongson.cn> Lulu Cheng <chenglulu@loongson.cn> libgcc/ChangeLog: * config/loongarch/crtfastmath.c: New file. * config/loongarch/linux-unwind.h: Like wise. * config/loongarch/sfp-machine.h: Like wise. * config/loongarch/t-crtstuff: Like wise. * config/loongarch/t-loongarch: Like wise. * config/loongarch/t-loongarch64: Like wise. * config/loongarch/t-softfp-tf: Like wise. * config.host: Add LoongArch tuples. * configure.ac: Add LoongArch support.
2022-01-03Update copyright years.Jakub Jelinek1-1/+1
2021-12-17libgcc, Darwin: Add missing build dependencies.Iain Sandoe1-0/+4
There was a race condition where the link for the new shared EH library (only used on earlier Darwin) could fail because the new crts had not been copied to the gcc directory. This can cause a build failure (although currently only seen on powerpc-darwin). Fixed by adding specific dependency on the crts and on the multi target. We also add the declaration header for the Darwin10 unwinder shim to the powerpc cases, since we build that there for Rosetta use. Signed-off-by: Iain Sandoe <iain@sandoe.co.uk> libgcc/ChangeLog: * config.host: Add shim declaration header to powerpc*-darwin builds. * config/rs6000/t-darwin-ehs: Remove dependency on the powerpc end file. * config/t-darwin-ehs: Add dependencies to the shared unwinder objects. * config/t-slibgcc-darwin: Add extra_parts to the dependencies for the shared EH lib. Add all-multi to the dependencies for the libgcc_s.1.dylib redirections.
2021-12-13Remove ppc*-vxworks7* inadequate libgcc Makefile fragmentsOlivier Hainque1-1/+1
t-linux assigns .so version numbers to a set of symbols, some of which aren't included the VxWorks libgcc on powerpc (from ibm-ldouble.c, in particular). t-slibgcc-libgcc yields a kind of .so file that the default loader can't handle. This sort of extension to tmake_file for shared libs will be better handled in a grouped fashion for all targets anyway. 2021-12-13 Olivier Hainque <hainque@adacore.com> * config.host (powerpc*-*-vxworks7*): Remove rs6000/t-linux and t-slibgcc-libgcc from tmake_file.
2021-12-13Remove special case for arm-vxworks on the use of vxcrtstuffOlivier Hainque1-4/+1
Not needed any more after the recent cleanups issued for the support of shared libraries. 2021-12-13 Olivier Hainque <hainque@adacore.com> libgcc/ * config.host (*vxworks*): Remove special case for arm on the use of vxcrtstuff.
2021-12-13Preserve cpu specific CRTSTUFF_T_CFLAGS on powerpc-vxworks7Olivier Hainque1-1/+2
The unconditional assignment performed in t-vxworks to handle include flags currently overrides what specific cpu ports had for the regular (!vxworks) crtstuff objects. This was not done on purpose and the proposed change adjusts the configuration bits to apply the vxworks specific flags on top of the cpu ones instead. 2021-12-07 Olivier Hainque <hainque@adacore.com> * config.host (powerpc*-wrs-vxworks7*): Place t-crtstuff ahead of the other files in tmake_files. * config/t-vxworks: Add to CRTSTUFF_T_CFLAGS instead of overriding it.
2021-12-13Leverage sysroot for VxWorksOlivier Hainque1-3/+0
The build of a VxWorks toolchain relies a lot on system headers and VxWorks has a few very specific features that require special processing. For example, different sets of headers for the kernel vs the rtp modes, which the compiler knows about by way of -mrtp on the command line. If we manage to avoid the need for fixincludes on recent versions of VxWorks (>= 7), we still need to handle at least VxWorks 6.9 at this stage. We sort of get away with locating the correct headers at run-time thanks to environment variables and various tests for -mrtp in cpp specs, but getting fixincludes to work for old configurations has always been tricky and getting a toolchain to build with c++/libstdc++ support gets trickier with every move to a more recent release. sysroot_headers_suffix_spec is a pretty powerful device to help address such issues, and this patch introduces changes that let us get advantage of it. The general idea is to leverage the assumption that compilations occur with --sysroot=$VSB_DIR on vx7 or --sysroot=$WIND_BASE/target prior to that. For the toolchains we build, this is achieved with a few configure options like: --with-sysroot --with-build-sysroot=${WIND_BASE}/target --with-specs=%{!sysroot=*:--sysroot=%:getenv(WIND_BASE /target)} This also allows simplifying the libgcc compilation flags control and we take the opportunity to merge t-vxworks7 into t-vxworks as the two files were differing only on the libgcc2 flags part. 2021-12-09 Olivier Hainque <hainque@adacore.com> gcc/ * config/t-vxworks: Clear NATIVE_SYSTEM_HEADER_DIR. * config/vxworks.h (SYSROOT_HEADERS_SUFFIX_SPEC): Define, for VxWorks 7 and earlier. (VXWORKS_ADDITIONAL_CPP_SPEC): Simplify accordingly. (STARTFILE_PREFIX_SPEC): Adjust accordingly. * config/rs6000/vxworks.h (STARTFILE_PREFIX_SPEC): Adjust. libgcc/ * config/t-vxworks (LIBGCC2_INCLUDES): Simplify and handle both VxWorks7 and earlier. * config/t-vxworks7: Remove. * config.host: Remove special case for vxworks7.
2021-12-10Replace t-ppccomm by t-vxworks in libgcc/config/rs6000Rasmus Villemoes1-2/+2
This removes ibm-ldouble.c and a few eabi crt files from the build closure, which were producing objects we don't use anyway. 2021-12-07 Rasmus Villemoes <rv@rasmusvillemoes.dk> libgcc/ * config/rs6000/t-vxworks: New file. * config.host (powerpc*-*-vxworks*): Use it instead of t-ppccomm.
2021-12-09Fix path to t-ppc64-fp for ppc*-vxworks7* libgcc tmake_fileFrederic Konrad1-1/+1
This fixes a basic mistake in the relative path used to reference a rs6000 specific Makefile fragment in the libgcc configuration bits for powerpc*-vxworks7. 2021-01-14 Fred Konrad <konrad@adacore.com> libgcc/ * config.host (powerpc*-wrs-vxworks7*): Fix path to rs6000/t-ppc64-fp, relative to config/ not libgcc/.
2021-12-08libgcc, Darwin: Build a libgcc_s.1 for backwards compatibility.Iain Sandoe1-3/+10
In order to reslve a long-standing issue with inter-operation with libSystem, we have bumped the SO name for libgcc_s. Distributions might wish to install this new version into a structure where exisiting code is already linked with the compiler-local libgcc_s.1 (providing symbols exported by the now-retired libgcc_ext.10.x shims). The replacement libgcc_s.1 forwards the symbols from the new SO. In order to support DYLD_LIBRARY_PATH on systems (where it works) we forward the libSystem unwinder symbols from 10.7+ and a compiler-local version of the libgcc unwinder on earlier. For macOS 10.4 to 10.6 this is 'bug-compatible' with existing uses. For 10.7+ the behaviour will now actually be correct. This should be squashed with the initial libgcc changes for PR80556 in any backport (r12-5418-gd4943ce939d) libgcc/ChangeLog: * config.host (*-*-darwin*): Add logic to build a shared unwinder library for Darwin8-10. * config/i386/t-darwin: Build legacy libgcc_s.1. * config/rs6000/t-darwin: Likewise. * config/t-darwin: Reorganise the EH fragments to place them for inclusion in a shared EH lib. * config/t-slibgcc-darwin: Build a legacy libgcc_s.1 and the supporting pieces (all FAT libs). * config/t-darwin-noeh: Removed. * config/darwin-unwind.ver: New file. * config/rs6000/t-darwin-ehs: New file. * config/t-darwin-ehs: New file.
2021-11-29libgcc: remove crt{begin,end}.o from powerpc-wrs-vxworks targetRasmus Villemoes1-1/+0
Since commit 78e49fb1bc (Introduce vxworks specific crtstuff support), the generic crtbegin.o/crtend.o have been unnecessary to build. So remove them from extra_parts. This is effectively a revert of commit 9a5b8df70 (libgcc: add crt{begin,end} for powerpc-wrs-vxworks target). libgcc/ * config.host (powerpc-wrs-vxworks): Do not add crtbegin.o and crtend.o to extra_parts.
2021-11-19Darwin: Rework handling for unwinder code in libgcc_s and specs [PR80556].Iain Sandoe1-2/+5
This addresses a long-standing problem where a work-around for an unwinder issue (also a regression) regresses other functionality. The patch replaces several work-arounds with a fix for PR80556 and a work-around for PR88590. * The fix for PR80556 requires a bump to the SO name for libgcc_s, since we need to remove the unwinder symbols from it. This would trigger PR88590 hence the work-around for that. * We weaken the symbols for emulated TLS support so that it is possible for a DSO linked with static-libgcc to interoperate with a DSO linked with libgcc_s. Likewise main exes. * We remove all the gcc-4.2.1 era stubs machinery and workarounds. * libgcc is always now linked ahead of libc, which avoids fails where the libc (libSystem) builtins implementations are not up to date. * The unwinder now always comes from the system - for Darwin9 from /usr/lib/libgcc_s.1.dylib - for Darwin10 from /usr/lib/libSystem.dylib - for Darwin11+ from /usr/lib/system/libunwind.dylib. We still insert a shim on Darwin10 to fix an omitted unwind function, but the underlying unwinder remains the system one. * The work-around for PR88590 has two parts (1) we always link libgcc from its convenience lib on affected system versions (avoiding the need to find the DSO path); (2) we add and export the emutls functions from DSOs - this makes a relatively small (20k) addition to a DSO. These can be backed out when a proper fix for PR88590 is committed. For distributions that wish to install a libgcc_s.1.dylib to satisfy linkage from exes that linked against the stubs can use a reexported libgcc_s.1.1 (since that contains all the symbols that were previously exported via the stubs). Signed-off-by: Iain Sandoe <iain@sandoe.co.uk> gcc/ChangeLog: PR target/80556 * config/darwin-driver.c (darwin_driver_init): Handle exported symbols and symbol lists (suppress automatic export of the TLS symbols). * config/darwin.c (darwin_rename_builtins): Remove workaround. * config/darwin.h (LINK_GCC_C_SEQUENCE_SPEC): Likewise. (REAL_LIBGCC_SPEC): Handle revised library uses. * config/darwin.opt (nodefaultexport): New. * config/i386/darwin.h (PR80556_WORKAROUND): Remove. * config/i386/darwin32-biarch.h (PR80556_WORKAROUND): Likewise. * config/i386/darwin64-biarch.h (PR80556_WORKAROUND): Likewise. libgcc/ChangeLog: * config.host: Add weak emutls crt to the extra_parts. * config/i386/darwin-lib.h (DECLARE_LIBRARY_RENAMES): Remove workaround. * config/libgcc-libsystem.ver: Add exclude list for the system- provided unwinder. * config/t-slibgcc-darwin: Bump SO version, remove stubs code. * config/i386/libgcc-darwin.10.4.ver: Removed. * config/i386/libgcc-darwin.10.5.ver: Removed. * config/rs6000/libgcc-darwin.10.4.ver: Removed. * config/rs6000/libgcc-darwin.10.5.ver: Removed. * config/t-darwin-noeh: New file. gcc/testsuite/ChangeLog: * gcc.dg/torture/fp-int-convert-timode-3.c: Remove XFAIL. * gcc.dg/torture/fp-int-convert-timode-4.c: Likewise.
2021-11-05Support TI mode and soft float on PA64John David Anglin1-2/+5
This change implements TI mode on PA64. Various new patterns are added to pa.md. The libgcc build needed modification to build both DI and TI routines. We also need various softfp routines to convert to and from TImode. I added full softfp for the -msoft-float option. At the moment, this doesn't completely eliminate all use of the floating-point co-processor. For this, libgcc needs to be built with -msoft-mult. The floating-point exception support also needs a soft option. 2021-11-05 John David Anglin <danglin@gcc.gnu.org> PR libgomp/96661 gcc/ChangeLog: * config/pa/pa-modes.def: Add OImode integer type. * config/pa/pa.c (pa_scalar_mode_supported_p): Allow TImode for TARGET_64BIT. * config/pa/pa.h (MIN_UNITS_PER_WORD) Define to MIN_UNITS_PER_WORD to UNITS_PER_WORD if IN_LIBGCC2. * config/pa/pa.md (addti3, addvti3, subti3, subvti3, negti2, negvti2, ashlti3, shrpd_internal): New patterns. Change some multi instruction types to multi. libgcc/ChangeLog: * config.host (hppa*64*-*-linux*): Revise tmake_file. (hppa*64*-*-hpux11*): Likewise. * config/pa/sfp-exceptions.c: New. * config/pa/sfp-machine.h: New. * config/pa/t-dimode: New. * config/pa/t-softfp-sfdftf: New.
2021-10-27Fix warnings building linux-atomic.c and fptr.c on hppa64-linuxJohn David Anglin1-1/+1
The file fptr.c is specific to 32-bit hppa-linux and should not be included in LIB2ADD on hppa64-linux. There is a builtin type mismatch in linux-atomic.c using the type long long unsigned int for 64-bit atomic operations on hppa64-linux. 2021-10-27 John David Anglin <danglin@gcc.gnu.org> libgcc/ChangeLog: * config.host (hppa*64*-*-linux*): Don't add pa/t-linux to tmake_file. * config/pa/linux-atomic.c: Define u8, u16 and u64 types. Use them in FETCH_AND_OP_2, OP_AND_FETCH_2, COMPARE_AND_SWAP_2, SYNC_LOCK_TEST_AND_SET_2 and SYNC_LOCK_RELEASE_1 macros. * config/pa/t-linux64 (LIB1ASMSRC): New define. (LIB1ASMFUNCS): Revise. (HOST_LIBGCC2_CFLAGS): Add "-DLINUX=1".
2021-09-19Darwin, crts: Build Darwin10 unwinder shim as a library.Iain Sandoe1-1/+1
We have a small unwinder shim that is only used for Darwin10 (and only then in quite specific cases). To avoid linking this code for every executable or DSO, we can present the crt as a convenience library (rather than a .o file). Signed-off-by: Iain Sandoe <iain@sandoe.co.uk> gcc/ChangeLog: * config/darwin.h (LINK_COMMAND_SPEC_A): Use Darwin10 unwinder shim as a convenience library. libgcc/ChangeLog: * config.host: Use convenience library for Darwin10 unwinder shim. * config/t-darwin: Build Darwin10 unwinder shim as a convenience library.
2021-09-13Remove m32r{,le}-*-linux* support from GCCAndrew Pinski1-6/+0
m32r support never made it to glibc and the support for the Linux kernel was removed with 4.18. It does not remove much but no reason to keep around a port which never worked or one which the support in other projects is gone. OK? Checked to make sure m32r-linux and m32rle-linux were rejected when building. contrib/ChangeLog: * config-list.mk: Remove m32r-linux and m32rle-linux from the list. gcc/ChangeLog: * config.gcc: Add m32r-*-linux* and m32rle-*-linux* to the Unsupported targets list. Remove support for m32r-*-linux* and m32rle-*-linux*. * config/m32r/linux.h: Removed. * config/m32r/t-linux: Removed. libgcc/ChangeLog: * config.host: Remove m32r-*-linux* and m32rle-*-linux*. * config/m32r/libgcc-glibc.ver: Removed. * config/m32r/t-linux: Removed.
2021-09-02libgcc: Enable hfmode soft-sf/df/xf/tf extensions and truncations.liuhongt1-4/+1
libgcc/ChangeLog: * config/i386/32/sfp-machine.h (_FP_NANFRAC_H): New macro. * config/i386/64/sfp-machine.h (_FP_NANFRAC_H): Ditto. * config/i386/sfp-machine.h (_FP_NANSIGN_H): Ditto. * config/i386/t-softfp: Add hf soft-fp. * config.host: Add i386/64/t-softfp. * config/i386/64/t-softfp: New file.
2021-08-21Don't build libgcc_stub.a on hppa[12]*-*-hpux11*.John David Anglin1-1/+0
2021-08-21 John David Anglin <danglin@gcc.gnu.org> libgcc/ChangeLog: * config.host: Remove extra_parts from hppa[12]*-*-hpux11* case.
2021-08-15or1k: Use cmodel=large when building crtstuffStafford Horne1-2/+2
When linking gcc runtime objects into large binaries the link may fail with the below errors. This will happen even if we are building with -mcmodel=large. /home/shorne/work/openrisc/output/host/lib/gcc/or1k-buildroot-linux-uclibc/10.3.0/crtbeginS.o: in function `deregister_tm_clones': crtstuff.c:(.text+0x3c): relocation truncated to fit: R_OR1K_GOT16 against undefined symbol `_ITM_deregisterTMCloneTable' /home/shorne/work/openrisc/output/host/lib/gcc/or1k-buildroot-linux-uclibc/10.3.0/crtbeginS.o: in function `register_tm_clones': crtstuff.c:(.text+0xc0): relocation truncated to fit: R_OR1K_GOT16 against undefined symbol `_ITM_registerTMCloneTable' This patch builds the gcc crtstuff binaries always with the -mcmodel=large option to ensure they can be linked into large binaries. libgcc/ChangeLog: PR target/99783 * config.host (or1k-*, tmake_file): Add or1k/t-crtstuff. * config/or1k/t-crtstuff: New file.
2021-06-09Conversions between 128-bit integer and floating point values.Carl Love1-0/+4
The files fixkfti-sw.c and fixunskfti-sw.c are renamed versions of fixkfti.c and fixunskfti.c respectively to do the conversions in software. The function names in the files were updated with the rename as well as some white spaces fixes. The file float128-p10.c contains the functions for using the ISA 3.1 hardware instructions to perform the conversions. 2021-06-08 Carl Love <cel@us.ibm.com> gcc/ChangeLog * config/rs6000/rs6000.c (__fixkfti, __fixunskfti, __floattikf, __floatuntikf): Names changed to __fixkfti_sw, __fixunskfti_sw, __floattikf_sw, __floatuntikf_sw respectively. * config/rs6000/rs6000.md (floatti<mode>2, floatunsti<mode>2, fix_trunc<mode>ti2, fixuns_trunc<mode>ti2): Add define_insn for mode IEEE 128. gcc/testsuite/ChangeLog * gcc.target/powerpc/fp128_conversions.c: New file. * gcc.target/powerpc/int_128bit-runnable.c(vextsd2q, vcmpuq, vcmpsq, vcmpequq, vcmpequq., vcmpgtsq, vcmpgtsq. vcmpgtuq, vcmpgtuq.): Update scan-assembler-times. (ppc_native_128bit): Remove dg-require-effective-target. libgcc/ChangeLog * config.host: Add if test and set for libgcc_cv_powerpc_3_1_float128_hw. * config/rs6000/fixkfti.c: Renamed to fixkfti-sw.c. Change calls of __fixkfti to __fixkfti_sw. * config/rs6000/fixunskfti.c: Renamed to fixunskfti-sw.c. Change calls of __fixunskfti to __fixunskfti_sw. * config/rs6000/float128-p10.c (__floattikf_hw, __floatuntikf_hw, __fixkfti_hw, __fixunskfti_hw): New file. * config/rs6000/float128-ifunc.c (SW_OR_HW_ISA3_1): New macro. (__floattikf_resolve, __floatuntikf_resolve, __fixkfti_resolve, __fixunskfti_resolve): Add resolve functions. (__floattikf, __floatuntikf, __fixkfti, __fixunskfti): New functions. * config/rs6000/float128-sed (floattitf, __floatuntitf, __fixtfti, __fixunstfti): Add editor commands to change names. * config/rs6000/float128-sed-hw (__floattitf, __floatuntitf, __fixtfti, __fixunstfti): Add editor commands to change names. * config/rs6000/floattikf.c: Renamed to floattikf-sw.c. * config/rs6000/floatuntikf.c: Renamed to floatuntikf-sw.c. * config/rs6000/quad-float128.h (__floattikf_sw, __floatuntikf_sw, __fixkfti_sw, __fixunskfti_sw, __floattikf_hw, __floatuntikf_hw, __fixkfti_hw, __fixunskfti_hw, __floattikf, __floatuntikf, __fixkfti, __fixunskfti): New extern declarations. * config/rs6000/t-float128 (floattikf, floatuntikf, fixkfti, fixunskfti): Remove file names from fp128_ppc_funcs. (floattikf-sw, floatuntikf-sw, fixkfti-sw, fixunskfti-sw): Add file names to fp128_ppc_funcs. * config/rs6000/t-float128-hw(fp128_3_1_hw_funcs, fp128_3_1_hw_src, fp128_3_1_hw_static_obj, fp128_3_1_hw_shared_obj, fp128_3_1_hw_obj): Add variables for ISA 3.1 support. * config/rs6000/t-float128-p10-hw: New file. * configure: Update script for isa 3.1 128-bit float support. * configure.ac: Add check for 128-bit float hardware support.
2021-01-04Update copyright years.Jakub Jelinek1-1/+1
2020-11-03Sync the aarch64-vx7r2 libgcc config with that of LinuxPat Bernardi1-0/+1
This adds ${cpu_type}/t-lse and t-slibgcc-libgcc to the tmake_file list for aarch64-vxworks7* configurations, as the Linux port does. t-lse is needed by all triplets now anyway and the standard setting for slibgcc makes sense as we are working on reintroducing PIC support for RTPs on various targets. The VxWorks7 system environments are leaning towards more and more similarilties with Linux in general, so the closer configurations the better. 2020-11-02 Pat Bernardi <bernardi@adacore.com> libgcc/ * config.host (aarch64-vxworks7*, tmake_file): Add ${cpu_type}/t-lse and t-slibgcc-libgcc. Co-authored-by: Olivier Hainque <hainque@adacore.com>
2020-10-30Introduce support for vxworks7r2 on x86 and x86_64Olivier Hainque1-1/+1
This change extends the VxWorks support on intel CPUs to VxWorks7r2 for x86_64 as well as x86, with a "mcmodel=large" additional multilib for the 64bit configuration. The support for fPIC is not functional yet for this model, so we just don't add the corresponding multilib. We extend the range of CPU families handled by TARGET_OS_CPP_BUILTINS, accounting for the fact that archs older than PENTIUM4 are not supported (any more) by VxWorks 7. As we did for powerpc, we leverage VX_CPU_PREFIX to emit different forms of definitions for different families of VxWorks as the system headers's expectations has evolved between Vx 5, 6 and 7. 2020-10-27 Olivier Hainque <hainque@adacore.com> gcc/ * config.gcc: Adjust the ix86/x86_64-wrs-vxworks filters to apply to VxWorks 7 as well. * config/i386/t-vxworks (MULTILIB_OPTIONS, MULTILIB_DIRNAMES): Remove the fPIC multilib and add one for the large code model on x86_64. * config/i386/vxworks.h: Separate sections for TARGET_VXWORKS7, other variants and common bits. (TARGET_OS_CPP_BUILTINS): Augment to support a range of CPU families. Leverage VX_CPU_PREFIX. (CC1_SPEC): Add definition. (STACK_CHECK_PROTECT): Use conditional expression instead of heavier to read conditioned macro definitions. libgcc/ * config.host: Adjust the ix86/x86_64-wrs-vxworks filters to apply to VxWorks 7 as well. Co-authored-by: Douglas Rupp <rupp@adacore.com> Co-authored-by: Pat Bernardi <bernardi@adacore.com>
2020-10-21Introduce vxworks7r2 support for ppc and ppc64Douglas Rupp1-0/+17
This change introduces support for the most recent versions of VxWorks on PowerPC targets, for both 32 and 64 bit thanks to a bi-arch setup. The system compilers are essentially configured as Linux toolchains with only a few specificities and we replicate that model here. The most visible specificities are the use of secureplt by default, the pre-definition of some macros that the system headers still rely on (_VX_CPU and _VX_CPU_FAMILY, for example), and of course some variations related to the so VxWorks typical kernel vs RTP mode distinction. In addition to the introduction of config.gcc and libgcc configuration chunks, much inspired by the linux ones, the change - Reworks rs6000/vxworks.h file to feature bits common to the Vx6 and Vx7 port then a separate section for each, where the Vx7 part is very short as we rely on the Linux definitions for most things. - Adjusts the CPU macro predefinitions in CPP_SPEC to resort to "_VX_CPU" instead of "CPU" for Vx7, to better match the more recent system headers expectations, - Adds a cpu definition case for e6500. - Changes to the use SUB3TARGET_OVERRIDE_OPTIONS instead of SUBSUBTARGET_OVERRIDE_OPTIONS for specifics, so we don't override the Linux's version of the latter for vx7. 2020-10-20 Douglas Rupp <rupp@adacore.com> gcc/ * config.gcc (powerpc*-wrs-vxworks7r*): New case. * config/rs6000/vxworks.h: Rework to handle VxWorks7. Refactor as common bits + vx6 vs vx7 ones. For the latter, rely essentially on the Linux configuration and adjust CPU to _VX_CPU in CPP_SPEC. Add a case for e6500. Use SUB3TARGET_OVERRIDE_OPTIONS for specifics to preserve the Linux SUBSUBTARGET_OVERRIDE_OPTIONS for vx7. libgcc/ * config.host (powerpc*-wrs-vxworks7*): New case. * configure.ac: Handle powerpc*-*-vxworks7* as powerpc*-*-linux* for ppc-fp_type. * configure: Regenerate. Co-authored-by: Olivier Hainque <hainque@adacore.com>
2020-09-16C-SKY: Enable crtbegin/crtend.o of libgcc for elf targetJojo R1-1/+1
libgcc/ChangeLog: * config.host (C-SKY): Enable crtbegin/crtend.o of libgcc for elf target.
2020-06-21aix: Add GCC64 configuration and FAT target libraries.David Edelsohn1-1/+1
This patch adds the ability to configure GCC on AIX to build as a 64 bit application and to build target libraries "FAT" libraries in both 32 bit and 64 bit mode. The patch adds makefile fragment hooks to target libraries that allows them to include target-specific rules. The target specific rules for AIX place both 32 bit and 64 bit objects and shared objects in archives at the top-level, not multilib subdirectories. The multilibs are built in subdirectories, but must be combined during the last parts of the target library build process. Because of the way that GCC bootstrap works, the libraries must be combined during the multiple stages of GCC bootstrap, not solely when installed in the final destination, so the libraries are correct at the end of each target library build stage, not solely an install recipe. gcc/ChangeLog 2020-06-21 David Edelsohn <dje.gcc@gmail.com> * config.gcc: Use t-aix64, biarch64 and default64 for cpu_is_64bit. * config/rs6000/aix72.h (ASM_SPEC): Remove aix64 option. (ASM_SPEC32): New. (ASM_SPEC64): New. (ASM_CPU_SPEC): Remove vsx and altivec options. (CPP_SPEC_COMMON): Rename from CPP_SPEC. (CPP_SPEC32): New. (CPP_SPEC64): New. (CPLUSPLUS_CPP_SPEC): Rename to CPLUSPLUS_CPP_SPEC_COMMON.. (TARGET_DEFAULT): Only define if not BIARCH. (LIB_SPEC_COMMON): Rename from LIB_SPEC. (LIB_SPEC32): New. (LIB_SPEC64): New. (LINK_SPEC_COMMON): Rename from LINK_SPEC. (LINK_SPEC32): New. (LINK_SPEC64): New. (STARTFILE_SPEC): Add 64 bit version of crtcxa and crtdbase. (ASM_SPEC): Define 32 and 64 bit alternatives using DEFAULT_ARCH64_P. (CPP_SPEC): Same. (CPLUSPLUS_CPP_SPEC): Same. (LIB_SPEC): Same. (LINK_SPEC): Same. (SUBTARGET_EXTRA_SPECS): Add new 32/64 specs. * config/rs6000/defaultaix64.h: New file. * config/rs6000/t-aix64: New file. libgcc/ChangeLog 2020-06-21 David Edelsohn <dje.gcc@gmail.com> * config.host (extra_parts): Add crtcxa_64 and crtdbase_64. * config/rs6000/t-aix-cxa: Explicitly compile 32 bit with -maix32 and 64 bit with -maix64. * config/rs6000/t-slibgcc-aix: Remove extra @multilib_dir@ level. Build and install AIX-style FAT libraries. libgomp/ChangeLog 2020-06-21 David Edelsohn <dje.gcc@gmail.com> * Makefile.am (tmake_file): Build and install AIX-style FAT libraries. * Makefile.in: Regenerate * configure.ac (tmake_file): Substitute. * configure: Regenerate. * configure.tgt (powerpc-ibm-aix*): Define tmake_file. * config/t-aix: New file. libstdc++-v3/ChangeLog 2020-06-21 David Edelsohn <dje.gcc@gmail.com> * Makefile.am (tmake_file): Build and install AIX-style FAT libraries. * Makefile.in: Regenerate. * configure.ac (tmake_file): Substitute. * configure: Regenerate. * configure.host (aix*): Define tmake_file. * config/os/aix/t-aix: New file. libatomic/ChangeLog 2020-06-21 David Edelsohn <dje.gcc@gmail.com> * Makefile.am (tmake_file): Build and install AIX-style FAT libraries. * Makefile.in: Regenerate. * configure.ac (tmake_file): Substitute. * configure: Regenerate. * configure.tgt (powerpc-ibm-aix*): Define tmake_file. * config/t-aix: New file. libgfortran/ChangeLog 2020-06-21 David Edelsohn <dje.gcc@gmail.com> * Makefile.am (tmake_file): Build and install AIX-style FAT libraries. * Makefile.in: Regenerate. * configure.ac (tmake_file): Substitute. * configure: Regenerate. * configure.host: Add system configury stanza. Define tmake_file. * config/t-aix: New file.
2020-06-18hurd: libgcc unwinding support over signal trampolinesSamuel Thibault1-1/+7
libgcc/ * config.host (md_unwind_header) <i[34567]86-*-gnu*>: Set to 'i386/gnu-unwind.h' * config/i386/gnu-unwind.h: New file. Signed-off-by: Thomas Schwinge <thomas@codesourcery.com>
2020-05-09libgcc: cris: Remove support for crisv32-*-* and cris*-*-linuxHans-Peter Nilsson1-9/+0
Part of the removal of crisv32-* and cris-*-linux* (cris-elf remains). libgcc: * config.host: Remove support for crisv32-*-* and cris*-*-linux. * config/cris/libgcc-glibc.ver, config/cris/t-linux: Remove.
2020-05-05Delete changes meant for a private branch.Michael Meissner1-3/+0
2020-05-05 Michael Meissner <meissner@linux.ibm.com> * config/rs6000/rs6000-builtin.def: Delete changes meant for a private branch. * config/rs6000/rs6000-c.c: Likewise. * config/rs6000/rs6000-call.c: Likewise. * gcc/config/rs6000/rs6000.c: Likewise. 2020-05-05 Michael Meissner <meissner@linux.ibm.com> * gcc.dg/nextafter-2.c: Delete changes meant for a private branch. * gcc.target/powerpc/pr70117.c: Likewise. 2020-05-05 Michael Meissner <meissner@linux.ibm.com> * config.host: Delete changes meant for a private branch. * config/rs6000/t-float128: Likewise. * configure.ac: Likewise. * configure: Likewise.
2020-05-05Patch ieee128-lib-patch010bMichael Meissner1-0/+3
2020-03-04IBM Z: zTPF: Build libgcc with -mtpf-trace-skipAndreas Krebbel1-1/+1
libgcc is supposed to be built with the trace skip flags and branch targets. Add a zTPF header file fragment and add the -mtpf-trace-skip option. libgcc/ChangeLog: 2020-03-04 Andreas Krebbel <krebbel@linux.ibm.com> * config.host: Include the new makefile fragment. * config/s390/t-tpf: New file.
2020-01-31nios2: Support for GOT-relative DW_EH_PE_datarel encoding.Sandra Loosemore1-1/+2
On nios2-linux-gnu, there has been a long-standing bug in C++ exception handling that sometimes resulted in link errors like ../nios2-linux-gnu/bin/ld: FDE encoding in /tmp/cccfpQ2l.o(.eh_frame) prevents .eh_frame_hdr table being created when building some shared libraries or PIE executables. The root of the problem is that GCC was incorrectly emitting an absolute encoding in EH tables for PIC. This patch changes it to use either DW_EH_PE_indirect (for global) or DW_EH_PE_datarel (for local), and fixes libgcc so it can find the address of the GOT as the base address for DW_EH_PE_datarel. Complicating matters somewhat, GAS was missing support for %gotoff(symbol) relocation syntax. I have just pushed a fix for that, but I've added a configure check to test for presence of the binutils support and fall back to the current absolute encoding (which works most of the time) if it is not available. Once the fix makes it into an official binutils release it might be appropriate to make this error out instead. Since this is a wrong-code bug and affects only nios2 target, I think this is appropriate for Stage 4. I regression-tested on both nios2-linux-gnu and nios2-elf, with and without the binutils support present, before committing this. 2020-01-31 Sandra Loosemore <sandra@codesourcery.com> gcc/ * configure.ac [nios2-*-*]: Check HAVE_AS_NIOS2_GOTOFF_RELOCATION. * config.in: Regenerated. * configure: Regenerated. * config/nios2/nios2.h (ASM_PREFERRED_EH_DATA_FORMAT): Fix handling for PIC when HAVE_AS_NIOS2_GOTOFF_RELOCATION. (ASM_MAYBE_OUTPUT_ENCODED_ADDR_RTX): New. gcc/testsuite/ * g++.target/nios2/hello-pie.C: New. * g++.target/nios2/nios2.exp: New. libgcc/ * config.host [nios2-*-linux*] (tmake_file, tm_file): Adjust. * config/nios2-elf-lib.h: New. * unwind-dw2-fde-dip.c (_Unwind_IteratePhdrCallback): Use existing code for finding GOT base for nios2.
2020-01-08Implement 64-bit double functions.Georg-Johann Lay1-0/+23
gcc/ PR target/92055 * config.gcc (tm_defines) [target=avr]: Support --with-libf7, --with-double-comparison. * doc/install.texi: Document them. * config/avr/avr-c.c (avr_cpu_cpp_builtins) <WITH_LIBF7_LIBGCC, WITH_LIBF7_MATH, WITH_LIBF7_MATH_SYMBOLS> <WITH_DOUBLE_COMPARISON>: New built-in defines. * doc/invoke.texi (AVR Built-in Macros): Document them. * config/avr/avr-protos.h (avr_float_lib_compare_returns_bool): New. * config/avr/avr.c (avr_float_lib_compare_returns_bool): New function. * config/avr/avr.h (FLOAT_LIB_COMPARE_RETURNS_BOOL): New macro. libgcc/ PR target/92055 * config.host (tmake_file) [target=avr]: Add t-libf7, t-libf7-math, t-libf7-math-symbols as specified by --with-libf7=. * config/avr/t-avrlibc: Don't copy libgcc.a if there are modules depending on sizeof (double) or sizeof (long double). * config/avr/libf7: New folder. libgcc/config/avr/libf7/ PR target/92055 * t-libf7: New file. * t-libf7-math: New file. * t-libf7-math-symbols: New file. * libf7-common.mk: New file. * libf7-asm-object.mk: New file. * libf7-c-object.mk: New file. * asm-defs.h: New file. * libf7.h: New file. * libf7.c: New file. * libf7-asm.sx: New file. * libf7-array.def: New file. * libf7-const.def: New file. * libf7-constdef.h: New file. * f7renames.sh: New script. * f7wraps.sh: New script. * f7-renames.h: New generated file. * f7-wraps.h: New generated file. From-SVN: r279994
2020-01-01Update copyright years.Jakub Jelinek1-1/+1
From-SVN: r279813
2019-12-16MSP430: Add new msp430-elfbare targetJozef Lawrynowicz1-2/+2
contrib/ChangeLog: 2019-12-16 Jozef Lawrynowicz <jozef.l@mittosystems.com> * config-list.mk: Add msp430-elfbare. gcc/ChangeLog: 2019-12-16 Jozef Lawrynowicz <jozef.l@mittosystems.com> * config.gcc: s/msp430*-*-*/msp430-*-*. Handle msp430-*-elfbare. * config/msp430/msp430-devices.c (TARGET_SUBDIR): Define. (_MSPMKSTR): Define. (__MSPMKSTR): Define. (rest_of_devices_path): Use TARGET_SUBDIR value in string. * config/msp430/msp430.c (msp430_option_override): Error if -fuse-cxa-atexit is used when it has been disabled at configure time. * config/msp430/t-msp430: Define TARGET_SUBDIR when building msp430-devices.o. * doc/install.texi: Document msp430-*-elf and msp430-*-elfbare. * doc/invoke.texi: Update documentation about which path devices.csv is searched for. gcc/testsuite/ChangeLog: 2019-12-16 Jozef Lawrynowicz <jozef.l@mittosystems.com> * g++.dg/init/dso_handle1.C: Require cxa_atexit support. * g++.dg/init/dso_handle2.C: Likewise. * g++.dg/other/cxa-atexit1.C: Likewise. * gcc.target/msp430/msp430.exp: Update csv-using-installed.c test to handle msp430-elfbare configuration. libgcc/ChangeLog: 2019-12-16 Jozef Lawrynowicz <jozef.l@mittosystems.com> * config.host: s/msp430*-*-elf/msp430-*-elf*. Override default "extra_parts" variable. * configure: Regenerate. * configure.ac: Disable TM clone registry by default for msp430-elfbare. From-SVN: r279442
2019-12-11MSP430: Add -fno-exceptions multilibJozef Lawrynowicz1-1/+2
ChangeLog: 2019-12-11 Jozef Lawrynowicz <jozef.l@mittosystems.com> * config-ml.in (msp430-*-*): Support --disable-no-exceptions configure flag. gcc/ChangeLog: 2019-12-11 Jozef Lawrynowicz <jozef.l@mittosystems.com> * config/msp430/msp430.h (STARTFILE_SPEC) [!fexceptions]: Use crtbegin_no_eh.o if building for the C language. [fno-exceptions]: Use crtbegin_no_eh.o if building for any language except C. (ENDFILE_SPEC) [!fexceptions]: Use crtend_no_eh.o if building for the C language. [fno-exceptions]: Use crtend_no_eh.o if building for any language except C. * config/msp430/t-msp430: Add -fno-exceptions multilib. * doc/install.texi: Document --disable-no-exceptions multilib configure option. * doc/sourcebuild.texi: Document exceptions_enabled effective target. gcc/testsuite/ChangeLog: 2019-12-11 Jozef Lawrynowicz <jozef.l@mittosystems.com> * lib/gcc-dg.exp: Add dg-prune messages for when exception handling is disabled. * lib/target-supports.exp (check_effective_target_exceptions_enabled): New. libgcc/ChangeLog: 2019-12-11 Jozef Lawrynowicz <jozef.l@mittosystems.com> * config.host: Add crt{begin,end}_no_eh.o to "extra_parts". * config.host (msp430*-*-elf): Add crt{begin,end}_no_eh.o to "extra_parts". From-SVN: r279246
2019-11-18musl: Don't use gthr weak refs in libgcc PR91737Szabolcs Nagy1-0/+7
The gthr weak reference based single thread detection is unsafe with static linking and in case of dynamic linking it's ineffective on musl since pthread symbols are defined in libc.so. (Ideally this should be fixed for all targets, since glibc plans to move libpthread.so into libc.so too and users want to static link to pthread without --whole-archive: PR87189.) For now we have to explicitly opt out from the broken behaviour in the config machinery of each target lib and libgcc was previously missed. libgcc/ChangeLog: 2019-11-18 Szabolcs Nagy <szabolcs.nagy@arm.com> * config.host: Add t-gthr-noweak on *-*-musl*. * config/t-gthr-noweak: New file. From-SVN: r278399
2019-11-14Update the arm-*-vxworks* supportJerome Lambourg1-11/+5
2019-11-13 Jerome Lambourg <lambourg@adacore.com> Doug Rupp <rupp@adacore.com> Olivier Hainque <hainque@adacore.com> gcc/ * config.gcc: Collapse the arm-vxworks entries into a single arm-wrs-vxworks7* one, bpabi based. Update the default cpu from arm8 to armv7-a * config/arm/vxworks.h (CC1_SPEC): Simplify, knowing that we always use ARM_UNWIND_INFO. (DWARF2_UNWIND_INFO): Remove redefinition. (ARM_TARGET2_DWARF_FORMAT): Likewise. (VXWORKS_PERSONALITY): Define, to "llvm". (VXWORKS_EXTRA_LIBS_RTP): Define, to "-lllvm". libgcc/ * config.host: Collapse the arm-vxworks entries into a single arm-wrs-vxworks7* one. * config/arm/unwind-arm-vxworks.c: Update comments. Provide __gnu_Unwind_Find_exidx and a weak dummy __cxa_type_match for kernel modules, to be overriden by libstdc++ when we link with it. Rely on externally provided __exidx_start/end. Co-Authored-By: Doug Rupp <rupp@adacore.com> Co-Authored-By: Olivier Hainque <hainque@adacore.com> From-SVN: r278253
2019-11-14Base support for vxworks 7 on aarch64Doug Rupp1-0/+6
2019-11-14 Doug Rupp <rupp@adacore.com> Olivier Hainque <hainque@adacore.com> Jerome Lambourg <lambourg@adacore.com> gcc/ * config.gcc: Handle aarch64*-wrs-vxworks7*. * config/aarch64/aarch64-vxworks.h: New file. * config/aarch64/t-aarch64-vxworks: New file. libgcc/ * config.host: Handle aarch64*-wrs-vxworks7*. Co-Authored-By: Jerome Lambourg <lambourg@adacore.com> Co-Authored-By: Olivier Hainque <hainque@adacore.com> From-SVN: r278251
2019-11-14Update the libgcc support for VxWorks AE/653Olivier Hainque1-0/+6
2019-11-12 Olivier Hainque <hainque@adacore.com> libgcc/ * config/t-gthr-vxworksae: New file, add all the gthr-vxworks sources except the cxx0x support to LIB2ADDEH. We don't support cxx0x on AE/653. * config/t-vxworksae: New file. * config.host: Handle *-*-vxworksae: Add the two aforementioned Makefile fragment files at their expected position in the tmake_file list, in accordance with what is done for other VxWorks variants. From-SVN: r278250
2019-11-14Improve the thread support for VxWorksCorentin Gay1-0/+12
2019-11-12 Corentin Gay <gay@adacore.com> Jerome Lambourg <lambourg@adacore.com> Olivier Hainque <hainque@adacore.com> libgcc/ * config/t-gthr-vxworks: New file, add all the gthr-vxworks sources to LIB2ADDEH. * config/t-vxworks: Remove adjustments to LIB2ADDEH. * config/t-vxworks7: Likewise. * config.host: Append a block at the end of the file to add the t-gthr files to the tmake_file list for VxWorks after everything else. * config/vxlib.c: Rename as gthr-vxworks.c. * config/vxlib-tls.c: Rename as gthr-vxworks-tls.c. * config/gthr-vxworks.h: Simplify a few comments. Expose a TAS API and a basic error checking API, both internal. Simplify the __gthread_once_t type definition and initializers. Add sections for condition variables support and for the C++0x thread support, conditioned against Vx653 for the latter. * config/gthr-vxworks.c (__gthread_once): Simplify comments and implementation, leveraging the TAS internal API. * config/gthr-vxworks-tls.c: Introduce an internal TLS data access API, leveraging the general availability of TLS services in VxWorks7 post SR6xxx. (__gthread_setspecific, __gthread_setspecific): Use it. (tls_delete_hook): Likewise, and simplify the enter/leave dtor logic. * config/gthr-vxworks-cond.c: New file. GTHREAD_COND variable support based on VxWorks primitives. * config/gthr-vxworks-thread.c: New file. GTHREAD_CXX0X support based on VxWorks primitives. Co-Authored-By: Jerome Lambourg <lambourg@adacore.com> Co-Authored-By: Olivier Hainque <hainque@adacore.com> From-SVN: r278249
2019-11-14Introduce vxworks specific crtstuff supportJerome Lambourg1-0/+10
2019-11-06 Jerome Lambourg <lambourg@adacore.com> Olivier Hainque <hainque@adacore.com> libgcc/ * config/vxcrtstuff.c: New file. * config/t-vxcrtstuff: New Makefile fragment. * config.host: Append t-vxcrtstuff to the tmake_file list on all VxWorks ports using dwarf for table based EH. gcc/ * config/vx-common.h (USE_TM_CLONE_REGISTRY): Remove definition, pointless with a VxWorks specific version of crtstuff. (DWARF2_UNWIND_INFO): Conditionalize on !ARM_UNWIND_INFO. * config/vxworks.h (VX_CRTBEGIN_SPEC, VX_CRTEND_SPEC): New local macros, controlling the addition of vxworks specific crtstuff objects depending on the EH mechanism and kind of module being linked. (VXWORKS_STARTFILE_SPEC, VXWORKS_ENDFILE_SPEC): Use them. Co-Authored-By: Olivier Hainque <hainque@adacore.com> From-SVN: r278248
2019-11-07Support 64-bit double and 64-bit long double configurations.Georg-Johann Lay1-0/+3
gcc/ Support 64-bit double and 64-bit long double configurations. PR target/92055 * config.gcc (tm_defines) [avr]: Set from --with-double=, --with-long-double=. * config/avr/t-multilib: Remove. * config/avr/t-avr: Output of genmultilib.awk is now fully dynamically generated and no more part of the repo. (HAVE_DOUBLE_MULTILIB, HAVE_LONG_DOUBLE_MULTILIB): New variables. Pass them down to... * config/avr/genmultilib.awk: ...here and handle them. * gcc/config/avr/avr.opt (-mdouble=, avr_double). New option and var. (-mlong-double=, avr_long_double). New option and var. * common/config/avr/avr-common.c (opts.h, diagnostic.h): Include. (TARGET_OPTION_OPTIMIZATION_TABLE) <-mdouble=, -mlong-double=>: Set default as requested by --with-double= (TARGET_HANDLE_OPTION): Define to this... (avr_handle_option): ...new hook worker. * config/avr/avr.h (DOUBLE_TYPE_SIZE): Define to avr_double. (LONG_DOUBLE_TYPE_SIZE): Define to avr_long_double. (avr_double_lib): New proto for spec function. (EXTRA_SPEC_FUNCTIONS) <double-lib>: Add. (DRIVER_SELF_SPECS): Call %:double-lib. * config/avr/avr.c (avr_option_override): Assert sizeof(long double) >= sizeof(double) for the target. * config/avr/avr-c.c (avr_cpu_cpp_builtins) [__HAVE_DOUBLE_MULTILIB__, __HAVE_LONG_DOUBLE_MULTILIB__] [__HAVE_DOUBLE64__, __HAVE_DOUBLE32__, __DEFAULT_DOUBLE__=] [__HAVE_LONG_DOUBLE64__, __HAVE_LONG_DOUBLE32__] [__HAVE_LONG_DOUBLE_IS_DOUBLE__, __DEFAULT_LONG_DOUBLE__=]: New built-in define depending on --with-double=, --with-long-double=. * config/avr/driver-avr.c (avr_double_lib): New spec function. * doc/invoke.tex (AVR Options) <-mdouble=,-mlong-double=>: Doc. * doc/install.texi (Cross-Compiler-Specific Options) <--with-double=, --with-long-double=>: Doc. libgcc/ Support 64-bit double and 64-bit long double configurations. PR target/92055 * config/avr/t-avr (HOST_LIBGCC2_CFLAGS): Only add -DF=SF if long double is a 32-bit type. * config/avr/t-avrlibc: Copy double64 and long-double64 multilib(s) from the vanilla one. * config/avr/t-copy-libgcc: New Makefile snip. From-SVN: r277908