Skip to content

Comments

WIP: Interpreted MFP evaluation#32021

Draft
antiguru wants to merge 7 commits intoMaterializeInc:mainfrom
antiguru:static_mfp
Draft

WIP: Interpreted MFP evaluation#32021
antiguru wants to merge 7 commits intoMaterializeInc:mainfrom
antiguru:static_mfp

Conversation

@antiguru
Copy link
Member

@antiguru antiguru commented Mar 26, 2025

Only trampoline once!

This adds an alternative evaluation mode for scalar expressions. At the moment, we evaluate expressions by matching on big enums. This form of evaluation is slow and does a lot of repeated work on every invocation.

Instead, we remember a function pointer paired with parameters and call the function directly. While it still comes with an overhead because the function is a separate function, we skip the function enum matching.

Signed-off-by: Moritz Hoffmann mh@materialize.com

Motivation

Tips for reviewer

Checklist

  • This PR has adequate test coverage / QA involvement has been duly considered. (trigger-ci for additional test/nightly runs)
  • This PR has an associated up-to-date design doc, is a design doc (template), or is sufficiently small to not require a design.
  • If this PR evolves an existing $T ⇔ Proto$T mapping (possibly in a backwards-incompatible way), then it is tagged with a T-proto label.
  • If this PR will require changes to cloud orchestration or tests, there is a companion cloud PR to account for those changes that is tagged with the release-blocker label (example).
  • If this PR includes major user-facing behavior changes, I have pinged the relevant PM to schedule a changelog post.

@antiguru antiguru changed the title Static MFP evaluation WIP: Interpreted MFP evaluation Mar 28, 2025
antiguru added 7 commits May 2, 2025 09:58
Signed-off-by: Moritz Hoffmann <mh@materialize.com>
Signed-off-by: Moritz Hoffmann <mh@materialize.com>
Only trampoline once!

Signed-off-by: Moritz Hoffmann <mh@materialize.com>
Signed-off-by: Moritz Hoffmann <mh@materialize.com>
Signed-off-by: Moritz Hoffmann <mh@materialize.com>
Signed-off-by: Moritz Hoffmann <mh@materialize.com>
Signed-off-by: Moritz Hoffmann <mh@materialize.com>
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