Reduce from four ways to look up Unit*'s to one

Summary: The 'eval' vs. 'lookup' distinction doesn't make
sense---neither of them did any evaluation.  I also didn't know what
an "include root" was or why you'd want to look one up.  Refactor
things so there's just lookupUnit (still on ExecutionContext for now).

Reviewed By: @bertmaher

Differential Revision: D1384187
Don't use FileRepository to find systemlib md5s

Summary: There's no need to do this---we can just ask the repo.

Reviewed By: @swtaarrs

Differential Revision: D1386880
Move lookupUnit out of ExecutionContext

Summary: Intermediate refactoring step.

Reviewed By: @alexmalyshev

Differential Revision: D1386881
Break more dependencies on PhpFile* outside of file-repository.cpp

Summary: EvaledFilesMap and debugger stuff still used these, but only
to call getFileName().  After some investigation, it looks like
phpFile->getFileName() is always equivalent to
phpFile->unit()->filepath() (we set the unit's filepath to the same
string we're going to pass the PhpFile constructor), even with
Eval.CheckSymLink on, so we can skip it.  While looking through this I
noticed m_evaledFilesOrder was being added to even if we're doing a
non-initial include of a file we've already included via a different
path, which makes the results of get_included_files not match php5, so
this diff also fixes that.

Reviewed By: @alexmalyshev

Differential Revision: D1386883
Hide the rest of FileRepository guts into its implementation

Summary: A few utility functions are still exported, but the main API
to this module is now just "lookupUnit", which is hopefully
understandable enough that it should be easy to replace the internals
with something more sane now.  (Later diff renames the file, it's a
"FileRepository" isn't a thing anymore.)

Reviewed By: @swtaarrs

Differential Revision: D1386886
Reflow various documentation to 79 columns

Summary: mwang and bsimmers like it better.

Reviewed By: @swtaarrs

Differential Revision: D1386888
Separate RepoAuthoritative Unit caching from the rest of the code

Summary: It's different enough that this seems less complex.  (And it already
made use of an entirely separate ConcurrentHashMap, anyway.)

Reviewed By: @mxw

Differential Revision: D1386891
Rewrite non-repo version of the thing formerly known as FileRepository

Summary: It was buggy, and had evolved poorly.

The main bug related to the ~PhpFile codepaths and the md5 map.  A treadmilled
PhpFile could be reused even though its unit was scheduled to be deleted.  This
diff fixes the race by having clearer ownership, and eliminating the md5 map.

Rationale on not reimplementing the md5-based cache for now: we are including
the file's path into the md5 to avoid sharing the "same" unit for files with
different paths (it would break the "Dir" and "File" opcodes as currently
implemented).  We also already have a cache to avoid starting from scratch if
the contents are the same (the Repo), so this only only can save on duplicating
JIT time/space, and Unit load time.  It also shouldn't be hitting very often: I
think the main case is if you manage to have the mtime change on a file without
the file contents actually changing.  Multiple copies of the "same" file for
different www checkouts on a shared server won't be getting shared Units right
now, and switching branches and then switching back can only reuse the Unit if
it either goes through the buggy code path and reused it even though it was
treadmilled or if the unit wasn't loaded since the time you were on the
previous branch.  So, I'm thinking let's make it simpler now and optimize it
again if we need to later.

Reviewed By: @swtaarrs

Differential Revision: D1386893
Rename file-repository to unit-cache

Summary: This is just a rename diff.  It's on top of everything else so we can
choose different names without me needing to rebase, if anyone has a better
naming idea.  This seems like a reasonable name, although both resolveVmInclude
and mangleUnitMd5 feel slightly out of place now (but resolveVmInclude (and
resolve_include) are pretty convoluted for historical reasons and deserving of
their own cleanup pass anyway, which I'm going to consider out of scope for now
since it's not causing bugs as far as we know ...).

Reviewed By: @mxw

Differential Revision: D1386894
Still use RankedCHM for unit-cache; rename the rank

Summary: I haven't changed anything to stop us from holding these tbb locks for
long periods of time, and these assertions have caught bugs, so they should
stay.  (I forgot about it in D1386893.)

Reviewed By: @elgenie

Differential Revision: D1396824
A few comment tweaks in the file-repository diff stack

Summary: Stuff from some review comments.  (So I don't have to rebase them
through the stack.)

Reviewed By: @swtaarrs

Differential Revision: D1408001