WebAssembly / WebAssembly/tool-conventions

Coredumps: Allow truncating locals and operand stack vecs when all values are optimized away

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

Nobody has claimed this yet.

Dominant language
WebAssembly
Stars
372
Forks
75
PR merge metrics
No merged PRs in 30d

Description

In Wasmtime, we don't currently include locals or the operand stack in core dumps currently (although we intend to soon) and in fact have even lost all information about how many locals there were or the size of the operand stack. Therefore, we emit empty vecs for locals and the operand stack, rather than a vec of N missing values, because we don't even know N.

I think this is reasonable behavior for an optimizing compiler, but also something that we should probably explicitly document as acceptable so that coredump-consuming tools are given a heads up and consider this case.

I wanted to bounce this off folks before making a PR adding such language.

Thoughts?

cc @xtuc @dschuff @itsrainy

Contributor guide

No contributing guide indexed for this repository

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

No file or test is identified in the issue. First locate the repository's coredump conventions, then document that optimized-away locals and operand stacks may be represented by empty vectors when their sizes are unknown, and clarify that consuming tools should handle this case.

Written by the indexing model from the issue text.

Assessment

Tech stack
wasm
Domain
documentation
Issue type
Documentation
Difficulty
2/5
Estimated time
1-3 hours
Activity status
Stale
Clarity
Mostly clear
Newbie friendliness
35/100

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.