<?xml version="1.0"?>
<rss version="2.0">
  <channel>
    <title>PHPDeveloper.org</title>
    <link>http://www.phpdeveloper.org</link>
    <description>Up-to-the Minute PHP News, views and community</description>
    <language>en-us</language>
    <pubDate>Fri, 24 May 2013 15:42:27 -0500</pubDate>
    <ttl>30</ttl>
    <item>
      <title><![CDATA[Joshua Thijssen's Blog: Bloom Filters]]></title>
      <guid>http://www.phpdeveloper.org/news/17792</guid>
      <link>http://www.phpdeveloper.org/news/17792</link>
      <description><![CDATA[<p>
In <a href="http://www.adayinthelifeof.nl/2012/04/09/bloom-filters/">this new post</a> to his blog <i>Joshua Thijssen</i> describes something that can help when processing large amounts of data (like, in his example, the text of a book) to search through the information and find if a certain piece of data is in the set - a bloom filter.
</p>
<blockquote>
Most of my co-workers never really heard of bloom filters, and I'm continuously need to explain what they are, what their purpose is and why it's a better solution than other ones. So let's do an introduction on bloom filters. [...] Bloom filters have the property of being exceptionally fast AND exceptionally small compared to other structures but it comes with a price: it MIGHT be possible that our bloom filter thinks that an element is inside our set, when it really isn't. Luckily, the reverse is not possible: when a bloom filter says something is NOT in the set, you are 100% sure that it isn't part of the set.
</blockquote>
<p>
He explains how the filter works, noting how it's better for memory consumption and how it's possible for it to give a "maybe" response instead of ab absolute "yes" or "no". He also points out <a href="http://pecl.php.net/package/bloomy">a PHP extension, bloomy</a> that takes the hard work out of it for you.
</p>]]></description>
      <pubDate>Mon, 09 Apr 2012 11:13:32 -0500</pubDate>
    </item>
    <item>
      <title><![CDATA[UMumble.com: Working with memory]]></title>
      <guid>http://www.phpdeveloper.org/news/17536</guid>
      <link>http://www.phpdeveloper.org/news/17536</link>
      <description><![CDATA[<p>
On the UMumble blog there's <a href="http://umumble.com/blogs/php/395/">a recent post</a> looking at memory consumption in PHP applications - what PHP does for you when managing how it uses your system's memory and what you need to worry about in your code.
</p>
<blockquote>
There is a widespread view that the ordinary PHP developer does not need to control memory management, but "controlling" and "knowing" are slightly different concepts. I will try to throw light upon some aspects of memory management when working with variables and arrays, and some interesting pitfalls of the internal optimization of PHP. As you can see, the optimization is good, but if you do not know exactly how it is optimized, you might meet the pitfalls, which can make you pretty nervous.
</blockquote>
<p>
They talk about some of the basics - how variables are stored in hash tables and how this helps memory consumption - as well as using the <a href="http://php.net/memory_get_usage">memory_get_usage</a> method to find your current consumption. This is show for both regular strings and arrays, comparing larger data (and assigning it multiple times) to simpler structures. They also mention how PHP handles memory usage in passing by reference and copying of values.
</p>]]></description>
      <pubDate>Tue, 14 Feb 2012 08:44:02 -0600</pubDate>
    </item>
  </channel>
</rss>
