Thank you for your response!
One more thing) Is there a way to know which optimization is on/off? I want to know the progress of cranelift's optimization.
Right now there is one main switch: the opt_level
option is set either to speed
or none
, and that turns on/off the entire optimizer
Oh thank you. And how do I check if an optimization rule written in ISLE under cranelift/codegen/src/opts/
is actually compiled down to cranelift compiler? I want to measure the number of rules that the ISLE compiler is accepting.
All are included; the ISLE compiler doesn't have any notion of not "accepting" a rule
(it does have type errors, but then the entire Cranelift build fails)
So this rule is actually included in the islec-compiled compiler code, but the generated compiler is not optimizing my program. Am I correct?
Ah, yes, there is some subtlety here. I took "included" to mean that the rule is compiled and included in Cranelift. That rule is indeed included in Cranelift. However the entry point for rule execution is not invoked on trapping operators, for the reasons given in that issue above.
So the rule is "included" but never executed
I suppose it's some future-proofing? I'm not sure why we included it otherwise
Thank you. I think now it is clear to me. Have a good rest of your day!
Bongjun Jang has marked this topic as resolved.
No problem, you as well!
Last updated: Jan 24 2025 at 00:11 UTC