https://gcc.gnu.org/bugzilla/show_bug.cgi?id=122215
--- Comment #11 from Jeffrey A. Law <law at gcc dot gnu.org> --- Been in meetings all day, but I think this is likely latent on the trunk. I can trigger the valgrind warning on the trunk in the same spot. Essentially we're getting back a value for hregno that is out of range for the costs array. The case where it's happening? Register "s1".
