Newsgroups: php.internals Path: news.php.net Xref: news.php.net php.internals:12918 Return-Path: Mailing-List: contact internals-help@lists.php.net; run by ezmlm Delivered-To: mailing list internals@lists.php.net Received: (qmail 78501 invoked by uid 1010); 21 Sep 2004 01:03:16 -0000 Delivered-To: ezmlm-scan-internals@lists.php.net Delivered-To: ezmlm-internals@lists.php.net Received: (qmail 78474 invoked from network); 21 Sep 2004 01:03:15 -0000 Received: from unknown (HELO mail.zend.com) (80.74.107.235) by pb1.pair.com with SMTP; 21 Sep 2004 01:03:15 -0000 Received: (qmail 21354 invoked from network); 21 Sep 2004 01:03:13 -0000 Received: from localhost (HELO AndiNotebook.zend.com) (127.0.0.1) by localhost with SMTP; 21 Sep 2004 01:03:13 -0000 Message-ID: <5.1.0.14.2.20040920180203.04495ec0@localhost> X-Sender: andi@localhost X-Mailer: QUALCOMM Windows Eudora Version 5.1 Date: Mon, 20 Sep 2004 18:02:52 -0700 To: Rasmus Lerdorf ,internals@lists.php.net In-Reply-To: Mime-Version: 1.0 Content-Type: text/plain; charset="us-ascii"; format=flowed Subject: Re: [PHP-DEV] Intel icc compiler warnings From: andi@zend.com (Andi Gutmans) References: I have done some playing around with Intel compiler. It usually tends to be faster 10-20% but it depends on the flags you use, inlining of the program (Intel compiler seems to optimize inlines much better). Andi At 10:34 PM 9/18/2004 -0700, Rasmus Lerdorf wrote: >Out of curiosity I built HEAD with Intel's icc 8.1 compiler on my Debian >laptop today. The full set of warnings (425k worth) are at: > > http://lerdorf.com/icc_warnings.txt > >There are some fun ones in there, like these: > >/home/rasmus/php-src/Zend/zend_alloc.c(252): warning #186: pointless >comparison of unsigned integer with zero > && offset >= 0) { > ^ > >Zend/zend_execute.h(83): warning #1572: floating-point equality and >inequality comparisons are unreliable > result = (op->value.dval ? 1 : 0); > ^ > >/home/rasmus/php-src/sapi/cli/php_cli.c(773): warning #25: quoted string >should contain at least one character > case '': /* generate indented source mode*/ > ^ > >/home/rasmus/php-src/ext/session/mod_files.c(332): warning #266: function >declared implicitly > n = pread(data->fd, *val, sbuf.st_size, 0); > ^ > >/home/rasmus/php-src/ext/session/mod_files.c(368): warning #266: function >declared implicitly > n = pwrite(data->fd, val, vallen, 0); > ^ > >The invalid attribute and unsigned vs. signed warnings really clutter >things up making it hard to find the more interesting warnings. > >The icc compiled libphp5.so was 9,816,098 bytes vs. 11,804,220 for gcc. >Other things I compiled also consistently showed icc creating much smaller >binaries. But that appears to just be due to a lot more symbol info. If >I strip both I get: > >gcc libphp5.so 2,590,412 >icc libphp5.so 2,793,780 > >Performance-wise it seems the icc binary is slower, but that is only from >a very unscientific benchmark and I wonder if loading an icc php binary >into a gcc Apache binary might not slow things down a bit. I haven't >looked into the gcc compatibility libraries icc ships with to understand >that well enough. But on first glance icc appears to generate a larger >and slower libphp5.so. > >-Rasmus > >-- >PHP Internals - PHP Runtime Development Mailing List >To unsubscribe, visit: http://www.php.net/unsub.php