Search code examples
clangllvmllvm-clang

What are the possible arguments can be passed to the option of -Xclang of the Clang compiler?


I'm using Clang as a front-end of my static analysis tool. I noticed that there is the option -Xclang that allows me to manually manage LLVM passes triggered by Clang.

-Xclang <arg>           Pass <arg> to the clang compiler

I already knew that -Xclang -disable-llvm-passes will disable all passes. But I could not find any good documentation describing what are the possible arguments passed to -Xclang.

Does anyone know where I can find more information about -Xclang?

Thank you very much!


Solution

  • Use clang -cc1 --help to see the full list of options. I believe these options are technically considered "internal" and may change from one release to the next.