Skip to content

chore(bigframes): Add simple Python bytcode translation#17320

Open
TrevorBergeron wants to merge 8 commits into
mainfrom
tbergeron_transpiler_start
Open

chore(bigframes): Add simple Python bytcode translation#17320
TrevorBergeron wants to merge 8 commits into
mainfrom
tbergeron_transpiler_start

Conversation

@TrevorBergeron
Copy link
Copy Markdown
Contributor

Thank you for opening a Pull Request! Before submitting your PR, there are a few things you can do to make sure it goes smoothly:

  • Make sure to open an issue as a bug/issue before writing your code! That way we can discuss the change, evaluate designs, and agree on the general idea
  • Ensure the tests and linter pass
  • Code coverage does not decrease (if any source code was changed)
  • Appropriate docs were updated (if necessary)

Fixes #<issue_number_goes_here> 🦕

Copy link
Copy Markdown
Contributor

@gemini-code-assist gemini-code-assist Bot left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Code Review

This pull request introduces bytecode compilation to BigQuery expressions, along with custom expression classes and unit tests. The reviewer feedback highlights several opportunities for improvement, including handling variables explicitly set to None in LOAD_GLOBAL, refactoring repetitive blocks for older Python binary operations using a module-level mapping, guarding against a potential AttributeError when op_symbol is None in BINARY_OP, and fixing typos and copy-paste errors in exception messages.

Comment thread packages/bigframes/bigframes/core/bytecode.py
Comment thread packages/bigframes/bigframes/core/bytecode.py
Comment thread packages/bigframes/bigframes/core/bytecode.py
Comment thread packages/bigframes/bigframes/core/bytecode.py Outdated
Comment thread packages/bigframes/bigframes/core/py_expressions.py Outdated
Comment thread packages/bigframes/bigframes/core/py_expressions.py Outdated
@TrevorBergeron TrevorBergeron changed the title refactor(bigframes): Add basic disassembly to IR compiler chore(bigframes): Add basic disassembly to IR compiler Jun 3, 2026
@TrevorBergeron TrevorBergeron requested a review from tswast June 3, 2026 23:25
@TrevorBergeron TrevorBergeron marked this pull request as ready for review June 3, 2026 23:25
@TrevorBergeron TrevorBergeron requested review from a team as code owners June 3, 2026 23:25
@TrevorBergeron TrevorBergeron changed the title chore(bigframes): Add basic disassembly to IR compiler chore(bigframes): Add simple Python bytcode translation Jun 3, 2026
@TrevorBergeron TrevorBergeron requested review from GarrettWu and removed request for tswast June 4, 2026 00:09
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant