lucy24 - 9:57 pm on Mar 19, 2013 (gmt 0)
depending on the regex engine implemented at compile time
Matter of fact that's the biggest variable I can think of. Not "regex engine" but "compile time". In a config file, Regular Expressions are parsed once, at startup, and then cached. In htaccess they are parsed all over again each time the server meets them. So you could have a setup where Task A takes more time than Task B -- but doing Task A once takes less time than doing Task B many times.
Does "look for 'P' or 'p'" take more time than "look for 'P'" alone? Once you get deep into the bowels of the computer, I doubt there's any inherent connection between P and p. The [NC] has triggered some previous function that tells it to match up 50 and 70. Or 80 and 112, as the case may be.
I don't think I could test it without leading to irate form letters from the host ;) Apparently they tell you when you are using excessive RAM and need to look into a VPS. And despite all the times I've managed to break a php include-- most recently yesterday-- or created a perpetual-motion error,* I've always done it without placing undue strain on server resources.
There exists at least one circumstance where
RewriteRule (.*) $1
does not lead to an infinite loop. This was an entertaining discovery; I've put it in the Trick Questions bin alongside "The light turned green so I had to wait longer".