anijain2305 commented on a change in pull request #4873: [Relay][FastMath] 
Relay pass to use fast exp/tanh
URL: https://github.com/apache/incubator-tvm/pull/4873#discussion_r378589877
 
 

 ##########
 File path: src/relay/backend/build_module.cc
 ##########
 @@ -307,6 +307,10 @@ class RelayBuildModule : public runtime::ModuleNode {
     }
     pass_seqs.push_back(transform::FoldConstant());
 
+    // Fast math optimizations.
+    pass_seqs.push_back(transform::FastMath());
+    pass_seqs.push_back(transform::FoldConstant());
 
 Review comment:
   OR I can just move the FastMath before the previous FoldConstant.
   
   I don't think FastMath brings any new const in the graph. I just put it 
there because FastMath becomes the last pass before FuseOps, and we want the 
graph to be fully optimized.

----------------------------------------------------------------
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.
 
For queries about this service, please contact Infrastructure at:
us...@infra.apache.org


With regards,
Apache Git Services

Reply via email to