<html>
    <head>
      <base href="https://bugs.llvm.org/">
    </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 - error: option '-mfloat128' cannot be specified with 'ppc64le'"
   href="https://bugs.llvm.org/show_bug.cgi?id=49694">49694</a>
          </td>
        </tr>

        <tr>
          <th>Summary</th>
          <td>error: option '-mfloat128' cannot be specified with 'ppc64le'
          </td>
        </tr>

        <tr>
          <th>Product</th>
          <td>clang
          </td>
        </tr>

        <tr>
          <th>Version</th>
          <td>trunk
          </td>
        </tr>

        <tr>
          <th>Hardware</th>
          <td>Other
          </td>
        </tr>

        <tr>
          <th>OS</th>
          <td>Linux
          </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>Driver
          </td>
        </tr>

        <tr>
          <th>Assignee</th>
          <td>unassignedclangbugs@nondot.org
          </td>
        </tr>

        <tr>
          <th>Reporter</th>
          <td>zilla@kayari.org
          </td>
        </tr>

        <tr>
          <th>CC</th>
          <td>llvm-bugs@lists.llvm.org, neeilans@live.com, richard-llvm@metafoo.co.uk
          </td>
        </tr></table>
      <p>
        <div>
        <pre>Using -mfloat128 on ppc64 gives this error:

error: option '-mfloat128' cannot be specified with 'ppc64le'

The docs seem suggest it should be valid:
<a href="https://clang.llvm.org/docs/ClangCommandLineReference.html#cmdoption-clang-mfloat128">https://clang.llvm.org/docs/ClangCommandLineReference.html#cmdoption-clang-mfloat128</a>
(although a list of flags with no actual documentation isn't very clear).


clang/lib/Basic/Targets/PPC.cpp has a confusing comment:

  if (!(ArchDefs & ArchDefinePwr9) && (ArchDefs & ArchDefinePpcgr) &&
      llvm::find(FeaturesVec, "+float128") != FeaturesVec.end()) {
    // We have __float128 on PPC but not power 9 and above.
    Diags.Report(diag::err_opt_not_valid_with_opt) << "-mfloat128" << CPU;
    return false;
  }

That comment says the type should be valid for "PPC but not power 9 and above",
but what it really means is "only for power 9 and above". If you add
-mcpu=power9 then -mfloat128 is accepted. I think the comment is just badly
phrased.

The error message would be a lot more useful if it told you that you need
power9. The comment in the source should also match the code.</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>