Fix several issues with type assert opcodes
commiteb8f8f3825bc815c6a649b3623d3f7dd147cd3c8
authorJordan DeLong <jdelong@fb.com>
Wed, 15 Jan 2014 00:27:40 +0000 (14 16:27 -0800)
committerSara Golemon <sgolemon@fb.com>
Fri, 17 Jan 2014 09:43:45 +0000 (17 01:43 -0800)
treeabf55199c83498bffae8bd76db8c50f9d27ae8da
parent040e87ba69953e20b7c91f30eb16b8c8522c7ec1
Fix several issues with type assert opcodes

Type assertions were allocating new DynLocations every time
we encountered them, which breaks getOutputUsage (it uses DynLocation
pointer equality to track the flow of values).  When encountering
assertions, it also wasn't doing the optimization that we have in
applyInputMetaData to eliminate earlier predictions on the same
location.  Finally, this diff finishes the support for optional object
types (fixes inlining and object property accesses in these
situations).

Reviewed By: @swtaarrs

Differential Revision: D1128602
hphp/runtime/vm/jit/normalized-instruction.cpp
hphp/runtime/vm/jit/translator.cpp