ffc team mailing list archive
-
ffc team
-
Mailing list archive
-
Message #03023
Re: Buildbot failing on winxp
On Wed, Sep 23, 2009 at 10:12:43AM +0100, Garth N. Wells wrote:
>
>
> Anders Logg wrote:
> > On Wed, Sep 23, 2009 at 10:06:00AM +0100, Garth N. Wells wrote:
> >>
> >> Anders Logg wrote:
> >>> On Wed, Sep 23, 2009 at 09:40:05AM +0200, Johannes Ring wrote:
> >>>> On Tue, Sep 22, 2009 at 2:46 PM, Anders Logg <logg@xxxxxxxxx> wrote:
> >>>>> Why is the buildbot failing for FFC on winxp-mingw32? Is this
> >>>>> something that could be fixed?
> >>>> The problem is that floats are represented slightly differently
> >>>> because of the underlying C library. On Windows, float(1e-8) is 1e-008
> >>>> while it is 1e-08 on Ubuntu.
> >>> I don't understand why this should matter. Where does this problem show up?
> >>>
> >> When performing a diff on the generated and reference files.
> >
> > You mean the regression test fail just because floats are formatted
> > differently on the two platforms?
> >
>
> Yes.
Johannes, could you send an example of a test that fails so I can look
at it in detail? I won't be able to test myself on Windows, but
perhaps you can find some solution by modifying the following lines in
ffc/compiler/ufcformat.py:
# Set number of digits for floating point and machine precision
precision = int(options["precision"])
f1 = "%%.%dg" % precision
f2 = "%%.%de" % precision
def floating_point(v):
if abs(v) < 100.0:
return f1 % v
else:
return f2 % v
self.format["floating point"] = floating_point
--
Anders
> Garth
>
> > That should be easy to fix since all floats are formatted through a
> > common function in FFC. We could fix that function to produce the same
> > results.
> >
> >> Garth
> >>
> >>>> BTW: The buildbot failed the FFC checks last night. No report was sent
> >>>> to the list because I have experimented with bug reports directly to
> >>>> launchpad. Obviously it did not work (problems with GPG signing of the
> >>>> mail).
> >>> ok.
> >>>
> >> _______________________________________________
> >> FFC-dev mailing list
> >> FFC-dev@xxxxxxxxxx
> >> http://www.fenics.org/mailman/listinfo/ffc-dev
> >>
> >> ------------------------------------------------------------------------
> >>
> >> _______________________________________________
> >> FFC-dev mailing list
> >> FFC-dev@xxxxxxxxxx
> >> http://www.fenics.org/mailman/listinfo/ffc-dev
> _______________________________________________
> FFC-dev mailing list
> FFC-dev@xxxxxxxxxx
> http://www.fenics.org/mailman/listinfo/ffc-dev
Attachment:
signature.asc
Description: Digital signature
Follow ups
References