diff options
author | David Shah <davey1576@gmail.com> | 2019-01-21 11:10:38 +0000 |
---|---|---|
committer | GitHub <noreply@github.com> | 2019-01-21 11:10:38 +0000 |
commit | 265fa1be16f9f50b371b646fc2cf8802273d9121 (patch) | |
tree | 48d3762f63bd9ae8d59d7139255ee6e65a00fe2d | |
parent | 00c0ce81ff668783749e929a22604b4bd2aa96ca (diff) | |
parent | b274a8f8f0dc9302f14e138bdec73474283f4798 (diff) | |
download | nextpnr-265fa1be16f9f50b371b646fc2cf8802273d9121.tar.gz nextpnr-265fa1be16f9f50b371b646fc2cf8802273d9121.tar.bz2 nextpnr-265fa1be16f9f50b371b646fc2cf8802273d9121.zip |
Merge pull request #211 from smunaut/ice40_ram_attrs
ice40/pack: Copy attributes to packed cell
-rw-r--r-- | ice40/pack.cc | 4 |
1 files changed, 4 insertions, 0 deletions
diff --git a/ice40/pack.cc b/ice40/pack.cc index b963f48a..a86083b6 100644 --- a/ice40/pack.cc +++ b/ice40/pack.cc @@ -265,6 +265,8 @@ static void pack_ram(Context *ctx) std::unique_ptr<CellInfo> packed = create_ice_cell(ctx, ctx->id("ICESTORM_RAM"), ci->name.str(ctx) + "_RAM"); packed_cells.insert(ci->name); + for (auto attr : ci->attrs) + packed->attrs[attr.first] = attr.second; for (auto param : ci->params) packed->params[param.first] = param.second; packed->params[ctx->id("NEG_CLK_W")] = @@ -995,6 +997,8 @@ static void pack_special(Context *ctx) std::unique_ptr<CellInfo> packed = create_ice_cell(ctx, ctx->id("ICESTORM_SPRAM"), ci->name.str(ctx) + "_RAM"); packed_cells.insert(ci->name); + for (auto attr : ci->attrs) + packed->attrs[attr.first] = attr.second; for (auto port : ci->ports) { PortInfo &pi = port.second; std::string newname = pi.name.str(ctx); |