Fix hphpc inferring return types of builtin funcs that are ParamCoerceMode

hphpc's symbolic stack was treating the return types of builtin
functions as gospel, and not accounting for the fact they might be
marked as ParamCoerceMode. The fix is to predict the return type
instead of inferring it.

Reviewed By: @markw65

Differential Revision: D1276687
Fix dns_get_record with ipv6 only nameservers in /etc/resolv.conf

Every dns lookup needs to zero and re-init the resolver state,
otherwise undefined behaviour can happen.  With IPv4 nameservers in
/etc/resolv.conf, things seemed to work just fine, but when IPv6
namesevers are in /etc/resolv.conf, then the second request to
res_nsearch failed since it was not re-initialized.  This matches what
is done in php-git.

Reviewed By: @ptarjan

Differential Revision: D1281701
Remove JIT:: in some places where it's unnecessary

Reviewed By: @jdelong

Differential Revision: D1281421
Add String(const StringData*) = delete to type-string

Found two broken things.

Reviewed By: @jano

Differential Revision: D1274141
Remove the explicit Variant(const StaticString*) constructor

If you have explicit constructors that can't be used (because
it's not an explicit call), implicit constructors may be used after
other conversions.  So, for example:

  struct foo {
    foo(bool);
    explicit foo(const char*);
  };
  void f(foo);
  int main() {
    const char* a = "heh";
    f(a);   // calls foo::foo(bool)  :-(
  }

Which is error prone and surprising.  This was why constructing String
implicitly with const StringData*'s was calling Variant(bool) and then
String(Variant&&).  (Deleted another way in D1274141, which seems
worth leaving in also.)

Reviewed By: @jano

Differential Revision: D1281739
Refactor EZC wrapper funcs to allow disabling EZC core

When we build without -DENABLE_ZEND_COMPAT none of EZC gets built
and builtinFuncPtr aims at unimplementedWrapper instead.

Reviewed By: @ptarjan

Differential Revision: D1280370
Let you run cmake from the top dir

detect our weird facebook config using relative direcotires

Reviewed By: @sgolemon

Differential Revision: D1281644
Fix for Xenon build on Mac

Disabling Xenon on the Mac, because of its lack of support for POSIX timers.

Reviewed By: @scannell

Differential Revision: D1282790
tc-print: break down perf events in TC by translation kind

For any sample of any event that's in the TC, bucketize it according to
the TransKind it occurred in, and print those counts in the output header.

Example: P9064864

Reviewed By: @edwinsmith

Differential Revision: D1282153
Fix ref counting bug in HhbcTranslator::pushStLoc

The following IR was being produced:

  t0:BoxedObj = LdLoc<BoxedObj,0> <--- t0 made by "global $var;"
  t1:Obj = LdStack<Obj,0>
  t2:Obj = LdRef<Obj> t0:BoxedObj

  StRef t0:BoxedObj, t1:Obj
  DecRef t2: Obj <--- runs destructor that modifies t0, and destructs t1
  IncRef t1:Obj

Fixes HhbcTranslator::pushStLoc to emit the IncRef before the DecRef.

Reviewed By: @swtaarrs

Differential Revision: D1280928
Don't assume predicted output type for interpOne

Returning inst.outPred from this function will turn the prediction
CheckStk into a nop.

Reviewed By: @edwinsmith

Differential Revision: D1282067
fix spelling error: Sytem => System

Reviewed By: @ptarjan

Differential Revision: D1283747
Disallow closing tag even in decl mode

HHVM disallows this and so we should be consistent. IMO it
makes sense for us to be stricter. Having a closing tag indicates a
fundamental misunderstanding of the way Hack works -- mixed HTML and PHP
just doesn't fly anymore. Hack is a programming language, not an HTML
processor. So it makes sense to ban this even in decl mode, IMO.

Closes #2390

Reviewed By: @pikatchu

Differential Revision: D1280962
allow open source people to use the wrapper

I've loved the wrapper. Lets share it with the world.

Reviewed By: @jdelong

Differential Revision: D1284108
don't seek to end of destination in stream_copy_to_stream

- Doesn't break any stream related tests.
- php-src doesn't seem to do the seek:
  https://github.com/php/php-src/blob/8d4ee1dbedcd339f119f04058e72eebba272bdb5/main/streams/streams.c#L1496

See the test for an example of how this would break.

Fixes #2453.
Closes #2463

Reviewed By: @ptarjan

Differential Revision: D1279649

Pulled By: @sgolemon
Move PCRE constants to ext/pcre and add missing constant

The pcre HNI conversion didn't move its constants out of constants.idl.json
so let's move them where they belong first, then apply PR#2462 to add the missing
one.

Closes #2462

The move portion of this diff was done by sgolemon, the add missing constant
was supplied by deguif.

Reviewed By: @ptarjan

Differential Revision: D1279611

Pulled By: @sgolemon
"break A::" should display "Breakpoint was not set in right format." instead of assertion error

Should close #2410
Closes #2412

Reviewed By: @ptarjan

Differential Revision: D1277965

Pulled By: @sgolemon
Update third-party
Sync TLD files

My export script was a little busted...
actually unopen source things that aren't open source

Over the years we've had various files held back from the OSS push for one reason or another. Well, lets stop that. Things in the /facebook/ dir aren't open source, everything else is.

This is the last of 'em.

Reviewed By: @sgolemon

Differential Revision: D1283193