[swift-dev] Tips for debugging interactions between optimization passes
me at benng.me
Fri Mar 3 11:58:43 CST 2017
I noticed that adding any semantic attribute to the two Array.append functions causes performance regressions in the Array benchmark. I think that it’s because the delayed inlining is blocking some array optimizations from happening.
What are some tips for debugging this sort of issue? There are a whole bunch of passes, and it’s difficult to figure out how they all interact. Reading the SIL generated after all optimizations have been run is pretty tedious, and I’m hoping that there’s a smarter way to go about this.
Can I get debug output that tells me what optimizations happened, and then diff the two outputs to find out what changed?
I also see a “Pass Pipeline” utility that looks useful, but it’s not obvious to me how to use it.
-------------- next part --------------
An HTML attachment was scrubbed...
More information about the swift-dev