standards/176031: [msun] pow() returns roots of negative values.

Pedro Giffuni giffunip at
Mon Feb 11 15:20:01 UTC 2013

>Number:         176031
>Category:       standards
>Synopsis:       [msun] pow() returns roots of negative values.
>Confidential:   no
>Severity:       non-critical
>Priority:       low
>Responsible:    freebsd-standards
>State:          open
>Class:          sw-bug
>Submitter-Id:   current-users
>Arrival-Date:   Mon Feb 11 15:20:00 UTC 2013
>Originator:     Pedro Giffuni
>Release:        9.1-PRERELEASE
FreeBSD pcbsd-8555 9.1-PRERELEASE FreeBSD 9.1-PRERELEASE #7: Sun Oct  7 00:05:03 COT 2012     Pedro at pcbsd-8555:/usr/src/sys/amd64/compile/GENERIC  amd64


I think there is a bug in our pow(). According to IEEE 754,

pow(x,y) signals the invalid operation exception when x <0 and
y is a non-integer value.
(-3)^1.5 returns -3 in FreeBSD, on Windows it produces an error.

This was seen in OpenOffice (which uses pow() ).


More information about the freebsd-standards mailing list