Note that once $sessionName has been used to provide a value for $sessionId from the cookie data it is totally redundant as all further reading and writing of the session data is controlled by $sessionId.
If, for any reason, it becomes necessary to identify the value for $sessionName which is associated with the current $sessionId then you should use the value that was passed on the open() method. Attempting to use a value from an alternative source could have unexpected side effects.