Btw, in https://build.opensuse.org/request/show/680643 I submitted a workaround for the issue to sphinxbase . Note that the workarounds mentioned here for the test case didn't help for the package. Adding a line with printf("%g\n", g1); did "fix" it, but of course, adding a printf is not an option. So I ended up working around it by using temporary variables and an attribute to force O0 optimization on the problematic function.