Sync parser generator with upstream
Don't crash reversing empty Vectors

In a new, empty vector start and end are null.
Don't cse LdCns

Because in php, constants aren't.
Simplify test output
"trait implements" syntax
Fix __HALT_COMPILER() support

Actually halt the compiler, and set __COMPILER_HALT_OFFSET__ constant
Remove deprecated asio_* methods

Remove unused deprecated methods:

- asio_enter_context()
- asio_exit_context()
- asio_get_current()
Inline the outer functions for continuations with no arguments

We store a bunch of data into an ActRec on the stack, then
call a php-level function that calls a C++ function to copy it into an
ActRec on the heap.  This should hopefully be a little better.
Kill alwaysLowMem

We're hitting the assert in some jobs (see task) and it's not
a measureable win.
Remove many of the genFoo functions from tracebuilder

Removes most of the wrappers in favor of gen(). Does two
cases that actually had logic by adding a new "preOptimize" pass where
TraceBuilder can use tracked state to modify instructions before they
go to the simplifier.
TraceBuilder and VectorTranslator get forwarding gen() helpers

s/m_tb(->|\.)gen/gen/
Simplifier gets gen()/cns(), replace genDefConst with cns outside tracebuilder

Also removes simplifier's genDef{Bool,Dbl,Int}.
Fix arithmetic op uses of type paramters, get rid of gen{Sub,Mul,...}

These guys were determining their output type with DParam,
even though the output type was a function of the input types.  Fixed
this and then get rid of the genFoo wrappers.  Move binArithResultType
out of Type.  OpMod didn't need a type parameter.
Rename TraceBuilder::genDefConst to cns()

Closer to the same instruction creation api in each.
Remove genDecRef from TraceBuilder

Replace with a preOptimizeDecRef.  Also caught a pseudo-issue
where we relied on the isRefCounted short-circuit for correctness (we
called genDecRef on Type::Cls).  That short-circuit is duplicated in
simplifier, and is stateless, so let's leave it there.  Remove some
dead code about BoxedCells and replace it with a comment in
ir.specification based on a conversation with @bsimmers.

(This is on top of all the other related diffs.)
Move gen{Guard,Assert}Loc logic to updateTrackedEffects/preOptimize

GuardLoc drops into preOptimize.  genAssertLoc did two things
based on a bool---one of which needed logic in preOptimize, and the
other which implied something for updateTrackedEffects (and was
handled in hhbctranslator).  Also removes genLdAssertedLoc---it's not
an instruction; I considered an emitLdAssertedLoc but since this is
only used in a few places (less than a LdIncRefLoc would be) it seemed
fine to just flatten.
Document TraceBuilder/HhbcTranslator/Simplifier @override-unit-failures

Adds comments explaining the role of each of these modules.
The comments explain the roles as I am planning to make them, not as
they actually are, so they are currently partially lies.  (I will move
EvalStack into TraceBuilder, and get the remaining "dubious" gen
routines out to HhbcTranslator on top of this diff.)
Remove some easy remaining TraceBuilder::genFoo functions

This diff should have nothing very interesting in it.
Remove genAssertStk/genCastStk and move their optimizations to Simplifier

The elimination of these is stateless, so it's going to
simplifier (along with getStackValue).  Other stack functions are
still here until I move EvalStack to tracebuilder.
Move ConvFooToBool selection to Simplifier

This is stateless---and it's possible the second
simplification pass may be able to perform more of it if operand types
change somehow (wishful thinking?).