Skip to content

Commit 2aa2568

Browse files
Artem Gindinsonbader
authored andcommitted
[SYCL][Driver][NFC] Drop obsolete function calls (#841)
Signed-off-by: Artem Gindinson <[email protected]>
1 parent 810312b commit 2aa2568

File tree

1 file changed

+6
-8
lines changed

1 file changed

+6
-8
lines changed

clang/lib/Driver/Driver.cpp

Lines changed: 6 additions & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -755,22 +755,20 @@ void Driver::CreateOffloadingDeviceToolChains(Compilation &C,
755755

756756
// -fsycl-targets cannot be used with -fsycl-link-targets
757757
if (SYCLTargets && SYCLLinkTargets)
758-
Diag(clang::diag::err_drv_option_conflict) << SYCLTargets->getSpelling()
759-
<< SYCLLinkTargets->getSpelling();
758+
Diag(clang::diag::err_drv_option_conflict)
759+
<< SYCLTargets->getSpelling() << SYCLLinkTargets->getSpelling();
760760
// -fsycl-link-targets and -fsycl-add-targets cannot be used together
761761
if (SYCLLinkTargets && SYCLAddTargets)
762-
Diag(clang::diag::err_drv_option_conflict) << SYCLLinkTargets->getSpelling()
763-
<< SYCLAddTargets->getSpelling();
762+
Diag(clang::diag::err_drv_option_conflict)
763+
<< SYCLLinkTargets->getSpelling() << SYCLAddTargets->getSpelling();
764764
// -fsycl-link-targets is not allowed with -fsycl-link
765765
if (SYCLLinkTargets && SYCLLink)
766766
Diag(clang::diag::err_drv_option_conflict)
767-
<< C.getInputArgs().getLastArg(options::OPT_fsycl_link_EQ)->getSpelling()
768-
<< SYCLLinkTargets->getSpelling();
767+
<< SYCLLink->getSpelling() << SYCLLinkTargets->getSpelling();
769768
// -fsycl-targets cannot be used with -fintelfpga
770769
if (SYCLTargets && SYCLfpga)
771770
Diag(clang::diag::err_drv_option_conflict)
772-
<< SYCLTargets->getSpelling()
773-
<< C.getInputArgs().getLastArg(options::OPT_fintelfpga)->getSpelling();
771+
<< SYCLTargets->getSpelling() << SYCLfpga->getSpelling();
774772

775773
bool HasSYCLTargetsOption = SYCLTargets || SYCLLinkTargets || SYCLAddTargets;
776774
llvm::StringMap<StringRef> FoundNormalizedTriples;

0 commit comments

Comments
 (0)