[PYTHON] [OPS] Added einsum implementation

This commit is contained in:
Philippe Tillet
2019-10-26 22:14:50 -04:00
parent 655f43fb5b
commit e11557855f
5 changed files with 183 additions and 44 deletions

View File

@@ -187,12 +187,12 @@ generator::generator(analysis::axes *a_axes,
void generator::visit_value(ir::value* v) {
std::cout << "visiting " << typeid(*v).name() << std::endl;
if(!seen_.insert(v).second)
return;
// create machine tile
if(v->get_type()->is_tile_ty())
if(v->get_type()->is_tile_ty()){
tmap_[v] = machine_layouts_.at(layouts_->get(v))->create(v);
}
// visit operands
BasicBlock *current = builder_->GetInsertBlock();
auto *inst = dynamic_cast<ir::instruction*>(v);