From owner-soc-status@FreeBSD.ORG Mon Jun 6 16:52:19 2011 Return-Path: Delivered-To: soc-status@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:4f8:fff6::34]) by hub.freebsd.org (Postfix) with ESMTP id 186F51065672 for ; Mon, 6 Jun 2011 16:52:19 +0000 (UTC) (envelope-from gockzy@gmail.com) Received: from mail-ew0-f54.google.com (mail-ew0-f54.google.com [209.85.215.54]) by mx1.freebsd.org (Postfix) with ESMTP id 76A368FC13 for ; Mon, 6 Jun 2011 16:52:18 +0000 (UTC) Received: by ewy1 with SMTP id 1so2087921ewy.13 for ; Mon, 06 Jun 2011 09:52:17 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=gamma; h=domainkey-signature:mime-version:from:date:message-id:subject:to:cc :content-type; bh=a28PE4yt+iuksAj2X1VvbMoIIZRRrfLN3V240IXPkxY=; b=fGc2A+u42zZc8oW02RZF5+MtXslqtNqFg3jBp2kiTKOFjJDyFJaPBiCkVwfd5FIJ4B UJKOoJWmS/J59yq4qFOobf3Uo2yLPp4PK+OQzKLSAmApR3XlDeUpYz1lJZO+2oC5OwX4 N4qh455zvyLbEOs4tNHHf9FHws62ASkRW2pbE= DomainKey-Signature: a=rsa-sha1; c=nofws; d=gmail.com; s=gamma; h=mime-version:from:date:message-id:subject:to:cc:content-type; b=JT/uNw2ym6Bj84+jpBzFbhFqiqJD/ZFkkQhiQUIcmDWaGGfPJwzZ4EvTx0esoZNYZo 2yWtOYFTwSJBkHHoUWeJi8RpVmya8k9LfBUcW0ZfKg1h5UgTDxj+tTG3O8ZhQdtyknTP NsEUQ0ZNwLkz7OizxJqxCB5lMZEsfF1cRSXP4= Received: by 10.213.21.141 with SMTP id j13mr1997905ebb.109.1307379137158; Mon, 06 Jun 2011 09:52:17 -0700 (PDT) MIME-Version: 1.0 Received: by 10.213.29.206 with HTTP; Mon, 6 Jun 2011 09:51:57 -0700 (PDT) From: Kazuya Goda Date: Tue, 7 Jun 2011 01:51:57 +0900 Message-ID: To: soc-status@freebsd.org Content-Type: text/plain; charset=ISO-8859-1 Cc: Takuya ASADA , "Robert N. M. Watson" Subject: [status report] RPS/RFS #week2 X-BeenThere: soc-status@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: Summer of Code Status Reports and Discussion List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Mon, 06 Jun 2011 16:52:19 -0000 Hi, The goal of my project is to implement RPS/RFS on FreeBSD. RPS solves the problem of mono-queue NIC which can't distribute packets across multiple processors. This week status: * Implement RPS act this: 1. get IP address and TCP port in Ethernet layer 2. calculate hash from IP address and TCP port 3. assign hash value to m->pkthdr.flowid 4. enable M_FLOWID flags in m->m_flags I added this process in ether_demux(). I used rss_hash_ip_4tuple() from //depot/users/rwatson/tcp/... branch to calculating hash value. I think I'd like to share functions of calculating hash value with RSS. * Test - Confirm to select CPU Enable RPS, pakcets are distributed other CPU on IP layer. At this time, same flow is distributed same CPU. So, I printed below values to comfirm. -- In netisr_select_cpuid() : m->pkthdr.flowid (flowid) , cpuid (destination CPU) -- In ip_input() : m->pkthdr.flowid (flowid), curcpu (current CPU) I confirmed that if flowid is the same, destination CPU is equal to current CPU. - Simplified benchmark test I used netperf to benchmark test. Server environment is: CPU : Xeon E5310@1.6GHz x2(total 8 core) NIC : e1000 (interface : PCI) Below is result running 300 instances of netperf TCP_RR test with 1 byte req. and resp. In both cases, net.isr.numthreads is 8. -- Result -- Without RPS : 132 tps With RPS : 230 tps *known problem In the case of net.isr.numthreads < CPU_NUM, connection is not closed at high load. * Next week - Search for a cause "known problem" - Implement IPv6, UDP support Regards, Kazuya Goda