[PATCH] D69878: Consoldiate internal denormal flushing controls
Matt Arsenault via Phabricator via cfe-commits
cfe-commits at lists.llvm.org
Thu Nov 7 13:09:28 PST 2019
arsenm marked an inline comment as done.
arsenm added a comment.
In D69878#1736865 <https://reviews.llvm.org/D69878#1736865>, @Anastasia wrote:
> > Stop emitting the denorms-are-zero attribute for the OpenCL flag. It
> > has no in-tree users. The meaning would also be target dependent, such
> > as the AMDGPU choice to treat this as only meaning allow flushing of
> > f32 and not f16 or f64. The naming is also potentially confusing,
> > since DAZ in other contexts refers to instructions implicitly treating
> > input denormals as zero, not necessarily flushing output denormals to
> > zero.
>
> Would the targets supporting OpenCL need to define their own behavior in `getDefaultDenormalModeForType`?
Yes. The future ieee default should be conservatively correct though
================
Comment at: clang/include/clang/Driver/ToolChain.h:619
+ const llvm::fltSemantics *FPType = nullptr) const {
+ // FIXME: This should be IEEE when default handling is fixed.
+ return llvm::DenormalMode::Invalid;
----------------
Anastasia wrote:
> Can you elaborate what has to be done in order to fix this?
The main problem is the current user assumes non-ieee by default. The main blocker is knowing what platforms should default to something different to avoid performance regressions. I have the patch almost ready to switch the default, it’s just missing toolchain overrides
CHANGES SINCE LAST ACTION
https://reviews.llvm.org/D69878/new/
https://reviews.llvm.org/D69878
More information about the cfe-commits
mailing list