Commit 46f0b67c by 雾雨魔理沙 Committed by Yizhi Liu

Fix error reporting for missing axis (#2835)

* Fix error reporting for missing axis

* Update data_layout.cc
parent db5bfa3c
......@@ -5,6 +5,7 @@
*/
#include <tvm/data_layout.h>
#include <tvm/ir_pass.h>
#include <cctype>
namespace tvm {
......@@ -115,7 +116,7 @@ Layout::Layout(const std::string& name) { // NOLINT(*)
char axis = v->var.get()->name_hint[0];
if (axis >= 'a' && axis <= 'z') {
CHECK(exist_axis[axis-'a'+'A']) << "Invalid layout " << name << ": missing axis "
<< axis - 'a' + 'A';
<< std::toupper(axis);
}
}
}
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment