[PATCH] D69979: clang: Guess at some platform FTZ/DAZ default settings
Sanjay Patel via Phabricator via cfe-commits
cfe-commits at lists.llvm.org
Mon Dec 2 11:29:29 PST 2019
spatel added a subscriber: andreadb.
spatel added inline comments.
================
Comment at: clang/include/clang/Driver/ToolChain.h:580
+ /// This checks for presence of the -Ofast, -ffast-math or -funsafe-math flags.
+ virtual bool FastMathRuntimeIsAvailable(
+ const llvm::opt::ArgList &Args, std::string &Path) const;
----------------
Formatting nit - prefer to start with verb and lower-case: isFastMathRuntimeAvailable() or hasFastMathRuntime().
================
Comment at: clang/include/clang/Driver/ToolChain.h:587
/// This checks for presence of the -Ofast, -ffast-math or -funsafe-math flags.
- virtual bool AddFastMathRuntimeIfAvailable(
- const llvm::opt::ArgList &Args, llvm::opt::ArgStringList &CmdArgs) const;
+ bool AddFastMathRuntimeIfAvailable(
+ const llvm::opt::ArgList &Args, llvm::opt::ArgStringList &CmdArgs) const;
----------------
Add -> add
================
Comment at: clang/lib/Driver/ToolChains/PS4CPU.h:95-96
+ const llvm::fltSemantics *FPType) const override {
+ // DAZ and FTZ are on by default.
+ return llvm::DenormalMode::getPreserveSign();
+ }
----------------
@probinson / @andreadb - is this correct for PS4? or is there some equivalent to the Linux startup file?
CHANGES SINCE LAST ACTION
https://reviews.llvm.org/D69979/new/
https://reviews.llvm.org/D69979
More information about the cfe-commits
mailing list