This is the mail archive of the gcc-patches@gcc.gnu.org mailing list for the GCC project.


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]
Other format: [Raw text]

Re: [PATCH]: Update news and gcc-4.3 changes for new MPFR stuff


Gerald Pfeifer wrote:
On Sat, 30 Dec 2006, Kaveh R. GHAZI wrote:
+    <li>The GCC middle-end has been integrated with the <a
+    href="http://www.mpfr.org/";>MPFR</a> library.  This allows GCC to
+    evaluate and replace at compile-time calls to built-in math
+    functions having constant arguments with their mathematically
+    equivalent results.  In making use of <a
+    href="http://www.mpfr.org/";>MPFR</a>, GCC can generate correct
+    results regardless of the library implementation or floating point
+    precision of the host platform.  This also allows GCC to generate
+    identical results regardless of whether one compiles in native or
+    cross-compile configurations to a particular target.  The
+    following built-in functions take advantage of this new
+    capability: <code>acos, acosh, asin, asinh, atan, atan2, atanh,
+    cbrt, cos, cosh, erf, erfc, exp, exp10, exp2, expm1, fma, fmax,
+    fmin, hypot, log, log10, log1p, log2, pow, pow10, sin, sincos,
+    sinh, tan, tanh</code> and <code>tgamma</code>.  The
+    <code>float</code> and <code>long double</code> variants of these
+    functions (e.g. <code>sinf</code> and <code>sinl</code>) are also
+    handled.  (The <code>sqrt</code> and related functions were
+    already optimized in prior GCC releases.)  </li>

I like this. Strictly speaking, we'd have to write <code>acos</code>, <code>acosh</code>, <code>asin</code>,... but I do not want you to break your fingers, so feel free to ignore this part of the review. ;-)

Search-and-replace (on ", ") is your friend. Here's an edited version that took me a minute or so. :)


   capability: <code>acos</code>, <code>acosh</code>, <code>asin</code>,
   <code>asinh</code>, <code>atan</code>, <code>atan2</code>,
   <code>atanh</code>, <code>cbrt</code>, <code>cos</code>,
   <code>cosh</code>, <code>erf</code>, <code>erfc</code>,
   <code>exp</code>, <code>exp10</code>, <code>exp2</code>,
   <code>expm1</code>, <code>fma</code>, <code>fmax</code>,
   <code>fmin</code>, <code>hypot</code>, <code>log</code>,
   <code>log10</code>, <code>log1p</code>, <code>log2</code>,
   <code>pow</code>, <code>pow10</code>, <code>sin</code>,
   <code>sincos</code>, <code>sinh</code>, <code>tan</code>,
   <code>tanh</code> and <code>tgamma</code>.  The <code>float</code>
   and <code>long double</code> variants of these functions (e.g.
   <code>sinf</code> and <code>sinl</code>) are also handled.  (The
   <code>sqrt</code> and related functions were already optimized in
   prior GCC releases.)  </li>

- Brooks


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]