You are here: Re: Xor bug in all PHP versions « PHP Programming Language « IT news, forums, messages
Re: Xor bug in all PHP versions

Posted by Andy Hassall on 01/19/06 00:45

On 18 Jan 2006 13:32:23 -0800, "DigDug" <dougitman@hotmail.com> wrote:

>I get two different results in doing a Xor on a large signed double
>between linux servers.
>working system is kernel 2.4 . bad results server is kernel 2.6.
>
> PHP version does not matter. I compile PHP from 4.2.2 to latest.
>
>test code:
><?PHP echo -4738698913 ^ 43814; ?>
>
>results:
>
>Good result from 2.4 kernel system is -443704711
>Bad result from 2.6 kernel systems(tried 5 different systems) is
>-2147439834
>
>BUG in PHP or kernel?

32 or 64 bit architecture?

Have you seen the related user notes on
http://www.php.net/manual/en/language.operators.bitwise.php ? (Not all apply to
XOR but there are several in there that may interest you).

--
Andy Hassall :: andy@andyh.co.uk :: http://www.andyh.co.uk
http://www.andyhsoftware.co.uk/space :: disk and FTP usage analysis tool

 

Navigation:

[Reply to this message]


Удаленная работа для программистов  •  Как заработать на Google AdSense  •  England, UK  •  статьи на английском  •  PHP MySQL CMS Apache Oscommerce  •  Online Business Knowledge Base  •  DVD MP3 AVI MP4 players codecs conversion help
Home  •  Search  •  Site Map  •  Set as Homepage  •  Add to Favourites

Copyright © 2005-2006 Powered by Custom PHP Programming

Сайт изготовлен в Студии Валентина Петручека
изготовление и поддержка веб-сайтов, разработка программного обеспечения, поисковая оптимизация