diff options
author | Alon Zakai <azakai@google.com> | 2022-11-15 11:21:44 -0800 |
---|---|---|
committer | GitHub <noreply@github.com> | 2022-11-15 11:21:44 -0800 |
commit | 0ffafa5d4f4bca8a6ab77e193caacc5292218a5d (patch) | |
tree | b0ea0aa88f03e231ec746f2ad18f394106ac6c3e /src/wasm-binary.h | |
parent | 59cbdd818dc3397a823a37e9821fd32f4522b2fc (diff) | |
download | binaryen-0ffafa5d4f4bca8a6ab77e193caacc5292218a5d.tar.gz binaryen-0ffafa5d4f4bca8a6ab77e193caacc5292218a5d.tar.bz2 binaryen-0ffafa5d4f4bca8a6ab77e193caacc5292218a5d.zip |
GlobalStructInference: Handle the case of just 1 value (#5259)
#5253 handled the case of just one possible global. It is also possible we have
multiple globals but just one value. This handles that case. (It slightly overlaps
with other passes, but as this pass actually identifies the creations of the objects
in globals, it has a guarantee of success that the others don't, and it is very easy
to just do given all the work done to handle the case of 2 values).
Also fix a minor bug in #5253 - we need to trap if the old reference were null.
That is, we know the reference must point to the only object ever created of
that type, but that is only if it is not null; if it's null we need to trap.
Diffstat (limited to 'src/wasm-binary.h')
0 files changed, 0 insertions, 0 deletions