mgorny added inline comments.

================
Comment at: lib/builtins/floattitf.c:65
+        if (a & ((tu_int)1 << LDBL_MANT_DIG)) {
+            a >>= 1;
+            ++e;
----------------
scanon wrote:
> Strictly speaking there's no need to adjust `a` here. If we rounded up into a 
> new binade, then `a` is necessarily `0b1000...0`, and the leading 1 bit will 
> get killed by the mask when we assemble `fb.u.high.all` regardless of its 
> position. Same comment applies to floatuntitf.
I'm sorry but I don't feel confident changing that. AFAIU if the 
LDBL_MANT_DIG+1 bit is set, this code shifts it lower, so it won't actually be 
killed by the mask.


https://reviews.llvm.org/D27898



_______________________________________________
cfe-commits mailing list
cfe-commits@lists.llvm.org
http://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

Reply via email to