From mboxrd@z Thu Jan 1 00:00:00 1970 X-Msuck: nntp://news.gmane.org/gmane.linux.lib.musl.general/10812 Path: news.gmane.org!.POSTED!not-for-mail From: u-uy74@aetey.se Newsgroups: gmane.linux.lib.musl.general Subject: Re: [PATCH v2] use lookup table for malloc bin index instead of float conversion Date: Sat, 17 Dec 2016 15:30:37 +0100 Message-ID: <20161217143036.GA18078@example.net> References: <20161127141541.GZ5749@port70.net> <20161217055058.GG1555@brightrain.aerifal.cx> <20161217073600.GZ18078@example.net> <20161217140323.GM16379@port70.net> Reply-To: musl@lists.openwall.com NNTP-Posting-Host: blaine.gmane.org Mime-Version: 1.0 Content-Type: text/plain; charset=us-ascii X-Trace: blaine.gmane.org 1481985070 28337 195.159.176.226 (17 Dec 2016 14:31:10 GMT) X-Complaints-To: usenet@blaine.gmane.org NNTP-Posting-Date: Sat, 17 Dec 2016 14:31:10 +0000 (UTC) To: musl@lists.openwall.com Original-X-From: musl-return-10825-gllmg-musl=m.gmane.org@lists.openwall.com Sat Dec 17 15:31:07 2016 Return-path: Envelope-to: gllmg-musl@m.gmane.org Original-Received: from mother.openwall.net ([195.42.179.200]) by blaine.gmane.org with smtp (Exim 4.84_2) (envelope-from ) id 1cIG0v-0006WS-PP for gllmg-musl@m.gmane.org; Sat, 17 Dec 2016 15:31:05 +0100 Original-Received: (qmail 7531 invoked by uid 550); 17 Dec 2016 14:31:08 -0000 Mailing-List: contact musl-help@lists.openwall.com; run by ezmlm Precedence: bulk List-Post: List-Help: List-Unsubscribe: List-Subscribe: List-ID: Original-Received: (qmail 7512 invoked from network); 17 Dec 2016 14:31:08 -0000 DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=fripost.org; h= in-reply-to:content-disposition:content-type:content-type :mime-version:references:message-id:subject:subject:from:from :date:date; s=20140703; t=1481985056; x=1483799457; bh=ggvmdoXqG jn0qXYetGJ7zcWXbLnGib70RAfslGWABvY=; b=p2zV5KGDfrRorNnU3EBKfz361 colKSx6ddlmlcyiRK+pSFoRfUcRclJ2xUdBJa1EO9CbezaohmTMsVI+diG+5RkJe HfqsMEyAQtsaURal3/dC0fgm95PcngGroBq5Z35qSRwiq+n98M/XWkR0vY05U1AA CKzjT3rYM2UQUlsYio= X-Virus-Scanned: Debian amavisd-new at fripost.org Content-Disposition: inline In-Reply-To: <20161217140323.GM16379@port70.net> Xref: news.gmane.org gmane.linux.lib.musl.general:10812 Archived-At: On Sat, Dec 17, 2016 at 03:03:24PM +0100, Szabolcs Nagy wrote: > > > ... wouldn't it be better to drop the 4 unused > > > entries from the table and add -4's to the indices? > > > Wouldn't this enlarge the code more than reduce the data? > > most targets have a load instruction with small offset > and on some targets the compiler emits relocation against > (tab-4) instead of tab so the code size is not affected. Oh indeed, I overlooked this link-time evaluation. Thanks. Rune