The man pages for
grep on Ubuntu 18.04 and CentOS 8 have this to say about the
-P option for grep:
-P, --perl-regexp Interpret the pattern as a Perl-compatible regular expression (PCRE). This is experimental and grep -P may warn of unimplemented features.
I have put emphasis on "experimental" and "may warn". Experimental implies it's not suitable for production. "may warn" implies that you could run into an unimplemented feature and
grep could fail to warn you about it.
On older versions of
grep, I have even seen the phrase "highly experimental" instead of just "experimental".
-P option to GNU
grep safe to use in production? Some of my bootstrapping scripts need certain perl features, so this option is quite useful to me when perl has not already been installed/included.