Skip to content
Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
4 changes: 4 additions & 0 deletions src/infinicore/ops/infiniops_impl.hpp
Original file line number Diff line number Diff line change
Expand Up @@ -61,6 +61,8 @@ inline infini::ops::Device toInfiniOpsDevice(const Device &device) {
return infini::ops::Device{infini::ops::Device::Type::kHygon, static_cast<int>(device.getIndex())};
case Device::Type::ASCEND:
return infini::ops::Device{infini::ops::Device::Type::kAscend, static_cast<int>(device.getIndex())};
case Device::Type::ALI:
return infini::ops::Device{infini::ops::Device::Type::kThead, static_cast<int>(device.getIndex())};
default:
throw std::runtime_error("InfiniOps backend does not support this device type.");
}
Expand All @@ -75,6 +77,7 @@ inline bool isSupportedDevice(Device::Type device_type) {
case Device::Type::CAMBRICON:
case Device::Type::HYGON:
case Device::Type::ASCEND:
case Device::Type::ALI:
return true;
default:
return false;
Expand All @@ -90,6 +93,7 @@ void registerSupportedDevices(Dispatcher &dispatcher, Function function) {
dispatcher.registerDevice(Device::Type::CAMBRICON, function);
dispatcher.registerDevice(Device::Type::HYGON, function);
dispatcher.registerDevice(Device::Type::ASCEND, function);
dispatcher.registerDevice(Device::Type::ALI, function);
}

struct TensorMeta {
Expand Down
Loading