From 1c98ff49a30b88a2601b92e8702ff2058c4fc226 Mon Sep 17 00:00:00 2001 From: "Yaxun (Sam) Liu" Date: Tue, 22 Oct 2019 16:15:04 -0400 Subject: [PATCH] Fix name of warn_ignored_hip_only_option Differential Revision: https://reviews.llvm.org/D69268 --- clang/include/clang/Basic/DiagnosticCommonKinds.td | 2 +- clang/lib/Frontend/CompilerInvocation.cpp | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/clang/include/clang/Basic/DiagnosticCommonKinds.td b/clang/include/clang/Basic/DiagnosticCommonKinds.td index 4091195..6018c14 100644 --- a/clang/include/clang/Basic/DiagnosticCommonKinds.td +++ b/clang/include/clang/Basic/DiagnosticCommonKinds.td @@ -305,7 +305,7 @@ def err_openclcxx_not_supported : Error< "'%0' is not supported in C++ for OpenCL">; // HIP -def warn_ignore_hip_only_option : Warning< +def warn_ignored_hip_only_option : Warning< "'%0' is ignored since it is only supported for HIP">, InGroup; diff --git a/clang/lib/Frontend/CompilerInvocation.cpp b/clang/lib/Frontend/CompilerInvocation.cpp index 767a071..f6e6f71 100644 --- a/clang/lib/Frontend/CompilerInvocation.cpp +++ b/clang/lib/Frontend/CompilerInvocation.cpp @@ -2532,7 +2532,7 @@ static void ParseLangArgs(LangOptions &Opts, ArgList &Args, InputKind IK, if (Opts.HIP) Opts.GPUAllowDeviceInit = 1; else - Diags.Report(diag::warn_ignore_hip_only_option) + Diags.Report(diag::warn_ignored_hip_only_option) << Args.getLastArg(OPT_fgpu_allow_device_init)->getAsString(Args); } Opts.HIPUseNewLaunchAPI = Args.hasArg(OPT_fhip_new_launch_api); -- 2.7.4