<table border="1" cellspacing="0" cellpadding="8">
<tr>
<th>Issue</th>
<td>
<a href=https://github.com/llvm/llvm-project/issues/64591>64591</a>
</td>
</tr>
<tr>
<th>Summary</th>
<td>
AMDGPUCodeGenPrepare should stop promoting uniform i16 values
</td>
</tr>
<tr>
<th>Labels</th>
<td>
backend:AMDGPU
</td>
</tr>
<tr>
<th>Assignees</th>
<td>
</td>
</tr>
<tr>
<th>Reporter</th>
<td>
arsenm
</td>
</tr>
</table>
<pre>
With DAG divergence and RegBankSelect, theoretically codegen should now have enough information to handle promotion of uniform 16-bit ops directly. This was originally done as a workaround for having no uniformity info after the IR.
AMDGPUCodeGenPrepare awkwardly uses forward iteration, which just so happens to work around a defect in uniformity info where newly created values are assumed uniform. I currently have a problem that requires iterating in reverse like a normal combiner, and this is blocking the reversal
</pre>
<img width="1px" height="1px" alt="" src="http://email.email.llvm.org/o/eJxsU09vqzgQ_zRwGTUCE2hy4JA2StXDSlV3V3se7Al2Y2x2bAfl2z-ZJu8d3ruAQP7N_P4ZQzCjI-qL9qVojyWmqD33yIHcVA5e3fr_TNRwPLyBMlfikZwkQKfgk8YXdJe_yZKMhXiFqMkzRSPR2htIr2gkB0H7ZBU4v4DGKwE5n0YNxp09TxiNdxA9aHTKEszsJ7_-82dIzuQzUHdPg4ng5wDKMMlobxv4R5sACwbwbEbj1pXKOwIMgLB4viD75BScPefFxo3g_GOmibeVAeA5Emfm8P65KapjUR2-n4e_jm8f_756RW_kPphmZAJcLguysjdIgUIenT_BROJVSXZh0UZq-EohQsi65plcyBIzJ7iTQlB0JhnBuN8oLZqYwNGSTWTCSAquaBMFWDmEkCZSD9gG3kEmZnLR3r4dxmzjYGmCqDEC0__JMIUHTTfmrUxX4kBgzSUjXA7DgvTTYBxxFpIzjtllE2CwXl4yMjv1DUVbqr5R-2aPJfV1t6-7brtvm1L3z9RWe4mi2za1qKttNSjVCKm6Rp1pu2tK04tKNNWuruqqbdtm0-66XfWMg9jLtqJOFduKJjR2Y-112ngeSxNCor7btvu6tDiQDWtlhRhQXsiporlHVgiRi8x9hj4NaQzFtrImxPBrWDTRUv_HiO91DdHPjza68WcVTd3dsygT217HOIeiORTiVIjTaKJOw0b6qRCnvOv-eprZf6135LSqCIU4rUJ-BAAA___MpDbQ">