I have a c++ program I am running from julia that acts as the inner loop of a simulation (actually its a game engine). I’ve been playing with lots of derivative free optimizations, and tried the FiniteDiff package which kind of works but very slowly. Then I had the (possibly crazy) idea compile it to LLVM IR then pass that to Julia.
- Could I run that IR code from Julia?
- Could I use Enzyme to do autodiff on the results?