1*05a0b428SJohn Marino.\" $OpenBSD: fma.3,v 1.3 2013/06/05 03:40:26 tedu Exp $ 2*05a0b428SJohn Marino.\" 3*05a0b428SJohn Marino.\" Copyright (c) 2011 Martynas Venckus <martynas@openbsd.org> 4*05a0b428SJohn Marino.\" 5*05a0b428SJohn Marino.\" Permission to use, copy, modify, and distribute this software for any 6*05a0b428SJohn Marino.\" purpose with or without fee is hereby granted, provided that the above 7*05a0b428SJohn Marino.\" copyright notice and this permission notice appear in all copies. 8*05a0b428SJohn Marino.\" 9*05a0b428SJohn Marino.\" THE SOFTWARE IS PROVIDED "AS IS" AND THE AUTHOR DISCLAIMS ALL WARRANTIES 10*05a0b428SJohn Marino.\" WITH REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF 11*05a0b428SJohn Marino.\" MERCHANTABILITY AND FITNESS. IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR 12*05a0b428SJohn Marino.\" ANY SPECIAL, DIRECT, INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES 13*05a0b428SJohn Marino.\" WHATSOEVER RESULTING FROM LOSS OF USE, DATA OR PROFITS, WHETHER IN AN 14*05a0b428SJohn Marino.\" ACTION OF CONTRACT, NEGLIGENCE OR OTHER TORTIOUS ACTION, ARISING OUT OF 15*05a0b428SJohn Marino.\" OR IN CONNECTION WITH THE USE OR PERFORMANCE OF THIS SOFTWARE. 16*05a0b428SJohn Marino.\" 17*05a0b428SJohn Marino.Dd $Mdocdate: June 5 2013 $ 18*05a0b428SJohn Marino.Dt FMA 3 19*05a0b428SJohn Marino.Os 20*05a0b428SJohn Marino.Sh NAME 21*05a0b428SJohn Marino.Nm fma , 22*05a0b428SJohn Marino.Nm fmaf , 23*05a0b428SJohn Marino.Nm fmal 24*05a0b428SJohn Marino.Nd floating multiply-add 25*05a0b428SJohn Marino.Sh SYNOPSIS 26*05a0b428SJohn Marino.In math.h 27*05a0b428SJohn Marino.Ft double 28*05a0b428SJohn Marino.Fn fma "double x" "double y" "double z" 29*05a0b428SJohn Marino.Ft float 30*05a0b428SJohn Marino.Fn fmaf "float x" "float y" "float z" 31*05a0b428SJohn Marino.Ft long double 32*05a0b428SJohn Marino.Fn fmal "long double x" "long double y" "long double z" 33*05a0b428SJohn Marino.Sh DESCRIPTION 34*05a0b428SJohn MarinoThe 35*05a0b428SJohn Marino.Fn fma , 36*05a0b428SJohn Marino.Fn fmaf 37*05a0b428SJohn Marinoand 38*05a0b428SJohn Marino.Fn fmal 39*05a0b428SJohn Marinofunctions compute (x * y) + z, rounded as one ternary operation. 40*05a0b428SJohn MarinoThe result is rounded according to the current rounding mode. 41*05a0b428SJohn Marino.Sh RETURN VALUES 42*05a0b428SJohn MarinoThe 43*05a0b428SJohn Marino.Fn fma , 44*05a0b428SJohn Marino.Fn fmaf 45*05a0b428SJohn Marinoand 46*05a0b428SJohn Marino.Fn fmal 47*05a0b428SJohn Marinofunctions return (x * y) + z, rounded as one ternary operation. 48*05a0b428SJohn Marino.Sh SEE ALSO 49*05a0b428SJohn Marino.Xr fegetround 3 , 50*05a0b428SJohn Marino.Xr remainder 3 51*05a0b428SJohn Marino.Sh STANDARDS 52*05a0b428SJohn MarinoThe 53*05a0b428SJohn Marino.Fn fma , 54*05a0b428SJohn Marino.Fn fmaf 55*05a0b428SJohn Marinoand 56*05a0b428SJohn Marino.Fn fmal 57*05a0b428SJohn Marinofunctions conform to 58*05a0b428SJohn Marino.St -isoC-99 . 59