This is Xamarin's bug tracking system. For product support, please use the support links listed in your Xamarin Account.
Bug 8250 - Math.Pow() returns incorrect results on ARM build
: Math.Pow() returns incorrect results on ARM build
Status: RESOLVED DUPLICATE of bug 7938
Product: Runtime
Classification: Mono
Component: JIT
: unspecified
: Other Linux
: --- normal
: ---
Assigned To: Bugzilla
:
:
:
:
  Show dependency treegraph
 
Reported: 2012-11-06 16:45 EST by XamarinBugzilla.20.jwman
Modified: 2012-11-07 11:07 EST (History)
3 users (show)

See Also:
Tags:
Test Case URL:
External Submit: ---


Attachments
Simple test program that ouputs results of calling Math.Pow (615 bytes, text/x-csharp)
2012-11-06 16:45 EST, XamarinBugzilla.20.jwman
Details

Description XamarinBugzilla.20.jwman 2012-11-06 16:45:08 EST
Created attachment 2872 [details]
Simple test program that ouputs results of calling Math.Pow

Mono Version 2.10.8.1ubuntu2.1
Ubuntu 12.04 
Running on BeagleBone platform.

Calling Math.Pow() returns incorrect results, like this:

Math.Pow(10, -5) results.  Expected: 1E-05  Actual: 0.00891799479722977
Math.Pow(10, 5) results.  Expected: 100000  Actual: 0.257413864135742
Math.Pow(2, 4) results.  Expected: 16  Actual: 0.263913869857788
Math.Pow(2, 8) results.  Expected: 256  Actual: 1

This works as expected on the x86 version 2.10.8.1 (Debian
2.10.8.1-1~dhx1~lucid1).
Comment 1 Zoltan Varga 2012-11-07 00:21:31 EST
Probably a dup of:
https://bugzilla.xamarin.com/show_bug.cgi?id=7938
Comment 2 XamarinBugzilla.20.jwman 2012-11-07 00:39:24 EST
Ah.  Yes, it is in fact using hardfp.  Didn't know that caused issues with
mono.

I'm sure that's the cause.
Comment 3 Zoltan Varga 2012-11-07 11:07:46 EST

*** This bug has been marked as a duplicate of bug 7938 ***

Note You need to log in before you can comment on or make changes to this bug.