https://gcc.gnu.org/bugzilla/show_bug.cgi?id=84502
--- Comment #1 from patrick.schlangen at bmw dot de --- Note: This problem does not happen with gcc 7.2.1. The problem can also be reproduced with -O3 when the empty struct object passed to the function is actually used in the function. (So it is not optimized out.)