<html>
<head>
<base href="https://llvm.org/bugs/" />
</head>
<body><table border="1" cellspacing="0" cellpadding="8">
<tr>
<th>Bug ID</th>
<td><a class="bz_bug_link
bz_status_NEW "
title="NEW --- - FP exception when optimized; code relocation implicated"
href="https://llvm.org/bugs/show_bug.cgi?id=26969">26969</a>
</td>
</tr>
<tr>
<th>Summary</th>
<td>FP exception when optimized; code relocation implicated
</td>
</tr>
<tr>
<th>Product</th>
<td>clang
</td>
</tr>
<tr>
<th>Version</th>
<td>3.7
</td>
</tr>
<tr>
<th>Hardware</th>
<td>Macintosh
</td>
</tr>
<tr>
<th>OS</th>
<td>MacOS X
</td>
</tr>
<tr>
<th>Status</th>
<td>NEW
</td>
</tr>
<tr>
<th>Severity</th>
<td>normal
</td>
</tr>
<tr>
<th>Priority</th>
<td>P
</td>
</tr>
<tr>
<th>Component</th>
<td>LLVM Codegen
</td>
</tr>
<tr>
<th>Assignee</th>
<td>unassignedclangbugs@nondot.org
</td>
</tr>
<tr>
<th>Reporter</th>
<td>richard.brandt@autodesk.com
</td>
</tr>
<tr>
<th>CC</th>
<td>llvm-bugs@lists.llvm.org
</td>
</tr>
<tr>
<th>Classification</th>
<td>Unclassified
</td>
</tr></table>
<p>
<div>
<pre>Created <span class=""><a href="attachment.cgi?id=16047" name="attach_16047" title="Source code, Makefile, README.TXT explaining issue.">attachment 16047</a> <a href="attachment.cgi?id=16047&action=edit" title="Source code, Makefile, README.TXT explaining issue.">[details]</a></span>
Source code, Makefile, README.TXT explaining issue.
You guys do great work!
Floating point exception due to unexpected code relocation, for all
optimization
levels greater than -O0.
This occurs in a C translation of the Fortran LAPACK numerical library.
We show a floating point overflow runtime exception which occurs due to
pre-evaluation of the expression "bignum * cnorm" in line 258 of dlaln2.c.
The overflow occurs because the cnorm variable is greater than 1. A following
if test checks the value of cnorm and should prevent the multiplication when
cnorm is greater than 1.
We'd like to know the LLVM compiler team's opinions:
* Is this a compiler bug? It seems that way to us. Previous versions of Xcode
did not produce the exception. We're using Xcode 7.1.
* If this is not a compiler bug, what is the rationale for allowing code
relocations which disregard tests of the operands?
* Is there a compiler command line option which we can set to disable the
specific optimization which causes the code relocation?
THANKS!!
Rich Brandt</pre>
</div>
</p>
<hr>
<span>You are receiving this mail because:</span>
<ul>
<li>You are on the CC list for the bug.</li>
</ul>
</body>
</html>