File tree Expand file tree Collapse file tree 2 files changed +8
-0
lines changed Expand file tree Collapse file tree 2 files changed +8
-0
lines changed Original file line number Diff line number Diff line change @@ -4147,6 +4147,8 @@ class OffloadingActionBuilder final {
4147
4147
continue ;
4148
4148
}
4149
4149
}
4150
+ if (Args.hasArg (options::OPT_fsyntax_only))
4151
+ OutputType = types::TY_Nothing;
4150
4152
A = C.MakeAction <CompileJobAction>(A, OutputType);
4151
4153
DeviceCompilerInput = A;
4152
4154
}
Original file line number Diff line number Diff line change 1118
1118
// RUN: %clang -### -fsycl -ffreestanding %s 2>&1 \
1119
1119
// RUN: | FileCheck -check-prefix=CHK-INCOMPATIBILITY %s
1120
1120
// CHK-INCOMPATIBILITY: error: The option -fsycl conflicts with -ffreestanding
1121
+
1122
+ /// Using -fsyntax-only with -fsycl should not emit IR
1123
+ // RUN: %clang -### -fsycl -fsyntax-only %s 2>&1 \
1124
+ // RUN: | FileCheck -check-prefixes=CHK-FSYNTAX-ONLY,CHK-NO-EMIT-IR %s
1125
+ // CHK-FSYNTAX-ONLY: clang{{.*}} "-cc1" "-triple" "spir64-unknown-unknown"{{.*}} "-fsyntax-only"
1126
+ // CHK-NO-EMIT-IR-NOT: "-emit-llvm-bc"
You can’t perform that action at this time.
0 commit comments