From mboxrd@z Thu Jan 1 00:00:00 1970 X-Spam-Checker-Version: SpamAssassin 3.4.4 (2020-01-24) on polar.synack.me X-Spam-Level: X-Spam-Status: No, score=-1.9 required=5.0 tests=BAYES_00,FREEMAIL_FROM autolearn=ham autolearn_force=no version=3.4.4 X-Google-Thread: 103376,c1bdceb867926fdb X-Google-NewGroupId: yes X-Google-Attributes: gida07f3367d7,domainid0,public,usenet X-Google-Language: ENGLISH,ASCII Path: g2news1.google.com!postnews.google.com!q35g2000yqn.googlegroups.com!not-for-mail From: sjw Newsgroups: comp.lang.ada Subject: Re: Interfacing Ada with C Date: Fri, 6 Aug 2010 01:39:18 -0700 (PDT) Organization: http://groups.google.com Message-ID: <4a3e5073-5e2b-48d6-b862-9bfd9a5c303e@q35g2000yqn.googlegroups.com> References: <143ef70b-7e74-426b-a621-a5fd157849be@x21g2000yqa.googlegroups.com> <06eb8f61-2a0c-4dda-93f3-8414d32b6e4f@f20g2000pro.googlegroups.com> NNTP-Posting-Host: 20.133.0.13 Mime-Version: 1.0 Content-Type: text/plain; charset=ISO-8859-1 Content-Transfer-Encoding: quoted-printable X-Trace: posting.google.com 1281083958 8416 127.0.0.1 (6 Aug 2010 08:39:18 GMT) X-Complaints-To: groups-abuse@google.com NNTP-Posting-Date: Fri, 6 Aug 2010 08:39:18 +0000 (UTC) Complaints-To: groups-abuse@google.com Injection-Info: q35g2000yqn.googlegroups.com; posting-host=20.133.0.13; posting-account=_RXWmAoAAADQS3ojtLFDmTNJCT0N2R4U User-Agent: G2/1.0 X-HTTP-UserAgent: Mozilla/5.0 (Windows; U; Windows NT 5.1; en-GB; rv:1.9.2.8) Gecko/20100722 Firefox/3.6.8,gzip(gfe) Xref: g2news1.google.com comp.lang.ada:12896 Date: 2010-08-06T01:39:18-07:00 List-Id: On Aug 5, 6:24=A0pm, Ada novice wrote: > On Aug 5, 3:57=A0pm, sjw wrote: > > > Although LAPACK/BLAS (at 3.2.2 anyway) allow you to build with > > extended precision (80-bit floats, GNAT Long_Long_Float if on x86 > > hardware) GNAT's implementation of Generic * Arrays assumes the worst > > case, ie BLAS/LAPACK only available in single & double precision; and > > if the type in use (My_Float in my test case) doesn't match Fortran > > single or double precision it converts to double precision, makes the > > call, then converts back. > > Can we change the subtype to Long_Long_Float? This will be of 18 > precision digits and "more" precise than Fortran's double precision. > It would be like asking for more precision that can be offered. Did I > understand you correctly? You can change to Long_Long_Float, and on an Intel machine that will use 80 bits (on a PowerPC it won't; Long_Long_Float is the same as Long_Float, because the FPU on a PPC doesn't support extended precision (AFAIK)). *BUT* *BUT* *BUT* the internals of the matrix operations (the standard ones and our extensions) only use 64 bits. So the apparent extra precision is fool's gold.