Skip to content

Document output selection #15744

Open
@cameel

Description

@cameel

Due to performance issues of IR compilation, recently there's been increased interest by frameworks in using outputSelection to select only the actually necessary contracts and outputs. However, this feature and its quirks were never extensively documented, so it's often used inefficiently, with no easy way for users to find out how it was intended to be used.

We really need some docs on:

  • Syntax:
    • The special "*" and "" values and where they can be used.
    • Valid outputs in all input modes (Solidity, Yul, evmasm import).
  • Semantics:
    • Behavior of wildcards, e.g.:
      • Inconsistencies between "*" and "".
      • The fact that "*" does not match experimental outputs (#14363) and a list of such outputs.
      • The fact that patterns like "*.sol" are interpreted literally and only specifically "*" is a wildcard.
    • Behavior of overlapping selections (e.g. "*"/"contract" vs "file.sol"/"*").
    • Other: invalid output names, duplicates, etc.
  • Lazy compilation
    • Which outputs trigger which compilation stages (parsing, analysis, code generation, bytecode generation).
    • Implicit compilation due to bytecode dependencies.
    • How this functionality changed across compiler versions (it's not straightforward to check because an inefficient selection won't usually produce an error).

Metadata

Metadata

Assignees

No one assigned

    Labels

    documentation 📖low effortThere is not much implementation work to be done. The task is very easy or tiny.medium impactDefault level of impactmust have eventuallySomething we consider essential but not enough to prevent us from releasing Solidity 1.0 without it.

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions