diff options
Diffstat (limited to 'machxo2/arch.cc')
-rw-r--r-- | machxo2/arch.cc | 11 |
1 files changed, 11 insertions, 0 deletions
diff --git a/machxo2/arch.cc b/machxo2/arch.cc index dbe17fd9..101ceae7 100644 --- a/machxo2/arch.cc +++ b/machxo2/arch.cc @@ -518,4 +518,15 @@ void Arch::assignArchInfo() {} bool Arch::cellsCompatible(const CellInfo **cells, int count) const { return false; } +std::vector<std::pair<std::string, std::string>> Arch::getTilesAtLocation(int row, int col) +{ + std::vector<std::pair<std::string, std::string>> ret; + auto &tileloc = chip_info->tile_info[row * chip_info->width + col]; + for (int i = 0; i < tileloc.num_tiles; i++) { + ret.push_back(std::make_pair(tileloc.tile_names[i].name.get(), + chip_info->tiletype_names[tileloc.tile_names[i].type_idx].get())); + } + return ret; +} + NEXTPNR_NAMESPACE_END |