This patch adds a new command line option to clang which outputs the directory containing clangs runtime libraries to stdout.
The primary use case for this command line flag is for build systems using clang-cl. Build systems when using clang-cl invoke the linker, that is either link or lld-link in this case, directly instead of invoking the compiler for the linking process as is common with the other drivers. This leads to issues when runtime libraries of clang, such as sanitizers or profiling, have to be linked in as the compiler cannot communicate the link directory to the linker.
Using this flag, build systems would be capable of getting the directory containing all of clang's runtime libraries and add it to the linker path.
One such implementation is in LLVM's CMake scripts which currently gets the path to the builtins library and uses the containing directory. This also has issues however when the builtins library does not exist, which AFAIK is not a prerequisite to using clang-cl. More info here: https://reviews.llvm.org/D98786