[CUDA] Allow using -o with -fsyntax-only
authorArtem Belevich <tra@google.com>
Thu, 1 Sep 2022 18:24:35 +0000 (11:24 -0700)
committerArtem Belevich <tra@google.com>
Thu, 1 Sep 2022 22:52:36 +0000 (15:52 -0700)
commit54c47ff9398fbd5fa7e4120b3286adfb4f736ec8
tree466a427b467bd724d94450ea90624dc6ab6574ec
parentca01c996b2185af08e076d92b39afd96e0567faf
[CUDA] Allow using -o with -fsyntax-only

-fsyntax-only breaks down CUDA compilation pipeline and make it look like
multiple independent subcompilations and that trips the multiple arguments check
when -o is specified.

We do want to allow -fsyntax-only to be used with otherwise unmodified clang
options as it's commonly used by various tooling.

Differential Revision: https://reviews.llvm.org/D133133
clang/lib/Driver/Driver.cpp
clang/test/Driver/cuda-bindings.cu