[dpdk-dev] Appropriate DPDK data structures for TCP sockets

2015-03-13 Thread Matthew Hall
On Mon, Feb 23, 2015 at 11:51:46PM +0200, Avi Kivity wrote: > https://github.com/cloudius-systems/seastar Hi Avi and others, My code unintentionally ended up looking somewhat like a C version of your seastar C++ code, even though I didn't really look at yours too much when I coded mine as it

[dpdk-dev] Appropriate DPDK data structures for TCP sockets

2015-02-23 Thread Avi Kivity
On 02/23/2015 11:16 PM, Matthew Hall wrote: > On Mon, Feb 23, 2015 at 08:48:57AM -0600, Matt Laswell wrote: >> Apologies in advance for likely being a bit long-winded. > Long winded is great, helps me get context. > >> First, you really need to take cache performance into account when you're >>

[dpdk-dev] Appropriate DPDK data structures for TCP sockets

2015-02-23 Thread Matthew Hall
On Mon, Feb 23, 2015 at 08:48:57AM -0600, Matt Laswell wrote: > Apologies in advance for likely being a bit long-winded. Long winded is great, helps me get context. > First, you really need to take cache performance into account when you're > choosing a data structure. Something like a balanced

[dpdk-dev] Appropriate DPDK data structures for TCP sockets

2015-02-23 Thread Matt Laswell
Hey Matthew, I've mostly worked on stackless systems over the last few years, but I have done a fair bit of work on high performance, highly scalable connection tracking data structures. In that spirit, here are a few counterintuitive insights I've gained over the years. Perhaps they'll be

[dpdk-dev] Appropriate DPDK data structures for TCP sockets

2015-02-22 Thread Matthew Hall
On Feb 22, 2015, at 4:02 PM, Stephen Hemminger wrote: > Use userspace RCU? or BSD RB_TREE Thanks Stephen, I think the RB_TREE stuff is single threaded mostly. But user-space RCU looks quite good indeed, I didn't know somebody ported it out of the kernel. I'll check it out. Matthew.

[dpdk-dev] Appropriate DPDK data structures for TCP sockets

2015-02-22 Thread Stephen Hemminger
On Sat, 21 Feb 2015 16:38:45 -0800 Matthew Hall wrote: > So far I was using rte_hash, but it's single writer multi reader, which is > eventually going to need some more complicated locking and probably run kind > of slow. Also, I need some timer functions to delete dead sockets and so >

[dpdk-dev] Appropriate DPDK data structures for TCP sockets

2015-02-21 Thread Matthew Hall
Hello fellow stack hackers :) , I'm working on a simple server-side implementation of TCP on DPDK. For this to work I need a good data structure to store some sockets. The lookup key is like this: struct ss_flow_key_s { uint8_t sip[IPV6_ALEN]; uint8_t dip[IPV6_ALEN]; uint16_t