Skip to content

Commit

Permalink
Revert commit
Browse files Browse the repository at this point in the history
  • Loading branch information
jcf94 committed Jun 24, 2020
1 parent 14a19cd commit 59c88d1
Show file tree
Hide file tree
Showing 36 changed files with 31 additions and 4,188 deletions.
1 change: 0 additions & 1 deletion docs/conf.py
Original file line number Diff line number Diff line change
Expand Up @@ -198,7 +198,6 @@
'../tutorials/language',
'../tutorials/optimize',
'../tutorials/autotvm',
'../tutorials/ansor',
'../tutorials/dev',
'../tutorials/topi',
'../tutorials/deployment',
Expand Down
13 changes: 0 additions & 13 deletions include/tvm/relay/attrs/transform.h
Original file line number Diff line number Diff line change
Expand Up @@ -296,19 +296,6 @@ struct LayoutTransformAttrs : public tvm::AttrsNode<LayoutTransformAttrs> {
}
};

/*! \brief Attributes for KernelLayoutTransform operator */
struct KernelLayoutTransformAttrs : public tvm::AttrsNode<KernelLayoutTransformAttrs> {
std::string src_layout;
std::string dst_layout;

TVM_DECLARE_ATTRS(KernelLayoutTransformAttrs, "relay.attrs.KernelLayoutTransformAttrs") {
TVM_ATTR_FIELD(src_layout)
.describe("The source layout of the tensor. (e.g. 1N32C112H112W)");
TVM_ATTR_FIELD(dst_layout)
.describe("The destination layout of the tensor. (e.g. 1N2C112H112W16c)");
}
};

/*! \brief Attributes for ShapeOf operator */
struct ShapeOfAttrs : public tvm::AttrsNode<ShapeOfAttrs> {
DataType dtype;
Expand Down
14 changes: 0 additions & 14 deletions include/tvm/relay/transform.h
Original file line number Diff line number Diff line change
Expand Up @@ -277,20 +277,6 @@ TVM_DLL Pass CanonicalizeOps();
*/
TVM_DLL Pass AlterOpLayout();

/*!
* \brief Alternate the layouts of kernels.
*
* \return The pass.
*/
TVM_DLL Pass KernelLayoutTransform();

/*!
* \brief The reverse of FuseOps.
*
* \return The pass.
*/
TVM_DLL Pass DeFuseOps();

/*!
* \brief Given a dest layout, this pass transforms the expr such that most of the ops input data
* layout is changed to the dest layout. In ideal situation, there are only 2 layout transforms, one
Expand Down
23 changes: 0 additions & 23 deletions include/tvm/runtime/c_runtime_api.h
Original file line number Diff line number Diff line change
Expand Up @@ -384,29 +384,6 @@ TVM_DLL int TVMFuncListGlobalNames(int* out_size, const char*** out_array);
TVM_DLL int TVMArrayAlloc(const tvm_index_t* shape, int ndim, int dtype_code, int dtype_bits,
int dtype_lanes, int device_type, int device_id, TVMArrayHandle* out);

/*!
* \brief Allocate a nd-array's memory of non-empty values,
* including space of shape, of given spec.
*
* \param shape The shape of the array, the data content will be copied to out
* \param ndim The number of dimension of the array.
* \param dtype_code The type code of the dtype
* \param dtype_bits The number of bits of dtype
* \param dtype_lanes The number of lanes in the dtype.
* \param device_type The device type of context
* \param device_id The device id of context.
* \param out The output handle.
* \return 0 when success, -1 when failure happens
*/
TVM_DLL int TVMArrayAllocNonEmpty(const tvm_index_t* shape,
int ndim,
int dtype_code,
int dtype_bits,
int dtype_lanes,
int device_type,
int device_id,
TVMArrayHandle* out);

/*!
* \brief Free the TVM Array.
* \param handle The array handle to be freed.
Expand Down
3 changes: 1 addition & 2 deletions include/tvm/runtime/device_api.h
Original file line number Diff line number Diff line change
Expand Up @@ -44,8 +44,7 @@ enum DeviceAttrKind : int {
kMaxClockRate = 6,
kMultiProcessorCount = 7,
kMaxThreadDimensions = 8,
kGcnArch = 9,
kMaxRegistersPerBlock = 10
kGcnArch = 9
};

/*! \brief Number of bytes each allocation must align to */
Expand Down
12 changes: 1 addition & 11 deletions include/tvm/runtime/ndarray.h
Original file line number Diff line number Diff line change
Expand Up @@ -138,17 +138,7 @@ class NDArray : public ObjectRef {
* \param ctx The context of the Array.
* \return The created Array
*/
TVM_DLL static NDArray Empty(std::vector<int64_t> shape,
DLDataType dtype, DLContext ctx);
/*!
* \brief Create an NDArray with non-empty values.
* \param shape The shape of the new array.
* \param dtype The data type of the new array.
* \param ctx The context of the Array.
* \return The created Array
*/
TVM_DLL static NDArray NonEmpty(std::vector<int64_t> shape,
DLDataType dtype, DLContext ctx);
TVM_DLL static NDArray Empty(std::vector<int64_t> shape, DLDataType dtype, DLContext ctx);
/*!
* \brief Create a NDArray backed by a dlpack tensor.
*
Expand Down
Loading

0 comments on commit 59c88d1

Please sign in to comment.