You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@tvm.apache.org by tq...@apache.org on 2020/07/16 02:23:04 UTC
[incubator-tvm] branch master updated: Fix error message in
Buffer::vstore, NFC (#6056)
This is an automated email from the ASF dual-hosted git repository.
tqchen pushed a commit to branch master
in repository https://gitbox.apache.org/repos/asf/incubator-tvm.git
The following commit(s) were added to refs/heads/master by this push:
new dff715a Fix error message in Buffer::vstore, NFC (#6056)
dff715a is described below
commit dff715a54ee0f02f27b4f4efde08c77e86eff2d2
Author: Krzysztof Parzyszek <kp...@quicinc.com>
AuthorDate: Wed Jul 15 21:22:56 2020 -0500
Fix error message in Buffer::vstore, NFC (#6056)
* Fix error message in Buffer::vstore, NFC
* Fix whitespace in comment as well
---
src/tir/ir/buffer.cc | 6 +++---
1 file changed, 3 insertions(+), 3 deletions(-)
diff --git a/src/tir/ir/buffer.cc b/src/tir/ir/buffer.cc
index e9f65ee..00e3335 100644
--- a/src/tir/ir/buffer.cc
+++ b/src/tir/ir/buffer.cc
@@ -283,7 +283,7 @@ inline PrimExpr BufferOffset(const BufferNode* n, Array<PrimExpr> index, DataTyp
}
PrimExpr Buffer::vload(Array<PrimExpr> begin, DataType dtype) const {
- // specially handle bool, stored asDataType::Int(8)
+ // specially handle bool, stored as DataType::Int(8)
const BufferNode* n = operator->();
CHECK(dtype.element_of() == n->dtype.element_of() && dtype.lanes() % n->dtype.lanes() == 0)
<< "Cannot load " << dtype << " from buffer of " << n->dtype;
@@ -297,11 +297,11 @@ PrimExpr Buffer::vload(Array<PrimExpr> begin, DataType dtype) const {
}
Stmt Buffer::vstore(Array<PrimExpr> begin, PrimExpr value) const {
- // specially handle bool, stored asDataType::Int(8)
+ // specially handle bool, stored as DataType::Int(8)
const BufferNode* n = operator->();
DataType dtype = value.dtype();
CHECK(dtype.element_of() == n->dtype.element_of() && dtype.lanes() % n->dtype.lanes() == 0)
- << "Cannot load " << dtype << " from buffer of " << n->dtype;
+ << "Cannot store " << dtype << " to buffer of " << n->dtype;
if (value.dtype() == DataType::Bool()) {
return tir::Store(n->data, tir::Cast(DataType::Int(8), value),
BufferOffset(n, begin, DataType::Int(8)), const_true());