From owner-freebsd-mips@FreeBSD.ORG Tue Apr 24 06:45:12 2012 Return-Path: Delivered-To: freebsd-mips@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:4f8:fff6::34]) by hub.freebsd.org (Postfix) with ESMTP id 84A891065672; Tue, 24 Apr 2012 06:45:12 +0000 (UTC) (envelope-from jasone@freebsd.org) Received: from canonware.com (10140.x.rootbsd.net [204.109.63.53]) by mx1.freebsd.org (Postfix) with ESMTP id 5C3618FC0A; Tue, 24 Apr 2012 06:45:12 +0000 (UTC) Received: from [172.25.16.174] (unknown [173.252.71.3]) (using TLSv1 with cipher AES128-SHA (128/128 bits)) (No client certificate requested) by canonware.com (Postfix) with ESMTPSA id A8E1128419; Mon, 23 Apr 2012 23:45:06 -0700 (PDT) Mime-Version: 1.0 (Apple Message framework v1257) Content-Type: text/plain; charset=iso-8859-1 From: Jason Evans In-Reply-To: Date: Mon, 23 Apr 2012 23:45:05 -0700 Content-Transfer-Encoding: quoted-printable Message-Id: References: <201204170722.q3H7ME6A070934@svn.freebsd.org> To: "Jayachandran C." X-Mailer: Apple Mail (2.1257) Cc: freebsd-mips@freebsd.org Subject: Re: svn commit: r234370 - in head: contrib/jemalloc contrib/jemalloc/doc contrib/jemalloc/include contrib/jemalloc/include/jemalloc contrib/jemalloc/include/jemalloc/internal contrib/jemalloc/src inclu... X-BeenThere: freebsd-mips@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: Porting FreeBSD to MIPS List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Tue, 24 Apr 2012 06:45:12 -0000 On Apr 23, 2012, at 11:35 PM, Jayachandran C. wrote: > On Tue, Apr 17, 2012 at 12:52 PM, Jason Evans = wrote: >> Author: jasone >> Date: Tue Apr 17 07:22:14 2012 >> New Revision: 234370 >> URL: http://svn.freebsd.org/changeset/base/234370 >=20 > [....] >> +diff --git a/include/jemalloc/jemalloc_FreeBSD.h = b/include/jemalloc/jemalloc_FreeBSD.h >> +new file mode 100644 >> +index 0000000..2c5797f >> +--- /dev/null >> ++++ b/include/jemalloc/jemalloc_FreeBSD.h >> +@@ -0,0 +1,76 @@ > [....] >> ++#ifdef __mips__ >> ++# define LG_SIZEOF_PTR 2 >> ++#endif >=20 > This breaks 64-bit mips platforms. I have a simple patch that fixes > this at http://people.freebsd.org/~jchandra/jemalloc.patch >=20 > Another possible fix suggested by Juli is to do > #define LG_SIZEOF_PTR _MIPS_SZPTR >=20 > Can you please check-in one of these? If you are busy, I can do the > check-in if you approve the changes. I had planned to do this, based on Juli's suggestion: > #ifdef __mips__ > # if (_MIPS_SZPTR =3D=3D 64) > # define LG_SIZEOF_PTR 3 > # else > # define LG_SIZEOF_PTR 2 > # endif > #endif Feel free to check in whichever approach you feel is cleaner. I can't = test it, so you might as well do the honors. =3D) Thanks, Jason=