AndrewZhaoLuo commented on a change in pull request #9223:
URL: https://github.com/apache/tvm/pull/9223#discussion_r731335329



##########
File path: src/target/llvm/llvm_common.cc
##########
@@ -106,10 +106,23 @@ void ParseLLVMTargetOptions(const Target& target, 
std::string* triple, std::stri
 #if TVM_LLVM_VERSION < 50
   opt.LessPreciseFPMADOption = true;
 #endif
-  opt.AllowFPOpFusion = llvm::FPOpFusion::Fast;
-  opt.UnsafeFPMath = false;
-  opt.NoInfsFPMath = false;
+  // We depend on generating IR with proper fast math flags to control fast 
math
+  // semantics. These just enable these optimizations if the proper IR flags
+  // are set.
+  opt.UnsafeFPMath = true;
+  opt.NoInfsFPMath = true;

Review comment:
       Hmm, yes these settings in Clang are passed in from LangOpts which 
describe the dialect of C or C++ that is accepted. Don't understand it fully 
and don't want to change the specification here so turned it off.




-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: [email protected]

For queries about this service, please contact Infrastructure at:
[email protected]


Reply via email to