[P4-dev] runtime_CLI.py in C/C++
antonin at barefootnetworks.com
Mon May 22 13:36:11 EDT 2017
What I meant is that this Thrift API is only available on bmv2. It is not
standardized and is not implemented on any other P4-programmable target
(e.g. P4 ASIC, P4 NIC,...). So any application code that you write would
not be usable on other P4 targets. However, for the purpose of a simulation
including exclusively bmv2 nodes, it is just fine.
On Mon, May 22, 2017 at 10:33 AM, Andreas Pantelopoulos <
padelopoulos at gmail.com> wrote:
> Thanks for the prompt answer. What exactly do you mean by " bmv2 Thrift
> API is not meant to be portable" ? What I want to achieve is port the
> simple_switch in the ns3 simulator so as to run simulations that involve p4
> switches *almost* automatically. To do that, all the binaries should be
> compiled in a specific manner. Since, runtime_CLI.py is in python, it is
> not compiled. I tried converting in C and then compiling but that has other
> Thanks for the code link!
> On Mon, May 22, 2017 at 7:26 PM, Antonin Bas <antonin at barefootnetworks.com
> > wrote:
>> I am not aware of a C++ equivalent of the runtime_CLI. The bmv2 Thrift
>> API is not meant to be portable and is not available on other P4 targets,
>> so you should probably keep that in mind.
>> There is an example of a small C++ client implementing a control-plane
>> for L2 switching here: https://github.com/p4lan
>> client/learn_client.cpp. It is only meant to be used with l2_switch.p4
>> but can be adapted for other P4 programs.
>> On Mon, May 22, 2017 at 10:12 AM, Andreas Pantelopoulos <
>> padelopoulos at gmail.com> wrote:
>>> I am wondering if you have developed any other thrift client for the
>>> behavioral model in C or C++. It might as well be not fully functional or
>>> just a draft.
>>> Thanks a lot,
>>> P4-dev mailing list
>>> P4-dev at lists.p4.org
-------------- next part --------------
An HTML attachment was scrubbed...
More information about the P4-dev