Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

[Substrait] Implement simple extensions. #853

Merged

Commits on Jul 31, 2024

  1. [Substrait] Implement simple extensions.

    This is a mechanism of Substrait to define functions and types external
    to the core specification. This PR models the declarations as `Symbol`s
    and references to them as symbol references in MLIR, which allows to use
    MLIR tooling around symbols (such as `SymbolTable`s, iterating over
    symbol uses, code navigation via the LSP server, etc.). The PR does not
    yet implement a mechanism to use the functions and types, which
    subsequent PRs for `ScalarFunction` and similar are going to do.
    
    While touching the `PlanOp`-related test cases, this op also merges the
    tests of that op, which were previously split into a "simple" and a
    "version" file, which probably predates the possibility to tell
    `mlir-translate` (and custom variants) to use output splitters.
    
    Signed-off-by: Ingo Müller <[email protected]>
    ingomueller-net committed Jul 31, 2024
    Configuration menu
    Copy the full SHA
    f94574d View commit details
    Browse the repository at this point in the history
  2. Fix tests of emit deduplication pass.

    In the meantime, `main` contains tests that used `func.call` ops to
    prevent further pattern application. This breaks with this PR, which
    makes `plan`s a `SymbolTable`, which become the closest symbol table of
    the `func.call`s, such that those symbols cannot be found anymore. As a
    solution, this commit changes the unit tests to use an opaque op from an
    unregistered dialect.
    
    Signed-off-by: Ingo Müller <[email protected]>
    ingomueller-net committed Jul 31, 2024
    Configuration menu
    Copy the full SHA
    35b8f45 View commit details
    Browse the repository at this point in the history