From ce55c0ff7e2a9f3bda35ca3683651b61150bc4e1 Mon Sep 17 00:00:00 2001 From: Predrag Ilkic Date: Fri, 16 Aug 2024 17:20:15 +0200 Subject: [PATCH] fix parsing of ChipPhysicalCoresAttr Removing commas from `assemblyFormat` so that the parsing of multiple optional groups works. It seems that there isn't great support for this kind of parsing in mlir... --- include/ttmlir/Dialect/TT/IR/TTOpsTypes.td | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/include/ttmlir/Dialect/TT/IR/TTOpsTypes.td b/include/ttmlir/Dialect/TT/IR/TTOpsTypes.td index a9b211eaa..413f5becf 100644 --- a/include/ttmlir/Dialect/TT/IR/TTOpsTypes.td +++ b/include/ttmlir/Dialect/TT/IR/TTOpsTypes.td @@ -69,7 +69,7 @@ def TT_ChipPhysicalCoresAttr : TT_Attr<"ChipPhysicalCores", "chip_physical_cores }]; let parameters = (ins ArrayRefParameter<"CoreCoordAttr">:$worker, ArrayRefParameter<"CoreCoordAttr">:$dram, OptionalArrayRefParameter<"CoreCoordAttr">:$eth, OptionalArrayRefParameter<"CoreCoordAttr">:$eth_inactive); - let assemblyFormat = "`{` `worker` `=` `[` $worker `]` `,` `dram` `=` `[` $dram `]` (`,` `eth` `=` `[` $eth^ `]`)? (`,` `eth_inactive` `=` `[` $eth_inactive^ `]`)? `}`"; + let assemblyFormat = "`{` `worker` `=` `[` $worker `]` `dram` `=` `[` $dram `]` (`eth` `=` `[` $eth^ `]`)? (`eth_inactive` `=` `[` $eth_inactive^ `]`)? `}`"; } def TT_ChipDescAttr : TT_Attr<"ChipDesc", "chip_desc"> {