https://gcc.gnu.org/bugzilla/show_bug.cgi?id=101995
--- Comment #11 from Segher Boessenkool <segher at gcc dot gnu.org> --- Yeah, that could be much more robust. OTOH this stuff is completely opportunistic in the first place: it handles only function return values, not any other hard registers (like local register vars).