Details
Diff Detail
- Repository
- rG LLVM Github Monorepo
Event Timeline
FYI this change had some pretty significant impact on compile-time (https://llvm-compile-time-tracker.com/compare.php?from=4718ec01669b01373180f4cd1256c6e2dd6f3999&to=f748e92295515ea7b39cd687a718915b559de6ec&stat=instructions) and code size (https://llvm-compile-time-tracker.com/compare.php?from=4718ec01669b01373180f4cd1256c6e2dd6f3999&to=f748e92295515ea7b39cd687a718915b559de6ec&stat=size-text). Is that expected?
I took a closer look at what the legacy unswitch pass does in regards to -O2/3/s/z, and it skips non-trivial unswitching for anything other than -O3. So in the -O3 case I think the increased compile time and code size is expected. But the other cases should be fixed, I'll do that.
(weird that sqlite3 is an outlier and compiles 11% faster with this change though)
(also it would be nice to have -O1/2/s/z runs on llvm-compile-time-tracker, but of course you can only test so many configurations)
I'm curious if the compile time impact is complemented by impact in run time. Looking into that for O3.