summaryrefslogtreecommitdiff
path: root/libgfortran/configure
AgeCommit message (Collapse)Author
2020-04-22libgfortran: Provide some further math library fallbacks [PR94694]Jakub Jelinek
The following patch provides some further math library fallbacks. fmaf can be implemented using fma if available, fma and fmal can use x * y + z as fallback, it is not perfect, but e.g. glibc on various arches has been using that as fallback for many years, and copysign/copysignl/fabs/fabsl can be implemented using corresponding __builtin_* if we make sure that gcc expands it inline instead of using a library call (these days it is expanded inline on most targets). 2020-04-22 Jakub Jelinek <jakub@redhat.com> PR libfortran/94694 PR libfortran/94586 * configure.ac: Add math func checks for fmaf, fma and fmal. Add HAVE_INLINE_BUILTIN_COPYSIGN check. * c99_protos.h (copysign, fmaf, fma, fmal): Provide fallback prototypes. (HAVE_COPYSIGN, HAVE_FMAF, HAVE_FMA, HAVE_FMAL): Define if not defined and fallback version is provided. * intrinsics/c99_functions.c (copysign, fmaf, fma, fmal): Provide fallback implementations if possible * configure: Regenerated. * config.h.in: Regenerated. * math.m4 (GCC_CHECK_MATH_INLINE_BUILTIN_FALLBACK1, GCC_CHECK_MATH_INLINE_BUILTIN_FALLBACK2): New.
2020-02-12Use a non-empty test program to test ability to link.Sandra Loosemore
On bare-metal targets, I/O support is typically provided by a BSP and requires a linker script and/or hosting library to be specified on the linker command line. Linking an empty program with the default linker script may succeed, however, which confuses libstdc++ configuration when programs that probe for the presence of various I/O features fail with link errors. 2020-02-12 Sandra Loosemore <sandra@codesourcery.com> PR libstdc++/79193 PR libstdc++/88999 config/ * no-executables.m4: Use a non-empty program to test for linker support. libgcc/ * configure: Regenerated. libgfortran/ * configure: Regenerated. libiberty/ * configure: Regenerated. libitm/ * configure: Regenerated. libobjc/ * configure: Regenerated. libquadmath/ * configure: Regenerated. libssp/ * configure: Regenerated. libstdc++v-3/ * configure: Regenerated.
2020-01-24Add `--with-toolexeclibdir=' configuration optionMaciej W. Rozycki
Provide means, in the form of a `--with-toolexeclibdir=' configuration option, to override the default installation directory for target libraries, otherwise known as $toolexeclibdir. This is so that it is possible to get newly-built libraries, particularly the shared ones, installed in a common place, so that they can be readily used by the target system as their host libraries, possibly over NFS, without a need to manually copy them over from the currently hardcoded location they would otherwise be installed in. In the presence of the `--enable-version-specific-runtime-libs' option and for configurations building native GCC the option is ignored. config/ * toolexeclibdir.m4: New file. gcc/ * doc/install.texi (Cross-Compiler-Specific Options): Document `--with-toolexeclibdir' option. libada/ * Makefile.in (configure_deps): Add `toolexeclibdir.m4'. * configure.ac: Handle `--with-toolexeclibdir='. * configure: Regenerate. libatomic/ * configure.ac: Handle `--with-toolexeclibdir='. * Makefile.in: Regenerate. * aclocal.m4: Regenerate. * configure: Regenerate. * testsuite/Makefile.in: Regenerate. libffi/ * configure.ac: Handle `--with-toolexeclibdir='. * Makefile.in: Regenerate. * aclocal.m4: Regenerate. * configure: Regenerate. * include/Makefile.in: Regenerate. * man/Makefile.in: Regenerate. * testsuite/Makefile.in: Regenerate. libgcc/ * Makefile.in (configure_deps): Add `toolexeclibdir.m4'. * configure.ac: Handle `--with-toolexeclibdir='. * configure: Regenerate. libgfortran/ * configure.ac: Handle `--with-toolexeclibdir='. * Makefile.in: Regenerate. * aclocal.m4: Regenerate. * configure: Regenerate. libgomp/ * configure.ac: Handle `--with-toolexeclibdir='. * Makefile.in: Regenerate. * aclocal.m4: Regenerate. * configure: Regenerate. * testsuite/Makefile.in: Regenerate. libhsail-rt/ * configure.ac: Handle `--with-toolexeclibdir='. * Makefile.in: Regenerate. * aclocal.m4: Regenerate. * configure: Regenerate. libitm/ * configure.ac: Handle `--with-toolexeclibdir='. * Makefile.in: Regenerate. * aclocal.m4: Regenerate. * configure: Regenerate. * testsuite/Makefile.in: Regenerate. libobjc/ * Makefile.in (aclocal_deps): Add `toolexeclibdir.m4'. * aclocal.m4: Include `toolexeclibdir.m4'. * configure.ac: Handle `--with-toolexeclibdir='. * configure: Regenerate. liboffloadmic/ * plugin/configure.ac: Handle `--with-toolexeclibdir='. * plugin/Makefile.in: Regenerate. * plugin/aclocal.m4: Regenerate. * plugin/configure: Regenerate. * configure.ac: Handle `--with-toolexeclibdir='. * Makefile.in: Regenerate. * aclocal.m4: Regenerate. * configure: Regenerate. libphobos/ * m4/druntime.m4: Handle `--with-toolexeclibdir='. * m4/Makefile.in: Regenerate. * libdruntime/Makefile.in: Regenerate. * src/Makefile.in: Regenerate. * testsuite/Makefile.in: Regenerate. * Makefile.in: Regenerate. * aclocal.m4: Regenerate. * configure: Regenerate. libquadmath/ * configure.ac: Handle `--with-toolexeclibdir='. * Makefile.in: Regenerate. * aclocal.m4: Regenerate. * configure: Regenerate. libsanitizer/ * configure.ac: Handle `--with-toolexeclibdir='. * Makefile.in: Regenerate. * aclocal.m4: Regenerate. * configure: Regenerate. * asan/Makefile.in: Regenerate. * interception/Makefile.in: Regenerate. * libbacktrace/Makefile.in: Regenerate. * lsan/Makefile.in: Regenerate. * sanitizer_common/Makefile.in: Regenerate. * tsan/Makefile.in: Regenerate. * ubsan/Makefile.in: Regenerate. libssp/ * configure.ac: Handle `--with-toolexeclibdir='. * Makefile.in: Regenerate. * aclocal.m4: Regenerate. * configure: Regenerate. libstdc++-v3/ * acinclude.m4: Handle `--with-toolexeclibdir='. * Makefile.in: Regenerate. * aclocal.m4: Regenerate. * configure: Regenerate. * doc/Makefile.in: Regenerate. * include/Makefile.in: Regenerate. * libsupc++/Makefile.in: Regenerate. * po/Makefile.in: Regenerate. * python/Makefile.in: Regenerate. * src/Makefile.in: Regenerate. * src/c++11/Makefile.in: Regenerate. * src/c++17/Makefile.in: Regenerate. * src/c++98/Makefile.in: Regenerate. * src/filesystem/Makefile.in: Regenerate. * testsuite/Makefile.in: Regenerate. libvtv/ * configure.ac: Handle `--with-toolexeclibdir='. * Makefile.in: Regenerate. * aclocal.m4: Regenerate. * configure: Regenerate. * testsuite/Makefile.in: Regenerate. zlib/ * configure.ac: Handle `--with-toolexeclibdir='. * Makefile.in: Regenerate. * aclocal.m4: Regenerate. * configure: Regenerate.
2019-09-27Regenerate `configure' scripts for `uclinuxfdpiceabi' libtool.m4 updateMaciej W. Rozycki
A change made with r275564 ("[ARM/FDPIC v6 02/24] [ARM] FDPIC: Handle arm*-*-uclinuxfdpiceabi in configure scripts") to libtool.m4 has not regenerated all the `configure' scripts affected. Fix it. gcc/ * configure: Regenerate. libatomic/ * configure: Regenerate. libbacktrace/ * configure: Regenerate. libcc1/ * configure: Regenerate. libffi/ * configure: Regenerate. libgfortran/ * configure: Regenerate. libgomp/ * configure: Regenerate. libhsail-rt/ * configure: Regenerate. libitm/ * configure: Regenerate. libobjc/ * configure: Regenerate. liboffloadmic/ * 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. From-SVN: r276213
2019-06-25Enable full GFortran library for AMD GCNKwok Cheung Yeung
2019-06-25 Kwok Cheung Yeung <kcy@codesourcery.com> Andrew Stubbs <ams@codesourcery.com> libgfortran/ * configure: Regenerate. * configure.ac (LIBGFOR_MINIMAL): Do not use on AMD GCN. Co-Authored-By: Andrew Stubbs <ams@codesourcery.com> From-SVN: r272649
2019-05-19libfortran/90038 Reap dead children when wait=.false.Janne Blomqvist
When using posix_spawn or fork to launch a child process, the parent needs to wait for the child, otherwise the dead child is left as a zombie process. For this purpose one can install a signal handler for SIGCHLD. 2019-05-19 Janne Blomqvist <jb@gcc.gnu.org> PR libfortran/90038 * intrinsics/execute_command_line (sigchld_handler): New function. (execute_command_line): Install handler for SIGCHLD. * configure.ac: Check for presence of sigaction and waitpid. * config.h.in: Regenerated. * configure: Regenerated. Regtested on x86_64-pc-linux-gnu. From-SVN: r271384
2019-05-17libfortran/90038: Use posix_spawn instead of forkJanne Blomqvist
fork() semantics can be problematic. Most unix style OS'es have posix_spawn which can be used to replace fork + exec in many cases. For more information see e.g. https://www.microsoft.com/en-us/research/uploads/prod/2019/04/fork-hotos19.pdf This replaces the one use of fork in libgfortran with posix_spawn. 2019-05-17 Janne Blomqvist <jb@gcc.gnu.org> PR libfortran/90038 * configure.ac (AC_CHECK_FUNCS_ONCE): Check for posix_spawn. * intrinsics/execute_command_line (execute_command_line): Use posix_spawn. * Makefile.in: Regenerated. * config.h.in: Regenerated. * configure: Regenerated. Regtested on x86_64-pc-linux-gnu. From-SVN: r271340
2019-01-17GCN libgfortran.Andrew Stubbs
This patch contains the GCN port of libgfortran. We use the minimal configuration created for NVPTX. That's all that's required, besides the target-independent bug fixes posted already. 2019-01-17 Andrew Stubbs <ams@codesourcery.com> Kwok Cheung Yeung <kcy@codesourcery.com> Julian Brown <julian@codesourcery.com> Tom de Vries <tom@codesourcery.com> libgfortran/ * configure.ac: Use minimal mode for amdgcn. * configure: Regenerate. Co-Authored-By: Julian Brown <julian@codesourcery.com> Co-Authored-By: Kwok Cheung Yeung <kcy@codesourcery.com> Co-Authored-By: Tom de Vries <tom@codesourcery.com> From-SVN: r268020
2019-01-12gfortran.texi: Add description in sections on TS 29113 and further ↵Paul Thomas
interoperability with C. 2019-01-12 Paul Thomas <pault@gcc.gnu.org> * gfortran.texi : Add description in sections on TS 29113 and further interoperability with C. * trans-array.c (gfc_conv_descriptor_attribute): New function. (gfc_get_dataptr_offset): Remove static function attribute. * trans-array.h : Add prototypes for above functions. * trans-decl.c : Add declarations for the library functions cfi_desc_to_gfc_desc and gfc_desc_to_cfi_desc. * trans-expr.c (gfc_conv_gfc_desc_to_cfi_desc): New function. (gfc_conv_procedure_call): Call it for scalar and array actual arguments, when the formal arguments are bind_c with assumed shape or assumed rank. * trans.h : External declarations for gfor_fndecl_cfi_to_gfc and gfor_fndecl_gfc_to_cfi. 2019-01-12 Paul Thomas <pault@gcc.gnu.org> * gfortran.dg/ISO_Fortran_binding_1.f90 : New test. * gfortran.dg/ISO_Fortran_binding_1.c : Auxilliary file for test. * gfortran.dg/ISO_Fortran_binding_2.f90 : New test. * gfortran.dg/ISO_Fortran_binding_2.c : Auxilliary file for test. * gfortran.dg/bind_c_array_params_2.f90 : Change search string for dump tree scan. 2019-01-12 Paul Thomas <pault@gcc.gnu.org> * ISO_Fortran_binding.h : New file. * Makefile.am : Include ISO_Fortran_binding.c in the list of files to compile. * Makefile.in : Regenerated. * gfortran.map : Add _gfortran_cfi_desc_to_gfc_desc, _gfortran_gfc_desc_to_cfi_desc and the CFI API functions. * runtime/ISO_Fortran_binding.c : New file containing the new functions added to the map. From-SVN: r267881
2018-11-22Replace sync builtins with atomic builtinsJanne Blomqvist
The old __sync builtins have been deprecated for a long time now in favor of the __atomic builtins following the C++11/C11 memory model. This patch converts libgfortran to use the modern __atomic builtins. At the same time I weakened the consistency to relaxed for incrementing and decrementing the counter, and acquire-release when decrementing to check whether the counter is 0 and the unit can be freed. This is similar to e.g. std::shared_ptr in C++. Regtested on x86_64-pc-linux-gnu. libgfortran/ChangeLog: 2018-11-22 Janne Blomqvist <jb@gcc.gnu.org> * acinclude.m4 (LIBGFOR_CHECK_ATOMIC_FETCH_ADD): Rename and test presence of atomic builtins instead of sync builtins. * configure.ac (LIBGFOR_CHECK_ATOMIC_FETCH_ADD): Call new test. * io/io.h (inc_waiting_locked): Use __atomic_fetch_add. (predec_waiting_locked): Use __atomic_add_fetch. (dec_waiting_unlocked): Use __atomic_fetch_add. * config.h.in: Regenerated. * configure: Regenerated. * Makefile.in: Regenerated. From-SVN: r266367
2018-10-31Update GCC to autoconf 2.69, automake 1.15.1 (PR bootstrap/82856).Joseph Myers
This patch updates GCC to use autoconf 2.69 and automake 1.15.1. (That's not the latest automake version, but it's the one used by binutils-gdb, with which consistency is desirable, and in any case seems a useful incremental update that should make a future update to 1.16.1 easier.) The changes are generally similar to the binutils-gdb ones, and are copied from there where shared files and directories are involved (there are some further changes to such shared directories, however, which I'd expect to apply to binutils-gdb once this patch is in GCC). Largely, obsolete AC_PREREQ calls are removed, while many AC_LANG_SOURCE calls are added to avoid warnings from aclocal and autoconf. Multilib support is no longer included in core automake, meaning that multilib.am needs copying from automake's contrib directory into the GCC source tree. Autoconf 2.69 has Go support, so local copies of that support are removed. I hope the D support will soon be submitted to upstream autoconf so the local copy of that can be removed in a future update. Changes to how automake generates runtest calls mean quotes are removed from RUNTEST definitions in five lib*/testsuite/Makefile.am files (libatomic, libgomp, libitm, libphobos, libvtv; some others have RUNTEST definitions without quotes, which are still OK); libgo and libphobos also get -Wno-override added to AM_INIT_AUTOMAKE so those overrides of RUNTEST do not generate automake warnings. Note that the regeneration did not include regeneration of fixincludes/config.h.in (attempting such regeneration resulted in all the USED_FOR_TARGET conditionals disappearing; and I don't see anything in the fixincludes/ directory that would result in such conditionals being generated, unlike in the gcc/ directory). Also note that libvtv/testsuite/other-tests/Makefile.in was not regenerated; that directory is not listed as a subdirectory for which Makefile.in gets regenerated by calling "automake" in libvtv/, so I'm not sure how it's meant to be regenerated. While I mostly fixed warnings should running aclocal / automake / autoconf, there were various such warnings from automake in the libgfortran, libgo, libgomp, liboffloadmic, libsanitizer, libphobos directories that I did not fix, preferring to leave those to the relevant subsystem maintainers. Specifically, most of those warnings were of the following form (example from libgfortran): Makefile.am:48: warning: source file 'caf/single.c' is in a subdirectory, Makefile.am:48: but option 'subdir-objects' is disabled automake: warning: possible forward-incompatibility. automake: At least a source file is in a subdirectory, but the 'subdir-objects' automake: automake option hasn't been enabled. For now, the corresponding output automake: object file(s) will be placed in the top-level directory. However, automake: this behaviour will change in future Automake versions: they will automake: unconditionally cause object files to be placed in the same subdirectory automake: of the corresponding sources. automake: You are advised to start using 'subdir-objects' option throughout your automake: project, to avoid future incompatibilities. I think it's best for the relevant maintainers to add subdir-objects and do any other associated Makefile.am changes needed. In some cases the paths in the warnings involved ../; I don't know if that adds any extra complications to the use of subdir-objects. I've tested this with native, cross and Canadian cross builds. The risk of any OS-specific issues should I hope be rather lower than if a libtool upgrade were included (we *should* do such an upgrade at some point, but it's more complicated - it involves identifying all our local libtool changes to see if any aren't included in the upstream version we update to, and reverting an upstream libtool patch that's inappropriate for use in GCC); I think it would be better to get this update into GCC so that people can test in different configurations and we can fix any issues found, rather than to try to get more and more testing done before it goes in. top level: 2018-10-31 Joseph Myers <joseph@codesourcery.com> PR bootstrap/82856 * multilib.am: New file. From automake. Merge from binutils-gdb: 2018-06-19 Simon Marchi <simon.marchi@ericsson.com> * libtool.m4: Use AC_LANG_SOURCE. * configure.ac: Remove AC_PREREQ, use AC_LANG_SOURCE. * ar-lib: New file. * test-driver: New file. * configure: Re-generate. config: 2018-10-31 Joseph Myers <joseph@codesourcery.com> PR bootstrap/82856 * math.m4, tls.m4: Use AC_LANG_SOURCE. Merge from binutils-gdb: 2018-06-19 Simon Marchi <simon.marchi@ericsson.com> * override.m4 (_GCC_AUTOCONF_VERSION): Bump from 2.64 to 2.69. fixincludes: 2018-10-31 Joseph Myers <joseph@codesourcery.com> PR bootstrap/82856 * configure.ac: Remove AC_PREREQ. * aclocal.m4, configure: Regenerate. gcc: 2018-10-31 Joseph Myers <joseph@codesourcery.com> PR bootstrap/82856 * configure.ac: Remove AC_PREREQ. Use AC_LANG_SOURCE. Use single line for second argument of AC_DEFINE_UNQUOTED. * doc/install.texi (Tools/packages necessary for modifying GCC): Update to autoconf 2.69 and automake 1.15.1. * aclocal.m4, config.in, configure: Regenerate. gnattools: 2018-10-31 Joseph Myers <joseph@codesourcery.com> PR bootstrap/82856 * configure.ac: Remove AC_PREREQ. * configure: Regenerate. gotools: 2018-10-31 Joseph Myers <joseph@codesourcery.com> PR bootstrap/82856 * config/go.m4: Remove file. * Makefile.am (ACLOCAL_AMFLAGS): Do not use -I ./config. * configure.ac: Remove AC_PREREQ. Do not include config/go.m4. * Makefile.in, aclocal.m4, configure: Regenerate. intl: 2018-10-31 Joseph Myers <joseph@codesourcery.com> PR bootstrap/82856 Merge from binutils-gdb: 2018-06-19 Simon Marchi <simon.marchi@ericsson.com> * configure.ac: Add AC_USE_SYSTEM_EXTENSIONS, remove AC_PREREQ. * configure: Re-generate. * config.h.in: Re-generate. * aclocal.m4: Re-generate. libada: 2018-10-31 Joseph Myers <joseph@codesourcery.com> PR bootstrap/82856 * configure.ac: Remove AC_PREREQ. * configure: Regenerate. libatomic: 2018-10-31 Joseph Myers <joseph@codesourcery.com> PR bootstrap/82856 * Makefile.am: Include multilib.am. * acinclude.m4: Use AC_LANG_SOURCE. * configure.ac: Remove AC_PREREQ. * testsuite/Makefile.am (RUNTEST): Remove quotes. * Makefile.in, aclocal.m4, configure, testsuite/Makefile.in: Regenerate. libbacktrace: 2018-10-31 Joseph Myers <joseph@codesourcery.com> PR bootstrap/82856 * Makefile.am: Include multilib.am. * configure.ac: Remove AC_PREREQ. Use AC_LANG_SOURCE. * Makefile.in, aclocal.m4, config.h.in, configure: Regenerate. libcc1: 2018-10-31 Joseph Myers <joseph@codesourcery.com> PR bootstrap/82856 * configure.ac: Remove AC_PREREQ. * Makefile.in, aclocal.m4, configure: Regenerate. libcpp: 2018-10-31 Joseph Myers <joseph@codesourcery.com> PR bootstrap/82856 * configure.ac: Remove AC_PREREQ. Use AC_LANG_SOURCE. * aclocal.m4, config.in, configure: Regenerate. libdecnumber: 2018-10-31 Joseph Myers <joseph@codesourcery.com> PR bootstrap/82856 Merge from binutils-gdb: 2018-06-19 Simon Marchi <simon.marchi@ericsson.com> * configure.ac: Remove AC_PREREQ. * configure: Re-generate. * aclocal.m4. libffi: 2018-10-31 Joseph Myers <joseph@codesourcery.com> PR bootstrap/82856 * Makefile.am: Include multilib.am. (AUTOMAKE_OPTIONS): Add info-in-builddir. (CLEANFILES): Remove doc/libffi.info. * configure.ac: Remove AC_PREREQ. * Makefile.in, aclocal.m4, configure, fficonfig.h.in, include/Makefile.in, man/Makefile.in, testsuite/Makefile.in: Regenerate. libgcc: 2018-10-31 Joseph Myers <joseph@codesourcery.com> PR bootstrap/82856 * configure.ac: Remove AC_PREREQ. Use AC_LANG_SOURCE. * configure: Regenerate. libgfortran: 2018-10-31 Joseph Myers <joseph@codesourcery.com> PR bootstrap/82856 * Makefile.am: Include multilib.am. * configure.ac: Remove AC_PREREQ. * Makefile.in, aclocal.m4, config.h.in, configure: Regenerate. libgo [logically part of this change but omitted from the commit]: 2018-10-31 Joseph Myers <joseph@codesourcery.com> PR bootstrap/82856 * Makefile.am: Include multilib.am. * config/go.m4: Remove file. * config/libtool.m4: Use AC_LANG_SOURCE. * configure.ac: Remove AC_PREREQ. Use AC_LANG_SOURCE. Use -Wno-override in AM_INIT_AUTOMAKE call. * Makefile.in, aclocal.m4, configure, testsuite/Makefile.in: Regenerate. libgomp: 2018-10-31 Joseph Myers <joseph@codesourcery.com> PR bootstrap/82856 * Makefile.am: Include multilib.am (AUTOMAKE_OPTIONS): Add info-in-builddir. (CLEANFILES): Remove libgomp.info. * configure.ac: Remove AC_PREREQ. * testsuite/Makefile.am (RUNTEST): Remove quotes. * Makefile.in, aclocal.m4, configure, testsuite/Makefile.in: Regenerate. libhsail-rt: 2018-10-31 Joseph Myers <joseph@codesourcery.com> PR bootstrap/82856 * configure.ac: Remove AC_PREREQ. * Makefile.in, aclocal.m4, configure: Regenerate. libiberty: 2018-10-31 Joseph Myers <joseph@codesourcery.com> PR bootstrap/82856 Merge from binutils-gdb: 2018-06-19 Simon Marchi <simon.marchi@ericsson.com> * configure.ac: Remove AC_PREREQ. * configure: Re-generate. * config.in: Re-generate. libitm: 2018-10-31 Joseph Myers <joseph@codesourcery.com> PR bootstrap/82856 * Makefile.am: Include multilib.am. (AUTOMAKE_OPTIONS): Add info-in-builddir. (CLEANFILES): Remove libitm.info. * configure.ac: Remove AC_PREREQ. * testsuite/Makefile.am (RUNTEST): Remove quotes. * Makefile.in, aclocal.m4, configure, testsuite/Makefile.in: Regenerate. libobjc: 2018-10-31 Joseph Myers <joseph@codesourcery.com> PR bootstrap/82856 * configure.ac: Remove AC_PREREQ. * aclocal.m4, config.h.in, configure: Regenerate. liboffloadmic: 2018-10-31 Joseph Myers <joseph@codesourcery.com> PR bootstrap/82856 * Makefile.am: Include multilib.am. * configure.ac: Remove AC_PREREQ. * plugin/Makefile.am: Include multilib.am. * plugin/configure.ac: Remove AC_PREREQ. * Makefile.in, aclocal.m4, configure, plugin/Makefile.in, plugin/aclocal.m4, plugin/configure: Regenerate. libphobos: 2018-10-31 Joseph Myers <joseph@codesourcery.com> PR bootstrap/82856 * Makefile.am: Include multilib.am. * configure.ac: Remove AC_PREREQ. Use -Wno-override in AM_INIT_AUTOMAKE call. * m4/autoconf.m4: Add extra argument to AC_LANG_DEFINE call. * m4/druntime/os.m4: Use AC_LANG_SOURCE. * testsuite/Makefile.am (RUNTEST): Remove quotes. * Makefile.in, aclocal.m4, configure, libdruntime/Makefile.in, src/Makefile.in, testsuite/Makefile.in: Regenerate. libquadmath: 2018-10-31 Joseph Myers <joseph@codesourcery.com> PR bootstrap/82856 * Makefile.am: Include multilib.am. (AUTOMAKE_OPTIONS): Remove 1.8. Add info-in-builddir. (all-local): Define outside conditional code. (CLEANFILES): Remove libquadmath.info. * configure.ac: Remove AC_PREREQ. * Makefile.in, aclocal.m4, config.h.in, configure: Regenerate. libsanitizer: 2018-10-31 Joseph Myers <joseph@codesourcery.com> PR bootstrap/82856 * Makefile.am: Include multilib.am. * configure.ac: Remove AC_PREREQ. Use AC_LANG_SOURCE. * Makefile.in, aclocal.m4, asan/Makefile.in, configure, interception/Makefile.in, libbacktrace/Makefile.in, lsan/Makefile.in, sanitizer_common/Makefile.in, tsan/Makefile.in, ubsan/Makefile.in: Regenerate. libssp: 2018-10-31 Joseph Myers <joseph@codesourcery.com> PR bootstrap/82856 * Makefile.am: Include multilib.am. (AUTOMAKE_OPTIONS): Remove 1.9.5. * configure.ac: Remove AC_PREREQ. Quote argument to AC_RUN_IFELSE. * Makefile.in, aclocal.m4, configure: Regenerate. libstdc++-v3: 2018-10-31 Joseph Myers <joseph@codesourcery.com> PR bootstrap/82856 * Makefile.am: Include multilib.am. * configure.ac: Remove AC_PREREQ. * Makefile.in, aclocal.m4, configure, doc/Makefile.in, include/Makefile.in, libsupc++/Makefile.in, po/Makefile.in, python/Makefile.in, src/Makefile.in, src/c++11/Makefile.in, src/c++17/Makefile.in, src/c++98/Makefile.in, src/filesystem/Makefile.in, testsuite/Makefile.in: Regenerate. libvtv: 2018-10-31 Joseph Myers <joseph@codesourcery.com> PR bootstrap/82856 * Makefile.am: Include multilib.am. * configure.ac: Remove AC_PREREQ. * testsuite/Makefile.am (RUNTEST): Remove quotes. * Makefile.in, aclocal.m4, configure, testsuite/Makefile.in: Regenerate. lto-plugin: 2018-10-31 Joseph Myers <joseph@codesourcery.com> PR bootstrap/82856 * configure.ac: Remove AC_PREREQ. Use AC_LANG_SOURCE. * Makefile.in, aclocal.m4, config.h.in, configure: Regenerate. zlib: 2018-10-31 Joseph Myers <joseph@codesourcery.com> PR bootstrap/82856 * Makefile.am: Include multilib.am. Merge from binutils-gdb: 2018-06-19 Simon Marchi <simon.marchi@ericsson.com> * configure.ac: Modernize AC_INIT call, remove AC_PREREQ. * Makefile.am (AUTOMAKE_OPTIONS): Remove 1.8, cygnus, add foreign. * Makefile.in: Re-generate. * aclocal.m4: Re-generate. * configure: Re-generate. From-SVN: r265695
2018-09-21Use vectored writes when reporting errors and warnings.Janne Blomqvist
When producing error and warning messages, libgfortran writes a message by using many system calls. By using vectored writes (the POSIX writev function) when available and feasible to use without major surgery, we reduce the chance that output gets intermingled with other output to stderr. In practice, this is done by introducing a new function estr_writev in addition to the existing estr_write. In order to use this, the old st_vprintf is removed, replaced by direct calls of vsnprintf, allowing more message batching. Regtested on x86_64-pc-linux-gnu. libgfortran/ChangeLog: 2018-09-21 Janne Blomqvist <jb@gcc.gnu.org> * config.h.in: Regenerated. * configure: Regenerated. * configure.ac: Check for writev and sys/uio.h. * libgfortran.h: Include sys/uio.h. (st_vprintf): Remove prototype. (struct iovec): Define if not available. (estr_writev): New prototype. * runtime/backtrace.c (error_callback): Use estr_writev. * runtime/error.c (ST_VPRINTF_SIZE): Remove. (estr_writev): New function. (st_vprintf): Remove. (gf_vsnprintf): New function. (ST_ERRBUF_SIZE): New macro. (st_printf): Use vsnprintf. (os_error): Use estr_writev. (runtime_error): Use vsnprintf and estr_writev. (runtime_error_at): Likewise. (runtime_warning_at): Likewise. (internal_error): Use estr_writev. (generate_error_common): Likewise. (generate_warning): Likewise. (notify_std): Likewise. * runtime/pause.c (pause_string): Likewise. * runtime/stop.c (report_exception): Likewise. (stop_string): Likewise. (error_stop_string): Likewise. From-SVN: r264487
2018-08-14Include <sys/random.h> for getentropy on SolarisRainer Orth
* configure.ac: Check for <sys/random.h>. * configure, config.h.in: Regenerate. * intrinsics/random.c [HAVE_SYS_RANDOM_H]: Include <sys/random.h>. From-SVN: r263543
2018-08-13Use getentropy() for seeding PRNGJanne Blomqvist
The getentropy function, found on Linux, OpenBSD, and recently also FreeBSD, can be used to get random bytes to initialize the PRNG. It is similar to the traditional way of reading from /dev/urandom, but being a system call rather than a special file, it doesn't suffer from problems like running out of file descriptors, or failure when running in a container where /dev/urandom may not be available. Regtested on x86_64-pc-linux-gnu, Ok for trunk? 2018-08-13 Janne Blomqvist <jb@gcc.gnu.org> * configure.ac: Check for getentropy. * intrinsics/random.c (getosrandom): Use getentropy if available. * config.h.in: Regenerated. * configure: Regenerated. From-SVN: r263522
2018-04-24Regenerate configure of target librariesH.J. Lu
* configure: Regenerated. From-SVN: r259610
2018-04-19cet.m4 (GCC_CET_FLAGS): Default to --disable-cet, replace ↵Jakub Jelinek
--enable-cet=default with --enable-cet=auto. * config/cet.m4 (GCC_CET_FLAGS): Default to --disable-cet, replace --enable-cet=default with --enable-cet=auto. * doc/install.texi: Document --disable-cet being the default and --enable-cet=auto. * configure: Regenerated. From-SVN: r259487
2018-04-18re PR jit/85384 (libgccjit does not work if --with-gcc-major-version is used)David Malcolm
PR jit/85384 * acx.m4 (GCC_BASE_VER): Remove \$\$ from sed expression. * configure.ac (gcc-driver-name.h): Honor --with-gcc-major-version by using gcc_base_ver to generate a gcc_driver_version, and use it when generating GCC_DRIVER_NAME. * configure: Regenerate. * configure: Regenerate. From-SVN: r259462
2018-02-19CET shouldn't be enabled in 32-bit run-time libraries by defualtIgor Tsimbalist
ENDBR32 and RDSSPD are multi-byte NOPs on x86-64 processors and newer x86 processors, starting Pentium Pro. They are UD on older 32-bit processors. Detect this at configure time and adjust the default value for enable_cet. GCC will enable CET in 32-bit run-time libraries in any case if --enable-cet is used to configure GCC. PR target/84148 * config/cet.m4: Check if target support multi-byte NOPS (SSE). * libatomic/configure: Regenerate. * libbacktrace/configure: Likewise. * libgcc/configure: Likewise. * libgfortran/configure: Likewise. * libgomp/configure: Likewise. * libitm/configure: Likewise. * libmpx/configure: Likewise. * libobjc/configure: Likewise. * libquadmath/configure: Likewise. * libsanitizer/configure: Likewise. * libssp/configure: Likewise. * libstdc++-v3/configure: Likewise. * libvtv/configure: Likewise. From-SVN: r257809
2017-11-17Enable building libgfortran with Intel CETIgor Tsimbalist
libgfortran/ * acinclude.m4: Add enable.m4, cet.m4. * Makefile.in: Regenerate. * configure: Likewise. * configure.ac: Set CET_FLAGS. Update AM_FCFLAGS, AM_CFLAGS, CFLAGS. From-SVN: r254902
2017-05-28Fix libgfortran FMA3/FMA4 testsRainer Orth
* acinclude.m4 (LIBGFOR_CHECK_FMA3): Use test from check_effective_target_fma in gcc.target/i386/i386.exp. (LIBGFOR_CHECK_FMA4): Use test from check_effective_target_fma4. * configure: Regenerate. From-SVN: r248547
2017-05-26re PR fortran/80889 (Bootstrap broken on all targets due to rev 248472)Thomas Koenig
2017-05-26 Thomas Koenig <tkoenig@gcc.gnu.org> PR boostrap/80889 * acinclude.m4: Also set HAVE_AVX128 on the false branch of LIBGFOR_CHECK_AVX128. * configure: Regenerated. From-SVN: r248519
2017-05-25re PR libfortran/78379 (Processor-specific versions for matmul)Thomas Koenig
2017-05-25 Thomas Koenig <tkoenig@gcc.gnu.org> PR libfortran/78379 * Makefile.am: Add generated/matmulavx128_*.c files. Handle them for compiling and setting the right flags. * acinclude.m4: Add tests for FMA3, FMA4 and AVX128. * configure.ac: Call them. * Makefile.in: Regenerated. * config.h.in: Regenerated. * configure: Regenerated. * m4/matmul.m4: Handle AMD chips by calling 128-bit AVX versions which use FMA3 or FMA4. * m4/matmulavx128.m4: New file. * generated/matmul_c10.c: Regenerated. * generated/matmul_c16.c: Regenerated. * generated/matmul_c4.c: Regenerated. * generated/matmul_c8.c: Regenerated. * generated/matmul_i1.c: Regenerated. * generated/matmul_i16.c: Regenerated. * generated/matmul_i2.c: Regenerated. * generated/matmul_i4.c: Regenerated. * generated/matmul_i8.c: Regenerated. * generated/matmul_r10.c: Regenerated. * generated/matmul_r16.c: Regenerated. * generated/matmul_r4.c: Regenerated. * generated/matmul_r8.c: Regenerated. * generated/matmulavx128_c10.c: New file. * generated/matmulavx128_c16.c: New file. * generated/matmulavx128_c4.c: New file. * generated/matmulavx128_c8.c: New file. * generated/matmulavx128_i1.c: New file. * generated/matmulavx128_i16.c: New file. * generated/matmulavx128_i2.c: New file. * generated/matmulavx128_i4.c: New file. * generated/matmulavx128_i8.c: New file. * generated/matmulavx128_r10.c: New file. * generated/matmulavx128_r16.c: New file. * generated/matmulavx128_r4.c: New file. * generated/matmulavx128_r8.c: New file. From-SVN: r248472
2017-01-19re PR target/78478 (Compile Error for i386-rtems)Uros Bizjak
PR target/78478 * config/ax_check_define.m4: New file. libgfortran/ChangeLog: PR target/78478 * acinclude.m4: Include ../config/ax_check_define.m4 * configure.ac: Check if _SOFT_FLOAT is defined. * configure.host (i?86 | x86_64): Use fpu-generic when have_soft_float is set. * configure: Regenerate. From-SVN: r244651
2017-01-19re PR target/79127 (Error: invalid register for .seh_savexmm in matmul_i4.c)Jakub Jelinek
PR target/79127 * acinclude.m4 (LIBGFOR_CHECK_AVX512F): Ensure the test clobbers some zmm16+ registers to verify they are handled by unwind info properly if needed. * configure: Regenerated. From-SVN: r244636
2017-01-17re PR other/79046 (g++ -print-file-name=plugin uses full version number in path)Jakub Jelinek
PR other/79046 * configure: Regenerated. config/ * acx.m4 (GCC_BASE_VER): New m4 function. (ACX_TOOL_DIRS): Require GCC_BASE_VER, for --with-gcc-major-version-only use just major number from BASE-VER. gcc/ * configure.ac: Add GCC_BASE_VER. * Makefile.in (version): Use @get_gcc_base_ver@ instead of cat to get version from BASE-VER file. (CFLAGS-gcc.o): Add -DBASEVER=$(BASEVER_s). (gcc.o): Depend on $(BASEVER). * common.opt (dumpfullversion): New option. * gcc.c (driver_handle_option): Handle OPT_dumpfullversion. * doc/invoke.texi: Document -dumpfullversion. * doc/install.texi: Document --with-gcc-major-version-only. * configure: Regenerated. libatomic/ * configure.ac: Add GCC_BASE_VER. * Makefile.am (gcc_version): Use @get_gcc_base_ver@ instead of cat to get version from BASE-VER file. * testsuite/Makefile.in: Regenerated. * configure: Regenerated. * Makefile.in: Regenerated. libgomp/ * configure.ac: Add GCC_BASE_VER. * Makefile.am (gcc_version): Use @get_gcc_base_ver@ instead of cat to get version from BASE-VER file. * testsuite/Makefile.in: Regenerated. * configure: Regenerated. * Makefile.in: Regenerated. libgcc/ * configure.ac: Add GCC_BASE_VER. * Makefile.in (version): Use @get_gcc_base_ver@ instead of cat to get version from BASE-VER file. * configure: Regenerated. libssp/ * configure.ac: Add GCC_BASE_VER. * Makefile.am (gcc_version): Use @get_gcc_base_ver@ instead of cat to get version from BASE-VER file. * configure: Regenerated. * Makefile.in: Regenerated. liboffloadmic/ * configure.ac: Add GCC_BASE_VER. * Makefile.am (gcc_version): Use @get_gcc_base_ver@ instead of cat to get version from BASE-VER file. * aclocal.m4: Include ../config/acx.m4. * configure: Regenerated. * Makefile.in: Regenerated. libquadmath/ * configure.ac: Add GCC_BASE_VER. * Makefile.am (gcc_version): Use @get_gcc_base_ver@ instead of cat to get version from BASE-VER file. * configure: Regenerated. * Makefile.in: Regenerated. libmpx/ * configure.ac: Add GCC_BASE_VER. * Makefile.am (gcc_version): Use @get_gcc_base_ver@ instead of cat to get version from BASE-VER file. * configure: Regenerated. * Makefile.in: Regenerated. libada/ * configure.ac: Add GCC_BASE_VER. * Makefile.in (version): Use @get_gcc_base_ver@ instead of cat to get version from BASE-VER file. * configure: Regenerated. lto-plugin/ * configure.ac: Add GCC_BASE_VER. * Makefile.am (gcc_version): Use @get_gcc_base_ver@ instead of cat to get version from BASE-VER file. * configure: Regenerated. * Makefile.in: Regenerated. libitm/ * configure.ac: Add GCC_BASE_VER. * Makefile.am (gcc_version): Use @get_gcc_base_ver@ instead of cat to get version from BASE-VER file. * testsuite/Makefile.in: Regenerated. * configure: Regenerated. * Makefile.in: Regenerated. fixincludes/ * configure.ac: Add GCC_BASE_VER. * Makefile.in (gcc_version): Use @get_gcc_base_ver@ instead of cat to get version from BASE-VER file. * configure: Regenerated. libcilkrts/ * configure.ac: Add GCC_BASE_VER. * Makefile.am (gcc_version): Use @get_gcc_base_ver@ instead of cat to get version from BASE-VER file. * aclocal.m4: Include ../config/acx.m4. * configure: Regenerated. * Makefile.in: Regenerated. libcc1/ * configure.ac: Add GCC_BASE_VER. For --with-gcc-major-version-only use just major number from BASE-VER. * configure: Regenerated. * Makefile.in: Regenerated. libobjc/ * configure.ac: Add GCC_BASE_VER. * Makefile.in (gcc_version): Use @get_gcc_base_ver@ instead of cat to get version from BASE-VER file. * configure: Regenerated. libstdc++-v3/ * configure.ac: Add GCC_BASE_VER. * fragment.am (gcc_version): Use @get_gcc_base_ver@ instead of cat to get version from BASE-VER file. * po/Makefile.in: Regenerated. * libsupc++/Makefile.in: Regenerated. * testsuite/Makefile.in: Regenerated. * src/Makefile.in: Regenerated. * configure: Regenerated. * Makefile.in: Regenerated. * include/Makefile.in: Regenerated. * doc/Makefile.in: Regenerated. * python/Makefile.in: Regenerated. * src/c++11/Makefile.in: Regenerated. * src/c++98/Makefile.in: Regenerated. * src/filesystem/Makefile.in: Regenerated. libvtv/ * configure.ac: Add GCC_BASE_VER. * Makefile.am (gcc_version): Use @get_gcc_base_ver@ instead of cat to get version from BASE-VER file. * testsuite/Makefile.in: Regenerated. * configure: Regenerated. * Makefile.in: Regenerated. libsanitizer/ * configure.ac: Add GCC_BASE_VER. * Makefile.am (gcc_version): Use @get_gcc_base_ver@ instead of cat to get version from BASE-VER file. * libbacktrace/Makefile.in: Regenerated. * interception/Makefile.in: Regenerated. * asan/Makefile.in: Regenerated. * ubsan/Makefile.in: Regenerated. * configure: Regenerated. * sanitizer_common/Makefile.in: Regenerated. * lsan/Makefile.in: Regenerated. * Makefile.in: Regenerated. * tsan/Makefile.in: Regenerated. libgfortran/ * configure.ac: Add GCC_BASE_VER. * Makefile.am (gcc_version): Use @get_gcc_base_ver@ instead of cat to get version from BASE-VER file. * configure: Regenerated. * Makefile.in: Regenerated. From-SVN: r244521
2016-12-12Disable hwcaps on libgfortranRainer Orth
libgfortran: * configure.ac: Call GCC_CHECK_LINKER_HWCAP. * Makefile.am (libgfortran_la_LDFLAGS): Add HWCAP_LDFLAGS. * aclocal.m4: Regenerate. * configure: Regenerate. * Makefile.in: Regenerate. config: * hwcaps.m4: New file. libitm: * acinclude.m4 (LIBITM_CHECK_LINKER_FEATURES): Remove. * aclocal.m4: Regenerate. * configure.ac: Call GCC_CHECK_LINKER_HWCAP instead of LIBITM_CHECK_LINKER_HWCAP. From-SVN: r243552
2016-12-03re PR libfortran/78379 (Processor-specific versions for matmul)Thomas Koenig
2016-12-03 Thomas Koenig <tkoenig@gcc.gnu.org> PR fortran/78379 * config/i386/cpuinfo.c: Move denums for processor vendors, processor type, processor subtypes and declaration of struct __processor_model into * config/i386/cpuinfo.h: New header file. * Makefile.am: Add dependence of m4/matmul_internal_m4 to mamtul files.. * Makefile.in: Regenerated. * acinclude.m4: Check for AVX, AVX2 and AVX512F. * config.h.in: Add HAVE_AVX, HAVE_AVX2 and HAVE_AVX512F. * configure: Regenerated. * configure.ac: Use checks for AVX, AVX2 and AVX_512F. * m4/matmul_internal.m4: New file. working part of matmul.m4. * m4/matmul.m4: Implement architecture-specific switching for AVX, AVX2 and AVX512F by including matmul_internal.m4 multiple times. * generated/matmul_c10.c: Regenerated. * generated/matmul_c16.c: Regenerated. * generated/matmul_c4.c: Regenerated. * generated/matmul_c8.c: Regenerated. * generated/matmul_i1.c: Regenerated. * generated/matmul_i16.c: Regenerated. * generated/matmul_i2.c: Regenerated. * generated/matmul_i4.c: Regenerated. * generated/matmul_i8.c: Regenerated. * generated/matmul_r10.c: Regenerated. * generated/matmul_r16.c: Regenerated. * generated/matmul_r4.c: Regenerated. * generated/matmul_r8.c: Regenerated. From-SVN: r243219
2016-11-15config-ml.in: Remove references to GCJ.Matthias Klose
<toplevel> 2016-11-15 Matthias Klose <doko@ubuntu.com> * config-ml.in: Remove references to GCJ. * configure.ac: Likewise. * configure: Regenerate. config/ 2016-11-15 Matthias Klose <doko@ubuntu.com> multi.m4: Don't set GCJ. gcc/ 2016-11-15 Matthias Klose <doko@ubuntu.com> * doc/install.texi: Remove references to gcj/libjava. * doc/invoke.texi: Likewise. */ (where necessary) 2016-11-15 Matthias Klose <doko@ubuntu.com> * configure: Regenerate. From-SVN: r242433
2016-08-29configure.ac (nvptx-*): Hardwire newlib.Nathan Sidwell
* configure.ac (nvptx-*): Hardwire newlib. * configure: Rebuilt. From-SVN: r239836
2015-08-31re PR fortran/47571 (undefined reference to clock_gettime in Linux build of ↵Francois-Xavier Coudert
02/01/2011) PR libfortran/47571 * acinclude.m4 (LIBGFOR_GTHREAD_WEAK): Reinstate. * configure.ac: Call LIBGFOR_GTHREAD_WEAK again. * config.h.in: Regenerate. * configure: Regenerate. From-SVN: r227347
2015-08-31re PR fortran/47571 (undefined reference to clock_gettime in Linux build of ↵Francois-Xavier Coudert
02/01/2011) PR libfortran/47571 * acinclude.m4 (LIBGFOR_GTHREAD_WEAK): Remove. (LIBGFOR_CHECK_WEAKREF): New test. * configure.ac: Call LIBGFOR_CHECK_WEAKREF instead of LIBGFOR_GTHREAD_WEAK. * config.h.in: Regenerate. * configure: Regenerate. * intrinsics/system_clock.c: Use SUPPORTS_WEAKREF instead of SUPPORTS_WEAK and GTHREAD_USE_WEAK. From-SVN: r227335
2015-08-29acinclude.m4: Remove LIBGFOR_CHECK_ATTRIBUTE_DLLEXPORT.Francois-Xavier Coudert
* acinclude.m4: Remove LIBGFOR_CHECK_ATTRIBUTE_DLLEXPORT. * configure.ac: Remove checks for strcasestr, execl, close, getrlimit, readlink, getppid, powl, erfl, j0l, j1l, y0l, y1l, tgammal, and lgammal. * config.h.in: Regenerate. * configure: Regenerate. From-SVN: r227319
2015-08-28[Patch] Add to the libgfortran/newlib bodge to "detect" ftruncate support in ↵James Greenhalgh
ARM/AArch64/SH * configure.ac: Auto-detect newlib function support unless we know there are issues when configuring for a host. * configure: Regenerate. From-SVN: r227301
2015-08-23re PR libfortran/54572 (Use libbacktrace library)Francois-Xavier Coudert
PR libfortran/54572 * Makefile.def: Make libgfortran depend on libbacktrace. * Makefile.in: Regenerate. * config-lang.in: Add libbacktrace to target_libs. * Makefile.am (libgfortran_la_LDFLAGS): Link in libbacktrace. (AM_CPPFLAGS): Add libbacktrace directories to include paths. * Makefile.in: Regenerate. * aclocal.m4: Regenerate. * config.h.in: Regenerate. * configure: Regenerate. * configure.ac: Remove checks for strtok_r, wait, execve, pipe, and dup2. Remove call to GCC_CHECK_UNWIND_GETIPINFO. * libgfortran.h (full_exe_path, find_addr2line, backtrace): Remove prototypes. (show_backtrace): Add prototype. * runtime/backtrace.c: Rework file entirely. * runtime/compile_options.c (backtrace_handler): Rename backtrace to show_backtrace. (maybe_find_addr2line): Remove function. (set_options): Remove call to maybe_find_addr2line. * runtime/error.c (sys_abort): Rename backtrace to show_backtrace. * runtime/main.c (store_exe_path): Empty function body. (full_exe_path, gfstrtok_r, find_addr2line): Remove functions. (cleanup): Don't free removed variables. * runtime/minimal.c (full_exe_path): Remove function. (set_args): Don't set exe_path. * gfortran.dg/backtrace_1.f90: New test. From-SVN: r227106
2015-04-22libstdc++, libgfortran gthr workaround for muslSzabolcs Nagy
On behalf of szabolcs.nagy@arm.com [libstdc++-v3/] 2015-04-22 Szabolcs Nagy <szabolcs.nagy@arm.com> * config/os/generic/os_defines.h (_GLIBCXX_GTHREAD_USE_WEAK): Define. * configure.host (os_include_dir): Set to "os/generic" for linux-musl*. [libgfortran/] 2015-04-22 Szabolcs Nagy <szabolcs.nagy@arm.com> * acinclude.m4 (GTHREAD_USE_WEAK): Define as 0 for *-*-musl*. * configure: Regenerate. From-SVN: r222329
2014-11-28Add support for a minimal version of libgfortran for accelerator targets.Bernd Schmidt
* Makefile.am (AM_CFLAGS): Add -DLIBGFOR_MINIMAL if LIBGFOR_MINIMAL. (gfor_io_src, gfor_heper_src, gfor_src): Split into minimal and always included sources. * Makefile.in: Regenerate. * configure.ac (LIBGFOR_MINIMAL): New AM_CONDITIONAL. * configure: Regenerate. * caf/single.c (caf_runtime_error): Don't print messages if LIBGFOR_MINIMAL. * runtime/compile_options.c (fatal_error_in_progress, show_signal, backtrace_handler, maybe_find_addr2line): Guard with !defined LIBGFOR_MINIMAL. (set_options): Likewise for the backtrace code. * runtime/minimal.c: New file. From-SVN: r218170
2014-11-24configure.ac: Guard include of <ieeefp.h>.John David Anglin
* configure.ac: Guard include of <ieeefp.h>. * configure: Rebuilt. From-SVN: r218032
2014-11-21Always use PIC option with -shared in libtoolH.J. Lu
Libtool needs to pass PIC option -shared when creating shared object to link regular object files with slim-lto archive. PR bootstrap/63784 * libtool.m4: Add $pic_flag with -shared. boehm-gc/ PR bootstrap/63784 * configure: Regenerated. gcc/ PR bootstrap/63784 * configure: Regenerated. libatomic/ PR bootstrap/63784 * configure: Regenerated. libbacktrace/ PR bootstrap/63784 * configure: Regenerated. libcc1/ PR bootstrap/63784 * configure: Regenerated. libcilkrts/ PR bootstrap/63784 * configure: Regenerated. libffi/ PR bootstrap/63784 * configure: Regenerated. libgfortran/ PR bootstrap/63784 * configure: Regenerated. libgomp/ PR bootstrap/63784 * configure: Regenerated. libitm/ PR bootstrap/63784 * configure: Regenerated. libjava/ PR bootstrap/63784 * configure: Regenerated. libjava/classpath/ PR bootstrap/63784 * configure: Regenerated. libobjc/ PR bootstrap/63784 * configure: Regenerated. libquadmath/ PR bootstrap/63784 * configure: Regenerated. libsanitizer/ PR bootstrap/63784 * configure: Regenerated. libssp/ PR bootstrap/63784 * configure: Regenerated. libstdc++-v3/ PR bootstrap/63784 * configure: Regenerated. libvtv/ PR bootstrap/63784 * configure: Regenerated. lto-plugin/ PR bootstrap/63784 * configure: Regenerated. From-SVN: r217937
2014-11-13PR 60324 Unbounded stack allocations in libgfortran.Janne Blomqvist
2014-11-13 Janne Blomqvist <jb@gcc.gnu.org> PR libfortran/60324 * configure: Regenerated. * configure.ac (AM_CFLAGS): Add Werror=vla. * libgfortran.h (gfc_alloca): Remove macro. (fc_strdup_notrim): New prototype. * intrinsics/access.c (access_func): Use fc_strdup rather than stack allocation. * intrinsics/chdir.c (chdir_i4_sub): Likewise. (chdir_i8_sub): Likewise. * intrinsics/chmod.c (chmod_internal): New function, move logic here. (chmod_func): Call chmod_internal. * intrinsics/env.c (getenv): Use fc_strdup rather than stack allocation. (get_environment_variable_i4): Likewise. * intrinsics/execute_command_line.c (execute_command_line): Likewise. * intrinsics/hostnm.c (hostnm_0): New function, use static buffer rather than VLA. (hostnm_i4_sub): Call hostnm_0. (hostnm_i8_sub): Likewise. (hostnm): Likewise. * intrinsics/link.c (link_internal): New function, use fc_strdup rather than stack allocation. (link_i4_sub): Call link_internal. (link_i8_sub): Likewise. (link_i4): Likewise. (link_i8): Likewise. * intrinsics/perror.c (perror_sub): Use fc_strdup rather than stack allocation. * intrinsics/random.c (random_seed_i4): Use static buffer rather than VLA, use _Static_assert to make sure it's big enough. * intrinsics/rename.c (rename_internal): New function, use fc_strdup rather than stack allocation. (rename_i4_sub): Call rename_internal. (rename_i8_sub): Likewise. (rename_i4): Likewise. (rename_i8): Likewise. * intrinsics/stat.c (stat_i4_sub_0): Use fc_strdup rather than stack allocation. (stat_i8_sub_0): Likewise. * intrinsics/symlink.c (symlnk_internal): New function, use fc_strdup rather than stack allocation. (symlnk_i4_sub): Call symlnk_internal. (symlnk_i8_sub): Likewise. (symlnk_i4): Likewise. (symlnk_i8): Likewise. * intrinsics/system.c (system_sub): Use fc_strdup rather than stack allocation. * intrinsics/unlink.c (unlink_i4_sub): Likewise. * io/file_pos.c (READ_CHUNK): Make it a macro rather than variable. * io/list_read.c (nml_get_obj_data): Use fixed stack buffer, fall back to xmalloc/free for large sizes. * io/read.c (read_f): Likewise. * io/transfer.c (MAX_READ): Make it a macro rather than variable. (WRITE_CHUNK): Likewise. * io/write_float.def (write_float): Use fixed stack buffer, fall back to xmalloc/free for large sizes. * runtime/string.c (fc_strdup_notrim): New function. From-SVN: r217480
2014-11-11re PR target/63610 (Fixing the libtool bug for Yosemite (darwin14))Francois-Xavier Coudert
toplevel: 2014-11-11 Francois-Xavier Coudert <fxcoudert@gcc.gnu.org> PR target/63610 * libtool.m4: Fix globbing of darwin versions. boehm-gc/ 2014-11-11 Francois-Xavier Coudert <fxcoudert@gcc.gnu.org> PR target/63610 * configure: Regenerate. gcc/ 2014-11-11 Francois-Xavier Coudert <fxcoudert@gcc.gnu.org> PR target/63610 * configure: Regenerate. libatomic/ 2014-11-11 Francois-Xavier Coudert <fxcoudert@gcc.gnu.org> PR target/63610 * configure: Regenerate. libbacktrace/ 2014-11-11 Francois-Xavier Coudert <fxcoudert@gcc.gnu.org> PR target/63610 * configure: Regenerate. libcc1/ 2014-11-11 Francois-Xavier Coudert <fxcoudert@gcc.gnu.org> PR target/63610 * configure: Regenerate. libcilkrts/ 2014-11-11 Francois-Xavier Coudert <fxcoudert@gcc.gnu.org> PR target/63610 * configure: Regenerate. libffi/ 2014-11-11 Francois-Xavier Coudert <fxcoudert@gcc.gnu.org> PR target/63610 * configure: Regenerate. libgfortran/ 2014-11-11 Francois-Xavier Coudert <fxcoudert@gcc.gnu.org> PR target/63610 * configure: Regenerate. libgomp/ 2014-11-11 Francois-Xavier Coudert <fxcoudert@gcc.gnu.org> PR target/63610 * configure: Regenerate. libitm/ 2014-11-11 Francois-Xavier Coudert <fxcoudert@gcc.gnu.org> PR target/63610 * configure: Regenerate. libobjc/ 2014-11-11 Francois-Xavier Coudert <fxcoudert@gcc.gnu.org> PR target/63610 * configure: Regenerate. libquadmath/ 2014-11-11 Francois-Xavier Coudert <fxcoudert@gcc.gnu.org> PR target/63610 * configure: Regenerate. libsanitizer/ 2014-11-11 Francois-Xavier Coudert <fxcoudert@gcc.gnu.org> PR target/63610 * configure: Regenerate. libssp/ 2014-11-11 Francois-Xavier Coudert <fxcoudert@gcc.gnu.org> PR target/63610 * configure: Regenerate. libstdc++-v3/ 2014-11-11 Francois-Xavier Coudert <fxcoudert@gcc.gnu.org> PR target/63610 * configure: Regenerate. libvtv/ 2014-11-11 Francois-Xavier Coudert <fxcoudert@gcc.gnu.org> PR target/63610 * configure: Regenerate. lto-plugin/ 2014-11-11 Francois-Xavier Coudert <fxcoudert@gcc.gnu.org> PR target/63610 * configure: Regenerate. libjava/ 2014-11-11 Francois-Xavier Coudert <fxcoudert@gcc.gnu.org> PR target/63610 * configure: Regenerate. libjava/classpath/ 2014-11-11 Francois-Xavier Coudert <fxcoudert@gcc.gnu.org> PR target/63610 * configure: Regenerate. zlib/ 2014-11-11 Francois-Xavier Coudert <fxcoudert@gcc.gnu.org> PR target/63610 * configure: Regenerate. From-SVN: r217366
2014-11-10PR 47007 and 61847 Locale failures in libgfortran.Janne Blomqvist
2014-11-10 Janne Blomqvist <jb@gcc.gnu.org> PR libfortran/47007 PR libfortran/61847 * config.h.in: Regenerated. * configure: Regenerated. * configure.ac (AC_CHECK_HEADERS_ONCE): Check for xlocale.h. (AC_CHECK_FUNCS_ONCE): Check for newlocale, freelocale, uselocale, strerror_l. * io/io.h (locale.h): Include. (xlocale.h): Include if present. (c_locale): New variable. (old_locale): New variable. (old_locale_ctr): New variable. (old_locale_lock): New variable. (st_parameter_dt): Add old_locale member. * io/transfer.c (data_transfer_init): Set locale to "C" if doing formatted transfer. (finalize_transfer): Reset locale to previous. * io/unit.c (c_locale): New variable. (old_locale): New variable. (old_locale_ctr): New variable. (old_locale_lock): New variable. (init_units): Init c_locale, init old_locale_lock. (close_units): Free c_locale. * runtime/error.c (locale.h): Include. (xlocale.h): Include if present. (gf_strerror): Use strerror_l if available. Reset locale to LC_GLOBAL_LOCALE for strerror_r branch. 2014-11-10 Janne Blomqvist <jb@gcc.gnu.org> PR libfortran/47007 PR libfortran/61847 * gfortran.texi: Add note about locale issues to thread-safety section. From-SVN: r217273
2014-10-20PR 63589 Fix splitting of PATH in find_addr2line.Janne Blomqvist
2014-10-20 Janne Blomqvist <jb@gcc.gnu.org> PR libfortran/63589 * configure.ac: Check for strtok_r. * runtime/main.c (gfstrtok_r): Fallback implementation of strtok_r. (find_addr2line): Use strtok_r to split PATH. * config.h.in: Regenerated. * configure: Regenerated. From-SVN: r216449
2014-09-30Add -Werror=implicit-function-declaration to AM_CFLAGS.Janne Blomqvist
2014-09-30 Janne Blomqvist <jb@gcc.gnu.org> * configure.ac (AM_CFLAGS): Add -Werror=implicit-function-declaration. * Makefile.in: Regenerated. * aclocal.m4: Regenerated. * configure: Regenerated. From-SVN: r215741
2014-07-05Restore Solaris/SPARC bootstrapRainer Orth
* configure, config.h.in: Regenerate. * config/fpu-sysv.h: Include <assert.h>. From-SVN: r212307
2014-06-28re PR fortran/29383 (Fortran 2003/F95[TR15580:1999]: Floating point ↵Francois-Xavier Coudert
exception (IEEE) support) PR fortran/29383 gcc/fortran/ * gfortran.h (gfc_simplify_ieee_selected_real_kind): New prototype. * libgfortran.h (GFC_FPE_*): Use simple integer values, valid in both C and Fortran. * expr.c (gfc_check_init_expr): Simplify IEEE_SELECTED_REAL_KIND. * simplify.c (gfc_simplify_ieee_selected_real_kind): New function. * module.c (mio_symbol): Keep track of symbols which came from intrinsic modules. (gfc_use_module): Keep track of the IEEE modules. * trans-decl.c (gfc_get_symbol_decl): Adjust code since we have new intrinsic modules. (gfc_build_builtin_function_decls): Build decls for ieee_procedure_entry and ieee_procedure_exit. (is_from_ieee_module, is_ieee_module_used, save_fp_state, restore_fp_state): New functions. (gfc_generate_function_code): Save and restore floating-point state on procedure entry/exit, when IEEE modules are used. * intrinsic.texi: Document the IEEE modules. libgfortran/ * configure.host: Add checks for IEEE support, rework priorities. * configure.ac: Define IEEE_SUPPORT, check for fpsetsticky and fpresetsticky. * configure: Regenerate. * Makefile.am: Build new ieee files, install IEEE_* modules. * Makefile.in: Regenerate. * gfortran.map (GFORTRAN_1.6): Add new symbols. * libgfortran.h (get_fpu_trap_exceptions, set_fpu_trap_exceptions, support_fpu_trap, set_fpu_except_flags, support_fpu_flag, support_fpu_rounding_mode, get_fpu_state, set_fpu_state): New prototypes. * config/fpu-*.h (get_fpu_trap_exceptions, set_fpu_trap_exceptions, support_fpu_trap, set_fpu_except_flags, support_fpu_flag, support_fpu_rounding_mode, get_fpu_state, set_fpu_state): New functions. * ieee/ieee_features.F90: New file. * ieee/ieee_exceptions.F90: New file. * ieee/ieee_arithmetic.F90: New file. * ieee/ieee_helper.c: New file. gcc/testsuite/ * lib/target-supports.exp (check_effective_target_fortran_ieee): New function. * gfortran.dg/ieee/ieee.exp: New file. * gfortran.dg/ieee/ieee_1.F90: New file. * gfortran.dg/ieee/ieee_2.f90: New file. * gfortran.dg/ieee/ieee_3.f90: New file. * gfortran.dg/ieee/ieee_4.f90: New file. * gfortran.dg/ieee/ieee_5.f90: New file. * gfortran.dg/ieee/ieee_6.f90: New file. * gfortran.dg/ieee/ieee_7.f90: New file. * gfortran.dg/ieee/ieee_rounding_1.f90: New file. From-SVN: r212102
2014-06-15re PR libfortran/60468 (./fpu-target.h:93:3: error: unknown type name 'choke')Francois-Xavier Coudert
PR libfortran/60468 * configure.ac: Include <math.h> when checking for fp_except_t and fp_rnd_t types. * configure: Regenerate. From-SVN: r211685
2014-05-23configure.ac [...] (HAVE_STRNLEN, [...]): Define.Hans-Peter Nilsson
* configure.ac [with_newlib] (HAVE_STRNLEN, HAVE_STRNDUP): Define. * configure: Regenerate. From-SVN: r210841
2014-05-22PR 60324 Handle long path names, don't use PATH_MAX.Janne Blomqvist
From-SVN: r210738
2014-05-12Use -std=gnu11 instead of -std=gnu99 for libgfortran C code.Janne Blomqvist
2014-05-12 Janne Blomqvist <jb@gcc.gnu.org> * configure.ac (AM_CFLAGS): Use -std=gnu11. (CFLAGS): Likewise. * configure: Regenerated. From-SVN: r210334
2014-04-24Fix warning in libgfortran configure scriptKyrylo Tkachov
* configure.ac: Quote usage of ac_cv_func_clock_gettime in if test. * configure: Regenerate. From-SVN: r209747