diff options
author | Thomas Lively <tlively@google.com> | 2023-01-03 16:22:54 -0600 |
---|---|---|
committer | GitHub <noreply@github.com> | 2023-01-03 16:22:54 -0600 |
commit | e761198190d5c5e6e0a3735c3dab59d02c970e43 (patch) | |
tree | 5390ade9034156baf63f1cd81e843b3888f4345e /src/passes/pass.cpp | |
parent | 938bf992f79257e938d37629e4859b1e09dbbe65 (diff) | |
download | binaryen-e761198190d5c5e6e0a3735c3dab59d02c970e43.tar.gz binaryen-e761198190d5c5e6e0a3735c3dab59d02c970e43.tar.bz2 binaryen-e761198190d5c5e6e0a3735c3dab59d02c970e43.zip |
[Parser] Parse array access instructions (#5375)
* [NFC][Parser] Track definition indices
For each definition in a module, record that definition's index in the relevant
index space. Previously the index was inferred from its position in a list of
module definitions, but that scheme does not scale to data segments defined
inline inside memory definitions because these data segments occupy a slot in
the data segment index space but do not have their own independent definitions.
* clarify comment
* [Parser] Parse data segments
Parse active and passive data segments, including all their variations and
abbreviations as well as data segments declared inline in memory declarations.
Switch to parsing data strings, memory limits, and memory types during the
ParseDecls phase so that the inline data segments can be completely parsed
during that phase and never revisited. Parsing the inline data segments in a
later phase would not work because they would be incorrectly inserted at the end
of the data segment index space.
Also update the printer to print a memory use on active data segments that are
initialized in a non-default memory.
* [Parser] Parse array creation and data segment instructions
* [Parser] Parse array access instructions
Diffstat (limited to 'src/passes/pass.cpp')
0 files changed, 0 insertions, 0 deletions