To elaborate, I really enjoyed reading Dennis Ritchie give some background on the evolution of Unix[1]:
> As a historical curiosity, in the very first versions of Unix chdir was a normal command rather than a shell builtin.
> You see, at that point Unix had no fork system call. There were multiple processes, but they were created statically at startup rather than on-demand. Running a command in the shell would cause the command to replace the shell in the address space of the process, and the process quitting would put the shell back in there.
> This worked perfectly with cd being a normal command. Then they implemented fork() and were for a while very confused trying to debug how in the world fork() could have broken the chdir() system call :)
Thanks @gtirloni! I'm new to SQL and was working on a small internal tool. This change, an obvious one in hindsight, sped up my tool by ~2-3x. So for anyone else, check this!