Date: Tue, 23 May 2000 14:49:53 +0300 (IDT) From: Eli Zaretskii X-Sender: eliz AT is To: Dieter Buerssner cc: djgpp-workers AT delorie DOT com Subject: Re: Bug 314 In-Reply-To: <200005231106.HAA32744@delorie.com> Message-ID: MIME-Version: 1.0 Content-Type: TEXT/PLAIN; charset=US-ASCII Reply-To: djgpp-workers AT delorie DOT com Errors-To: nobody AT delorie DOT com X-Mailing-List: djgpp-workers AT delorie DOT com X-Unsubscribes-To: listserv AT delorie DOT com Precedence: bulk On Tue, 23 May 2000, Dieter Buerssner wrote: > On 23 May 00, at 12:06, Eli Zaretskii wrote: > > > The code seems consistent with C9X draft, as far as I could see, but > > isn't it better to replace it with inline asm that does this in a > > single instruction? > > Gcc will usually produce only one idiv instruction for n/d; n%d pairs > for integer types smaller long long. Sorry for not being clear. First, I meant the long long version as well. And second, I was thinking about putting a fast inline version into stdlib.h as a macro, and making the function versions use that macro as their body. We do that for getc and putc, for example.