As there are two variables in http core module:
$request_uri
This variable is equal to the *original* request URI as received from the client including the args. It cannot be modified. Look at $uri for the post-rewrite/altered URI.
$uri
This variable is equal to current URI in the request (without arguments, those are in $args.) It can differ from $request_uri which is what is sent by the browser. Examples of how it can be modified are internal redirects, or with the use of index.
They are different at subrequest or internal redirects, but it is impossible to define is subrequest or not at server{} part ?
Can I compare some variables to do so?