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

New IR -- WIP #24466

Draft
wants to merge 1 commit into
base: master
Choose a base branch
from
Draft

New IR -- WIP #24466

wants to merge 1 commit into from

Conversation

kasiafi
Copy link
Member

@kasiafi kasiafi commented Dec 13, 2024

See core/trino-main/src/main/java/io/trino/sql/newir/README.md for details.

@cla-bot cla-bot bot added the cla-signed label Dec 13, 2024
@kasiafi kasiafi force-pushed the 526Abstractions branch 2 times, most recently from ed4c70f to 6ea030e Compare December 13, 2024 17:44
@kasiafi
Copy link
Member Author

kasiafi commented Dec 13, 2024

example assembly printout

{
  ^query
      %0 = values() : () -> multiset(row(f_1 bigint, f_2 boolean)) ({
          ^row
              %1 = constant() : () -> bigint ()
                  {constant_result = 3:bigint}
              %2 = constant() : () -> boolean ()
                  {constant_result = true:boolean}
              %3 = row(%1, %2) : (bigint, boolean) -> row(bigint, boolean) ()
              %4 = return(%3) : (row(bigint, boolean)) -> row(bigint, boolean) ()
          }, {
          ^row
              %5 = constant() : () -> bigint ()
                  {constant_result = 5:bigint}
              %6 = constant() : () -> boolean ()
                  {constant_result = false:boolean}
              %7 = row(%5, %6) : (bigint, boolean) -> row(bigint, boolean) ()
              %8 = return(%7) : (row(bigint, boolean)) -> row(bigint, boolean) ()
          })
          {cardinality = 2}
      %9 = filter(%0) : (multiset(row(f_1 bigint, f_2 boolean))) -> multiset(row(f_1 bigint, f_2 boolean)) ({
          ^predicate (%10 : row(f_1 bigint, f_2 boolean))
              %11 = constant() : () -> boolean ()
                  {constant_result = true:boolean}
              %12 = return(%11) : (boolean) -> boolean ()
          })
      %13 = output(%9) : (multiset(row(f_1 bigint, f_2 boolean))) -> io.trino.spi.type.VoidType@5e0ca599 ({
          ^outputFieldSelector (%14 : row(f_1 bigint, f_2 boolean))
              %15 = field_selection(%14) : (row(f_1 bigint, f_2 boolean)) -> bigint ()
                  {field_name = f_1}
              %16 = row(%15) : (bigint) -> row(bigint) ()
              %17 = return(%16) : (row(bigint)) -> row(bigint) ()
          })
          {output_names = [col_a]}
  }

@kasiafi kasiafi force-pushed the 526Abstractions branch 13 times, most recently from 03bdcf5 to 30ed4b3 Compare December 20, 2024 13:00
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Development

Successfully merging this pull request may close these issues.

1 participant