News for hackers. Stuff that matters.
Re:Float Self-Tagging by pansa2 on Wednesday November 27, 2024 @10:06PM (#42262058)
> reconfirm those bits afterwards

Thanks - I hadn't thought about that but it seems to be the main downside of this approach. The benefit of NaN-boxing is that it reassigns values that are otherwise unused - floating-point calculations will never generate NaNs with those bit patterns.

Re:Float Self-Tagging by AlotOfReading on Thursday November 28, 2024 @02:23AM (#42263237)
An additional wrinkle is that NaNs are a bit unstable and can have large performance penalties. You can't let the NaNs ever escape into arithmetic and you may even have issues even storing them in a register.