You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@tvm.apache.org by GitBox <gi...@apache.org> on 2021/04/16 05:55:47 UTC
[GitHub] [tvm] junrushao1994 commented on a change in pull request #7809: [Target][Lowering] Update Op Intrinsic Lowering Mechanism And Intrinsic Lowering Pass
junrushao1994 commented on a change in pull request #7809:
URL: https://github.com/apache/tvm/pull/7809#discussion_r614576312
##########
File path: include/tvm/tir/op_attr_types.h
##########
@@ -28,11 +28,13 @@
#ifndef TVM_TIR_OP_ATTR_TYPES_H_
#define TVM_TIR_OP_ATTR_TYPES_H_
+#include <tvm/ir/expr.h>
Review comment:
No need for this
##########
File path: include/tvm/tir/op_attr_types.h
##########
@@ -28,11 +28,13 @@
#ifndef TVM_TIR_OP_ATTR_TYPES_H_
#define TVM_TIR_OP_ATTR_TYPES_H_
+#include <tvm/ir/expr.h>
#include <tvm/runtime/container.h>
+#include <tvm/runtime/packed_func.h>
namespace tvm {
namespace tir {
-
+using namespace runtime;
Review comment:
No need for this
##########
File path: include/tvm/tir/op_attr_types.h
##########
@@ -43,6 +45,11 @@ using TGlobalSymbol = String;
*/
using TVectorizable = bool;
+/*!
+ * \brief The intrinsic lowering function for given OP.
+ */
+using FLowerIntrinsic = PackedFunc;
Review comment:
Using `runtime::TypedPackedFunc` when possible, which is a simple wrapper of `PackedFunc`, but with the clear signature like `std::function`, so it could help readability :-)
--
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:
users@infra.apache.org