I'm closing this old Grep bug report, on two grounds:
* I can no longer reproduce the the problem on Fedora 35 x86-64, using Norihiro Tanaka's test case <https://bugs.gnu.org/19420#20>. This suggests the PCRE library has been fixed.
* GNU Grep has switched to PCRE2, so PCRE bugs shouldn't matter now. See <https://bugs.gnu.org/47264>.