https://gcc.gnu.org/bugzilla/show_bug.cgi?id=81504
--- Comment #5 from Bill Schmidt <wschmidt at gcc dot gnu.org> --- OK, so the problem is in the swaps pass. It's just that the add of 16 is correctly placed in every prior optimization pass following ivopts, which has shifted it around in the usual fashion. Prior to swap optimization, the store is performed to the address prior to the add of 16, but following swap optimization, it is performed to the address following the add of 16. This is a post-pass performed after the usual swap optimization to identify patterns that should be turned into an lvx or stvx. However, there appears to be a bug wherein the source operand chosen is not checked for continued availability at the point of the store. The register chosen has been overwritten, leading to incorrect code.