https://gcc.gnu.org/bugzilla/show_bug.cgi?id=62173
--- Comment #24 from Jiong Wang <jiwang at gcc dot gnu.org> --- (In reply to amker from comment #23) partially agree. at least for the single use case given by Seb, I think tree ivopt should do it. (I verified clang do ivopt correctly for the case) for the rtl re-associate, it's a little bit painful from my experiment experiences. as it's not always good to reassociate virtual_frame + offset, we can only benefit if it's in loop, because the re-associate will increase register pressure, there will be situations that more callee-saved regs used, and finally we run into unncessary push/pop in pro/epilogue... and I haven't found a good place where we can safely re-use existed rtl info and do the rtl re-association as I am afraid rebuild those rtl info will cause compile time penalty.