HomePhabricator

[libc] Add a class called NormalFloat which represents normalized floats.

Authored by sivachandra on Aug 19 2020, 1:08 AM.

Description

[libc] Add a class called NormalFloat which represents normalized floats.

This class helps in dealing with normal and subnormal numbers uniformly.
Moreover, since this class has been designed to handle all floating
formats across platforms, it helps implement floating point functions in
a uniform manner.

The implementations of frexp and logb have been switched to use this new
class as it allows us to use just one implementation across all
different floating point formats.

Reviewed By: lntue

Differential Revision: https://reviews.llvm.org/D86241

Details

Committed
sivachandraAug 20 2020, 9:00 AM
Reviewer
lntue
Differential Revision
D86241: [libc] Add a class called NormalFloat which represents normalized floats.
Parents
rG4aaf77254296: [PeepholeOptimizer] Remove dead code
Branches
Unknown
Tags
Unknown