[PATCH] D69552: Move floating point related entities to namespace level

Serge Pavlov via Phabricator via llvm-commits llvm-commits at lists.llvm.org
Wed Nov 6 21:27:12 PST 2019


sepavloff marked an inline comment as done.
sepavloff added a comment.

In D69552#1735614 <https://reviews.llvm.org/D69552#1735614>, @arsenm wrote:

> I think these enums should go into the same header as added in D69598 <https://reviews.llvm.org/D69598>


It is definitely a good idea. But I would propose to move enums from `llvm/ADT/FloatingPointMode.h` in D69598 <https://reviews.llvm.org/D69598> to the file `FPEnv.h` from this patch. The directory `ADT` is for //Advanced Data Types// and contains mostly general purpose classes. On the other hand enum `DenormalMode` in that file implements representation of floating point environment. Now it is used in CodeGen, but exposing it to users seems to be natural step, as now we do not have a way to control handling denormals.

We need to agree upon file name. Initially the file was `FloatingPoint.h`, then it was renamed to `FPEnv.h` to be more specific. What is your opinion about the name?
Also we could agree whether to use namespaces or strict enums.


Repository:
  rG LLVM Github Monorepo

CHANGES SINCE LAST ACTION
  https://reviews.llvm.org/D69552/new/

https://reviews.llvm.org/D69552





More information about the llvm-commits mailing list