https://gcc.gnu.org/bugzilla/show_bug.cgi?id=121718
--- Comment #3 from Hongtao Liu <liuhongt at gcc dot gnu.org> --- Created attachment 62233 --> https://gcc.gnu.org/bugzilla/attachment.cgi?id=62233&action=edit use __builtin_fegetround. Does this help?