WebAssembly / WebAssembly/custom-descriptors

Implementation limits for `configureAll`

Open
#98 0 comments 2 reactions 0 assignees View on GitHub

Nobody has claimed this yet.

Dominant language
WebAssembly
Stars
12
Forks
3
Avg merge
3d 2h
Merged PRs (30d)
1

Description

The configureAll method allows creating JS objects with a potentially large amount of fields.

Similarly to how we have implementation limits for the number of fields in a structure, it probably makes sense to limit the number of properties / methods we allow to setup using configureAll in a JS object.
JS implementations surely have internal limits on object sizes (V8 definitely does), so they will eventually crash or throw if the number of properties is excessively large. To ensure consistency and interoperability between implementations, it's probably useful to have such a limit be spec'ed, similar to other Wasm limits, a value of 10K or 100K properties per prototype and constructor might work.

A value higher than the limit should throw before any method is installed on the "current" prototype / constructor object in the configureAll configuration data (so semantically at the point where the vector size in the configuration data is located).

Contributor guide

Open the contributing guide

First steps

  1. Read the whole issue, then the project's contributing guide.
  2. Comment on the issue to say you are picking it up — it saves two people doing the same work.
  3. Fork the repository and make your change on a branch.
  4. Open a pull request that references the issue number.

Research direction

Start by reviewing the configureAll method and the existing implementation limits for structure fields. Determine an interoperable limit for properties and methods per prototype and constructor, then specify behavior for values above it. Done means the limit and the point at which configureAll throws before installing methods are defined consistently.

Written by the indexing model from the issue text.

Assessment

Tech stack
wasm
Domain
compilers
Issue type
Feature
Difficulty
5/5
Estimated time
Over a week
Activity status
Stale
Clarity
Mostly clear
Newbie friendliness
35/100

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.