On 2/18/26 11:33 AM, Victor Do Nascimento wrote:
- Finally, a simplification is made. Before, we had the check:if ((vf.is_constant () && pow2p_hwi (new_alignment.to_constant ())) || (!vf.is_constant () && pow2p_hwi (align_factor_c))) Given that we have `new_alignment = vf * align_factor_c', I do not believe anything can be derived from `new_alignment' that is now known already in `align_factor_c '. That is, a power of 2 has only one prime factor: 2. If `align_factor_c' is not itself a power of 2, the multiplication by `vf' cannot correct that, such that the check for `new_alignment' seems redundant. The predicate can thus simplified to `if (pow2p_hwi (align_factor_c))'. The seems sound to me, should my logic be correct.
This simplification is certainly wrong if vf is constant and not a power of 2 and if align_factor_c is a power of 2.... if that can happen.
Theo.
