Passing command line options to LLVM only?

Hey All,

This is a bit of a dumb question but I'm struggling to figure out how to pass a command line option to LLVM only. The closest thing I've found is '-mllvm <option>' which does set the option correctly, however, this appears to also pass the option to the assembler, which throws me an error that my option is unrecognized.

How can I pass a command line option from the clang driver such that it is *only* given to LLVM?

Thanks!
Dillon

Hey All,

This is a bit of a dumb question but I'm struggling to figure out how to pass a command line option to LLVM only. The closest thing I've found is '-mllvm <option>' which does set the option correctly, however, this appears to also pass the option to the assembler, which throws me an error that my option is unrecognized.

How can I pass a command line option from the clang driver such that it is *only* given to LLVM?

I cannot reproduce the problem. Running

clang -### -c -save-temps test.c -Xclang -mllvm -Xclang -mfoo -no-integrated-as

shows -mfoo being passed to "clang -cc1", but not to the assembler. Do
open a bug if you have a case where it is being passed.

Thanks!
Dillon

Cheers,
Rafael