From owner-svn-src-all@freebsd.org Wed Jun 27 19:14:47 2018 Return-Path: Delivered-To: svn-src-all@mailman.ysv.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2610:1c1:1:606c::19:1]) by mailman.ysv.freebsd.org (Postfix) with ESMTP id 581CB1003004; Wed, 27 Jun 2018 19:14:47 +0000 (UTC) (envelope-from dim@FreeBSD.org) Received: from mxrelay.nyi.freebsd.org (mxrelay.nyi.freebsd.org [IPv6:2610:1c1:1:606c::19:3]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (Client CN "mxrelay.nyi.freebsd.org", Issuer "Let's Encrypt Authority X3" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 929958DCB1; Wed, 27 Jun 2018 19:14:45 +0000 (UTC) (envelope-from dim@FreeBSD.org) Received: from repo.freebsd.org (repo.freebsd.org [IPv6:2610:1c1:1:6068::e6a:0]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (Client did not present a certificate) by mxrelay.nyi.freebsd.org (Postfix) with ESMTPS id 2FD0C272FD; Wed, 27 Jun 2018 19:14:45 +0000 (UTC) (envelope-from dim@FreeBSD.org) Received: from repo.freebsd.org ([127.0.1.37]) by repo.freebsd.org (8.15.2/8.15.2) with ESMTP id w5RJEjaR043044; Wed, 27 Jun 2018 19:14:45 GMT (envelope-from dim@FreeBSD.org) Received: (from dim@localhost) by repo.freebsd.org (8.15.2/8.15.2/Submit) id w5RJEjXR043043; Wed, 27 Jun 2018 19:14:45 GMT (envelope-from dim@FreeBSD.org) Message-Id: <201806271914.w5RJEjXR043043@repo.freebsd.org> X-Authentication-Warning: repo.freebsd.org: dim set sender to dim@FreeBSD.org using -f From: Dimitry Andric Date: Wed, 27 Jun 2018 19:14:45 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-vendor@freebsd.org Subject: svn commit: r335724 - vendor/compiler-rt/dist-release_60/lib/sanitizer_common X-SVN-Group: vendor X-SVN-Commit-Author: dim X-SVN-Commit-Paths: vendor/compiler-rt/dist-release_60/lib/sanitizer_common X-SVN-Commit-Revision: 335724 X-SVN-Commit-Repository: base MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit X-BeenThere: svn-src-all@freebsd.org X-Mailman-Version: 2.1.26 Precedence: list List-Id: "SVN commit messages for the entire src tree \(except for " user" and " projects" \)" List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Wed, 27 Jun 2018 19:14:47 -0000 Author: dim Date: Wed Jun 27 19:14:44 2018 New Revision: 335724 URL: https://svnweb.freebsd.org/changeset/base/335724 Log: Vendor import of compiler-rt 6.0.1 release r335540: https://llvm.org/svn/llvm-project/compiler-rt/tags/RELEASE_601/final@335540 Modified: vendor/compiler-rt/dist-release_60/lib/sanitizer_common/sanitizer_platform_limits_posix.cc Modified: vendor/compiler-rt/dist-release_60/lib/sanitizer_common/sanitizer_platform_limits_posix.cc ============================================================================== --- vendor/compiler-rt/dist-release_60/lib/sanitizer_common/sanitizer_platform_limits_posix.cc Wed Jun 27 19:14:40 2018 (r335723) +++ vendor/compiler-rt/dist-release_60/lib/sanitizer_common/sanitizer_platform_limits_posix.cc Wed Jun 27 19:14:44 2018 (r335724) @@ -159,7 +159,6 @@ typedef struct user_fpregs elf_fpregset_t; # include #endif #include -#include #include #include #include @@ -253,7 +252,19 @@ namespace __sanitizer { #endif // SANITIZER_LINUX || SANITIZER_FREEBSD #if SANITIZER_LINUX && !SANITIZER_ANDROID - unsigned struct_ustat_sz = sizeof(struct ustat); + // Use pre-computed size of struct ustat to avoid which + // has been removed from glibc 2.28. +#if defined(__aarch64__) || defined(__s390x__) || defined (__mips64) \ + || defined(__powerpc64__) || defined(__arch64__) || defined(__sparcv9) \ + || defined(__x86_64__) +#define SIZEOF_STRUCT_USTAT 32 +#elif defined(__arm__) || defined(__i386__) || defined(__mips__) \ + || defined(__powerpc__) || defined(__s390__) +#define SIZEOF_STRUCT_USTAT 20 +#else +#error Unknown size of struct ustat +#endif + unsigned struct_ustat_sz = SIZEOF_STRUCT_USTAT; unsigned struct_rlimit64_sz = sizeof(struct rlimit64); unsigned struct_statvfs64_sz = sizeof(struct statvfs64); #endif // SANITIZER_LINUX && !SANITIZER_ANDROID