Fix includes in curl_tls_workarounds.cpp

raise_notice() wasn't declared in this file, so include runtime_error.h.
This caused further problems with ATTRIBUTE_PRINTF not being defined
yet, so include some more stuff.
Most constructors return null

So annotate the PopR to avoid generating code.
HHIR: Optimized useless incref-decref pairs.

Incref-Decref pairs whose incref'ed SSATmp is not used by any
other instruction other than the decref can be eliminated when the
type of the refcounted value has no destructor (i.e., strings and
boxed strings). This commonly occurs for stores to memory (e.g., SetS,
SetG, and SetM) followed by PopC.

For example:

  47: SetS
    (32) t16:PtrToGen = LdClsPropAddrCached t9:Cls, "s1", "c", Cls(0)
    (33) t17:PtrToCell = UnboxPtr t16:PtrToGen
    (34) t18:Cell = LdMem<Cell> t17:PtrToCell, 0
    (35) t19:Str = IncRef t15:Str
    (36) StMem [t17:PtrToCell]:Str, t15:Str
    (37) DecRef t18:Cell
  48: PopC
    (39) DecRef t19:Str

In this example, eliminating the DecRef instruction (39) along with
its IncRef (35) may cause the string referenced by t19 to be destroyed
earlier in the DecRef instruction (37), but this is safe because
destroying strings has no visible side effects.

This diff eliminates these pairs.

Note that its not safe to do this for types that have destructors with
side effects. Applying this optimization to decref'ed types that have
destructors could change the order of those side effects with respect
to the side effects in instruction (37). A follow-on diff will change
the DecRef (37) to bail the trace when it has to run a destructor to
enable this for the general case.
Implement Tuple

Implement a Tuple class as part of collections.
Fix assertion when target==analyze

Option::OutputHHBC should always be true.
Fix StringBuffer::resize()

capacity doesnt include the terminating null, so len is
allowed to grow to capacity (not capacity - 1).
Initialize local that receives an error code only if there is actually an error.

uidna_openUTS46 overwrites its error code argument only if
there is actually an error. Hence, if the variable is not initialized to
zero it may seem to the calling code that an error has ocurred. This
diff initializes the variable and re-enables the failing test.
Fixed problems with HHIR's LdObjMethod instruction

This diff fixes problems with FPushObjMethodD stack unwinding, to HHIR.
This diff simply moves the try-catch into the methodCacheSlowPath.
This should also improve the code generated by gcc for the fast path.
Introduce callee-saved-regs clobber macro

Self-explanatory. The list of callee-saved regs on ARM comes from the
ARMv8 Procedure Call Standard.
Re-Tighten live register calculations

Compute the registers that are live across each IR instruction, rather
than the live-out set.  I noticed this while working on a fix for the
CallBuiltin instruction.

We currently compute which registers are live-out from each instruction,
then use the sets to push/pop callee-saved registers around native calls.
cgCallHelper() has a hack to remove destination registers from this set,
but it's not always precise, because we sometimes call cgCallHelper with
different dest registers than were assigned to the instruction, which
(rarely) can cause unnecessary spilling.

In one case cgLdClsMethodFCache(), one of the src tmps is copied to a
destination before the internal call; in that case the dst is not live
across the whole instruction but the value must still be preserved
across the call.  Easy fix: mark it live before cgCallHelper().
Implement specialized array setting in VectorTranslator

This mimics what TranslatorX64 does in translateSetMArray,
but it does it with fewer helpers and (often) fewer instructions in
translated code. I also found a bug in both jits and the interpreter
when dealing with arrays that hold refs to themselves. The new test
case exercises the fix, which involved a bit of refactoring of the
refcounting logic.

Enabling VectorTranslator while punting to tx64 is no longer a
regression so I removed the punt in emit().
Implement support for stack bases in VectorTranslator

Any vector instructions that take a pointer to a base and might modify
it are now flagged with MayModifyStack. Any that actually do modify the stack
(this can be determined by looking at the input types) will produe two dests:
their original result and a new StkPtr. getStackValue calls into VectorEffects
to extract the new type and/or value. The instructions currently assume that
the stack cell they might be modifying is already synced to memory. This may
change in the future when we don't have to do a full SpillStack before the
helpers.
Print relative offsets in Eval.JitCompareHHIR

This diff adds a relativeOffsets option to Disasm, which will print
code addresses as relative offsets from the beginning of the tracelet instead
of absolute addresses. This format makes it much easier to compare the relative
sizes of the instructions selected by the two jits. I also changed the runtime
option to be a double instead of a bool, which is used as the cutoff ratio for
which tracelets to print. Setting it to 1 will print tracelets where the ir
made larger code than tx64, setting it to 2 will print tracelets where the ir's
code is at least twice as big as tx64's, etc...
Eliminate {get,set}NthKid() usage with known specific kid

{get,set}NthKid() should be only used to walk thru all the kids and not to get/set a known specific kid. Replace its use by direct helper method.

All remaining callers of {get,set}NthKid() were audited and there are no instances left accessing specific kid.