https://gcc.gnu.org/bugzilla/show_bug.cgi?id=71942
--- Comment #1 from Albi <albrecht.guendel at web dot de> --- To give a minimum case: int main(void) { volatile unsigned short foo = 0; while(1) foo ^= 1; } creates: ldrh.w r3, [sp, #6] uxth r3, r3 << again no reason for this eor.w r3, r3, #1 strh.w r3, [sp, #6]