I can almost guarantee you won't see any difference in object code size by using an extra automatic variable (buttonState1) here. The compiler is very good at optimizing the generated code (sometimes in ways that surprise me, and I've been programming in C for 25 years).