On Tue, Feb 08, 2011, Richard Guenther wrote: > On Mon, Feb 7, 2011 at 9:37 PM, Andrew Pinski <pins...@gmail.com> wrote: > > On Mon, Feb 7, 2011 at 2:55 AM, Richard Guenther > > <richard.guent...@gmail.com> wrote: > >> Does FreeBSD ever set errno for malloc() calls? See PR47179 and > >> PR42944 - which means it might require splitting the flag into a > >> math piece and a general piece (or one covering just malloc & friends). > > > > The option's documentation (and the name itself) says it is a math > > piece anyways. So I don't see why need to split it up? > > Because we (ab-)use it for malloc as well as there is no way for the > Fortran frontend to specify it doesn't care for errno at all. Thus, > we probably need a -fno-non-math-errno (ick).
FreeBSD does set errno in malloc(), but does not ship with the Fortran frontend. The undocumented abuse of -fno-math-errno to affect gcc's model for malloc() sounds insidious.