Hi Chris, On 6 August 2017 at 19:35, Christopher Li <sparse@xxxxxxxxxxx> wrote: > If we agree sparse shouldn't generate the following. > > and.32 %r3 <- %r4, $-65 > or.32 %r4 <- %r3, $64 > > Let's fix it then. > I agree that simplifications must not result in incorrect code (in my case correct code is more valuable than efficient code) - and in this particular example, the C code is legal and correct and this is not an instance of an uninitialized variable because in the C code the variable is assigned a value prior to it being accessed. I am not sure that this is easy to fix though - as the original IR does not capture the intent of the C program. Maybe you could have a separate IR instruction to assign value to a bit field - rather than using load/and/or sequence. This will enable the original IR to reflect the intent of the C program more accurately and hopefully enable the simplification phase can handle it correctly. Regards Dibyendu -- To unsubscribe from this list: send the line "unsubscribe linux-sparse" in the body of a message to majordomo@xxxxxxxxxxxxxxx More majordomo info at http://vger.kernel.org/majordomo-info.html