<table border="1" cellspacing="0" cellpadding="8">
<tr>
<th>Issue</th>
<td>
<a href=https://github.com/llvm/llvm-project/issues/131273>131273</a>
</td>
</tr>
<tr>
<th>Summary</th>
<td>
[MLIR] optimization int-range-optimizations crashes
</td>
</tr>
<tr>
<th>Labels</th>
<td>
mlir
</td>
</tr>
<tr>
<th>Assignees</th>
<td>
</td>
</tr>
<tr>
<th>Reporter</th>
<td>
thaddywu
</td>
</tr>
</table>
<pre>
To reproduce: https://godbolt.org/z/34cz5zfxE
Calling `--int-range-optimizations` crashes on this snippet of code
`--int-range-optimizations`
```
"builtin.module"() ({
"func.func"() <{
function_type = () -> (),
sym_name = "simple_arith.ceildivui"
}>({
%0 = "test.with_bounds"() <{
smax = 0 : i32,
smin = -1 : i32,
umax = 0 : i32,
umin = -1 : i32
}> : () -> i32
%1 = "arith.constant"() <{value = 7 : i32}> : () -> i32
%2 = "arith.ceildivui"(%1, %0) : (i32, i32) -> i32
"func.return"() : () -> ()
}) : () -> ()
}) : () -> ()
```
</pre>
<img width="1" height="1" alt="" src="http://email.email.llvm.org/o/eJyMVMGOmzAQ_ZrhYoHMOA7JgQObbKRK7aXqPTLYCa6MjbCd3eTrKwhpolW6WwlhxLyZ997YY-G9PlqlSuAvwLeJiKF1QxlaIeX5LSa1k-fylyOD6gcnY6OAVaQNoffAKsAd4O7oZO1MyNxwBNxdAHds0Vz45fD-CrTaCGO0PRJY0jTVNqSDsEeVuj7oTl9E0M56WFLSDMK3yhNnSWi1J97qvleBuANpnFRAqy8qjIgJND-0AsQ6ahO0zTono1GACLgCXJNxKV6AVgQQD9E22fh6iLPNHCeEjKGRZR_OvSLAtmRGpcBe52_AzYz2525vRXcDotddb9ReDDq0WaO0kfoU9Ug14qHYAnu9yyGEAHJ6Sw7Kh-xNh3Zfu2ilf6bQd-J9wo9ZFdEM72II8Z22UzTNn4Xjp8nxSfIsctI9_XxsxhVwN5LfjMz2nfVB2PDRxkmYeG1Y8Zfn_wjwA8Fjf8c0ngNuppZe2aZqV5dXs8_rXs_EoEIc7KPY6tnW3_bxM8SX8du5TWTJ5JqtRaLKvFjka1zljCZtuVqqojjIg-DLVcO5lAXjalGvlvQg6qVcJbpEipyyfEEXnDOaMarWsqGqOawUEzWHBVWd0CYz5tSN45po76Mqc5ZjwRIjamX8dBEgdkYPo3G-TYZyxKd1PHpYUKN98PcKQQczXR4_vn_7CXxLHseS_GNab8OexMGUHy4THdpYZ43rAHcjy7yk_eB-qyYA7ibRHnA36z6V-CcAAP__1jNOTQ">