Skip to content

[SYCL] Fix some incorrect diagnostic wording; NFC #3705

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Merged
merged 1 commit into from
May 11, 2021
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
8 changes: 4 additions & 4 deletions clang/include/clang/Basic/DiagnosticSemaKinds.td
Original file line number Diff line number Diff line change
Expand Up @@ -11328,7 +11328,7 @@ def warn_sycl_kernel_too_big_args : Warning<
"size of kernel arguments (%0 bytes) may exceed the supported maximum "
"of %1 bytes on some devices">, InGroup<SyclStrict>, ShowInSystemHeader;
def err_sycl_virtual_types : Error<
"No class with a vtable can be used in a SYCL kernel or any code included in the kernel">;
"no class with a vtable can be used in a SYCL kernel or any code included in the kernel">;
def note_sycl_recursive_function_declared_here: Note<"function implemented using recursion declared here">;
def err_sycl_non_trivially_copy_ctor_dtor_type
: Error<"kernel parameter has non-trivially %select{copy "
Expand All @@ -11349,7 +11349,7 @@ def err_sycl_attribute_internal_function
: Error<"%0 attribute cannot be applied to a "
"static function or function in an anonymous namespace">;
def err_sycl_compiletime_property_duplication : Error<
"Can't apply %0 property twice to the same accessor">;
"can't apply %0 property twice to the same accessor">;
def err_sycl_invalid_property_list_param_number : Error<
"%0 must have exactly one template parameter">;
def err_sycl_invalid_accessor_property_template_param : Error<
Expand All @@ -11363,10 +11363,10 @@ def err_sycl_num_kernel_wrong_reqd_wg_size : Error<
"%0 attribute must evenly divide the work-group size for the %1 attribute">;

def warn_sycl_pass_by_value_deprecated
: Warning<"Passing kernel functions by value is deprecated in SYCL 2020">,
: Warning<"passing kernel functions by value is deprecated in SYCL 2020">,
InGroup<Sycl2020Compat>, ShowInSystemHeader;
def warn_sycl_pass_by_reference_future
: Warning<"Passing of kernel functions by reference is a SYCL 2020 extension">,
: Warning<"passing of kernel functions by reference is a SYCL 2020 extension">,
InGroup<Sycl2017Compat>, ShowInSystemHeader;
def warn_sycl_implicit_decl
: Warning<"SYCL 1.2.1 specification requires an explicit forward "
Expand Down
4 changes: 2 additions & 2 deletions clang/test/CodeGenSYCL/kernel-by-reference.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -15,15 +15,15 @@ int simple_add(int i) {
int main() {
queue q;
#if defined(SYCL2020)
// expected-warning@#KernelSingleTask2017 {{Passing kernel functions by value is deprecated in SYCL 2020}}
// expected-warning@#KernelSingleTask2017 {{passing kernel functions by value is deprecated in SYCL 2020}}
// expected-note@+3 {{in instantiation of function template specialization}}
#endif
q.submit([&](handler &h) {
h.single_task_2017<class sycl2017>([]() { simple_add(10); });
});

#if defined(SYCL2017)
// expected-warning@#KernelSingleTask {{Passing of kernel functions by reference is a SYCL 2020 extension}}
// expected-warning@#KernelSingleTask {{passing of kernel functions by reference is a SYCL 2020 extension}}
// expected-note@+3 {{in instantiation of function template specialization}}
#endif
q.submit([&](handler &h) {
Expand Down
2 changes: 1 addition & 1 deletion clang/test/SemaSYCL/buffer_location.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -86,7 +86,7 @@ int main() {
accessorD.use();
//expected-error@+1{{sixth template parameter of the accessor must be of accessor_property_list type}}
accessorE.use();
//expected-error@+1{{Can't apply buffer_location property twice to the same accessor}}
//expected-error@+1{{can't apply buffer_location property twice to the same accessor}}
accessorF.use();
#endif
});
Expand Down