基于P4C编译器后端的编译方法、系统及电子设备
By acquiring the API libraries of the P4C compiler front-end and middle-end, the IR nodes processed by the P4C middle-end are converted into JSON format data, parsed and generated into dedicated machine code firmware files, solving the problem of low performance of the P4 compiler back-end, and realizing efficient compilation and performance improvement of smart network cards.
Patent Information
- Authority / Receiving Office
- CN · China
- Patent Type
- Patents(China)
- Current Assignee / Owner
- YIHUA TECHNOLOGY (BEIJING) CO LTD
- Filing Date
- 2026-05-09
- Publication Date
- 2026-07-17
AI Technical Summary
The existing P4 compiler backend cannot efficiently compile general-purpose P4 programs into dedicated smart network card machine code, resulting in low performance efficiency of the P4 processor for hardware resources.
By acquiring the API libraries of the P4C compiler front-end and middle-end, the IR nodes processed by the P4C middle-end are converted into JSON format data, and the semantics of the P4 program are parsed to generate dedicated machine code firmware files for the Parser, the Matching Execution Unit (MAT), and the Deparser, thus realizing the IR downcompilation of the P4 program from IR to hardware machine code.
It enables the compilation of general-purpose P4 programs into dedicated machine code for smart network cards, improving the performance efficiency of the P4 processor in utilizing hardware resources and supporting in-depth optimization of network protocols.
Smart Images

Figure CN122152325B_ABST