WebAssembly / WebAssembly/binaryen

Add an option to emit tracing output to a file

Open
#1,618 0 comments 0 reactions 0 assignees View on GitHub

Nobody has claimed this yet.

help wanted
Dominant language
WebAssembly
Stars
8.6k
Forks
885
Avg merge
1d 19h
Merged PRs (30d)
69

Description

The tracing option in the C API makes it easy to create testcases from code using the C API. It's come up that printing to a file might be better than stdout which is what we currently do. Background: https://github.com/tweag/asterius/issues/22#issuecomment-403305157

For simplicity maybe we can just change the API and make BinaryenSetAPITracing receive a filename (and if people want stdout, they can pass in /dev/stdout).

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 at the BinaryenSetAPITracing C API entry point and trace how tracing output currently reaches stdout. Done means the API accepts a filename for file output, with stdout still usable through the proposed /dev/stdout approach; the payload names no test file, so locate the relevant tracing tests before changing it.

Written by the indexing model from the issue text.

Assessment

Tech stack
c
Domain
api, compilers
Issue type
Feature
Difficulty
3/5
Estimated time
1-2 days
Activity status
Stale
Clarity
Mostly clear
Newbie friendliness
45/100

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.