VPP typically works best if configured with a relatively small number of 
buffers. On the other hand, nsim can induce a large amount of delay, so the 
buffers cannot be used to temporarily store the data. 

Florin

> On Jan 29, 2019, at 3:19 AM, Raj <rajlistu...@gmail.com> wrote:
> 
> Hello all,
> 
> While I was browsing through the nsim code (plugins/nsim),
> 
> in nsim_inline()  we are copying the packet data to ep->data like below
> 
>          clib_memcpy (ep->data, vlib_buffer_get_current (b[0]),
>                       ep->current_length);
> 
> and in nsim_input.c the same packet is transferring to TX
> 
>          clib_memcpy (b0->data, ep->data, ep->current_length)
> 
> The data is defined in the below structure
> typedef struct
> {
>  f64 tx_time;
>  u32 tx_sw_if_index;
>  u32 current_length;
>    CLIB_CACHE_LINE_ALIGN_MARK (pad);
>  u8 data[WHEEL_ENTRY_DATA_SIZE];
> } nsim_wheel_entry_t;
> 
> I am just wondering if there is any special reason why 'data' as such
> is copied here from the vlib buffer to the wheel buffer, instead of
> using the pointer(copying just the address), and thus avoiding a
> packet copy?
> 
> Is it not possible to keep the  packet in  vlib buffer itself till it
> is transmitted NIC/DPDK TX after a delay?
> 
> Thanks and Regards,
> 
> Raj
> -=-=-=-=-=-=-=-=-=-=-=-
> Links: You receive all messages sent to this group.
> 
> View/Reply Online (#12040): https://lists.fd.io/g/vpp-dev/message/12040
> Mute This Topic: https://lists.fd.io/mt/29581029/675152
> Group Owner: vpp-dev+ow...@lists.fd.io
> Unsubscribe: https://lists.fd.io/g/vpp-dev/unsub  [fcoras.li...@gmail.com]
> -=-=-=-=-=-=-=-=-=-=-=-

-=-=-=-=-=-=-=-=-=-=-=-
Links: You receive all messages sent to this group.

View/Reply Online (#12048): https://lists.fd.io/g/vpp-dev/message/12048
Mute This Topic: https://lists.fd.io/mt/29581029/21656
Group Owner: vpp-dev+ow...@lists.fd.io
Unsubscribe: https://lists.fd.io/g/vpp-dev/unsub  [arch...@mail-archive.com]
-=-=-=-=-=-=-=-=-=-=-=-

Reply via email to