@nil i dont have access to a computer with gcc atm, so I cannot check: does this happen at O1?
i'm also wondering how gcc detects this "pattern". if it's based on the function name, then that seems outright passive-aggressive. if it's based on the code structure, it seems really brittle and I would not expect that at low optimization levels.