Closed Bug 1885363 Opened 1 year ago Closed 1 year ago

Merge ModuleEnvironment and Metadata

Categories

(Core :: JavaScript: WebAssembly, task, P3)

task

Tracking

()

RESOLVED DUPLICATE of bug 1891182

People

(Reporter: rhunt, Assigned: bvisness)

References

Details

ModuleEnvironment stores all the metadata needed to validate a module and compile it's functions. Metadata stores all the generic metadata needed by a running instance. The original design was that we could drop any metadata that's not needed at runtime when we move from a ModuleEnvironment to a Metadata object. However, overtime they've almost gotten to the point where they store exactly the same thing. At this point, the only difference appears to be that ModuleEnvironment stores FuncDesc's for all funcs in the module, while Metadata has no need for that.

As we look at supporting profile directed inlining, we'll need the full ModuleEnvironment around to be able to compile functions after runtime. Merging these two classes seems like it would make sense. In order to avoid regressing current workloads, we could free the memory in the FuncDesc vector conditionally for if the inlining flag is enabled.

Assignee: nobody → bvisness

This is made redundant by bug 1891182; should we close this one?

See Also: → 1891182
Status: NEW → RESOLVED
Closed: 1 year ago
Duplicate of bug: 1891182
Resolution: --- → DUPLICATE
You need to log in before you can comment on or make changes to this bug.