The parentheses always start a subshell. What's happening is that bash detects that sleep 5 is the last command executed by that subshell, so it calls exec instead of fork+exec. The sleep command replaces the subshell in the same process.
In other words, the base case is:
- ( … )create a subshell. The original process calls- forkand- wait. In the subprocess, which is a subshell:- sleepis an external command which requires a subprocess of the subprocess. The subshell calls- forkand- wait. In the subsubprocess:-  The subsubprocess executes the external command → exec.
-  Eventually the command terminates → exit.
 
-  The subsubprocess executes the external command → 
- waitcompletes in the subshell.
 
- waitcompletes in the original process.
The optimization is:
- ( … )create a subshell. The original process calls- forkand- wait. In the subprocess, which is a subshell until it calls- exec:- sleepis an external command, and it's the last thing this process needs to do.
-  The subprocess executes the external command → exec.
-  Eventually the command terminates → exit.
 
- waitcompletes in the original process.
 When you add something else after the call the sleep, the subshell needs to be kept around, so this optimization can't happen.
 When you add something else before the call to sleep, the optimization could be made (and ksh does it), but bash doesn't do it (it's very conservative with this optimization).
 
                