Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

List possible implementation limits #438

Merged
merged 5 commits into from
Sep 20, 2023
Merged
Changes from 1 commit
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
9 changes: 8 additions & 1 deletion document/core/appendix/implementation.rst
Original file line number Diff line number Diff line change
Expand Up @@ -41,6 +41,9 @@ An implementation may impose restrictions on the following dimensions of a modul
* the number of :ref:`data segments <syntax-data>` in a :ref:`module <syntax-module>`
* the number of :ref:`imports <syntax-import>` to a :ref:`module <syntax-module>`
* the number of :ref:`exports <syntax-export>` from a :ref:`module <syntax-module>`
* the number of :ref:`sub types <syntax-subtype>` in a :ref:`recursive type <syntax-rectype>`
* the subtyping depth of a :ref:`sub type <syntax-subtype>`
* the number of fields in a :ref:`structure type <syntax-structtype>`
* the number of parameters in a :ref:`function type <syntax-functype>`
* the number of results in a :ref:`function type <syntax-functype>`
* the number of parameters in a :ref:`block type <syntax-blocktype>`
Expand All @@ -50,7 +53,8 @@ An implementation may impose restrictions on the following dimensions of a modul
* the size of a :ref:`structured control instruction <syntax-instr-control>`
* the number of :ref:`structured control instructions <syntax-instr-control>` in a :ref:`function <syntax-func>`
* the nesting depth of :ref:`structured control instructions <syntax-instr-control>`
* the number of :ref:`label indices <syntax-labelidx>` in a |brtable| instruction
* the number of :ref:`label indices <syntax-labelidx>` in a |BRTABLE| instruction
* the length of the array in a |ARRAYNEWFIXED| instruction
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

AFAICT this is also limited by the bytecode length, but I'm fine specifying it separately this way.

Do we have a limitation on the size of an initializer expression?

Copy link
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Good point, added.

* the length of an :ref:`element segment <syntax-elem>`
* the length of a :ref:`data segment <syntax-data>`
* the length of a :ref:`name <syntax-name>`
Expand Down Expand Up @@ -124,8 +128,11 @@ Restrictions on the following dimensions may be imposed during :ref:`execution <
* the number of allocated :ref:`table instances <syntax-tableinst>`
* the number of allocated :ref:`memory instances <syntax-meminst>`
* the number of allocated :ref:`global instances <syntax-globalinst>`
* the number of allocated :ref:`structure instances <syntax-structinst>`
* the number of allocated :ref:`array instances <syntax-arrayinst>`
* the size of a :ref:`table instance <syntax-tableinst>`
* the size of a :ref:`memory instance <syntax-meminst>`
* the size of an :ref:`array instance <syntax-arrayinst>`
* the number of :ref:`frames <syntax-frame>` on the :ref:`stack <stack>`
* the number of :ref:`labels <syntax-label>` on the :ref:`stack <stack>`
* the number of :ref:`values <syntax-val>` on the :ref:`stack <stack>`
Expand Down
Loading