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: PING: two middle-end builtin cproj patches


From: "Richard Guenther" <richard.guenther@gmail.com>

On Sun, Apr 18, 2010 at 6:45 PM, Kaveh R. GHAZI <ghazi@caip.rutgers.edu> wrote:

Two patches for builtin cproj:


http://gcc.gnu.org/ml/gcc-patches/2010-04/msg00490.html

http://gcc.gnu.org/ml/gcc-patches/2010-04/msg00517.html

I am worried that with old glibc still around we now silently change cproj semantics. Can you at least add one executable testcase that would FAIL with the incorrect implementation and PASS with a correct implementation? Please add an entry to gcc-4.6/changes,html mentioning this change and the newest glibc version affected.

Ok with that change.

and here is the update to the webpage:


Index: changes.html
===================================================================
RCS file: /cvs/gcc/wwwdocs/htdocs/gcc-4.6/changes.html,v
retrieving revision 1.7
diff -u -p -r1.7 changes.html
--- changes.html        25 Apr 2010 15:05:32 -0000      1.7
+++ changes.html        25 Apr 2010 23:19:15 -0000
@@ -21,6 +21,18 @@
    <code>&lt;<em>machine</em>&gt;-gcc-&lt;<em>version</em>&gt;</code>
    to run a different version of <code>gcc</code>. </li>

+    <li>Versions of the GNU C library up to and including 2.11.1
+    included an <a
+    href="http://sourceware.org/bugzilla/show_bug.cgi?id=10401";>incorrect
+    implementation of the <code>cproj</code> function</a>.  GCC
+    optimizes its builtin <code>cproj</code> according to the behavior
+    specified and allowed by the ISO C99 standard.  If you want to
+    avoid discrepancies between the C library and GCC's builtin
+    transformations when using <code>cproj</code> in your code, use
+    GLIBC 2.12 or later.  If you are using an older GLIBC and actually
+    rely on the incorrect behavior of cproj, then you can disable
+    GCC's transformations using <code>-fno-builtin-cproj</code>. </li>
+
</ul>

<h2>General Optimizer Improvements</h2>


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