Skip to content

Silence some error output in the presence of multi-step commands #7215

Open
@rickyvetter

Description

@rickyvetter

I am calling wasm-merge, wasm-metadce, and wasm-opt in sequence and the output of the first two steps both errors with "Some VMs may not accept this binary because it has a large number of locals in function". I think it makes sense to silence this error with some flag that implies that the result isn't final or that there are further optimizations that will be applied.

I'm not confident if this is the only type of error that it makes sense to do something like this and how special-cased the solution might be.

Activity

kripken

kripken commented on Jan 15, 2025

@kripken
Member

Does the --quiet flag not help there? If not then maybe we should make it apply to that. Another option might be -w to silence all warnings, perhaps, which I don't think we have yet. (I'm not sure which option is best.)

rickyvetter

rickyvetter commented on Jan 15, 2025

@rickyvetter
Author

This error isn't gated behind a --quiet check.

std::cerr << "Some VMs may not accept this binary because it has a large "

I think either that or -w would be an improvement but maybe not ideal. My hesitancy with recommending either of those directly was around how this does feel like a context-dependent hard error. As a final artifact, this wasm file would be unusable and so in that context a --quiet silencing the error report would be a shame.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

      Participants

      @kripken@rickyvetter

      Issue actions

        Silence some error output in the presence of multi-step commands · Issue #7215 · WebAssembly/binaryen