X-Recipient: archive-cygwin AT delorie DOT com X-Spam-Check-By: sourceware.org To: cygwin AT cygwin DOT com From: Victor Paesa Subject: Re: llrint implementation in Cygwin Date: Mon, 29 Oct 2007 14:14:37 +0000 (UTC) Lines: 36 Message-ID: References: <46F6C151 DOT 3070301 AT computer DOT org> <4725D1BA DOT C2D2ED8A AT dessent DOT net> <033e01c81a2a$30ae3150$2e08a8c0 AT CAM DOT ARTIMI DOT COM> <4725D805 DOT 2C412C94 AT dessent DOT net> Mime-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Transfer-Encoding: 7bit User-Agent: Loom/3.14 (http://gmane.org/) X-IsSubscribed: yes Mailing-List: contact cygwin-help AT cygwin DOT com; run by ezmlm List-Id: List-Subscribe: List-Archive: List-Post: List-Help: , Sender: cygwin-owner AT cygwin DOT com Mail-Followup-To: cygwin AT cygwin DOT com Delivered-To: mailing list cygwin AT cygwin DOT com Hi, Brian Dessent writes: > > Dave Korn wrote: > > > I don't think it was being advocated in general, but I think it's reasonable > > to assume that a pure const function like llrint isn't going to do anything > > wacky. > > Yes, I realize it was probably not a worry in this particular case, but > I didn't want somebody stumbling on the archives at a later date and > getting the bright idea that you could just go around extracting random > objects from a MinGW library for use in a Cygwin link. I completely agree, most of the time it is a very bad idea to mix MinGW objects with Cygwin's ones, that is why I extracted the llrint.o instead of linking to libmingwex.a And indeed llrint.o works only because it is self-contained. I checked that at the code: $ cat /usr/src/cygwin-1.5.24-2/winsup/mingw/mingwex/math/llrint.c #include long long llrint (double x) { long long retval; __asm__ __volatile__ \ ("fistpll %0" : "=m" (retval) : "t" (x) : "st"); \ return retval; } Regards, Victor -- Unsubscribe info: http://cygwin.com/ml/#unsubscribe-simple Problem reports: http://cygwin.com/problems.html Documentation: http://cygwin.com/docs.html FAQ: http://cygwin.com/faq/