google / cairn

Apache License 2.0
4 stars 3 forks source link

Be cautious about parser node merging #9

Open XiangyuG opened 10 months ago

XiangyuG commented 10 months ago

Some passes in p4c frontend will automatically merge 2 parser node into one. However, this could not be taken for granted if we consider the hardware constraints of the backend. For instance, there could be some limit over the # of extractions per parser node or the total extraction bit length per parser node.

We could remain the existing pass in the frontend for now and deal with "HUGE" parser node in later passes by splitting it into multiple ones.

DKLoehr commented 10 months ago

We're going to need a pass to break up overlarge states anyway, so I don't think we need to worry about making states too large early in the process.