Skip to content

feat: build function with reactant#1799

Draft
avik-pal wants to merge 3 commits intoJuliaSymbolics:masterfrom
avik-pal:ap/reactant_lowering
Draft

feat: build function with reactant#1799
avik-pal wants to merge 3 commits intoJuliaSymbolics:masterfrom
avik-pal:ap/reactant_lowering

Conversation

@avik-pal
Copy link
Contributor

@avik-pal avik-pal commented Feb 12, 2026

@ChrisRackauckas @AayushSabharwal can I get an initial review here? I will follow up with tests.

@ChrisRackauckas
Copy link
Member

How does one compile those expressions?

@avik-pal
Copy link
Contributor Author

How does one compile those expressions?

It is possible (though a bit annoying). My assumption was the expression == Val{true} case was more for diagnosis?

I can add a helper to compile MlirModule in reactant, which would mean you can do compile(returned_expr, args...)

@ChrisRackauckas
Copy link
Member

Not really. It's more for caching so that the user can compile later, or use with precompilation.

@AayushSabharwal
Copy link
Member

MTK only uses expression = Val{true} so it can control when and how things are compiled, along with being able to generate expressions that evaluate to the desired ODEProblem (as opposed to the ODEProblem itself). We can say that the latter is not supported with ReactantTarget but being able to control which module the code is compiled in is essential.

@avik-pal
Copy link
Contributor Author

Can you point me to where this happens in MTK? We already have a serialization setup in Reactant which exports the expression into a standalone file.

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.

3 participants