summaryrefslogtreecommitdiff
path: root/src/passes/ConstantFieldPropagation.cpp
diff options
context:
space:
mode:
authorAlon Zakai <azakai@google.com>2023-04-07 09:49:31 -0700
committerGitHub <noreply@github.com>2023-04-07 09:49:31 -0700
commit757d6a21a3c5626cfaa9dac28c28555748b93a6b (patch)
treea056cc39cd95168ced58c5b4357468b70d7fac17 /src/passes/ConstantFieldPropagation.cpp
parent9328b6c1906e2fb91253f65c6983547407c0a77c (diff)
downloadbinaryen-757d6a21a3c5626cfaa9dac28c28555748b93a6b.tar.gz
binaryen-757d6a21a3c5626cfaa9dac28c28555748b93a6b.tar.bz2
binaryen-757d6a21a3c5626cfaa9dac28c28555748b93a6b.zip
[GUFA] Refine global types during flow (#5639)
Previously (ref.as_non_null (global.get ..)) would return the global with no changes, and if the global was nullable then the type didn't match the output, which hit an assertion (where GUFA checks that the contents match the declared type in the wasm). To fix this, refine global types, that is, the type we track on GlobalInfo may be more refined than the global itself. In the above example, if the global is nullable then the GlobalInfo would point to that global but have a non-nullable type. In fact the code was already prepared for this, and few changes were needed.
Diffstat (limited to 'src/passes/ConstantFieldPropagation.cpp')
0 files changed, 0 insertions, 0 deletions