https://gcc.gnu.org/bugzilla/show_bug.cgi?id=111709
--- Comment #25 from John David Anglin <danglin at gcc dot gnu.org> --- The unions in this code have been completely optimized away making this code very difficult to debug. I worry that there is a disconnect between the floating and integer values in the unions. Float computations may need to be forced to complete to ensure the union values are updated. I had to do this to determine where the underflow flag was being set. But maybe you are right about needing a barrier after the rounding mode change.