Closed suriyakode closed 5 years ago
How is normal code supposed to differ from architecture-specific code?
Ahh okay, basically there were a round of frontend passes that modified the structure before I called ToP4. I have resolved my problem and will close the issue.
When I read a tofino-16 P4 program and build the IR using the open source P4C compiler, the output using P4::ToP4 is always appearing as normal P4-16 code rather than being architecture dependant. I tried this by adding both a ToP4 visitor pass as well as using --top4 option included on some of the executables. My understanding is that the outputted program should be for the same architecture as the inputted program, which doesn't seem to be the case.