<table border="1" cellspacing="0" cellpadding="8">
    <tr>
        <th>Issue</th>
        <td>
            <a href=https://github.com/llvm/llvm-project/issues/123947>123947</a>
        </td>
    </tr>

    <tr>
        <th>Summary</th>
        <td>
            Finalise setup of buildbot for RISC-V RVA23 EVL tail folding
        </td>
    </tr>

    <tr>
      <th>Labels</th>
      <td>
            backend:RISC-V
      </td>
    </tr>

    <tr>
      <th>Assignees</th>
      <td>
      </td>
    </tr>

    <tr>
      <th>Reporter</th>
      <td>
          asb
      </td>
    </tr>
</table>

<pre>
    This requires a builder with:
`-march=rva23u64 -mllvm -force-tail-folding-style=data-with-evl -mllvm -prefer-predicate-over-epilogue=predicate-else-scalar-epilogue'` and ideally qemu settings `rvv_ta_all_1s=true,rvv_ma_all_1s=true,rvv_vl_half_avl=true` to maximise the chance of finding bugs. This will be done using the same cross-compile and then execute under qemu-system setup used for the RVA20 bot. Not all items below are specific to the RVA23 bot.

This requires:
* [x] Update to QEMU 9.2.0 and check for no regressions
* [x] Redeploy x86-64 host with appropriate config
* [x] Resolve sporadic failures due to running out of disk space.
  * Bumping the size of llvm-project.img worked. Issues were sporadic seemingly due to varying test order meaning disk size limits were sometimes reached with temporary files but sometimes not.
* [x] Get a working local debug flow for subsets of the LLVM tests (`ninja check-llvm-executionengine` for instance fails to work due to llvm-lit being invoked from a different subdirectory and lit-on-qemu not handling this)
* [x] Investigate and fix failures for MCJIT/ExecutionEngine tests
  * Issue was a failure to set `-DLLVM_HOST_TRIPLE=riscv64-linux-gnu` leading to a confusing compilation flow for mcjit/executionengine
* [x] Resolve issues with host python3 path not matching the one under qemu-system (e.g. when using pip on the host)
  * Explicitly passing `-DPython3_EXECUTABLE=/usr/bin/python3` resolves this
* [x] Resolve issues with buildbot running under python3.13 on the host
  * Manual fix for pipes.quote usage and depend on legacy-cgi installed via pip
* [ ] (non-blocking issue) Document Python 3.13 workarounds in docs on local builder testing
* [ ] Resolve test failures for small subset of tests that try to use lit-on-qemu (set through `-DLLVM_EXTERNAL_LIT`) internally. Seems to primarily be the update_test_checks tests.
  * Could potentially mask these tests, or alternatively find a way to override the lit path for just these tests, or set up lit-on-qemu in the correct path under qemu-system that just forwards to lit. 
* [ ] (non-blocking issue) Figure out why MCJIT/ExecutionEngine tests aren't running with e.g. `ninja check-llvm-executionengine` (marked as 'unsupported', even the RISC-V ones).
* [ ] Receive review on PR to switch over rva23 evl builder https://github.com/llvm/llvm-zorg/pull/358
* [ ] Finalise x86-64 host deployment for rva23 evl builder once llvm-zorg#358 lands
* [ ] Test enabling the test suite locally and resolve any issues
* [ ] Enable the running of the test suite on rva23 evl builder
* [ ] Evaluate what other LLVM subprojects can/should be enabled in this setup (and expand this list to cover that work)
</pre>
<img width="1" height="1" alt="" src="http://email.email.llvm.org/o/eJyMV11T20oS_TXipUsuMbKN_eAHAvYuW-TuXUJS9801GrWkDqMZZT5kfH_9Vo9sIJDazRNV2P1xTp8-PZbeU2sQN9niU7a4vZAxdNZtpK8uKlsfN48deXD4I5JDDxKqSLpGBwcKXVZeZ8V1tizyXjrVZeWtG6Uo43IOea_12EPeWKcwD5J03lhdk2lzH44as_K2lkHmnCbHUb8EDA4bdPynJiUD5nZEl-NA2raRw14_Qe0x90pq-eYL4ipbFiBNDVSj1PoIP7CP4DEEMq2HbFm4cdwHuZda7y99Vt4Gx3E3_O_-1_8e9b6TutnLUZ8_WBYQLPTymXryCKFDUJ00CsE20JBhqFDF1s8gUXggraFCqK1BiJ4_5RgvewTlrPe5sv1AGlPvoUMD-IwqBoRomHCGkfujD9gzmjhA9FhDY11K9PDtWhRQ2TCDP2wAqTVQwN5DhdoeQDoEP6CihhQ3fg4pUwhPsbj-adSn2YpryBafnrPFLXwdahmQg_-z_fwV1jMxm4hWHaqn1Iix4LB16D1Z49_FP2CNg7ZHeF4t8-UcOutDkhHIYXB2cMTplTUNtR9CvdUjI7BO1qSgkaQjC7KOqSMXjWFKbQzMf03-CfwgFTI0AM71KfbDC-v0d5oTSy4fnP2OKsyob-Fg3RPWM7jzP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