
workloop:
....
if (RI) // we know the loop will come around
{
  Ralph = SBUF;
}

or

for (Billy = big_number; Billy!=0; Billy--)
{
  if (RI) break;
}
if (RI) // timeout or data ?
{
  Ralph = SBUF;
}