From owner-svn-src-head@FreeBSD.ORG Sat Jun 8 13:22:53 2013 Return-Path: Delivered-To: svn-src-head@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:1900:2254:206a::19:1]) by hub.freebsd.org (Postfix) with ESMTP id EA150A51; Sat, 8 Jun 2013 13:22:53 +0000 (UTC) (envelope-from ed@FreeBSD.org) Received: from svn.freebsd.org (svn.freebsd.org [IPv6:2001:1900:2254:2068::e6a:0]) by mx1.freebsd.org (Postfix) with ESMTP id DB9F915BC; Sat, 8 Jun 2013 13:22:53 +0000 (UTC) Received: from svn.freebsd.org ([127.0.1.70]) by svn.freebsd.org (8.14.7/8.14.7) with ESMTP id r58DMr52063484; Sat, 8 Jun 2013 13:22:53 GMT (envelope-from ed@svn.freebsd.org) Received: (from ed@localhost) by svn.freebsd.org (8.14.7/8.14.5/Submit) id r58DMrCr063482; Sat, 8 Jun 2013 13:22:53 GMT (envelope-from ed@svn.freebsd.org) Message-Id: <201306081322.r58DMrCr063482@svn.freebsd.org> From: Ed Schouten Date: Sat, 8 Jun 2013 13:22:53 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-head@freebsd.org Subject: svn commit: r251525 - head/lib/libcompiler_rt X-SVN-Group: head MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit X-BeenThere: svn-src-head@freebsd.org X-Mailman-Version: 2.1.14 Precedence: list List-Id: SVN commit messages for the src tree for head/-current List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Sat, 08 Jun 2013 13:22:54 -0000 Author: ed Date: Sat Jun 8 13:22:53 2013 New Revision: 251525 URL: http://svnweb.freebsd.org/changeset/base/251525 Log: Use improved __sync_*() intrinsics for MIPS in userspace as well. r251524 introduced custom tailored versions for MIPS of these functions for kernel-space code. We can just reuse them in userspace as well. Deleted: head/lib/libcompiler_rt/__sync_fetch_and_add_8.c head/lib/libcompiler_rt/__sync_fetch_and_and_8.c head/lib/libcompiler_rt/__sync_fetch_and_or_8.c head/lib/libcompiler_rt/__sync_fetch_and_sub_8.c head/lib/libcompiler_rt/__sync_fetch_and_xor_8.c head/lib/libcompiler_rt/__sync_lock_test_and_set_8.c head/lib/libcompiler_rt/__sync_val_compare_and_swap_8.c Modified: head/lib/libcompiler_rt/Makefile Modified: head/lib/libcompiler_rt/Makefile ============================================================================== --- head/lib/libcompiler_rt/Makefile Sat Jun 8 13:19:11 2013 (r251524) +++ head/lib/libcompiler_rt/Makefile Sat Jun 8 13:22:53 2013 (r251525) @@ -157,7 +157,7 @@ SRCF+= divsi3 \ .endif # FreeBSD-specific atomic intrinsics. -.if ${MACHINE_CPUARCH} == "arm" || ${MACHINE_CPUARCH} == "mips" +.if ${MACHINE_CPUARCH} == "arm" SRCF+= __sync_fetch_and_add_4 \ __sync_fetch_and_and_4 \ __sync_fetch_and_or_4 \ @@ -166,15 +166,10 @@ SRCF+= __sync_fetch_and_add_4 \ __sync_lock_test_and_set_4 \ __sync_synchronize \ __sync_val_compare_and_swap_4 -.endif -.if ${MACHINE_ARCH:Mmips64*} != "" -SRCF+= __sync_fetch_and_add_8 \ - __sync_fetch_and_and_8 \ - __sync_fetch_and_or_8 \ - __sync_fetch_and_sub_8 \ - __sync_fetch_and_xor_8 \ - __sync_lock_test_and_set_8 \ - __sync_val_compare_and_swap_8 +.elif ${MACHINE_CPUARCH} == "mips" +.PATH: ${.CURDIR}/../../sys/mips/mips + +SRCF+= stdatomic .endif .for file in ${SRCF}