<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 - [zorg] stage-1 SVE builds use unsupported flags with system compiler"
   href="https://bugs.llvm.org/show_bug.cgi?id=51836">51836</a>
          </td>
        </tr>

        <tr>
          <th>Summary</th>
          <td>[zorg] stage-1 SVE builds use unsupported flags with system compiler
          </td>
        </tr>

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

        <tr>
          <th>Version</th>
          <td>unspecified
          </td>
        </tr>

        <tr>
          <th>Hardware</th>
          <td>PC
          </td>
        </tr>

        <tr>
          <th>OS</th>
          <td>All
          </td>
        </tr>

        <tr>
          <th>Status</th>
          <td>NEW
          </td>
        </tr>

        <tr>
          <th>Severity</th>
          <td>enhancement
          </td>
        </tr>

        <tr>
          <th>Priority</th>
          <td>P
          </td>
        </tr>

        <tr>
          <th>Component</th>
          <td>-New Bugs
          </td>
        </tr>

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

        <tr>
          <th>Reporter</th>
          <td>peter.waller@arm.com
          </td>
        </tr>

        <tr>
          <th>CC</th>
          <td>htmldeveloper@gmail.com, llvm-bugs@lists.llvm.org, neeilans@live.com, richard-llvm@metafoo.co.uk
          </td>
        </tr></table>
      <p>
        <div>
        <pre>The builders clang-aarch64-sve-vla-2stage and clang-aarch64-sve-vls-2stage both
use flags not understood by the stage1 compiler provided by the host which at
the moment is clang-12.

<a href="https://github.com/llvm/llvm-zorg/commit/6fc25a74c84e064b375e320b918b62fed3a2bde0">https://github.com/llvm/llvm-zorg/commit/6fc25a74c84e064b375e320b918b62fed3a2bde0</a>

At stage 1:

* The VLA bot silently ignores the -mllvm -scalable-vectorization=preferred
flag passed to it.

* The VLS bot compiles with -msve-vector-bits=...

It seems to me it would be preferable to have a three-stage build, where the
first stage uses relatively boring flags. If that's not possible, at least
there needs to be a way to specify different flags between stage1 and stage2
which it seems isn't supported by zorg.

If at some point these builders are using clang-13, and it turns out there are
latent SVE codegen bugs, then this builder could fail in surprising ways when
stage1 executes and it won't be possible to fix it by submitting a patch to the
main branch. We're effectively in that situation in clang-12, although happily
I think the flags are being mostly ignored. The linked patch did change the
behaviour of the stage-1 build however, where previously it was testing the vls
codegen (because it understood -mllvm -aarch64-sve-vector-bits-min) but now it
does not.</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>