From owner-svn-src-all@freebsd.org Mon Sep 9 17:37:53 2019 Return-Path: Delivered-To: svn-src-all@mailman.nyi.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2610:1c1:1:606c::19:1]) by mailman.nyi.freebsd.org (Postfix) with ESMTP id 5570DD97B0; Mon, 9 Sep 2019 17:37:53 +0000 (UTC) (envelope-from kevans@FreeBSD.org) Received: from mxrelay.nyi.freebsd.org (mxrelay.nyi.freebsd.org [IPv6:2610:1c1:1:606c::19:3]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) server-signature RSA-PSS (4096 bits) client-signature RSA-PSS (4096 bits) client-digest SHA256) (Client CN "mxrelay.nyi.freebsd.org", Issuer "Let's Encrypt Authority X3" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 46RwNd1Vl3z4HkK; Mon, 9 Sep 2019 17:37:53 +0000 (UTC) (envelope-from kevans@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 17E31191EE; Mon, 9 Sep 2019 17:37:53 +0000 (UTC) (envelope-from kevans@FreeBSD.org) Received: from repo.freebsd.org ([127.0.1.37]) by repo.freebsd.org (8.15.2/8.15.2) with ESMTP id x89Hbq6s083788; Mon, 9 Sep 2019 17:37:52 GMT (envelope-from kevans@FreeBSD.org) Received: (from kevans@localhost) by repo.freebsd.org (8.15.2/8.15.2/Submit) id x89Hbqq5083786; Mon, 9 Sep 2019 17:37:52 GMT (envelope-from kevans@FreeBSD.org) Message-Id: <201909091737.x89Hbqq5083786@repo.freebsd.org> X-Authentication-Warning: repo.freebsd.org: kevans set sender to kevans@FreeBSD.org using -f From: Kyle Evans Date: Mon, 9 Sep 2019 17:37:52 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-stable@freebsd.org, svn-src-stable-11@freebsd.org Subject: svn commit: r352083 - in stable: 11/lib/libc/mips 11/sys/mips/include 12/lib/libc/mips 12/sys/mips/include X-SVN-Group: stable-11 X-SVN-Commit-Author: kevans X-SVN-Commit-Paths: in stable: 11/lib/libc/mips 11/sys/mips/include 12/lib/libc/mips 12/sys/mips/include X-SVN-Commit-Revision: 352083 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.29 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: Mon, 09 Sep 2019 17:37:53 -0000 Author: kevans Date: Mon Sep 9 17:37:52 2019 New Revision: 352083 URL: https://svnweb.freebsd.org/changeset/base/352083 Log: MFC r351681: mips: fix some mcount nits The symbol version for _mcount was removed 12 years ago in r169525 from gmon/Symbol.map, to be added to the per-arch Symbol.map. mips was overlooked in this, so _mcount has no symver. Add it back to where it should have been, rather than where it would go if it were added today, since we're correcting a historical mistake. Additionally, _mcount is getting thrown into .mdebug.abi32 in the llvm80/90 world as it's not getting explicitly thrown into .text, so do this now. This fixes the libc build that was previously failing due to relocations in .mdebug.abi32. This is specifically due to the way clang's integrated AS works and that they emit the .mdebug.abiNN section early in the process. An LLVM bug has been submitted (and since committed) and an agreement has been made that the mips backend should switch to .text following .mdebug.abiNN for compatibility. Modified: stable/11/lib/libc/mips/Symbol.map stable/11/sys/mips/include/profile.h Directory Properties: stable/11/ (props changed) Changes in other areas also in this revision: Modified: stable/12/lib/libc/mips/Symbol.map stable/12/sys/mips/include/profile.h Directory Properties: stable/12/ (props changed) Modified: stable/11/lib/libc/mips/Symbol.map ============================================================================== --- stable/11/lib/libc/mips/Symbol.map Mon Sep 9 17:36:29 2019 (r352082) +++ stable/11/lib/libc/mips/Symbol.map Mon Sep 9 17:37:52 2019 (r352083) @@ -11,6 +11,7 @@ FBSD_1.0 { /* PSEUDO syscalls */ _exit; + _mcount; _setjmp; _longjmp; alloca; Modified: stable/11/sys/mips/include/profile.h ============================================================================== --- stable/11/sys/mips/include/profile.h Mon Sep 9 17:36:29 2019 (r352082) +++ stable/11/sys/mips/include/profile.h Mon Sep 9 17:37:52 2019 (r352083) @@ -44,7 +44,8 @@ /*XXX This is not MIPS64 safe. */ #define MCOUNT \ - __asm(".globl _mcount;" \ + __asm(".text;" \ + ".globl _mcount;" \ ".type _mcount,@function;" \ "_mcount:;" \ ".set noreorder;" \