Support SetM in new minstrs
Summary: This adds new final operation minstrs to handle SetM.
A few things worth calling out:
- The unwinder now DecRefs tvRef/tvRef2 if a minstr throws. This takes the
place of the custom catch traces used by the old minstr instructions.
- FrameState supports member set operations that modify local/stack bases
through pointers that don't come directly from LdLocAddr/LdStkAddr. This
almost never happens in practice but now that we can break tracelets in the
middle of a member operation, it's necessary for correctness. The current
support is extremely conservative; if that turns out to be a problem it can
be refined later.
- Added gen-time load-elim for the member base register, to preserve some of
the optimizations done in irgen-minstr. Track the type when we have to give
up on the specific value. We can stop relying on this if and when we move a
lot of the logic in irgen-minstr to its own pass.
- Fixed a bug in relaxToGuardable() that was causing us to guard on StaticArr
in a pseudomain. Also added an assert in codegen that will catch this if it
happens again, rather than just emitting an incorrect guard.
- Fixed a couple places in member-operations.h where we were returning &tvRef
with tvRef set to Uninit, violating the invariant that the result is &tvRef
iff tvRef isn't Uninit.
Reviewed By: alexmalyshev
Differential Revision:
D2507681
fb-gh-sync-id:
25ee0c2e3e9d0711f64457afe9eb435ca896899e