Repository navigation
Conversation
0abd87f to
5314ff8
Compare
5314ff8 to
ea35973
Compare
|
API-wise, I think this might make sense, but as in the previous discussion, I think there are competing API concerns. On the one hand a more minimal API is better, and adding a piece of a specific optimization suggests we may want to add many more. (For comparison, I don't think the LLVM C API provides stuff like this.) But on the other hand, maybe this is a common-enough operation, I'm not sure. If we generalize this I'd be a lot more confident. We currently have a way to optimize a module, and maybe we should have a way to optimize an expression by itself, something like That would include |
|
Sure, going to investigate. Now that there's Might need a way to set some options then, i.e. |
|
Closing in favor of #1295. |
As a follow-up to #1288, this PR adds some precompute utility that can be used from the C- and JS-API.
Adds the following function to the C-API:
Respectively, the following to the JS-API:
modulewith the current instance)There is just a simple test for now showing that it's basically working. Though, it seems that the precompute pass does not traverse through constant globals when used in this way. Appreciating any hints.