Fixed bug #1182: preg_replace should support some sort of cache eviction

Problem
------------
If we have count of dynamic regexes more than cache capacity, hhvm raised error that "PCRE cache full".

Solution
------------
Set lock on read cross-thread regex storage, and call reinitialize storage method. Losk set via mutex.

Test
-------
hphp/test/slow/ext_preg/1182.php

```php
$subject = 'done';
for ($i = 0; $i < 97 * 1024; $i++) {
    preg_replace('/(' . $i . ')/ui', 'replaced', $subject);
}

var_dump($subject);
```