This is an archive of the discontinued LLVM Phabricator instance.

Fix convertBFloatAPFloatToAPInt for NaN/Inf values
ClosedPublic

Authored by dcaballe on Jun 5 2020, 1:30 PM.

Details

Summary

Bfloat type has an 8-bit exponent so the exponent of NaN/Inf numbers
must be 0xff instead of 0x1f. This is probably a copy-paste mistake
from the half float type.

Diff Detail

Event Timeline

dcaballe created this revision.Jun 5 2020, 1:30 PM
Herald added a project: Restricted Project. · View Herald TranscriptJun 5 2020, 1:30 PM
lattner accepted this revision.Jun 5 2020, 1:56 PM

nice catch

This revision is now accepted and ready to land.Jun 5 2020, 1:56 PM
stuij added a comment.Jun 5 2020, 3:39 PM

Ah, awesome. Thanks :)

This revision was automatically updated to reflect the committed changes.