Return-Path: Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S964965AbVIUV3R (ORCPT ); Wed, 21 Sep 2005 17:29:17 -0400 Received: (majordomo@vger.kernel.org) by vger.kernel.org id S964968AbVIUV3R (ORCPT ); Wed, 21 Sep 2005 17:29:17 -0400 Received: from mf01.sitadelle.com ([212.94.174.68]:4764 "EHLO smtp.cegetel.net") by vger.kernel.org with ESMTP id S964965AbVIUV3Q (ORCPT ); Wed, 21 Sep 2005 17:29:16 -0400 Message-ID: <4331D0A9.3080801@cosmosbay.com> Date: Wed, 21 Sep 2005 23:29:13 +0200 From: Eric Dumazet User-Agent: Mozilla Thunderbird 1.0 (Windows/20041206) X-Accept-Language: fr, en MIME-Version: 1.0 To: linux-kernel@vger.kernel.org, netfilter-devel@lists.netfilter.org, netdev@vger.kernel.org Cc: Andi Kleen Subject: [PATCH 1/3] netfilter : 3 patches to boost ip_tables performance References: <432EF0C5.5090908@cosmosbay.com> <200509191948.55333.ak@suse.de> <432FDAC5.3040801@cosmosbay.com> <200509201830.20689.ak@suse.de> <433082DE.3060308@cosmosbay.com> <43308324.70403@cosmosbay.com> In-Reply-To: <43308324.70403@cosmosbay.com> Content-Type: multipart/mixed; boundary="------------030503000403080601080704" Sender: linux-kernel-owner@vger.kernel.org X-Mailing-List: linux-kernel@vger.kernel.org Content-Length: 13448 Lines: 205 This is a multi-part message in MIME format. --------------030503000403080601080704 Content-Type: text/plain; charset=UTF-8; format=flowed Content-Transfer-Encoding: 7bit Patch 1/3 1) No more one rwlock_t protecting the 'curtain' One major bottleneck on SMP machines is the fact that one rwlock is taken in ipt_do_table() entry and exit. That 2 atomic operations are the killer, and even if multiple readers can work together on the same table (using read_lock_bh()), the cache line containing rwlock still must be taken exclusively by each CPU at entry/exit of ipt_do_table(). As existing code already use separate copies of the data for each cpu, it is very easy to convert the central rwlock to separate rwlocks, allocated percpu (and NUMA aware). When a cpu enters ipt_do_table(), it can locks its local copy, touching a cache line that is not used by other cpus. Further operations are done on 'local' copy of the data. When a sum of all counters must be done, we can write_lock each part at a time, instead of locking all the parts, reducing the lock contention. Note1 : I also optimized get_counters(), using a SET_COUNTER() for the first cpu, avoiding a memset() and ADD_COUNTER() if SMP on other cpus. Signed-off-by: Eric Dumazet --------------030503000403080601080704 Content-Type: text/plain; name="patch_ip_tables_numa.1" Content-Transfer-Encoding: base64 Content-Disposition: inline; filename="patch_ip_tables_numa.1" LS0tIGxpbnV4LTIuNi9pbmNsdWRlL2xpbnV4L25ldGZpbHRlcl9pcHY0L2lwX3RhYmxlcy5o CTIwMDUtMDktMTMgMDU6MTI6MDkuMDAwMDAwMDAwICswMjAwCisrKyBsaW51eC0yLjYtZWQv aW5jbHVkZS9saW51eC9uZXRmaWx0ZXJfaXB2NC9pcF90YWJsZXMuaAkyMDA1LTA5LTIxIDE3 OjQyOjA3LjAwMDAwMDAwMCArMDIwMApAQCAtNDQ1LDcgKzQ0NSwxMSBAQAogCXVuc2lnbmVk IGludCB2YWxpZF9ob29rczsKIAogCS8qIExvY2sgZm9yIHRoZSBjdXJ0YWluICovCisjaWZk ZWYgQ09ORklHX1NNUAorCXJ3bG9ja190ICpsb2NrX3A7IC8qIG9uZSBsb2NrIHBlciBjcHUg Ki8KKyNlbHNlCiAJcndsb2NrX3QgbG9jazsKKyNlbmRpZgogCiAJLyogTWFuIGJlaGluZCB0 aGUgY3VydGFpbi4uLiAqLwogCXN0cnVjdCBpcHRfdGFibGVfaW5mbyAqcHJpdmF0ZTsKLS0t IGxpbnV4LTIuNi4xNC1yYzEucDEvbmV0L2lwdjQvbmV0ZmlsdGVyL2lwX25hdF9ydWxlLmMJ MjAwNS0wOS0xMyAwNToxMjowOS4wMDAwMDAwMDAgKzAyMDAKKysrIGxpbnV4LTIuNi4xNC1y YzEvbmV0L2lwdjQvbmV0ZmlsdGVyL2lwX25hdF9ydWxlLmMJMjAwNS0wOS0yMSAxNzo0NDow MS4wMDAwMDAwMDAgKzAyMDAKQEAgLTkzLDcgKzkzLDYgQ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CX0KKwlmb3JfZWFjaF9jcHUo Y3B1KQorCQlyd2xvY2tfaW5pdChwZXJfY3B1X3B0cih0YWJsZS0+bG9ja19wLCBjcHUpKTsK KyNlbHNlCisJcndsb2NrX2luaXQoJnRhYmxlLT5sb2NrKTsKKyNlbmRpZgogCW5ld2luZm8g PSB2bWFsbG9jKHNpemVvZihzdHJ1Y3QgaXB0X3RhYmxlX2luZm8pCiAJCQkgICsgU01QX0FM SUdOKHJlcGwtPnNpemUpICogbnVtX3Bvc3NpYmxlX2NwdXMoKSk7CiAJaWYgKCFuZXdpbmZv KQpAQCAtMTQ5Nyw3ICsxNjEwLDYgQEAKIAkvKiBzYXZlIG51bWJlciBvZiBpbml0aWFsIGVu dHJpZXMgKi8KIAl0YWJsZS0+cHJpdmF0ZS0+aW5pdGlhbF9lbnRyaWVzID0gdGFibGUtPnBy aXZhdGUtPm51bWJlcjsKIAotCXJ3bG9ja19pbml0KCZ0YWJsZS0+bG9jayk7CiAJbGlzdF9w cmVwZW5kKCZpcHRfdGFibGVzLCB0YWJsZSk7CiAKICB1bmxvY2s6CkBAIC0xNTE5LDYgKzE2 MzEsMTAgQEAKIAlJUFRfRU5UUllfSVRFUkFURSh0YWJsZS0+cHJpdmF0ZS0+ZW50cmllcywg dGFibGUtPnByaXZhdGUtPnNpemUsCiAJCQkgIGNsZWFudXBfZW50cnksIE5VTEwpOwogCXZm cmVlKHRhYmxlLT5wcml2YXRlKTsKKyNpZmRlZiBDT05GSUdfU01QCisJZnJlZV9wZXJjcHUo dGFibGUtPmxvY2tfcCk7CisJdGFibGUtPmxvY2tfcCA9IE5VTEw7CisjZW5kaWYKIH0KIAog LyogUmV0dXJucyAxIGlmIHRoZSBwb3J0IGlzIG1hdGNoZWQgYnkgdGhlIHJhbmdlLCAwIG90 aGVyd2lzZSAqLwo= --------------030503000403080601080704-- - To unsubscribe from this list: send the line "unsubscribe linux-kernel" in the body of a message to majordomo@vger.kernel.org More majordomo info at http://vger.kernel.org/majordomo-info.html Please read the FAQ at http://www.tux.org/lkml/