From owner-freebsd-performance@FreeBSD.ORG Sun Dec 9 01:19:42 2007 Return-Path: Delivered-To: freebsd-performance@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:4f8:fff6::34]) by hub.freebsd.org (Postfix) with ESMTP id DF00716A417; Sun, 9 Dec 2007 01:19:42 +0000 (UTC) (envelope-from stas@ht-systems.ru) Received: from com1.ht-systems.ru (mr1.ht-systems.ru [78.110.50.56]) by mx1.freebsd.org (Postfix) with ESMTP id 94CD913C455; Sun, 9 Dec 2007 01:19:42 +0000 (UTC) (envelope-from stas@ht-systems.ru) Received: from quasar.ht-systems.ru ([78.110.49.49]) by com1.ht-systems.ru with esmtp (Exim 4.62) (envelope-from ) id 1J19xs-0003wE-5u; Sun, 09 Dec 2007 03:24:12 +0300 Received: from quasar.ht-systems.ru (localhost [127.0.0.1]) by quasar.ht-systems.ru (8.14.1/8.14.1) with ESMTP id lB90OJku058485; Sun, 9 Dec 2007 03:24:19 +0300 (MSK) (envelope-from stas@quasar.ht-systems.ru) Received: (from stas@localhost) by quasar.ht-systems.ru (8.14.1/8.14.1/Submit) id lB90OGP7058468; Sun, 9 Dec 2007 03:24:16 +0300 (MSK) (envelope-from stas) Date: Sun, 9 Dec 2007 03:24:16 +0300 From: Stanislav Sedov To: Philipp Wuensche Message-ID: <20071209002416.GD2044@dracon.ht-systems.ru> References: <4755ED57.6030603@h3q.com> <20071204195131.56cb1307.wmoran@collaborativefusion.com> <4755FAD8.5030805@h3q.com> <4756BDC1.2070802@h3q.com> MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: <4756BDC1.2070802@h3q.com> Organization: The FreeBSD Project X-Voice: +7 916 849 20 23 X-XMPP: ssedov@jabber.ru X-Yahoo: stanislav_sedov X-PGP-Fingerprint: F21E D6CC 5626 9609 6CE2 A385 2BF5 5993 EB26 9581 X-University: MEPhI X-Mailer: carrier-pigeon X-Operating-System: FreeBSD quasar.ht-systems.ru 7.0-BETA2 FreeBSD 7.0-BETA2 Cc: Adrian Chadd , "freebsd-performance@freebsd.org" Subject: Re: tuning for high connection rates X-BeenThere: freebsd-performance@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: Performance/tuning List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Sun, 09 Dec 2007 01:19:43 -0000 On Wed, Dec 05, 2007 at 04:03:29PM +0100 Philipp Wuensche mentioned: > Adrian Chadd wrote: > > On 05/12/2007, Philipp Wuensche wrote: > > > >> As I understand it, and correct me if I'm wrong, polling helps against > >> high interrupt rates but for that intel gigabit cards have interrupt > >> moderation. We don't have a problem with interrupts (20% CPU) at the > >> moment but with system (100% CPU) as you can see in the system > >> monitoring graphs. Interrupts sometimes peak at, but usually are under, > >> the 2k interrupts/sec limit. > > > > Begin by reading up on the hardware profiling support (hwpmc, pmc, > > etc) and see if you can get some system and process-specific profiling > > information. > > Oh interesting stuff, I definitely have to take a look into that. Nice. > You can find a good tutorial on hwpmc by Robert Watson here: http://lists.freebsd.org/pipermail/freebsd-current/2006-February/061096.html -- Stanislav Sedov ST4096-RIPE From owner-freebsd-performance@FreeBSD.ORG Thu Dec 13 12:34:33 2007 Return-Path: Delivered-To: freebsd-performance@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:4f8:fff6::34]) by hub.freebsd.org (Postfix) with ESMTP id C3DC116A417 for ; Thu, 13 Dec 2007 12:34:33 +0000 (UTC) (envelope-from shantanu_ghosh@yahoo.com) Received: from web54505.mail.re2.yahoo.com (web54505.mail.re2.yahoo.com [206.190.49.155]) by mx1.freebsd.org (Postfix) with SMTP id 567BF13C44B for ; Thu, 13 Dec 2007 12:34:33 +0000 (UTC) (envelope-from shantanu_ghosh@yahoo.com) Received: (qmail 78488 invoked by uid 60001); 13 Dec 2007 12:07:51 -0000 DomainKey-Signature: a=rsa-sha1; q=dns; c=nofws; s=s1024; d=yahoo.com; h=X-YMail-OSG:Received:Date:From:Subject:To:MIME-Version:Content-Type:Content-Transfer-Encoding:Message-ID; b=Tlo5u60hqVVf5q8WnLGFN2vrKndRyirnncPqAjBa0jgjVGbuvpwl9cnDCy6lpqkj7SgQFUuk0rrK35aZAvfyGe0VA93lEtOH2HeTT757BKoT4C90BsGtQyN/RTRyaNPttIyzgaVKRA1cH9a0Cm3Hvgv8/HHhmSbFtjS2orBqfok=; X-YMail-OSG: ritwFiIVM1nCzwJSCOExbep_K129GAHvLC6.6H6uAldPAP3vlfuwaGolykuduvdfbbgnVsXC7BbXhok5FbwU6N1ACxVPMWotfkIQhzuAP4w_go8PEt4- Received: from [203.145.181.122] by web54505.mail.re2.yahoo.com via HTTP; Thu, 13 Dec 2007 04:07:50 PST Date: Thu, 13 Dec 2007 04:07:50 -0800 (PST) From: Shantanu Ghosh To: freebsd-performance@freebsd.org MIME-Version: 1.0 Content-Type: text/plain; charset=iso-8859-1 Content-Transfer-Encoding: 8bit Message-ID: <963530.77689.qm@web54505.mail.re2.yahoo.com> Subject: freebsd vs linux: performance problem X-BeenThere: freebsd-performance@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: Performance/tuning List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Thu, 13 Dec 2007 12:34:33 -0000 Hi, I am running FreeBSD 7.0 Beta1 and Linux FC6 on two identical pieces of hardware - Dell poweredge with intel core2 duo. Each system has 4 CPUs. Now, in simple memory access operations, I see the freebsd system being noticably slower than the linux system. A simple C program that copies from one memory buffer to another, when executed in a loop executes between 10-30% slower on freebsd, as compared to linux. The assembly code of the program used for testing is identical in both the cases. One observation is that freebsd system performance decreases as the size of the buffer increases. If the buffer is under 1k, both the sytems give the same performance. freebsd performance is about 10% slower if the buffer size is around 4k, and about 30% slower if the buffer is around 1Mb. A benchmark like sysbench memory read operation performs miserably on the freebsd system, compared to linux. As far as I can see, the BIOS settings are identical on both the machines. Any idea what could be going on? Thanks and regards. -- Shantanu. ____________________________________________________________________________________ Never miss a thing. Make Yahoo your home page. http://www.yahoo.com/r/hs From owner-freebsd-performance@FreeBSD.ORG Thu Dec 13 14:00:25 2007 Return-Path: Delivered-To: freebsd-performance@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:4f8:fff6::34]) by hub.freebsd.org (Postfix) with ESMTP id C1F8616A468 for ; Thu, 13 Dec 2007 14:00:25 +0000 (UTC) (envelope-from trashy_bumper@yahoo.com) Received: from web36306.mail.mud.yahoo.com (web36306.mail.mud.yahoo.com [209.191.91.183]) by mx1.freebsd.org (Postfix) with SMTP id 6651C13C4D9 for ; Thu, 13 Dec 2007 14:00:25 +0000 (UTC) (envelope-from trashy_bumper@yahoo.com) Received: (qmail 49732 invoked by uid 60001); 13 Dec 2007 13:33:44 -0000 DomainKey-Signature: a=rsa-sha1; q=dns; c=nofws; s=s1024; d=yahoo.com; h=X-YMail-OSG:Received:X-Mailer:Date:From:Subject:To:MIME-Version:Content-Type:Message-ID; b=fP5IObhMBZt67kFnNpNPWTRoMns7nuHIa8hK1ZbGOr4o0qwJ4a52cHZJhZSIfdZ1NihmsegCYwAQBxCcCbJnbbLFHWHWNZxzrcae9ZGBs/Spz+SrmagU+LOx7QntKT8lvotqOZlO6gvG3QkXdcCsYB/gNh6UPDGYj4x4xY2VVAo=; X-YMail-OSG: BidPoC0VM1lNXzYZHxAw2ih489m7sSio5Y9GDvPIzRN4rn0CbKmce_4RPAztifkKUpGaxMyrM.tNy5Otiq7OZXctUS7mnIxf.DN_2kqPngMMDdtm7R4- Received: from [77.122.205.244] by web36306.mail.mud.yahoo.com via HTTP; Thu, 13 Dec 2007 05:33:43 PST X-Mailer: YahooMailRC/818.31 YahooMailWebService/0.7.158.1 Date: Thu, 13 Dec 2007 05:33:43 -0800 (PST) From: Nash Nipples To: freebsd-performance@freebsd.org MIME-Version: 1.0 Message-ID: <28761.46997.qm@web36306.mail.mud.yahoo.com> Content-Type: text/plain; charset=us-ascii X-Content-Filtered-By: Mailman/MimeDel 2.1.5 Subject: Re: freebsd vs linux: performance problem X-BeenThere: freebsd-performance@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: Performance/tuning List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Thu, 13 Dec 2007 14:00:25 -0000 sounds like a power unit problem. try to switch them and repeat. ----- Original Message ---- From: Shantanu Ghosh To: freebsd-performance@freebsd.org Sent: Thursday, December 13, 2007 2:07:50 PM Subject: freebsd vs linux: performance problem Hi, I am running FreeBSD 7.0 Beta1 and Linux FC6 on two identical pieces of hardware - Dell poweredge with intel core2 duo. Each system has 4 CPUs. Now, in simple memory access operations, I see the freebsd system being noticably slower than the linux system. A simple C program that copies from one memory buffer to another, when executed in a loop executes between 10-30% slower on freebsd, as compared to linux. The assembly code of the program used for testing is identical in both the cases. One observation is that freebsd system performance decreases as the size of the buffer increases. If the buffer is under 1k, both the sytems give the same performance. freebsd performance is about 10% slower if the buffer size is around 4k, and about 30% slower if the buffer is around 1Mb. A benchmark like sysbench memory read operation performs miserably on the freebsd system, compared to linux. As far as I can see, the BIOS settings are identical on both the machines. Any idea what could be going on? Thanks and regards. -- Shantanu. ____________________________________________________________________________________ Never miss a thing. Make Yahoo your home page. http://www.yahoo.com/r/hs _______________________________________________ freebsd-performance@freebsd.org mailing list http://lists.freebsd.org/mailman/listinfo/freebsd-performance To unsubscribe, send any mail to "freebsd-performance-unsubscribe@freebsd.org" ____________________________________________________________________________________ Looking for last minute shopping deals? Find them fast with Yahoo! Search. http://tools.search.yahoo.com/newsearch/category.php?category=shopping From owner-freebsd-performance@FreeBSD.ORG Thu Dec 13 17:55:09 2007 Return-Path: Delivered-To: freebsd-performance@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:4f8:fff6::34]) by hub.freebsd.org (Postfix) with ESMTP id F121516A417 for ; Thu, 13 Dec 2007 17:55:09 +0000 (UTC) (envelope-from gofp-freebsd-performance@m.gmane.org) Received: from ciao.gmane.org (main.gmane.org [80.91.229.2]) by mx1.freebsd.org (Postfix) with ESMTP id 8C43613C4E1 for ; Thu, 13 Dec 2007 17:55:09 +0000 (UTC) (envelope-from gofp-freebsd-performance@m.gmane.org) Received: from list by ciao.gmane.org with local (Exim 4.43) id 1J2rrv-0002hd-6b for freebsd-performance@freebsd.org; Thu, 13 Dec 2007 17:29:07 +0000 Received: from 78-1-88-159.adsl.net.t-com.hr ([78.1.88.159]) by main.gmane.org with esmtp (Gmexim 0.1 (Debian)) id 1AlnuQ-0007hv-00 for ; Thu, 13 Dec 2007 17:29:07 +0000 Received: from ivoras by 78-1-88-159.adsl.net.t-com.hr with local (Gmexim 0.1 (Debian)) id 1AlnuQ-0007hv-00 for ; Thu, 13 Dec 2007 17:29:07 +0000 X-Injected-Via-Gmane: http://gmane.org/ To: freebsd-performance@freebsd.org From: Ivan Voras Date: Thu, 13 Dec 2007 18:22:15 +0100 Lines: 41 Message-ID: References: <963530.77689.qm@web54505.mail.re2.yahoo.com> Mime-Version: 1.0 Content-Type: multipart/signed; micalg=pgp-sha1; protocol="application/pgp-signature"; boundary="------------enigB2DDB6CF8976D01247E9B5EC" X-Complaints-To: usenet@ger.gmane.org X-Gmane-NNTP-Posting-Host: 78-1-88-159.adsl.net.t-com.hr User-Agent: Thunderbird 2.0.0.9 (Windows/20071031) In-Reply-To: <963530.77689.qm@web54505.mail.re2.yahoo.com> X-Enigmail-Version: 0.95.5 Sender: news Subject: Re: freebsd vs linux: performance problem X-BeenThere: freebsd-performance@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: Performance/tuning List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Thu, 13 Dec 2007 17:55:10 -0000 This is an OpenPGP/MIME signed message (RFC 2440 and 3156) --------------enigB2DDB6CF8976D01247E9B5EC Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: quoted-printable Shantanu Ghosh wrote: > Hi, >=20 > I am running FreeBSD 7.0 Beta1 and Linux FC6 on two identical pieces of= > hardware - Dell poweredge with intel core2 duo. Each system has 4 CPUs.= >=20 > Now, in simple memory access operations, I see the freebsd system being= > noticably slower than the linux system. A simple C program that copies > from one memory buffer to another, when executed in a loop executes > between 10-30% slower on freebsd, as compared to linux. The assembly > code of the program used for testing is identical in both the cases. AMD64 or i386 mode? Do they also have the same amount of memory? How much? --------------enigB2DDB6CF8976D01247E9B5EC Content-Type: application/pgp-signature; name="signature.asc" Content-Description: OpenPGP digital signature Content-Disposition: attachment; filename="signature.asc" -----BEGIN PGP SIGNATURE----- Version: GnuPG v1.2.5 (MingW32) Comment: Using GnuPG with Mozilla - http://enigmail.mozdev.org iD8DBQFHYWpHldnAQVacBcgRAvZ/AKDo4l5rJlgcFtd3P/98KURVdjtjXACg+FIi 082LwcPItgHpHKIsO65sJLM= =ZSYF -----END PGP SIGNATURE----- --------------enigB2DDB6CF8976D01247E9B5EC-- From owner-freebsd-performance@FreeBSD.ORG Fri Dec 14 02:44:24 2007 Return-Path: Delivered-To: freebsd-performance@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:4f8:fff6::34]) by hub.freebsd.org (Postfix) with ESMTP id E0D4C16A419 for ; Fri, 14 Dec 2007 02:44:24 +0000 (UTC) (envelope-from oceanare@pacific.net.sg) Received: from smtpgate1.pacific.net.sg (smtpgate1.pacific.net.sg [203.120.90.31]) by mx1.freebsd.org (Postfix) with SMTP id 339E613C506 for ; Fri, 14 Dec 2007 02:44:23 +0000 (UTC) (envelope-from oceanare@pacific.net.sg) Received: (qmail 20366 invoked from network); 14 Dec 2007 02:16:22 -0000 Received: from adsl2.dyn234.pacific.net.sg (HELO P2120.somewherefaraway.com) (oceanare@210.24.234.2) by smtpgate1.pacific.net.sg with ESMTPA; 14 Dec 2007 02:16:21 -0000 Message-ID: <4761E76D.6090202@pacific.net.sg> Date: Fri, 14 Dec 2007 10:16:13 +0800 From: Erich Dollansky User-Agent: Thunderbird 2.0.0.6 (X11/20070826) MIME-Version: 1.0 To: Nash Nipples References: <28761.46997.qm@web36306.mail.mud.yahoo.com> In-Reply-To: <28761.46997.qm@web36306.mail.mud.yahoo.com> Content-Type: text/plain; charset=ISO-8859-1; format=flowed Content-Transfer-Encoding: 7bit Cc: freebsd-performance@freebsd.org Subject: Re: freebsd vs linux: performance problem X-BeenThere: freebsd-performance@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: Performance/tuning List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Fri, 14 Dec 2007 02:44:25 -0000 Hi, Nash Nipples wrote: > sounds like a power unit problem. try to switch them and repeat. hey, in the next step you tell him that the MTU is set wrongly. > > > Now, in simple memory access operations, I see the freebsd system being > noticably slower than the linux system. A simple C program that copies As already mentioned, are both systems working as 32 or 64 bit systems? > from one memory buffer to another, when executed in a loop executes > between 10-30% slower on freebsd, as compared to linux. The assembly > code of the program used for testing is identical in both the cases. Don't you call memcpy? Erich From owner-freebsd-performance@FreeBSD.ORG Fri Dec 14 03:19:08 2007 Return-Path: Delivered-To: freebsd-performance@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:4f8:fff6::34]) by hub.freebsd.org (Postfix) with ESMTP id 9B34516A421 for ; Fri, 14 Dec 2007 03:19:08 +0000 (UTC) (envelope-from shantanu_ghosh@yahoo.com) Received: from web54505.mail.re2.yahoo.com (web54505.mail.re2.yahoo.com [206.190.49.155]) by mx1.freebsd.org (Postfix) with SMTP id 41C4513C467 for ; Fri, 14 Dec 2007 03:19:08 +0000 (UTC) (envelope-from shantanu_ghosh@yahoo.com) Received: (qmail 10792 invoked by uid 60001); 14 Dec 2007 03:19:07 -0000 DomainKey-Signature: a=rsa-sha1; q=dns; c=nofws; s=s1024; d=yahoo.com; h=X-YMail-OSG:Received:Date:From:Subject:To:In-Reply-To:MIME-Version:Content-Type:Content-Transfer-Encoding:Message-ID; b=FsCQml2US3k7txuQgusUn+AmYjAJBB7lHSVomfrYDdn7smKTCvb/PlaG9zGYVftEOeaJDLA3rg2VLP0/LMXGEc8fkjApOTwQfqSi05gRTy661KRINzhP6ukhTsdcIKleAAaFEK7fj/9yOQvQMdK6iw3Yn6RpmVtIY9A4Fk9vqTU=; X-YMail-OSG: _LNhdXsVM1l_4ifUe5GJB1UkOfA6DIfx_299C1xZKA_6HJJfUc7uRWT9_DHC48RmR6EhnQx50iNcSvWnmLPDQpUbxxWlWXgpdt5k6vPOS2Sy2CAjGoU6QXTNgkdD Received: from [203.145.181.122] by web54505.mail.re2.yahoo.com via HTTP; Thu, 13 Dec 2007 19:19:07 PST Date: Thu, 13 Dec 2007 19:19:07 -0800 (PST) From: Shantanu Ghosh To: Ivan Voras , freebsd-performance@freebsd.org In-Reply-To: MIME-Version: 1.0 Content-Type: text/plain; charset=iso-8859-1 Content-Transfer-Encoding: 8bit Message-ID: <391084.10339.qm@web54505.mail.re2.yahoo.com> Cc: Subject: Re: freebsd vs linux: performance problem X-BeenThere: freebsd-performance@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: Performance/tuning List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Fri, 14 Dec 2007 03:19:08 -0000 --- Ivan Voras wrote: > Shantanu Ghosh wrote: > > Hi, > > > > I am running FreeBSD 7.0 Beta1 and Linux FC6 on two identical > pieces of > > hardware - Dell poweredge with intel core2 duo. Each system has 4 > CPUs. > > > > Now, in simple memory access operations, I see the freebsd system > being > > noticably slower than the linux system. A simple C program that > copies > > from one memory buffer to another, when executed in a loop executes > > between 10-30% slower on freebsd, as compared to linux. The > assembly > > code of the program used for testing is identical in both the > cases. > > AMD64 or i386 mode? Sorry, forgot to mention - amd64. Similarly, x86_64 in linux. > > Do they also have the same amount of memory? How much? Yes, 8gb each. Regards, Shantanu. ____________________________________________________________________________________ Looking for last minute shopping deals? Find them fast with Yahoo! Search. http://tools.search.yahoo.com/newsearch/category.php?category=shopping From owner-freebsd-performance@FreeBSD.ORG Fri Dec 14 03:22:58 2007 Return-Path: Delivered-To: freebsd-performance@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:4f8:fff6::34]) by hub.freebsd.org (Postfix) with ESMTP id 768CC16A586 for ; Fri, 14 Dec 2007 03:22:58 +0000 (UTC) (envelope-from shantanu_ghosh@yahoo.com) Received: from web54501.mail.re2.yahoo.com (web54501.mail.re2.yahoo.com [206.190.49.151]) by mx1.freebsd.org (Postfix) with SMTP id 38DA313C46E for ; Fri, 14 Dec 2007 03:22:58 +0000 (UTC) (envelope-from shantanu_ghosh@yahoo.com) Received: (qmail 73111 invoked by uid 60001); 14 Dec 2007 03:22:57 -0000 DomainKey-Signature: a=rsa-sha1; q=dns; c=nofws; s=s1024; d=yahoo.com; h=X-YMail-OSG:Received:Date:From:Subject:To:Cc:In-Reply-To:MIME-Version:Content-Type:Content-Transfer-Encoding:Message-ID; b=Ta+rI0LQ70EWtuq1e3WywxvyrKju/ofRkf+cbPm4k56SY2L9Y9jXv6jzk+iloOjf/Y1tXPYdXEuJVxBBGrrW3w75BKNm3JjzOTZEx8Qcj9CAiy/zvAcwuSi85E3TmSxQ8/bLglVIxY+mUkwqTh4tyKCHjVbuTPaNzUii7Zmh6xo=; X-YMail-OSG: 71pe6XIVM1nC5ZZwcUGvk5fXU3iHUX5zMlqDBj2bv05uxkkidhynraP5kcyPrve91E0kwnfIrjcS2TZum2G32JaPSu9Cq8yTLCMTPztmgn4HDUE02n_HOR26g53GvpyKoLf.SkjJIWbVgsg- Received: from [203.145.181.122] by web54501.mail.re2.yahoo.com via HTTP; Thu, 13 Dec 2007 19:22:56 PST Date: Thu, 13 Dec 2007 19:22:56 -0800 (PST) From: Shantanu Ghosh To: Erich Dollansky , Nash Nipples In-Reply-To: <4761E76D.6090202@pacific.net.sg> MIME-Version: 1.0 Content-Type: text/plain; charset=iso-8859-1 Content-Transfer-Encoding: 8bit Message-ID: <150023.72900.qm@web54501.mail.re2.yahoo.com> Cc: freebsd-performance@freebsd.org Subject: Re: freebsd vs linux: performance problem X-BeenThere: freebsd-performance@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: Performance/tuning List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Fri, 14 Dec 2007 03:22:58 -0000 --- Erich Dollansky wrote: > Hi, > > Nash Nipples wrote: > > sounds like a power unit problem. try to switch them and repeat. > > hey, in the next step you tell him that the MTU is set wrongly. > > > > > > Now, in simple memory access operations, I see the freebsd system > being > > noticably slower than the linux system. A simple C program that > copies > > As already mentioned, are both systems working as 32 or 64 bit > systems? Both are working as 64 bit systems. > > > from one memory buffer to another, when executed in a loop executes > > between 10-30% slower on freebsd, as compared to linux. The > assembly > > code of the program used for testing is identical in both the > cases. > > Don't you call memcpy? Well, I first did - then I wrote a function to do the same, just to make sure that the code executed is exactly the same in both the cases. The difference was there both when using memcpy, and when using the replacement function. > > Erich > _______________________________________________ > freebsd-performance@freebsd.org mailing list > http://lists.freebsd.org/mailman/listinfo/freebsd-performance > To unsubscribe, send any mail to > "freebsd-performance-unsubscribe@freebsd.org" > ____________________________________________________________________________________ Never miss a thing. Make Yahoo your home page. http://www.yahoo.com/r/hs From owner-freebsd-performance@FreeBSD.ORG Fri Dec 14 03:33:07 2007 Return-Path: Delivered-To: freebsd-performance@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:4f8:fff6::34]) by hub.freebsd.org (Postfix) with ESMTP id 8719F16A421 for ; Fri, 14 Dec 2007 03:33:07 +0000 (UTC) (envelope-from oceanare@pacific.net.sg) Received: from smtpgate2.pacific.net.sg (smtpgate2.pacific.net.sg [203.120.90.32]) by mx1.freebsd.org (Postfix) with SMTP id D05CB13C4EB for ; Fri, 14 Dec 2007 03:33:06 +0000 (UTC) (envelope-from oceanare@pacific.net.sg) Received: (qmail 364 invoked from network); 14 Dec 2007 03:33:04 -0000 Received: from adsl2.dyn234.pacific.net.sg (HELO P2120.somewherefaraway.com) (oceanare@210.24.234.2) by smtpgate2.pacific.net.sg with ESMTPA; 14 Dec 2007 03:33:03 -0000 Message-ID: <4761F963.5040505@pacific.net.sg> Date: Fri, 14 Dec 2007 11:32:51 +0800 From: Erich Dollansky User-Agent: Thunderbird 2.0.0.6 (X11/20070826) MIME-Version: 1.0 To: Shantanu Ghosh References: <150023.72900.qm@web54501.mail.re2.yahoo.com> In-Reply-To: <150023.72900.qm@web54501.mail.re2.yahoo.com> Content-Type: text/plain; charset=ISO-8859-1; format=flowed Content-Transfer-Encoding: 7bit Cc: freebsd-performance@freebsd.org, Nash Nipples Subject: Re: freebsd vs linux: performance problem X-BeenThere: freebsd-performance@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: Performance/tuning List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Fri, 14 Dec 2007 03:33:07 -0000 Hi, Shantanu Ghosh wrote: > --- Erich Dollansky wrote: > >> Don't you call memcpy? > > Well, I first did - then I wrote a function to do the same, just to > make sure that the code executed is exactly the same in both the cases. > The difference was there both when using memcpy, and when using the > replacement function. Do you have Linux compatibility installed on the FreeBSD machine? You should then be able to run the Linux binary to see what happens then. I have had once the problem of a task moving from CPU to CPU and s performing badly on FreeBSD. I am not informed how this is handled currently. I also assume that this example is a single-threaded program which should perform just fine on single CPU machine. One other thing, can you just boot up with one CPU and one core to see what happens then? Erich From owner-freebsd-performance@FreeBSD.ORG Fri Dec 14 04:07:04 2007 Return-Path: Delivered-To: freebsd-performance@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:4f8:fff6::34]) by hub.freebsd.org (Postfix) with ESMTP id 73A6C16A417 for ; Fri, 14 Dec 2007 04:07:04 +0000 (UTC) (envelope-from kip.macy@gmail.com) Received: from wa-out-1112.google.com (wa-out-1112.google.com [209.85.146.178]) by mx1.freebsd.org (Postfix) with ESMTP id 542D913C45B for ; Fri, 14 Dec 2007 04:07:04 +0000 (UTC) (envelope-from kip.macy@gmail.com) Received: by wa-out-1112.google.com with SMTP id k17so1563702waf.3 for ; Thu, 13 Dec 2007 20:07:03 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=gamma; h=domainkey-signature:received:received:message-id:date:from:to:subject:cc:in-reply-to:mime-version:content-type:content-transfer-encoding:content-disposition:references; bh=2eQOHn/AKUg1+DWOoeB+LcuXXCfksU1D9TiwfEcAOHk=; b=VbFAjmGYblYREd1fS2dwfNoNAG1BYMv+jAIyx70NIlqtMUqItGh7zcJqGarDgmFEw4CuHdwTZL1+TXSGENjVUCcel65UZsu+8kDEi5RrVDAvjgqYWaMCL6r1RT84dlZT+QGvbEpkgX0wAwLshnFyflOwgy2YfCF7D/EoxsEP/6g= DomainKey-Signature: a=rsa-sha1; c=nofws; d=gmail.com; s=gamma; h=message-id:date:from:to:subject:cc:in-reply-to:mime-version:content-type:content-transfer-encoding:content-disposition:references; b=E8o6DeQ2VlkCwEIg0S8KDuC37WsDq+/DmO/cGa8kFfsEvPaUMPIEp3qul39gQgR/i2UnUTokHFUaij7VYEC0ln63etneVHA2Hnakw9EwZ4oNk0qDr13Xv4fJS3rUbA8cDtu07fi9Q9JtJ8RCqyrM6PG4PJZKp+k8c67f/giJn30= Received: by 10.114.93.17 with SMTP id q17mr3173915wab.70.1197603709968; Thu, 13 Dec 2007 19:41:49 -0800 (PST) Received: by 10.114.255.11 with HTTP; Thu, 13 Dec 2007 19:41:49 -0800 (PST) Message-ID: Date: Thu, 13 Dec 2007 19:41:49 -0800 From: "Kip Macy" To: "Shantanu Ghosh" In-Reply-To: <963530.77689.qm@web54505.mail.re2.yahoo.com> MIME-Version: 1.0 Content-Type: text/plain; charset=ISO-8859-1 Content-Transfer-Encoding: 7bit Content-Disposition: inline References: <963530.77689.qm@web54505.mail.re2.yahoo.com> Cc: freebsd-performance@freebsd.org Subject: Re: freebsd vs linux: performance problem X-BeenThere: freebsd-performance@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: Performance/tuning List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Fri, 14 Dec 2007 04:07:04 -0000 On Dec 13, 2007 4:07 AM, Shantanu Ghosh wrote: > Hi, > > I am running FreeBSD 7.0 Beta1 and Linux FC6 on two identical pieces of > hardware - Dell poweredge with intel core2 duo. Each system has 4 CPUs. > > Now, in simple memory access operations, I see the freebsd system being > noticably slower than the linux system. A simple C program that copies > from one memory buffer to another, when executed in a loop executes > between 10-30% slower on freebsd, as compared to linux. The assembly > code of the program used for testing is identical in both the cases. > > One observation is that freebsd system performance decreases as the > size of the buffer increases. If the buffer is under 1k, both the > sytems give the same performance. freebsd performance is about 10% > slower if the buffer size is around 4k, and about 30% slower if the > buffer is around 1Mb. A benchmark like sysbench memory read operation > performs miserably on the freebsd system, compared to linux. > > As far as I can see, the BIOS settings are identical on both the > machines. Any idea what could be going on? Are you running with ULE or 4BSD? Have you checked that the BIOS cache settings are identical? -Kip From owner-freebsd-performance@FreeBSD.ORG Fri Dec 14 04:24:33 2007 Return-Path: Delivered-To: freebsd-performance@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:4f8:fff6::34]) by hub.freebsd.org (Postfix) with ESMTP id 9BB3C16A41A for ; Fri, 14 Dec 2007 04:24:33 +0000 (UTC) (envelope-from shantanu_ghosh@yahoo.com) Received: from web54507.mail.re2.yahoo.com (web54507.mail.re2.yahoo.com [206.190.49.157]) by mx1.freebsd.org (Postfix) with SMTP id 5C81413C43E for ; Fri, 14 Dec 2007 04:24:33 +0000 (UTC) (envelope-from shantanu_ghosh@yahoo.com) Received: (qmail 7018 invoked by uid 60001); 14 Dec 2007 04:24:32 -0000 DomainKey-Signature: a=rsa-sha1; q=dns; c=nofws; s=s1024; d=yahoo.com; h=X-YMail-OSG:Received:Date:From:Subject:To:Cc:In-Reply-To:MIME-Version:Content-Type:Content-Transfer-Encoding:Message-ID; b=R6Nw46T4uXy7gs96oxLpSHYTeQl9reiLnzr99POhPHgei3xypTfZFrxZtJ1MUF16BhFOIYQ20QxoIhn8uajDPp+MH70XpwzuQZB3Ul4iDIsA7Dmw9ZENqiCKs5ahxM1RH1+hyvdMUVkVEbbq8t613uqMnwteo3FpBh9YN81zJmE=; X-YMail-OSG: ptzJewwVM1lqBPBZxO2fqy3VbZuH6E4B43xFpoZxG7dUD4ibcZLdZ61GyyhkySk6Aw-- Received: from [203.145.181.122] by web54507.mail.re2.yahoo.com via HTTP; Thu, 13 Dec 2007 20:24:32 PST Date: Thu, 13 Dec 2007 20:24:32 -0800 (PST) From: Shantanu Ghosh To: Erich Dollansky In-Reply-To: <4761F963.5040505@pacific.net.sg> MIME-Version: 1.0 Content-Type: text/plain; charset=iso-8859-1 Content-Transfer-Encoding: 8bit Message-ID: <344260.5397.qm@web54507.mail.re2.yahoo.com> Cc: freebsd-performance@freebsd.org Subject: Re: freebsd vs linux: performance problem X-BeenThere: freebsd-performance@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: Performance/tuning List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Fri, 14 Dec 2007 04:24:33 -0000 --- Erich Dollansky wrote: > Hi, > > Shantanu Ghosh wrote: > > --- Erich Dollansky wrote: > > > >> Don't you call memcpy? > > > > Well, I first did - then I wrote a function to do the same, just to > > make sure that the code executed is exactly the same in both the > cases. > > The difference was there both when using memcpy, and when using the > > replacement function. > > Do you have Linux compatibility installed on the FreeBSD machine? > > You should then be able to run the Linux binary to see what happens > then. > > I have had once the problem of a task moving from CPU to CPU and s > performing badly on FreeBSD. > > I am not informed how this is handled currently. This could be something I am facing. I noticed that when I run vmstat while running this code, on linux, there's hardly any perceptible difference in the number of context switches, but on freebsd, the number of context switches in the system seems to go up a bit. However, this is not very reliable. Do you know how I can check this migration? > > I also assume that this example is a single-threaded program which > should perform just fine on single CPU machine. > > One other thing, can you just boot up with one CPU and one core to > see > what happens then? While I have not tried it on this machine, on a single cpu machine, the non-SMP build of freebsd seems to perform as well as linux for this kind of test. Thanks a lot for your help. > > Erich > _______________________________________________ > freebsd-performance@freebsd.org mailing list > http://lists.freebsd.org/mailman/listinfo/freebsd-performance > To unsubscribe, send any mail to > "freebsd-performance-unsubscribe@freebsd.org" > -- Shantanu. ____________________________________________________________________________________ Be a better friend, newshound, and know-it-all with Yahoo! Mobile. Try it now. http://mobile.yahoo.com/;_ylt=Ahu06i62sR8HDtDypao8Wcj9tAcJ From owner-freebsd-performance@FreeBSD.ORG Fri Dec 14 04:41:20 2007 Return-Path: Delivered-To: freebsd-performance@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:4f8:fff6::34]) by hub.freebsd.org (Postfix) with ESMTP id F143E16A41A for ; Fri, 14 Dec 2007 04:41:20 +0000 (UTC) (envelope-from oceanare@pacific.net.sg) Received: from smtpgate1.pacific.net.sg (smtpgate1.pacific.net.sg [203.120.90.31]) by mx1.freebsd.org (Postfix) with SMTP id 4881413C44B for ; Fri, 14 Dec 2007 04:41:20 +0000 (UTC) (envelope-from oceanare@pacific.net.sg) Received: (qmail 18621 invoked from network); 14 Dec 2007 04:41:18 -0000 Received: from adsl2.dyn234.pacific.net.sg (HELO P2120.somewherefaraway.com) (oceanare@210.24.234.2) by smtpgate1.pacific.net.sg with ESMTPA; 14 Dec 2007 04:41:17 -0000 Message-ID: <47620966.3030108@pacific.net.sg> Date: Fri, 14 Dec 2007 12:41:10 +0800 From: Erich Dollansky User-Agent: Thunderbird 2.0.0.6 (X11/20070826) MIME-Version: 1.0 To: Shantanu Ghosh References: <344260.5397.qm@web54507.mail.re2.yahoo.com> In-Reply-To: <344260.5397.qm@web54507.mail.re2.yahoo.com> Content-Type: text/plain; charset=ISO-8859-1; format=flowed Content-Transfer-Encoding: 7bit Cc: freebsd-performance@freebsd.org Subject: Re: freebsd vs linux: performance problem X-BeenThere: freebsd-performance@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: Performance/tuning List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Fri, 14 Dec 2007 04:41:21 -0000 Hi, Shantanu Ghosh wrote: > --- Erich Dollansky wrote: > >> Shantanu Ghosh wrote: >>> --- Erich Dollansky wrote: >>> >> I have had once the problem of a task moving from CPU to CPU and s >> performing badly on FreeBSD. >> >> I am not informed how this is handled currently. > > This could be something I am facing. I noticed that when I run vmstat > while running this code, on linux, there's hardly any perceptible > difference in the number of context switches, but on freebsd, the > number of context switches in the system seems to go up a bit. However, > this is not very reliable. > > Do you know how I can check this migration? I forgot how I checked it. > > While I have not tried it on this machine, on a single cpu machine, the > non-SMP build of freebsd seems to perform as well as linux for this > kind of test. Ok, this could then be a hint that the task is simply migrating. > > Thanks a lot for your help. No not praise the day before night falls. Erich From owner-freebsd-performance@FreeBSD.ORG Fri Dec 14 19:47:30 2007 Return-Path: Delivered-To: freebsd-performance@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:4f8:fff6::34]) by hub.freebsd.org (Postfix) with ESMTP id C525616A419 for ; Fri, 14 Dec 2007 19:47:30 +0000 (UTC) (envelope-from gofp-freebsd-performance@m.gmane.org) Received: from ciao.gmane.org (main.gmane.org [80.91.229.2]) by mx1.freebsd.org (Postfix) with ESMTP id 6E69E13C457 for ; Fri, 14 Dec 2007 19:47:30 +0000 (UTC) (envelope-from gofp-freebsd-performance@m.gmane.org) Received: from root by ciao.gmane.org with local (Exim 4.43) id 1J3GT1-0000OD-Bz for freebsd-performance@freebsd.org; Fri, 14 Dec 2007 19:45:03 +0000 Received: from 78-0-85-236.adsl.net.t-com.hr ([78.0.85.236]) by main.gmane.org with esmtp (Gmexim 0.1 (Debian)) id 1AlnuQ-0007hv-00 for ; Fri, 14 Dec 2007 19:45:03 +0000 Received: from ivoras by 78-0-85-236.adsl.net.t-com.hr with local (Gmexim 0.1 (Debian)) id 1AlnuQ-0007hv-00 for ; Fri, 14 Dec 2007 19:45:03 +0000 X-Injected-Via-Gmane: http://gmane.org/ To: freebsd-performance@freebsd.org From: Ivan Voras Date: Fri, 14 Dec 2007 20:39:07 +0100 Lines: 32 Message-ID: References: <150023.72900.qm@web54501.mail.re2.yahoo.com> <4761F963.5040505@pacific.net.sg> Mime-Version: 1.0 Content-Type: multipart/signed; micalg=pgp-sha1; protocol="application/pgp-signature"; boundary="------------enigCD23FF01A7621E53ED216EFC" X-Complaints-To: usenet@ger.gmane.org X-Gmane-NNTP-Posting-Host: 78-0-85-236.adsl.net.t-com.hr User-Agent: Thunderbird 2.0.0.9 (Windows/20071031) In-Reply-To: <4761F963.5040505@pacific.net.sg> X-Enigmail-Version: 0.95.5 Sender: news Subject: Re: freebsd vs linux: performance problem X-BeenThere: freebsd-performance@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: Performance/tuning List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Fri, 14 Dec 2007 19:47:30 -0000 This is an OpenPGP/MIME signed message (RFC 2440 and 3156) --------------enigCD23FF01A7621E53ED216EFC Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: quoted-printable Erich Dollansky wrote: > I have had once the problem of a task moving from CPU to CPU and s > performing badly on FreeBSD. This is easy to check: either rebuild a kernel without "options SMP" or disable processes by setting machdep.hlt_cpus (see smp(4)) or set hint.lapic.X.disable=3D1, then run the program again. --------------enigCD23FF01A7621E53ED216EFC Content-Type: application/pgp-signature; name="signature.asc" Content-Description: OpenPGP digital signature Content-Disposition: attachment; filename="signature.asc" -----BEGIN PGP SIGNATURE----- Version: GnuPG v1.2.5 (MingW32) Comment: Using GnuPG with Mozilla - http://enigmail.mozdev.org iD8DBQFHYtvbldnAQVacBcgRAk+rAKCUbLo/q4oDBvX/6Lmcf1EKdvewvwCfS1eO Tzbj71yD3bAXJUCGNPJcWbY= =Txrn -----END PGP SIGNATURE----- --------------enigCD23FF01A7621E53ED216EFC--