Delete GlobalCache, take 3

Pulling the trigger; it's unused post-tx64. This diff preserves the
ability to mark units as merge-only when the pseudomain only contains
assignments to known globals. When the unit is being merged, the set
operation goes directly to the global varenv instead of through the
targetcache (GlobalCache stored pointers into the global varenv's
NameValueTable).
Fix warnings for various things being passed by reference

We were fataling when passing a list assignment expression with an
array-element RHS (like "$arr[0]") as an argument that the callee
expected to take by reference. Zend allows this, but with a warning. I
figured out the rules as best I can (this is one of those corners of
Zend where layers of insanity have piled up over time). I won't swear
that I got it 100% right w.r.t. whether we warn or not, but I'm pretty
sure we're closer to 100% right w.r.t. whether we fatal or not.
Change interface to ext_mysql C++ code to allow transporting underlying conns

This allows for connections to be created from existing mysql
connections as well as extracting the underlying connection from it.
Apply metadata to the ir in translateTracelet

In one of my pending region compiler diffs, I added code to forget the
values/types of locals after some FCalls (not doing so was wrong but we were
mostly getting away with it). This exposed an issue where the known type of a
local in the IR was less specific that what Translator::analyze was using. The
more specific type came from metadata on instructions after the FCall, so this
diff applies metadat to the IR before translating each instruction, using the
same code I wrote for the region compiler.

The changes to apply the metadata are pretty small; most of the
changes in this diffs are real bugs I found while attempting an
alternate solution.
Support parameter reffiness in the tracelet region selector

This brings the tracelet region selector to 100% coverage,
though perf is still not at parity. Guard relaxation/specialization
and inlining are the big remaining features that will help perf.
Add structs for holding heap profile dumps

These structs will eventually hold the heap profiling data
for PHP request heaps, so that it can be gathered and displayed
using the pprof tool.

This was tested by layering the smart allocator stuff on top and
making sure everything worked as planned. Nothing uses the structs
in this diff, so it's kind of difficult to test otherwise.
Instrument smart allocator

Dumps information about allocation events in smart
allocator, and aggregates some information such as bytes
allocated per callsite in the current request (or across
requests). This information can be gathered in the heaptrace
command, and the information collected during the trace is
enough to find how much memory an object is responsible for
(i.e. keeping reachable).

It's all conditionally compiled because perflab showed a pretty
significant instruction regression if it was a runtime option.
You'll need to fbconfig with --extra-cxxflags=-DMEMORY_PROFILING
in order to use it.

This isn't done, but I wanted to get some feedback on where I
should take this (general design, what to log, where to dump
stuff, etc)
Leak Units when memory profiling to prevent cleanup of Funcs and Classes

Memory profiling is going to rely on these things not getting
destroyed, so we are intentionally going to leak them in this case.
The use case of this is that the memory profiler is going to store
a stack trace as a bunch of SrcKeys, which can be used with D892173
to look up the original Func the stack trace goes through. Since we are
looking up the Func potentially much later than the SrcKey was
originally recorded, there is no guarantee that the Func will still be
around, or that we won't grab a pointer to it only to find that it is
in the middle of destructing and is thus full of garbage.
Move RuntimeOption settings for APC section to ext_apc

Avoid the massive monolithic structure that it
runtime_options.cpp

Rename settings along the way to drop superflous "Apc" naming.
handle file:// includes

Now that we can include urls, we shoudl handle `file://`.
use correct class for RecursiveDirectoryIterator

That was one hell of a bug. They overwrote a subclass and expected the overwriting to stay when it created a new copy.
Add an aprof code region and use it for profile translations in JitPGO mode

This diff generalizes the AHotSelector (now called AsmSelector) to
select an assembler among 'a', 'ahot', and 'aprof'.  'aprof' is only
allocated and used in JitPGO mode, and it's used for TransProfile
translations.
implement read support for phars

A first pass at phar. The parsing logic was done from the spec:
http://www.php.net/manual/en/phar.fileformat.phar.php
import phar tests

Now that phars sort of work, we can import their tests and they don't spew everywhere.
HPHP/XHP: always pass file/line into XHP constructors
Revert "simplexml fixes for text children and casting"
no POSIX timers on OSX

- unbreak OSX build

Closes #891
Remove obsolete debugger test suite

The debugger tests that are run via hphp/test/ext/test have now been replaced by tests that run via hphp/test/run, so they can be deleted as they test nothing additional and appear to be flaky.
fix zend error message

I stupidly changed this without retesting. The message shouldn't have a newline in it.
disable failing test

This worked when imported
Due to a diff that was reverted
Because it broke other things