Skip to content
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

Add guidelines for adding FE tests #3122

Merged
merged 6 commits into from
Feb 2, 2021
Merged
Changes from 1 commit
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
14 changes: 14 additions & 0 deletions CONTRIBUTING.md
Original file line number Diff line number Diff line change
Expand Up @@ -54,6 +54,20 @@ see [ABI Policy Guide](sycl/doc/ABIPolicyGuide.md) for more information.
- Run regression tests -
[instructions](sycl/doc/GetStartedGuide.md#test-dpc-toolchain).

**Guidelines for adding Clang FE tests**:
srividya-sundaram marked this conversation as resolved.
Show resolved Hide resolved
- Use `sycl::` namespace instead of `cl::sycl::`

- Include sycl mock headers as system headers.
Example: `-internal-isystem %S/Inputs`
`#include "sycl.hpp"`

- Use SYCL functions for invoking kernels from the mock header `(single_task, parallel_for)`
srividya-sundaram marked this conversation as resolved.
Show resolved Hide resolved
srividya-sundaram marked this conversation as resolved.
Show resolved Hide resolved

- Add a helpful comment describing what the test does at the beginning and other comments throughout the test as necessary.

- Try to follow descriptive naming convention for variables, functions as much as possible.
Please refer [LLVM naming convention](https://llvm.org/docs/CodingStandards.html#id43)
srividya-sundaram marked this conversation as resolved.
Show resolved Hide resolved

### Commit message

- When writing your commit message, please make sure to follow
Expand Down