Commit Graph

476 Commits

Author SHA1 Message Date
GCC Administrator
ab869e7f75 Daily bump. 2022-05-06 00:16:26 +00:00
H.J. Lu
a48be2e513 libsanitizer: cherry-pick commit b226894d475b from upstream
cherry-pick:

b226894d475b [sanitizer] [sanitizer] Correct GetTls for x32
2022-05-05 13:59:16 -07:00
Martin Liska
7ec6fed1e8 libsanitizer: update LOCAL_PATCHES.
libsanitizer/ChangeLog:

	* LOCAL_PATCHES: Update.
2022-05-05 13:25:16 +02:00
Martin Liska
45e69f7f38 libsanitizer: Apply local patches 2022-05-05 13:24:20 +02:00
Martin Liska
8996894d00 libsanitizer: merge from master (75f9e83ace52773af65dcebca543005ec8a2705d). 2022-05-05 13:24:04 +02:00
GCC Administrator
3e7db51747 Daily bump. 2022-05-05 00:16:29 +00:00
H.J. Lu
ae90c2d0f9 libsanitizer: cherry-pick commit f52e365092aa from upstream
cherry-pick:

f52e365092aa [sanitizer] Use newfstatat for x32
2022-05-04 15:59:49 -07:00
Martin Liska
056d8a82fc libsanitizer: Update Makefile.am files.
libsanitizer/ChangeLog:

	* tsan/Makefile.am: Update Makefile.am files.
	* hwasan/Makefile.am: Likewise.
	* sanitizer_common/Makefile.am: Likewise.
	* Makefile.in: Re-generate.
	* asan/Makefile.in: Likewise.
	* hwasan/Makefile.in: Likewise.
	* interception/Makefile.in: Likewise.
	* libbacktrace/Makefile.in: Likewise.
	* lsan/Makefile.in: Likewise.
	* sanitizer_common/Makefile.in: Likewise.
	* tsan/Makefile.in: Likewise.
	* ubsan/Makefile.in: Likewise.
2022-05-04 11:00:53 +02:00
H.J. Lu
22a2a09186 libsanitizer: Apply local patches 2022-05-04 11:00:52 +02:00
Martin Liska
f732bf6a60 libsanitizer: merge from upstream (0a1bcab9f3bf75c4c5d3e53bafb3eeb80320af46). 2022-05-04 11:00:48 +02:00
GCC Administrator
510613e76c Daily bump. 2022-03-15 00:16:49 +00:00
Xi Ruoyao
344e6f9f2a
Enable libsanitizer build on mips64
Bootstrapped and regtested on mips64-linux-gnuabi64.

bootstrap-ubsan revealed 3 bugs (PR 104842, 104843, 104851).
bootstrap-asan did not reveal any new bug.

gcc/

	* config/mips/mips.h (SUBTARGET_SHADOW_OFFSET): Define.
	* config/mips/mips.cc (mips_option_override): Make
	-fsanitize=address imply -fasynchronous-unwind-tables.  This is
	needed by libasan for stack backtrace on MIPS.
	(mips_asan_shadow_offset): Return SUBTARGET_SHADOW_OFFSET.

gcc/testsuite:

	* c-c++-common/asan/global-overflow-1.c: Skip for MIPS with some
	optimization levels because inaccurate debug info is causing
	dg-output mismatch on line numbers.
	* g++.dg/asan/large-func-test-1.C: Likewise.

libsanitizer/

	* configure.tgt: Enable build on mips*64*-*-linux*.
2022-03-15 00:39:47 +08:00
Xi Ruoyao
a60a3a95d0
libsanitizer: cherry-pick db7bca28638e from upstream
libsanitizer/

	* sanitizer_common/sanitizer_atomic_clang.h: Ensures to only
	include sanitizer_atomic_clang_mips.h for O32.
2022-03-15 00:34:12 +08:00
GCC Administrator
875e493bf5 Daily bump. 2022-02-16 00:16:26 +00:00
Jakub Jelinek
c4c0aa6089 sanitizer: Use glibc _thread_db_sizeof_pthread symbol if present
I've cherry-picked following fix from llvm-project.  Recent glibcs
have _thread_db_sizeof_pthread symbol variable which contains the
size of struct pthread, so that sanitizers don't need to guess that
and risk that it will change again.

2022-02-15  Jakub Jelinek  <jakub@redhat.com>

	* sanitizer_common/sanitizer_linux_libcdep.cpp: Cherry-pick
	llvm-project revision ef14b78d9a144ba81ba02083fe21eb286a88732b.
2022-02-15 11:18:56 +01:00
GCC Administrator
682ede3959 Daily bump. 2022-02-04 00:16:24 +00:00
David Seifert
45ba6bf28b make -Werror optional in libatomic/libbacktrace/libgomp/libitm/libsanitizer
* `-Werror` can cause issues when a more recent version of GCC compiles
  an older version:
  - https://bugs.gentoo.org/229059
  - https://bugs.gentoo.org/475350
  - https://bugs.gentoo.org/667104

libatomic/ChangeLog:

	* configure.ac: Support --disable-werror.
	* configure: Regenerate.

libbacktrace/ChangeLog:

	* configure.ac: Support --disable-werror.
	* configure: Regenerate.

libgomp/ChangeLog:

	* configure.ac: Support --disable-werror.
	* configure: Regenerate.

libitm/ChangeLog:

	* configure.ac: Support --disable-werror.
	* configure: Regenerate.

libsanitizer/ChangeLog:

	* configure.ac: Support --disable-werror.
	* aclocal.m4: Include also ../config/warnings.m4.
	* libbacktrace/Makefile.am (WARN_FLAGS): Remove.
	* configure: Regenerate.
	* Makefile.in: Regenerate.
	* asan/Makefile.in: Regenerate.
	* hwasan/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.

Co-Authored-By: Jakub Jelinek <jakub@redhat.com>
2022-02-03 16:10:18 +01:00
GCC Administrator
3a580f967e Daily bump. 2021-12-07 00:16:23 +00:00
H.J. Lu
2a20407bac libsanitizer: Update LOCAL_PATCHES
Add

commit 70b043845d
Author: H.J. Lu <hjl.tools@gmail.com>
Date:   Tue Nov 30 05:31:26 2021 -0800

    libsanitizer: Use SSE to save and restore XMM registers

to LOCAL_PATCHES.

	* LOCAL_PATCHES: Add commit 70b043845d.
2021-12-06 08:17:49 -08:00
H.J. Lu
70b043845d libsanitizer: Use SSE to save and restore XMM registers
Use SSE, instead of AVX, to save and restore XMM registers to support
processors without AVX.  The affected codes are unused in upstream since

https://github.com/llvm/llvm-project/commit/66d4ce7e26a5

and will be removed in

https://reviews.llvm.org/D112604

This fixed

FAIL: g++.dg/tsan/pthread_cond_clockwait.C   -O0  execution test
FAIL: g++.dg/tsan/pthread_cond_clockwait.C   -O2  execution test

on machines without AVX.

	PR sanitizer/103466
	* tsan/tsan_rtl_amd64.S (__tsan_trace_switch_thunk): Replace
	vmovdqu with movdqu.
	(__tsan_report_race_thunk): Likewise.
2021-12-06 08:16:49 -08:00
GCC Administrator
2f0dd172bc Daily bump. 2021-11-29 00:16:16 +00:00
Andrew Pinski
32377c1019 Fix PR 62157: disclean in libsanitizer not working
So what is happening is DIST_SUBDIRS contains the conditional
directories which is wrong, so we need to force DIST_SUBDIRS
to be the same as SUBDIRS as recommened by the automake manual.

OK? Bootstrapped and tested on x86_64-linux-gnu with no regressions.
Also now make distclean works inside libsanitizer directory.

libsanitizer/ChangeLog:

	PR sanitizer/62157
	* Makefile.am: Force DIST_SUBDIRS to be SUBDIRS.
	* Makefile.in: Regenerate.
	* asan/Makefile.in: Likewise.
	* hwasan/Makefile.in: Likewise.
	* interception/Makefile.in: Likewise.
	* libbacktrace/Makefile.in: Likewise.
	* lsan/Makefile.in: Likewise.
	* sanitizer_common/Makefile.in: Likewise.
	* tsan/Makefile.in: Likewise.
	* ubsan/Makefile.in: Likewise.
2021-11-28 22:40:36 +00:00
GCC Administrator
483092d3d9 Daily bump. 2021-11-19 00:16:34 +00:00
Jakub Jelinek
edd2249b17 libsanitizer: Fix bootstrap on FreeBSD [PR102675]
Here is an alternative to the patch changing a file imported from
compiler-rt upstream, so that we don't need to cary a local patch for that
particular problem.

2021-11-18  Jakub Jelinek  <jakub@redhat.com>

	PR bootstrap/102675
	* sanitizer_common/Makefile.am: Use -DUSE_SYSTEM_MD5 in AM_CXXFLAGS
	of sanitizer_platform_limits_freebsd.cpp.
	* sanitizer_common/Makefile.in: Regenerated.
2021-11-18 10:08:03 +01:00
GCC Administrator
a8029add30 Daily bump. 2021-11-14 00:16:23 +00:00
H.J. Lu
380fc3b69f libsanitizer: Update LOCAL_PATCHES
* LOCAL_PATCHES: Update to the corresponding revision.
2021-11-13 05:17:14 -08:00
H.J. Lu
55b43a22ab libsanitizer: Apply local patches 2021-11-13 05:15:25 -08:00
H.J. Lu
86289a4ff4 libsanitizer: Merge with upstream
Merged revision: 82bc6a094e85014f1891ef9407496f44af8fe442

with the fix for PR sanitizer/102911
2021-11-13 05:15:24 -08:00
Martin Liska
bdb9d47218 libsanitizer: update LOCAL_PATCHES. 2021-11-05 18:21:42 +01:00
H.J. Lu
5f0a3fb08c libsanitizer: Apply local patches 2021-11-05 18:21:29 +01:00
Martin Liska
2afc8f0b91 libsanitizer: merge from master (78d3e0a4f1406b17cdecc77540e09210670fe9a9). 2021-11-05 18:21:27 +01:00
GCC Administrator
29a1af24ef Daily bump. 2021-11-05 00:16:36 +00:00
Martin Liska
af976d90fa libsanitizer: update LOCAL_PATCHES
libsanitizer/ChangeLog:

	* LOCAL_PATCHES: Update git revision.
2021-11-04 13:26:58 +01:00
H.J. Lu
65ade6a34c libsanitizer: Apply local patches 2021-11-04 13:26:17 +01:00
Martin Liska
0cedf1fb76 lisanitizer: Apply autoreconf. 2021-11-04 13:26:05 +01:00
Martin Liska
cb0437584b libsanitizer: merge from master (c86b4503a94c277534ce4b9a5c015a6ac151b98a). 2021-11-04 13:24:53 +01:00
GCC Administrator
ce6eec3926 Daily bump. 2021-10-09 00:16:26 +00:00
H.J. Lu
a23653c6a6 libsanitizer: Add AM_CCASFLAGS to Makefile.am
commit 9069eb28d4
Author: Igor Tsimbalist <igor.v.tsimbalist@intel.com>
Date:   Fri Nov 17 22:34:50 2017 +0100

    Enable building libsanitizer with Intel CET

    libsanitizer/
            * acinclude.m4: Add enable.m4 and cet.m4.
            * Makefile.in: Regenerate.
            * asan/Makefile.am: Update AM_CXXFLAGS.
            * asan/Makefile.in: Regenerate.
            * configure: Likewise.
            * configure.ac: Set CET_FLAGS. Update EXTRA_CFLAGS,
            EXTRA_CXXFLAGS, EXTRA_ASFLAGS.
            * interception/Makefile.am: Update AM_CXXFLAGS.
            * interception/Makefile.in: Regenerate.
            * libbacktrace/Makefile.am: Update AM_CFLAGS, AM_CXXFLAGS.
            * libbacktrace/Makefile.in: Regenerate.
            * lsan/Makefile.am: Update AM_CXXFLAGS.
            * lsan/Makefile.in: Regenerate.
            * sanitizer_common/Makefile.am: Update AM_CXXFLAGS,
            AM_CCASFLAGS.
            * sanitizer_common/sanitizer_linux_x86_64.S: Include cet.h.
            Add _CET_ENDBR macro.
            * sanitizer_common/Makefile.in: Regenerate.
            * tsan/Makefile.am: Update AM_CXXFLAGS.
            * tsan/Makefile.in: Regenerate.
            * tsan/tsan_rtl_amd64.S Include cet.h. Add _CET_ENDBR macro.
            * ubsan/Makefile.am: Update AM_CXXFLAGS.
            * ubsan/Makefile.in: Regenerate.

failed to add EXTRA_ASFLAGS to AM_CCASFLAGS in all Makefile.am.  As
the result, CET aren't enabled in all assembly codes.

Add AM_CCASFLAGS to Makefile.am to compile assembly codes with $CET_FLAGS.

	PR sanitizer/102632
	* asan/Makefile.am (AM_CCASFLAGS): New.  Set to $(EXTRA_ASFLAGS).
	* hwasan/Makefile.am (AM_CCASFLAGS): Likewise.
	* interception/Makefile.am (AM_CCASFLAGS): Likewise.
	* lsan/Makefile.am (AM_CCASFLAGS): Likewise.
	* tsan/Makefile.am (AM_CCASFLAGS): Likewise.
	* ubsan/Makefile.am (AM_CCASFLAGS): Likewise.
	* asan/Makefile.in: Regenerate.
	* hwasan/Makefile.in: Likewise.
	* interception/Makefile.in: Likewise.
	* lsan/Makefile.in: Likewise.
	* tsan/Makefile.in: Likewise.
	* ubsan/Makefile.in: Likewise.
2021-10-08 06:17:01 -07:00
GCC Administrator
57c7ec62ee Daily bump. 2021-10-07 00:16:24 +00:00
H.J. Lu
929cb75e42 libsanitizer: Update LOCAL_PATCHES
* LOCAL_PATCHES: Update to the corresponding revision.
2021-10-06 13:11:34 -07:00
H.J. Lu
bb8adf080e libsanitizer: Apply local patches 2021-10-06 13:08:47 -07:00
H.J. Lu
2e3d50c095 libsanitizer: Merge with upstream
Merged revision: fdf4c035225de52f596899931b1f6100e5e3e928
2021-10-06 13:08:47 -07:00
GCC Administrator
9d116bcc55 Daily bump. 2021-10-02 00:16:31 +00:00
H.J. Lu
be5bdccd86 libsanitizer: Update LOCAL_PATCHES
* LOCAL_PATCHES: Update to the corresponding revision.
2021-10-01 09:04:28 -07:00
H.J. Lu
984400f04e libsanitizer: Bump asan/tsan versions
Bump asan/tsan versions for upstream commits:

commit f1bb30a4956f83e46406d6082e5d376ce65391e0
Author: Vitaly Buka <vitalybuka@google.com>
Date:   Thu Aug 26 10:25:09 2021 -0700

    [sanitizer] No THREADLOCAL in qsort and bsearch

    qsort can reuse qsort_r if available.
    bsearch always passes key as the first comparator argument, so we
    can use it to wrap the original comparator.

    Differential Revision: https://reviews.llvm.org/D108751

commit d77b476c1953bcb0a608b2d6a4f2dd9fe0b43967
Author: Dmitry Vyukov <dvyukov@google.com>
Date:   Mon Aug 2 16:52:53 2021 +0200

    tsan: avoid extra call indirection in unaligned access functions

    Currently unaligned access functions are defined in tsan_interface.cpp
    and do a real call to MemoryAccess. This means we have a real call
    and no read/write constant propagation.

    Unaligned memory access can be quite hot for some programs
    (observed on some compression algorithms with ~90% of unaligned accesses).

    Move them to tsan_interface_inl.h to avoid the additional call
    and enable constant propagation.
    Also reorder the actual store and memory access handling for
    __sanitizer_unaligned_store callbacks to enable tail calling
    in MemoryAccess.

    Depends on D107282.

    Reviewed By: vitalybuka, melver

commit 97795be22f634667ce7a022398c59ccc9f7440eb
Author: Dmitry Vyukov <dvyukov@google.com>
Date:   Fri Jul 30 08:35:11 2021 +0200

    tsan: optimize test-only barrier

    The updated lots_of_threads.c test with 300 threads
    started running for too long on machines with low
    hardware parallelism (e.g. taskset -c 0-1).
    On lots of CPUs it finishes in ~2 secs. But with
    taskset -c 0-1 it runs for hundreds of seconds
    effectively spinning in the barrier in the sleep loop.

    We now have the handy futex API in sanitizer_common.
    Use it instead of the passive spin loop.
    It makes the test run only faster with taskset -c 0-1,
    it runs for ~1.5 secs, while with full parallelism
    it still runs for ~2 secs (but consumes less CPU time).

    Depends on D107131.

    Reviewed By: vitalybuka
2021-10-01 09:02:54 -07:00
H.J. Lu
488efba0ab libsanitizer: Apply local patches 2021-10-01 09:02:54 -07:00
H.J. Lu
76288e1c5d libsanitizer: Merge with upstream
Merged revision: 1c2e5fd66ea27d0c51360ba4e22099124a915562
2021-10-01 09:02:54 -07:00
GCC Administrator
58f8750342 Daily bump. 2021-08-12 00:16:28 +00:00
Jakub Jelinek
0e6017f5b4 sanitizer: Cherry-pick realpath fix
tsan in some cases starts ignoring interceptors and only calls the
intercepted functions.  But for realpath the behavior for NULL second argument
was only handled in the interceptor and intercepted function was the one
found by dlsym which is often one that doesn't handle NULL as second argument.

Fixed by using dlvsym with "GLIBC_2.3" if possible for intercepted function
and don't emulate behavior in the wrapper.

2021-08-11  Jakub Jelinek  <jakub@redhat.com>

	* sanitizer_common/sanitizer_common_interceptors.inc: Cherry-pick
	llvm-project revision faef0d042f523357fe5590e7cb6a8391cf0351a8.
2021-08-11 10:23:34 +02:00
GCC Administrator
fa1407c761 Daily bump. 2021-08-04 00:16:51 +00:00
Mosè Giordano
759f3854f0 Fix bashism in `libsanitizer/configure.tgt'
Appending to a string variable with `+=' is a bashism and does not work in
strict POSIX shells like dash.  This results in the extra compilation flags not
to be set correctly.  This patch replaces the `+=' syntax with a simple string
interpolation to append to the `EXTRA_CXXFLAGS' variable.

libsanitizer/ChangeLog

	PR sanitizer/101111
	* configure.tgt: Fix bashism in setting of `EXTRA_CXXFLAGS'.
2021-08-03 13:24:47 +02:00
GCC Administrator
3916902930 Daily bump. 2021-07-29 00:16:43 +00:00
Ilya Leoshkevich
ea22954e7c IBM Z: Enable LSan and TSan
libsanitizer/ChangeLog:

	* configure.tgt (s390*-*-linux*): Enable LSan and TSan for
	s390x.
2021-07-28 13:03:32 +02:00
GCC Administrator
92d4550991 Daily bump. 2021-07-21 00:16:54 +00:00
H.J. Lu
4eea703e7d libsanitizer: Bump asan/tsan versions
Bump asan/tsan versions for the upstream commit:

commit acf0a6428681dccac803984bfbb1e3e54248f090
Author: Ilya Leoshkevich <iii@linux.ibm.com>
Date:   Fri Jul 2 02:42:38 2021 +0200

    [sanitizer] Fix __sanitizer_kernel_sigset_t endianness issue

    setuid(0) hangs on SystemZ under TSan because TSan's BackgroundThread
    ignores SIGSETXID. This in turn happens because internal_sigdelset()
    messes up the mask bits on big-endian system due to how
    __sanitizer_kernel_sigset_t is defined.

    Commit d9a1a53b8d80 ("[ESan] [MIPS] Fix workingset-signal-posix.cpp on
    MIPS") fixed this for MIPS by adjusting the __sanitizer_kernel_sigset_t
    definition. Generalize this by defining __SANITIZER_KERNEL_NSIG based
    on kernel's _NSIG and using uptr[] for __sanitizer_kernel_sigset_t.sig
    on all platforms.

    Reviewed By: dvyukov

    Differential Revision: https://reviews.llvm.org/D105629

which changed __sanitizer_kernel_sigset_t and changed the ABI for function

void __sanitizer_syscall_post_impl_rt_sigaction
  (long int, long int,
   const __sanitizer::__sanitizer_kernel_sigaction_t*,
   __sanitizer::__sanitizer_kernel_sigaction_t*,
   SIZE_T);

	* asan/libtool-version: Bump version.
	* tsan/libtool-version: Likewise.
2021-07-20 14:21:52 -07:00
H.J. Lu
a6e600f197 libsanitizer: Update LOCAL_PATCHES
* LOCAL_PATCHES: Update to the corresponding revision.
2021-07-20 14:21:52 -07:00
H.J. Lu
1388232dc1 libsanitizer: Apply local patches 2021-07-20 14:21:51 -07:00
H.J. Lu
90e46074e6 libsanitizer: Merge with upstream
Merged revision: 7704fedfff6ef5676adb6415f3be0ac927d1a746
2021-07-20 14:21:51 -07:00
GCC Administrator
2832d51b38 Daily bump. 2021-05-22 00:16:29 +00:00
Tamar Christina
745dae5923 libsanitizer: Remove cyclades from libsanitizer
The Linux kernel has removed the interface to cyclades from
the latest kernel headers[1] due to them being orphaned for the
past 13 years.

libsanitizer uses this header when compiling against glibc, but
glibcs itself doesn't seem to have any references to cyclades.

Further more it seems that the driver is broken in the kernel and
the firmware doesn't seem to be available anymore.

As such since this is breaking the build of libsanitizer (and so the
GCC bootstrap[2]) I propose to remove this.

[1] https://lkml.org/lkml/2021/3/2/153
[2] https://gcc.gnu.org/bugzilla/show_bug.cgi?id=100379

(cherry picked from commit f7c5351552387bd43f6ca3631016d7f0dfe0f135)

libsanitizer/ChangeLog:

	PR sanitizer/100379
	* sanitizer_common/sanitizer_common_interceptors_ioctl.inc: Cherry-pick
	llvm-project revision f7c5351552387bd43f6ca3631016d7f0dfe0f135.
	* sanitizer_common/sanitizer_platform_limits_posix.cpp: Likewise.
	* sanitizer_common/sanitizer_platform_limits_posix.h: Likewise.
2021-05-21 10:30:59 +01:00
H.J. Lu
f3b1516d9d libsanitizer: cherry-pick from upstream
cherry-pick:

72797dedb720 [sanitizer] Use size_t on g_tls_size to fix build on x32
2021-05-13 18:23:55 -07:00
GCC Administrator
f9af11c7f1 Daily bump. 2021-05-14 00:16:30 +00:00
Iain Sandoe
1f6fc2826d libsanitizer : Update LOCAL_PATCHES.
This adds the local patch to handle missing __builtin_os_log_format
on Darwin.

libsanitizer/ChangeLog:

	* LOCAL_PATCHES: Add Darwin patch for __builtin_os_log_format.
2021-05-13 21:19:19 +01:00
Iain Sandoe
adab7b2bf4 libsanitizer, Darwin : Handle missing __builtin_os_log_format.
GCC does not, currently, define __builtin_os_log_format, which
is needed by os/log.h.  Do not include that header unless the
builtin is defined (since the header errors out on the same
condition).  Provide a work-around solution to the missing API
provided via the header.

libsanitizer/ChangeLog:

	* sanitizer_common/sanitizer_mac.cpp : Check for the
	availability of __builtin_os_log_format before trying to
	include a header depending on it.
	(OS_LOG_DEFAULT): New.
	(os_log_error): Define to a fall-back using an older API.
2021-05-13 21:18:18 +01:00
Martin Liska
269338fe9d libsanitizer: update LOCAL_PATCHES.
libsanitizer/ChangeLog:

	* LOCAL_PATCHES: Update to the corresponding revision.
2021-05-13 09:30:05 +02:00
Martin Liska
fb73b1ce36 libsanitizer: Apply local patches. 2021-05-13 09:29:50 +02:00
Martin Liska
d0fee87e0c libsanitizer: merge from master
Merged revision: f58e0513dd95944b81ce7a6e7b49ba656de7d75f
2021-05-13 09:29:17 +02:00
GCC Administrator
da946b41be Daily bump. 2021-04-18 00:16:21 +00:00
Jakub Jelinek
d9f462fb37 sanitizer: Fix asan against glibc 2.34 [PR100114]
As mentioned in the PR, SIGSTKSZ is no longer a compile time constant in
glibc 2.34 and later, so
static const uptr kAltStackSize = SIGSTKSZ * 4;
needs dynamic initialization, but is used by a function called indirectly
from .preinit_array and therefore before the variable is constructed.
This results in using 0 size instead and all asan instrumented programs
die with:
==91==ERROR: AddressSanitizer failed to allocate 0x0 (0) bytes of SetAlternateSignalStack (error code: 22)

Here is a cherry-pick from upstream to fix this.

2021-04-17  Jakub Jelinek  <jakub@redhat.com>

	PR sanitizer/100114
	* sanitizer_common/sanitizer_posix_libcdep.cpp: Cherry-pick
	llvm-project revisions 82150606fb11d28813ae6da1101f5bda638165fe
	and b93629dd335ffee2fc4b9b619bf86c3f9e6b0023.
2021-04-17 11:27:14 +02:00
GCC Administrator
6405b40f4a Daily bump. 2021-03-09 00:16:57 +00:00
Martin Liska
81fee43851 libsanitizer: cherry-pick ad294e572bc5c16f9dc420cc994322de6ca3fbfb
libsanitizer/ChangeLog:

	PR sanitizer/98920
	* asan/asan_interceptors.cpp (COMMON_INTERCEPT_FUNCTION_VER):
	Cherry pick.
	(COMMON_INTERCEPT_FUNCTION_VER_UNVERSIONED_FALLBACK): Likewise.
	* asan/asan_interceptors.h (ASAN_INTERCEPT_FUNC_VER_UNVERSIONED_FALLBACK): Likewise.
	* sanitizer_common/sanitizer_common_interceptors.inc
	(COMMON_INTERCEPT_FUNCTION_GLIBC_VER_MIN): Likewise.
	(INIT_REGEX): Likewise.
	* tsan/tsan_interceptors_posix.cpp (COMMON_INTERCEPT_FUNCTION_VER_UNVERSIONED_FALLBACK):
	Likewise.

gcc/testsuite/ChangeLog:

	PR sanitizer/98920
	* c-c++-common/asan/pr98920.c: New test.
2021-03-08 15:55:27 +01:00
Martin Liska
e03e58c184 Fix UBSAN in __ubsan::Value::getSIntValue
/home/marxin/Programming/gcc2/libsanitizer/ubsan/ubsan_value.cpp:77:25: runtime error: left shift of 0x0000000000000000fffffffffffffffb by 96 places cannot be represented in type '__int128'
    #0 0x7ffff754edfe in __ubsan::Value::getSIntValue() const /home/marxin/Programming/gcc2/libsanitizer/ubsan/ubsan_value.cpp:77
    #1 0x7ffff7548719 in __ubsan::Value::isNegative() const /home/marxin/Programming/gcc2/libsanitizer/ubsan/ubsan_value.h:190
    #2 0x7ffff7542a34 in handleShiftOutOfBoundsImpl /home/marxin/Programming/gcc2/libsanitizer/ubsan/ubsan_handlers.cpp:338
    #3 0x7ffff75431b7 in __ubsan_handle_shift_out_of_bounds /home/marxin/Programming/gcc2/libsanitizer/ubsan/ubsan_handlers.cpp:370
    #4 0x40067f in main (/home/marxin/Programming/testcases/a.out+0x40067f)
    #5 0x7ffff72c8b24 in __libc_start_main (/lib64/libc.so.6+0x27b24)
    #6 0x4005bd in _start (/home/marxin/Programming/testcases/a.out+0x4005bd)

Differential Revision: https://reviews.llvm.org/D97263

Cherry-pick from 16ede0956cb1f4b692dfa619ccfa6ab1de28e19b.
2021-02-23 11:15:16 +01:00
GCC Administrator
e62bb7f083 Daily bump. 2021-01-27 00:16:33 +00:00
Martin Liska
2e81b16c24 liblsan: build missing lsan_posix.cpp file
libsanitizer/ChangeLog:

	PR sanitizer/98828
	* lsan/Makefile.am: Add missing lsan_posix.cpp file.
	* lsan/Makefile.in: Likewise.
2021-01-26 14:14:40 +01:00
GCC Administrator
651b8a50a6 Daily bump. 2021-01-06 00:16:55 +00:00
Samuel Thibault
f56de3557f Update GNU/Hurd configure support
ChangeLog:

	* libtool.m4: Match gnu* along other GNU systems.
	* libgo/config/libtool.m4: Match gnu* along other GNU systems.
	* libgo/configure: Re-generate.

libffi/
	* configure: Re-generate.

libgomp/
	* configure: Re-generate.

gcc/

	* configure: Re-generate.

libatomic/

	* configure: Re-generate.

libbacktrace/

	* configure: Re-generate.

libcc1/

	* configure: Re-generate.

libgfortran/

	* configure: Re-generate.

libgomp/

	* configure: Re-generate.

libhsail-rt/

	* configure: Re-generate.

libitm/

	* configure: Re-generate.

libobjc/

	* configure: Re-generate.

liboffloadmic/

	* configure: Re-generate.
	* plugin/configure: Re-generate.

libphobos/

	* configure: Re-generate.

libquadmath/

	* configure: Re-generate.

libsanitizer/

	* configure: Re-generate.

libssp/

	* configure: Re-generate.

libstdc++-v3/

	* configure: Re-generate.

libvtv/

	* configure: Re-generate.

lto-plugin/

	* configure: Re-generate.

zlib/

	* configure: Re-generate.
2021-01-05 16:04:14 -07:00
GCC Administrator
6e1edf48eb Daily bump. 2020-12-06 00:16:44 +00:00
Iain Sandoe
1352bc88a0 Darwin : Update libtool and dependencies for Darwin20 [PR97865]
The change in major version (and the increment from Darwin19 to 20)
caused libtool tests to fail which resulted in incorrect build settings
for shared libraries.

We take this opportunity to sort out the shared undefined symbols state
rather than propagating the current unsound behaviour into a new rev.

This change means that we default to the case that missing symbols are
considered an error, and if one wants to allow this intentionally, the
confiuration for that case should be set appropriately.

Three existing cases need undefined dynamic lookup:
 libitm, where there is already a configuration mechanism to add the
         flags.
 libcc1, where we add simple configuration to add the flags for Darwin.
 libsanitizer, where we can add to the existing extra flags.

libcc1/ChangeLog:

	PR target/97865
	* Makefile.am: Add dynamic_lookup to LD flags for Darwin.
	* configure.ac: Test for Darwin host and set a flag.
	* Makefile.in: Regenerate.
	* configure: Regenerate.

libitm/ChangeLog:

	PR target/97865
	* configure.tgt: Add dynamic_lookup to XLDFLAGS for Darwin.
	* configure: Regenerate.

libsanitizer/ChangeLog:

	PR target/97865
	* configure.tgt: Add dynamic_lookup to EXTRA_CXXFLAGS for
	Darwin.
	* configure: Regenerate.

ChangeLog:

	PR target/97865
	* libtool.m4: Update handling of Darwin platform link flags
	for Darwin20.

gcc/ChangeLog:

	PR target/97865
	* configure: Regenerate.

libatomic/ChangeLog:

	PR target/97865
	* configure: Regenerate.

libbacktrace/ChangeLog:

	PR target/97865
	* configure: Regenerate.

libffi/ChangeLog:

	PR target/97865
	* configure: Regenerate.

libgfortran/ChangeLog:

	PR target/97865
	* configure: Regenerate.

libgomp/ChangeLog:

	PR target/97865
	* configure: Regenerate.

libhsail-rt/ChangeLog:

	PR target/97865
	* configure: Regenerate.

libobjc/ChangeLog:

	PR target/97865
	* configure: Regenerate.

libphobos/ChangeLog:

	PR target/97865
	* configure: Regenerate.

libquadmath/ChangeLog:

	PR target/97865
	* configure: Regenerate.

libssp/ChangeLog:

	PR target/97865
	* configure: Regenerate.

libstdc++-v3/ChangeLog:

	PR target/97865
	* configure: Regenerate.

libvtv/ChangeLog:

	PR target/97865
	* configure: Regenerate.

zlib/ChangeLog:

	PR target/97865
	* configure: Regenerate.
2020-12-05 08:43:20 +00:00
GCC Administrator
a9625c50dd Daily bump. 2020-11-30 00:16:27 +00:00
John David Anglin
4e4ba6478a Fix hppa64-hpux11 build to remove source paths from embedded path.
This change adds the +nodefaultrpath ld option to remove all library
paths that were specified with the -L option from the embedded path.

2020-11-29  John David Anglin  <danglin@gcc.gnu.org>

ChangeLog:
	* libtool.m4 (archive_cmds): Add +nodefaultrpath ld option on
	hppa64-*-hpux11*.

libatomic/ChangeLog:
	* configure: Regenerate.

libbacktrace/ChangeLog:
	* configure: Regenerate.

libcc1/ChangeLog:
	* configure: Regenerate.

libffi/ChangeLog:
	* configure: Regenerate.

libgfortran/ChangeLog:
	* configure: Regenerate.

libgomp/ChangeLog:
	* configure: Regenerate.

libhsail-rt/ChangeLog:
	* configure: Regenerate.

libitm/ChangeLog:
	* configure: Regenerate.

libobjc/ChangeLog:
	* configure: Regenerate.

liboffloadmic/ChangeLog:
	* configure: Regenerate.
	* plugin/configure: Regenerate.

libquadmath/ChangeLog:
	* configure: Regenerate.

libsanitizer/ChangeLog:
	* configure: Regenerate.

libssp/ChangeLog:
	* configure: Regenerate.

libstdc++-v3/ChangeLog:
	* configure: Regenerate.

libvtv/ChangeLog:
	* configure: Regenerate.

lto-plugin/ChangeLog:
	* configure: Regenerate.

zlib/ChangeLog:
	* configure: Regenerate.
2020-11-29 20:11:38 +00:00
GCC Administrator
360258daf5 Daily bump. 2020-11-26 00:16:41 +00:00
Matthew Malcomson
b85fb3187e libsanitizer: Add recently added commit to LOCAL_PATCHES
libsanitizer/ChangeLog:

	* LOCAL_PATCHES: Add one commit.
2020-11-25 16:39:11 +00:00
Matthew Malcomson
8a769f816f libsanitizer: Only build libhwasan when targeting AArch64
Though the library has limited support for x86, we don't have any
support for generating code targeting x86 so there is no point building
for that target.

Ensure we build for AArch64 but not for AArch64 ilp32.

libsanitizer/ChangeLog:

	* Makefile.am: Condition Build hwasan directory.
	* Makefile.in: Regenerate.
	* configure: Regenerate.
	* configure.ac: Set HWASAN_SUPPORTED based on target
	architecture.
	* configure.tgt: Likewise.
2020-11-25 16:35:35 +00:00
Matthew Malcomson
edb07cb95a libsanitizer: Tie the hwasan library into our build system
This patch tries to tie libhwasan into the GCC build system in the same way
that the other sanitizer runtime libraries are handled.

libsanitizer/ChangeLog:

	* Makefile.am:  Build libhwasan.
	* Makefile.in:  Build libhwasan.
	* asan/Makefile.in:  Build libhwasan.
	* configure:  Build libhwasan.
	* configure.ac:  Build libhwasan.
	* hwasan/Makefile.am: New file.
	* hwasan/Makefile.in: New file.
	* hwasan/libtool-version: New file.
	* interception/Makefile.in: Build libhwasan.
	* libbacktrace/Makefile.in: Build libhwasan.
	* libsanitizer.spec.in: Build libhwasan.
	* lsan/Makefile.in: Build libhwasan.
	* sanitizer_common/Makefile.in: Build libhwasan.
	* tsan/Makefile.in: Build libhwasan.
	* ubsan/Makefile.in: Build libhwasan.
2020-11-25 16:35:33 +00:00
Matthew Malcomson
8eb12742e8 libsanitizer: Hwasan reporting check for dladdr failing
In `GetGlobalSizeFromDescriptor` we use `dladdr` to get info on the the
current address.  `dladdr` returns 0 if it failed.
During testing on Linux this returned 0 to indicate failure, and
populated the `info` structure with a NULL pointer which was
dereferenced later.

This patch checks for `dladdr` returning 0, and in that case returns 0
from `GetGlobalSizeFromDescriptor` to indicate failure of identifying
the address.

This occurs when `GetModuleNameAndOffsetForPC` succeeds for some address
not in a dynamically loaded library.  One example is when the found
"module" is '[stack]' having come from parsing /proc/self/maps.

Cherry-pick from 83ac18205ec69a00ac2be3b603bc3a61293fbe89.

Differential Revision: https://reviews.llvm.org/D91344
2020-11-25 16:35:31 +00:00
Martin Liska
1ee3d1ef10 libsanitizer: add hwasan.
Introduce the libhwasan library from LLVM sources.
2020-11-25 16:35:30 +00:00
GCC Administrator
7a97e2fcf7 Daily bump. 2020-11-22 00:16:24 +00:00
Iain Sandoe
93f1186f7d Darwin, libsanitizer : Support libsanitizer for x86_64-darwin20.
The sanitizer is supported for at least x86_64 and Darwin20.

libsanitizer/ChangeLog:

	* configure.tgt: Allow x86_64 Darwin2x.
2020-11-21 08:56:41 +00:00
GCC Administrator
77f67db2a4 Daily bump. 2020-11-14 00:16:38 +00:00
Martin Liska
a98ebdc50a libsanitizer: update LOCAL_PATCHES.
libsanitizer/ChangeLog:

	* LOCAL_PATCHES: Update to the latest commit.
2020-11-13 17:31:16 +01:00
Martin Liska
d72227e29a libsanitizer: Apply local patches. 2020-11-13 17:29:28 +01:00
Martin Liska
98f792ff53 libsanitizer: merge from master. 2020-11-13 17:28:49 +01:00
Martin Liska
b69f33f477 ASAN: Support detect_invalid_pointer_pairs=1 with detect_stack_use_after_return=1
Do not crash when AsanThread::GetStackVariableShadowStart does not find
a variable for a pointer on a shadow stack.

Cherry-pick from ad2be02a833e56f7fe280797280b219eb3312621.

Differential Revision: https://reviews.llvm.org/D89552
2020-10-21 09:27:08 +02:00
Vitaly Buka
00b355522b Fix compilation on older systems
Cherry-pick upstream commit f97ca48b1cbbf5da065e94271cb3af4f1c907dd4.

Fixes https://bugs.llvm.org/show_bug.cgi?id=47896
2020-10-20 11:15:10 +02:00
GCC Administrator
970d683f67 Daily bump. 2020-10-20 00:16:29 +00:00
Martin Liska
04ffed2ef2 libsanitizer: Add recently added commit to LOCAL_PATCHES.
libsanitizer/ChangeLog:

	* LOCAL_PATCHES: Add one commit.
2020-10-19 09:05:34 +02:00
GCC Administrator
3acb91a48e Daily bump. 2020-10-19 00:16:22 +00:00
Iain Sandoe
476036b35c libsanitizer, Darwin, Bootstrap : Fix bootstrap on Darwin <= 15.
The latest upstream merge for libsanitizer introduces code that makes
use of some macro values that are not available in SDKs for versions
of Darwin <= 15 (macOS 10.11).

Add definitions for these where they are not present.

libsanitizer/ChangeLog:

	* sanitizer_common/sanitizer_mac.h: Ensure that TARGET_OS_
	macros are defined where the macOS SDK does not contain
	them.
	(TARGET_OS_OSX, TARGET_OS_IOS, TARGET_OS_TV, TARGET_OS_WATCH):
	Define where needed.
2020-10-18 20:55:58 +01:00
GCC Administrator
56e4eee935 Daily bump. 2020-10-17 00:16:29 +00:00
Martin Liska
9791b4bb4b libsanitizer: update locale patches
libsanitizer/ChangeLog:

	* LOCAL_PATCHES: Update revision.
2020-10-16 10:58:03 +02:00
Martin Liska
b040b1ce1f Reapply all revisions mentioned in LOCAL_PATCHES.
(cherry picked from commit 21bb1625bd)
2020-10-16 10:57:16 +02:00
Martin Liska
0b997f6e07 libsanitizer: merge from master 2020-10-16 10:57:03 +02:00
GCC Administrator
44135373fc Daily bump. 2020-09-22 00:16:31 +00:00
Ian Lance Taylor
762c16eba6 libsanitizer: rename new libbacktrace symbols
* libbacktrace/backtrace-rename.h (backtrace_uncompress_lzma):
	Define.
	(backtrace_syminfo_to_full_callback): Define.
	(backtrace_syminfo_to_full_error_callback): Define.
2020-09-21 12:03:45 -07:00
GCC Administrator
96686b3fcd Daily bump. 2020-07-17 00:16:27 +00:00
Rainer Orth
6805c1c6a6 libsanitizer: Fix GetPcSpBp determination of SP on 32-bit Solaris/x86
The latest Solaris 11.4/x86 update uncovered a libsanitizer bug that
caused one test to FAIL for 32-bit:

+FAIL: c-c++-common/asan/null-deref-1.c   -O0  output pattern test
+FAIL: c-c++-common/asan/null-deref-1.c   -O1  output pattern test
+FAIL: c-c++-common/asan/null-deref-1.c   -O2  output pattern test
+FAIL: c-c++-common/asan/null-deref-1.c   -O2 -flto  output pattern test
+FAIL: c-c++-common/asan/null-deref-1.c -O2 -flto -flto-partition=none
output pattern test
+FAIL: c-c++-common/asan/null-deref-1.c   -O3 -g  output pattern test
+FAIL: c-c++-common/asan/null-deref-1.c   -Os  output pattern test

I've identified the problem and the fix has just landed in upstream
llvm-project:

	https://reviews.llvm.org/D83664

Tested on i386-pc-solaris2.11 and x86_64-pc-linux.gnu.

	libsanitizer:
	* sanitizer_common/sanitizer_linux.cpp: Cherry-pick llvm-project
	revision f0e9b76c3500496f8f3ea7abe6f4bf801e3b41e7.
2020-07-16 10:38:48 +02:00
GCC Administrator
b952c2cfcd Daily bump. 2020-06-10 00:16:47 +00:00
Martin Liska
942a384ef9
libsanitizer: use gnu++14
libsanitizer/ChangeLog:

	* asan/Makefile.am: Replace gnu++11 with gnu++14.
	* interception/Makefile.am: Likewise.
	* libbacktrace/Makefile.am: Likewise.
	* lsan/Makefile.am: Likewise.
	* sanitizer_common/Makefile.am: Likewise.
	* tsan/Makefile.am: Likewise.
	* ubsan/Makefile.am: Likewise.
	* asan/Makefile.in: Regenerate.
	* interception/Makefile.in: Likewise.
	* libbacktrace/Makefile.in: Likewise.
	* lsan/Makefile.in: Likewise.
	* sanitizer_common/Makefile.in: Likewise.
	* tsan/Makefile.in: Likewise.
	* ubsan/Makefile.in: Likewise.
2020-06-09 10:07:24 +02:00
GCC Administrator
a9312a7926 Daily bump. 2020-06-03 00:16:34 +00:00
Martin Liska
e8546a6593
Update link to LOCAL_PATCHES.
libsanitizer/ChangeLog:

	* LOCAL_PATCHES: Update hash of local patches.
2020-06-02 08:03:48 +02:00
Martin Liska
f18ab18032
Reapply all revisions mentioned in LOCAL_PATCHES.
(cherry picked from commit 21bb1625bd)
2020-06-02 08:02:15 +02:00
Martin Liska
3c6331c29f
Libsanitizer: merge from master.
Merged from revision b638b63b99d66786cb37336292604a2ae3490cfd.

The patch successfully bootstraps on x86_64-linux-gnu and
ppc64le-linux-gnu. I also tested ppc64-linux-gnu that exposed:
https://reviews.llvm.org/D80864 (which is fixed on master).

Abidiff looks happy and I made UBSAN and ASAN bootstrap on
x86_64-linux-gnu.

I'm planning to do merge from master twice a year, once now and
next time short before stage1 closes.

I am going to install the patches as merge from master is obvious
and I haven't made anything special.

libsanitizer/ChangeLog:

	* MERGE: Merge from master.
2020-06-02 08:02:07 +02:00
GCC Administrator
885ef72f27 Daily bump. 2020-05-30 00:16:27 +00:00
H.J. Lu
9051b54827 Avoid nested save_CFLAGS and save_LDFLAGS
Avoid nested save_CFLAGS and save_LDFLAGS by replacing save_CFLAGS and
save_LDFLAGS with cet_save_CFLAGS and cet_save_LDFLAGS in cet.m4.

config/

	PR bootstrap/95413
	* cet.m4: Replace save_CFLAGS and save_LDFLAGS with
	cet_save_CFLAGS and cet_save_LDFLAGS.

gcc/

	PR bootstrap/95413
	* configure: Regenerated.

libatomic/

	PR bootstrap/95413
	* configure: Regenerated.

libbacktrace/

	PR bootstrap/95413
	* configure: Regenerated.

libcc1/

	PR bootstrap/95413
	* configure: Regenerated.

libcpp/

	PR bootstrap/95413
	* configure: Regenerated.

libdecnumber/

	PR bootstrap/95413
	* configure: Regenerated.

libgcc/

	PR bootstrap/95413
	* configure: Regenerated.

libgfortran/

	PR bootstrap/95413
	* configure: Regenerated.

libgomp/

	PR bootstrap/95413
	* configure: Regenerated.

libiberty/

	PR bootstrap/95413
	* configure: Regenerated.

libitm/

	PR bootstrap/95413
	* configure: Regenerated.

libobjc/

	PR bootstrap/95413
	* configure: Regenerated.

libphobos/

	PR bootstrap/95413
	* configure: Regenerated.

libquadmath/

	PR bootstrap/95413
	* configure: Regenerated.

libsanitizer/

	PR bootstrap/95413
	* configure: Regenerated.

libssp/

	PR bootstrap/95413
	* configure: Regenerated.

libstdc++-v3/

	PR bootstrap/95413
	* configure: Regenerated.

libvtv/

	PR bootstrap/95413
	* configure: Regenerated.

lto-plugin/

	PR bootstrap/95413
	* configure: Regenerated.

zlib/

	PR bootstrap/95413
	* configure: Regenerated.
2020-05-29 12:56:40 -07:00
Martin Liska
6bee5ffd8a
Remove references to SVN in libsanitizer.
Simple documentation update based on usage of GIT by both
LLVM and GCC.

libsanitizer/ChangeLog:

	* HOWTO_MERGE: Do not mention not existing argument.
	* README.gcc: Update LLVM repository location.
2020-05-29 11:50:54 +02:00
GCC Administrator
c3a4169be9 Daily bump. 2020-05-27 07:45:56 +00:00
Martin Liska
b3d566f570
Update merge.sh to reflect usage of git.
After switching to GIT, we should use it in libsanitizer
merge script. I'll do merge from master as soon as
PR95311 gets fixed.

I'm going to install the patch.

libsanitizer/ChangeLog:

	* LOCAL_PATCHES: Use git hash instead of SVN id.
	* merge.sh: Use git instead of VCS.  Update paths
	relative to upstream git repository.
2020-05-26 08:48:14 +02:00
H.J. Lu
4c1a5d8b71 x86: Also check if -fcf-protection works
When defaulting CET run-time support to auto, check if -fcf-protection
works.  Even if the stage1 GCC doesn't support -fcf-protection, since
the final GCC does, CET run-time support will be enabled by default if
binutils support CET.

config/

	PR bootstrap/95147
	* cet.m4 (GCC_CET_FLAGS): Also check if -fcf-protection works
	when defaulting to auto.

libatomic/

	PR bootstrap/95147
	* configure: Regenerated.

libbacktrace/

	PR bootstrap/95147
	* configure: Regenerated.

libgcc/

	PR bootstrap/95147
	* configure: Regenerated.

libgfortran/

	PR bootstrap/95147
	* configure: Regenerated.

libgomp/

	PR bootstrap/95147
	* configure: Regenerated.

libitm/

	PR bootstrap/95147
	* configure: Regenerated.

libobjc/

	PR bootstrap/95147
	* configure: Regenerated.

libphobos/

	PR bootstrap/95147
	* configure: Regenerated.

libquadmath/

	PR bootstrap/95147
	* configure: Regenerated.

libsanitizer/

	PR bootstrap/95147
	* configure: Regenerated.

libssp/

	PR bootstrap/95147
	* configure: Regenerated.

libstdc++-v3/

	PR bootstrap/95147
	* configure: Regenerated.

libvtv/

	PR bootstrap/95147
	* configure: Regenerated.

zlib/

	PR bootstrap/95147
	* configure: Regenerated.
2020-05-15 09:07:17 -07:00
H.J. Lu
8d286dd118 x86: Default CET run-time support to auto
CET has been added since GCC 8.  This patch defaults CET run-time support
to auto.  It enables CET run-time support if asssembler supports CET
instructions and multi-byte NOPs are enabled via SSE2.

config/

	* cet.m4 (GCC_CET_FLAGS): Change default to auto.

gcc/

	* configure: Regenerated.

libatomic/

	* configure: Regenerated.

libbacktrace/

	* configure: Regenerated.

libcc1/

	* configure: Regenerated.

libcpp/

	* configure: Regenerated.

libdecnumber/

	* configure: Regenerated.

libgcc/

	* configure: Regenerated.

libgfortran/

	* configure: Regenerated.

libgomp/

	* configure: Regenerated.

libitm/

	* configure: Regenerated.

libobjc/

	* configure: Regenerated.

libquadmath/

	* configure: Regenerated.

libsanitizer/

	* configure: Regenerated.

libssp/

	* configure: Regenerated.

libstdc++-v3/

	* configure: Regenerated.

libvtv/

	* configure: Regenerated.

zlib/

	* configure: Regenerated.
2020-05-14 09:05:02 -07:00
Andreas Tobler
d730fd95ee gcc: Enable bits for sanitizer support on FreeBSD x86_64
This patch add the necessary bits to suport libasan on FreeBSD x86_64.

gcc
	* config/i386/i386.h: Define a new macro: SUBTARGET_SHADOW_OFFSET.
	* config/i386/i386.c (ix86_asan_shadow_offset): Use this macro.
	* config/i386/darwin.h: Override the SUBTARGET_SHADOW_OFFSET macro.
	* config/i386/freebsd.h: Likewise.
	* config/freebsd.h (LIBASAN_EARLY_SPEC): Define.
	LIBTSAN_EARLY_SPEC): Likewise. (LIBLSAN_EARLY_SPEC): Likewise.

libsanitizer:

	* configure.tgt: Add x86_64- and i?86-*-freebsd* targets.
2020-05-01 17:18:47 +02:00
Andreas Tobler
bf1dde9790 libsanitizer: Add missing file and regen Makefile.in
In the last import the sanitizer_platform_limits_freebsd.cpp got
forgotten. Fix this.

libsanitizer/sanitizer_common:

	* Makefile.am: Add sanitizer_platform_limits_freebsd.cpp.
	* Makefile.in: Regenerate.
2020-05-01 16:24:37 +02:00
Iain Sandoe
63cc547f6d Darwin, libsanitizer: Adjust minimum supported Darwin version (PR93731).
The current imported libsanitizer code produces kernel panics for
Darwin 11 (macOS 10.7) and is unsupported for earlier versions already.

It is not clear if the current sources are even intended to be supported
on Darwin 11, so this patch causes the default to be build without
sanitizers for Darwin <= 11.

2020-03-01  Iain Sandoe  <iain@sandoe.co.uk>

	PR sanitizer/93731
	* configure.tgt (x86_64-*-darwin*, i?86-*-darwin*): Enable by
	default only for Darwin versions greater than 12 (macOS 10.8).
2020-03-01 14:40:57 +00:00
Iain Sandoe
69a9b14b96 [Darwin, libsanitizer] Default to no sanitizer for Darwin <= 10
Darwin10 is no longer supported upstream and will not build without
additional patches.
2020-03-01 14:25:46 +00:00
Maciej W. Rozycki
e8e66971cd Add `--with-toolexeclibdir=' configuration option
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.
2020-01-24 11:24:25 +00:00
Jakub Jelinek
4abc46b51a re PR sanitizer/92154 (new glibc breaks arm bootstrap due to libsanitizer)
PR sanitizer/92154
	* sanitizer_common/sanitizer_platform_limits_posix.h: Cherry-pick
	llvm-project revision 947f9692440836dcb8d88b74b69dd379d85974ce.
	* sanitizer_common/sanitizer_platform_limits_posix.cpp: Likewise.

From-SVN: r278722
2019-11-26 10:08:31 +01:00
Martin Liska
f6fbdc385a Update comment in libsanitizer/*/libtool-version files.
2019-11-20  Martin Liska  <mliska@suse.cz>

	* libtool-version: Remove.
	* lsan/libtool-version: Upate comment to not mention libmudflap.
	* tsan/libtool-version: Likewise.
	* ubsan/libtool-version: Likewise.

From-SVN: r278500
2019-11-20 14:52:05 +00:00
Andreas Schwab
4a96e1c4dd Enable libsanitizer build on riscv64
* configure.tgt (riscv64-*-linux*): Enable build.

From-SVN: r278126
2019-11-13 09:45:15 +00:00
Martin Liska
db37dc33a6 Update LOCAL_PATCHES.
From-SVN: r277911
2019-11-07 09:34:42 +00:00
Martin Liska
21bb1625bd Reapply all revisions mentioned in LOCAL_PATCHES.
2019-11-07  Martin Liska  <mliska@suse.cz>

	* all source files: Reapply all revisions mentioned in LOCAL_PATCHES.

From-SVN: r277910
2019-11-07 09:34:14 +00:00
Martin Liska
cb7dc4da4c Libsanitizer: merge from trunk
2019-11-07  Martin Liska  <mliska@suse.cz>

	* merge.sh: Update to use llvm-project git repository.
	* all source files: Merge from upstream
	82588e05cc32bb30807e480abd4e689b0dee132a.

From-SVN: r277909
2019-11-07 09:33:54 +00:00
Martin Liska
4330d1c477 Update LOCAL_PATCHES.
From-SVN: r277839
2019-11-05 13:56:51 +00:00
Martin Liska
1c48938e38 Set print_summary for UBSAN.
2019-11-05  Martin Liska  <mliska@suse.cz>

	* ubsan/ubsan_flags.cpp (InitializeFlags): Trunk decided to print
	summary for all sanitizers, but we want to have UBSAN without it.

From-SVN: r277837
2019-11-05 13:55:44 +00:00
Martin Liska
acd700fdc7 Reapply all revisions mentioned in LOCAL_PATCHES.
2019-11-05  Martin Liska  <mliska@suse.cz>

	* asan/asan_globals.cpp (CheckODRViolationViaIndicator): Reapply from
	LOCAL_PATCHES.
	(CheckODRViolationViaPoisoning): Likewise.
	(RegisterGlobal): Likewise.
	* asan/asan_interceptors.h (ASAN_INTERCEPT___CXA_RETHROW_PRIMARY_EXCEPTION): Likewise.
	(defined): Likewise.
	* asan/asan_mapping.h: Likewise.
	* sanitizer_common/sanitizer_linux_libcdep.cpp (defined): Likewise.
	* sanitizer_common/sanitizer_mac.cpp (defined): Likewise.
	* sanitizer_common/sanitizer_platform_limits_linux.cpp (defined): Likewise.
	* sanitizer_common/sanitizer_platform_limits_posix.h: Likewise.
	* sanitizer_common/sanitizer_stacktrace.cpp (GetCanonicFrame): Likewise.
	* tsan/tsan_rtl_ppc64.S: Likewise.
	* ubsan/ubsan_handlers.cpp (__ubsan::__ubsan_handle_cfi_bad_icall): Likewise.
	(__ubsan::__ubsan_handle_cfi_bad_icall_abort): Likewise.
	* ubsan/ubsan_handlers.h (struct CFIBadIcallData): Likewise.
	(struct CFICheckFailData): Likewise.
	(RECOVERABLE): Likewise.
	* ubsan/ubsan_platform.h: Likewise.

From-SVN: r277836
2019-11-05 13:55:27 +00:00
Martin Liska
617be04ad7 Update Makefile.am.
2019-11-05  Martin Liska  <mliska@suse.cz>

	* tsan/Makefile.am: Rename tsan_interceptors.cpp to
	tsan_interceptors_posix.
	* tsan/Makefile.in: Regenerate.

From-SVN: r277835
2019-11-05 13:55:17 +00:00
Martin Liska
3ca75cd550 Libsanitizer: merge from trunk with merge.sh.
2019-11-05  Martin Liska  <mliska@suse.cz>

	* all source files: Merge from upstream r375507.

From-SVN: r277834
2019-11-05 13:54:57 +00:00
Tamar Christina
761a3a95ee Arm: Fix arm libsanitizer bootstrap failure
Glibc has recently introduced changed to the mode field in ipc_perm
in commit 2f959dfe849e0646e27403f2e4091536496ac0f0. For Arm this
means that the mode field no longer has the same size.

This causes an assert failure against libsanitizer's internal copy
of ipc_perm.  Since this change can't be easily detected I am adding
arm to the list of targets that are excluded from this check.  libsanitizer
doesn't use this field (and others, it in fact uses only 1 field) so this check
can be ignored.

Padding bits were used by glibc when the field was changed so sizeof and offsets
of the remaining fields should be the same.

libsanitizer/ChangeLog:

	PR sanitizer/92154
	* sanitizer_common/sanitizer_platform_limits_posix.cpp (defined):
	Cherry-pick compiler-rt revision r375220.

From-SVN: r277291
2019-10-22 14:25:38 +00:00
Maciej W. Rozycki
e9085da528 Regenerate configure' scripts for uclinuxfdpiceabi' libtool.m4 update
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-09-27 21:24:42 +00:00
Christophe Lyon
45d53c679a [ARM/FDPIC v6 03/24] [ARM] FDPIC: Force FDPIC related options unless -mno-fdpic is provided
In FDPIC mode, we set -fPIE unless the user provides -fno-PIE, -fpie,
-fPIC or -fpic: indeed FDPIC code is PIC, but we want to generate code
for executables rather than shared libraries by default.

We also make sure to use the --fdpic assembler option, and select the
appropriate linker emulation.

At link time, we also default to -pie, unless we are generating a
shared library or a relocatable file (-r). Note that static link is
not supported as it requires specifying the dynamic linker because the
executable still has to relocate itself at startup.

We also force 'now' binding since lazy binding is not supported.

We should also apply the same behavior for -Wl,-Ur as for -r, but I
couldn't find how to describe that in the specs fragment.

2019-09-10  Christophe Lyon  <christophe.lyon@st.com>
	Mickaël Guêné <mickael.guene@st.com>

	gcc/
	* config.gcc: Handle arm*-*-uclinuxfdpiceabi.
	* config/arm/bpabi.h (TARGET_FDPIC_ASM_SPEC): New.
	(SUBTARGET_EXTRA_ASM_SPEC): Use TARGET_FDPIC_ASM_SPEC.
	* config/arm/linux-eabi.h (FDPIC_CC1_SPEC): New.
	(CC1_SPEC): Use FDPIC_CC1_SPEC.
	(MUSL_DYNAMIC_LINKER): Add -fdpic suffix when needed.
	* config/arm/uclinuxfdpiceabi.h: New file.

	libsanitizer/
	* configure.tgt (arm*-*-*fdpiceabi): Sanitizers are
	unsupported in this configuration.



Co-Authored-By: Mickaël Guêné <mickael.guene@st.com>

From-SVN: r275565
2019-09-10 09:39:47 +02:00
Iain Sandoe
639f51ba26 libsanitizer, record a local patch.
2019-08-16  Iain Sandoe  <iain@sandoe.co.uk>

	* LOCAL_PATCHES: Add r274585.

From-SVN: r274586
2019-08-16 19:49:07 +00:00
Iain Sandoe
dea853e840 libsanitize, asan - reapply r272406
The entry in LOCAL_PATCHES was accidentally omitted.

2019-08-16  Iain Sandoe  <iain@sandoe.co.uk>

	* asan/asan_interceptors.h: Reapply r272406.

From-SVN: r274585
2019-08-16 19:46:09 +00:00
Martin Liska
b3595983e3 Add r274540 to LOCAL_PATCHES.
2019-08-15  Martin Liska  <mliska@suse.cz>

	* LOCAL_PATCHES: Add r274540

From-SVN: r274541
2019-08-15 15:32:46 +00:00
Martin Liska
71e895b119 Reapply missing patch for libsanitizer.
2019-08-15  Martin Liska  <mliska@suse.cz>

	* tsan/tsan_rtl_ppc64.S: Reapply.

From-SVN: r274540
2019-08-15 15:31:46 +00:00
Iain Sandoe
8bc1fac71d [libsanitizer] Fix PR bootstrap/91455
If a target does not support libbacktrace, it might still the include
for $(top_srcdir).

Regenerate the built files using automake-1.15.1

libsanitizer/

2019-08-15  Iain Sandoe  <iain@sandoe.co.uk>

	PR bootstrap/91455
	* Makefile.in: Regenerated.
	* aclocal.m4: Likewise.
	* asan/Makefile.in: Likewise.
	* configure: Likewise.
	* interception/Makefile.in: Likewise.
	* libbacktrace/Makefile.in: Likewise.
	* lsan/Makefile.in: Likewise.
	* sanitizer_common/Makefile.am: Include top_srcdir unconditionally.
	* sanitizer_common/Makefile.in: Regenerated.
	* tsan/Makefile.in: Likewise.
	* ubsan/Makefile.in: Likewise.

From-SVN: r274538
2019-08-15 14:13:10 +00:00
Martin Liska
e272312308 Refresh LOCAL_PATCHES
2019-08-14  Martin Liska  <mliska@suse.cz>

	* LOCAL_PATCHES: Refresh based on what was committed.

From-SVN: r274430
2019-08-14 08:50:24 +00:00
Martin Liska
47f0255fbb Reapply all revisions mentioned in LOCAL_PATCHES.
2019-08-14  Martin Liska  <mliska@suse.cz>

	* asan/asan_globals.cpp (CheckODRViolationViaIndicator): Reapply
	patch from trunk.
	(CheckODRViolationViaPoisoning): Likewise.
	(RegisterGlobal): Likewise.
	* asan/asan_mapping.h: Likewise.
	* sanitizer_common/sanitizer_linux_libcdep.cpp (defined): Likewise.
	* sanitizer_common/sanitizer_mac.cpp (defined): Likewise.
	* sanitizer_common/sanitizer_platform_limits_linux.cpp (defined): Likewise.
	* sanitizer_common/sanitizer_platform_limits_posix.h (defined): Likewise.
	* sanitizer_common/sanitizer_stacktrace.cpp (GetCanonicFrame): Likewise.
	* ubsan/ubsan_handlers.cpp (__ubsan::__ubsan_handle_cfi_bad_icall): Likewise.
	(__ubsan::__ubsan_handle_cfi_bad_icall_abort): Likewise.
	* ubsan/ubsan_handlers.h (struct CFIBadIcallData): Likewise.
	(struct CFICheckFailData): Likewise.
	(RECOVERABLE): Likewise.
	* ubsan/ubsan_platform.h: Likewise.

From-SVN: r274427
2019-08-14 08:47:36 +00:00
Martin Liska
b667dd7017 Libsanitizer merge from trunk r368656.
2019-08-14  Martin Liska  <mliska@suse.cz>

	PR sanitizer/89832
	PR sanitizer/91325
	* All source files: Merge from upstream 368656.

From-SVN: r274426
2019-08-14 08:47:11 +00:00
Rainer Orth
7cfb726052 Fix sanitizer_common/sanitizer_posix_libcdep.cc compilation on Solaris 11.5
* sanitizer_common/sanitizer_posix_libcdep.cc: Cherry-pick
	compiler-rt revision 363778.

From-SVN: r272685
2019-06-26 10:43:08 +00:00
Iain Sandoe
9553f0d221 libsanitizer - remove reference to __cxa_rethrow_primary_exception.
For some Darwin versions the absence of the rethrow_primary_exception
symbol causes almost all sanitizer tests to fail.
The symbol is not present in libstdc++ and, therefore is is correct to
remove the reference to it for all platforms.  We do this by adding a
new guard "ASAN_HAS_CXA_RETHROW_PRIMARY_EXCEPTION".

libsanitizer/

2019-06-18  Iain Sandoe  <iain@sandoe.co.uk>

	PR libsanitizer/87880
	* asan/asan_interceptors.h:
	(ASAN_INTERCEPT___CXA_RETHROW_PRIMARY_EXCEPTION): New.
	* asan/Makefile.am (DEFS): Add 
	ASAN_HAS_CXA_RETHROW_PRIMARY_EXCEPTION, defined to 0.
	* asan/Makefile.in: Regenerated.
	* asan/libtool-version: Bump version.

From-SVN: r272406
2019-06-18 08:01:00 +00:00
Segher Boessenkool
7f63a85400 rs6000: Fix sanitizer build (PR90639)
The assembler code needs to say it uses AltiVec instructions.


libsanitizer/
	PR target/90639
	* tsan/tsan_rtl_ppc64.S: Add ".machine altivec".

From-SVN: r271668
2019-05-27 21:12:19 +02:00
Rainer Orth
ccd1242eec Remove obsolete Solaris 10 support
libstdc++-v3:
	* config/os/solaris/solaris2.10: Move to ...
	* config/os/solaris: ... this.
	* configure.host (os_include_dir): Adapt.
	(abi_baseline_pair): Remove Solaris 10 handling.
	* config/abi/post/i386-solaris2.10: Remove.
	* config/abi/post/sparc-solaris2.10: Remove.
	* config/abi/post/i386-solaris2.11: Rename to ...
	* config/abi/post/i386-solaris: ... this.
	* config/abi/post/sparc-solaris2.11: Rename to ...
	* config/abi/post/sparc-solaris: ... this.

	* libsupc++/new_opa.cc [_GLIBCXX_HAVE_MEMALIGN] [__sun]: Remove
	workaround.

	* testsuite/ext/enc_filebuf/char/13598.cc: Remove *-*-solaris2.10
	xfail.

	libsanitizer:
	* configure.ac (have_dl_iterate_phdr): Remove *-*-solaris2.10*
	handling.
	* configure: Regenerate.

	libgcc:
	* config.host: Simplify various *-*-solaris2.1[0-9]* to
	*-*-solaris2*.
	* configure.ac: Likewise.
	* configure: Regenerate.

	* config/i386/sol2-unwind.h (x86_fallback_frame_state): Remove
	Solaris 10 and Solaris 11 < snv_125 handling.

	libbacktrace:
	* configure.ac (have_dl_iterate_phdr): Remove *-*-solaris2.10*
	handling.
	* configure: Regenerate.

	gcc/testsuite:
	* gcc.dg/atomic/c11-atomic-exec-4.c: Simplify triplet to
	*-*-solaris2*.
	* gcc.dg/atomic/c11-atomic-exec-5.c: Likewise.
	* gcc.dg/c99-math-double-1.c: Likewise.
	* gcc.dg/c99-math-float-1.c: Likewise.
	* gcc.dg/c99-math-long-double-1.c: Likewise.
	* gcc.misc-tests/linkage.exp: Simplify triplet to
	x86_64-*-solaris2*.

	* gcc.target/i386/mcount_pic.c: Remove *-*-solaris2.10* && !gld
	xfail.
	* gcc.target/i386/pr63620.c: Likewise.

	* lib/target-supports.exp (check_sse_os_support_available): Remove
	Solaris 9/x86 workaround.

	gcc:
	* config.gcc: Move *-*-solaris2.10* from obsolete configurations
	to unsupported ones.
	Simplify x86_64-*-solaris2.1[0-9]* to x86_64-*-solaris2*.
	* config.host: Likewise.
	* config/i386/sol2.h (ASM_COMMENT_START): Remove.
	* config/sparc/driver-sparc.c (host_detect_local_cpu) [__sun__ &&
	__svr4__]: Remove "brand" fallback.
	[!KSTAT_DATA_STRING]: Remove.
	* configure.ac (gcc_cv_ld_hidden): Simplify *-*-solaris2.1[0-9]*
	to *-*-solaris2*.
	(comdat_group): Likewise.
	(set_have_as_tls): Likewise.
	(gcc_cv_target_dl_iterate_phdr): Likewise.
	(gcc_cv_as_shf_merge): Remove Solaris 10/x86 workaround.
	(gcc_cv_ld_aligned_shf_merge): Remove Solaris 10/SPARC workaround.
	* configure: Regenerate.
	* doc/install.texi: Simplify Solaris target triplets.
	(Specific, i?86-*-solaris2*): Remove Solaris 10 references.
	(Specific, *-*-solaris2*): Document Solaris 10 removal.
	Remove Solaris 10 references.
	Remove obsolete Solaris bug reference.
	(Specific, sparc-sun-solaris2.10): Remove.

From-SVN: r271183
2019-05-14 17:17:23 +00:00