On Tue, Nov 8, 2022 at 12:07 PM Jakub Jelinek wrote: > > On Mon, Nov 07, 2022 at 04:38:29PM +0100, Aldy Hernandez wrote: > > From d214bcdff2cb90ad1eb808d29bda6fb98d510b4c Mon Sep 17 00:00:00 2001 > > From: Aldy Hernandez > > Date: Mon, 7 Nov 2022 14:18:57 +0100 > > Subject: [PATCH] Provide normalized and denormal format version of > > real_isdenormal. > > > > Implement real_isdenormal_target() to be used within real.cc where the > > argument is known to be in denormal format. Rewrite real_isdenormal() > > for use outside of real.cc where the argument is known to be > > normalized. > > > > gcc/ChangeLog: > > > > * real.cc (real_isdenormal_target): New. > > (encode_ieee_single): Use real_isdenormal_target. > > (encode_ieee_double): Same. > > (encode_ieee_extended): Same. > > (encode_ieee_quad): Same. > > (encode_ieee_half): Same. > > (encode_arm_bfloat_half): Same. > > * value-range.cc (frange::flush_denormals_to_zero): Same. > > * real.h (real_isdenormal): Rewrite to look at mode. > > I'd make real_isdenormal_target static inline bool > rather than inline bool, it is only defined in real.cc, so there is > no point exporting it. Huh. I thought inline alone would inhibit the exporting. Thanks. > Though, as you've added the mode argument, the real.cc inline > could very well also be called real_isdenormal too, it wouldn't be > a redeclaration or ODR violation. Great, even better. OK pending tests? Aldy