<table border="1" cellspacing="0" cellpadding="8">
<tr>
<th>Issue</th>
<td>
<a href=https://github.com/llvm/llvm-project/issues/144268>144268</a>
</td>
</tr>
<tr>
<th>Summary</th>
<td>
[mlir][linalg][promotion] Allow promoting dynamic buffer with dynamic alloc size
</td>
</tr>
<tr>
<th>Labels</th>
<td>
mlir
</td>
</tr>
<tr>
<th>Assignees</th>
<td>
</td>
</tr>
<tr>
<th>Reporter</th>
<td>
BZZiv
</td>
</tr>
</table>
<pre>
Currently linalg promotion transform attempts to allocate the promoted buffer with the smallest size. It is achieved by computing a constant upper bound for the promoted subviews, and only when the computation fails it fallbacks to dynamic allocation size. It would be nice to have the option to prefer the exact allocation size, even at the price of dynamic allocation.
I'd be happy to add the support myself if there's interest.
</pre>
<img width="1" height="1" alt="" src="http://email.email.llvm.org/o/eJxsUsFyozoQ_BpxmQolZBTHBw5OUq7KL-Q2ghHoPSFR0oCX_fotsOPdbO0JatTq6W415uz6QNQI_Sr0e4EzDzE1r5-fbilM7NbmbU6JAvsVvAvoe5hSHCO7GIAThmxjGgGZaZw4A0dA72OLTMAD3cHUgZmtpQRXx8N-kEf0njJDdj-phA8GlwHbwdGyoVdo4zjN7EIPCG0MmTEwzNNECUycQwc2pu8r8mwWR9cs1Btg6CAGv8J1oLDDbny4C7fofAbHYNF7g-3_u_BuDTi69svABnyIu8bZd2AIgmtpAw-43BzG6ZZFhCnRZnEb0g9s-W-iTRctFAD5LnzjivYfi0shz0KeP4Q67lsHnKZ1D7frbvHN0xQTw7hm8hac3aaJhDpmcIEpUeay6JpDdzqcsKCmOmoppapeZDE01lRERp8qXZ1UrSsrjTGdPnYHfXrWSheuUVJp-VzpStcHKUusaoOdxNpW1r4cUdSSRnS-9H4Zy5j6wuU8U1PVtXp-KTwa8nkvlVKjd0kotdUrNRv-ycx9FrX0LnP-zcCO_V7E_YJ-F_r1Vrnb_6N3Qr_D2ft4_api6B8R_lmzb7HuL1DMyTcD85TF4SzURahL73iYTdnGUajLJuX-eZpS_I9aFuqyO8tCXe7mlkb9CgAA___Y-xyT">