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

Update clang-tidy rules for Lightning builds under aarch64 #567

Merged
merged 19 commits into from
Dec 8, 2023

Conversation

mlxd
Copy link
Member

@mlxd mlxd commented Nov 27, 2023

Before submitting

Please complete the following checklist when submitting a PR:

  • All new features must include a unit test.
    If you've fixed a bug or added code that should be tested, add a test to the
    tests directory!

  • All new functions and code must be clearly commented and documented.
    If you do make documentation changes, make sure that the docs build and
    render correctly by running make docs.

  • Ensure that the test suite passes, by running make test.

  • Add a new entry to the .github/CHANGELOG.md file, summarizing the
    change, and including a link back to the PR.

  • Ensure that code is properly formatted by running make format.

When all the above are checked, delete everything above the dashed
line and fill in the pull request template.


Context: More recent versions of clang-tidy are less permission than those used for the general wheel builders. This PR aims to allow us to use clang-tidy-16 on platforms such as aarch64. This will also serve as the base to update the clang-tidy rules to a unified format across all repos in 2024.

Description of the Change: Removes redundant clang-tidy config files, silences unneeded warnings, and makes source changes to allow clang-tidy passes where useful.

Benefits: Better support for clang-tidy across newer platforms.

Possible Drawbacks:

Related GitHub Issues: Also resolves #560

Copy link

codecov bot commented Nov 27, 2023

Codecov Report

Attention: 7 lines in your changes are missing coverage. Please review.

Comparison is base (d165de1) 99.02% compared to head (c8628fa) 99.09%.
Report is 1 commits behind head on master.

Files Patch % Lines
...rc/simulators/lightning_gpu/StateVectorCudaMPI.hpp 50.00% 2 Missing ⚠️
...imulators/lightning_gpu/StateVectorCudaManaged.hpp 50.00% 2 Missing ⚠️
...lators/lightning_qubit/gates/DynamicDispatcher.hpp 94.44% 2 Missing ⚠️
...ylane_lightning/lightning_qubit/lightning_qubit.py 96.87% 1 Missing ⚠️
Additional details and impacted files
@@            Coverage Diff             @@
##           master     #567      +/-   ##
==========================================
+ Coverage   99.02%   99.09%   +0.06%     
==========================================
  Files         168      201      +33     
  Lines       23235    29203    +5968     
==========================================
+ Hits        23009    28938    +5929     
- Misses        226      265      +39     

☔ View full report in Codecov by Sentry.
📢 Have feedback on the report? Share it here.

@mlxd mlxd changed the title Update clang-tidy rules for Lightning builds Update clang-tidy rules for Lightning builds under aarch64 Nov 27, 2023
@mlxd mlxd marked this pull request as ready for review November 27, 2023 21:53
Copy link
Contributor

@vincentmr vincentmr left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I like all the constant definitions. Looks good to me, thanks @mlxd .

Copy link
Contributor

@AmintorDusko AmintorDusko left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Hi @mlxd, do you know why we are observing a drop in coverage?

@mlxd
Copy link
Member Author

mlxd commented Nov 28, 2023

Hi @mlxd, do you know why we are observing a drop in coverage?

I think this is just due to a reduced line count again --- I don't think any of the test infrastructure changes here, so I'd call it a false flag.

Copy link
Contributor

@AmintorDusko AmintorDusko left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Thank you for that!

@vincentmr
Copy link
Contributor

Hi @mlxd, do you know why we are observing a drop in coverage?

Given the %'s, I would say it is because parallel-GPU tests are not run.

@AmintorDusko AmintorDusko added the ci:use-multi-gpu-runner Enable usage of Multi-GPU runner for this Pull Request label Dec 8, 2023
@AmintorDusko
Copy link
Contributor

[sc-50799]

@AmintorDusko
Copy link
Contributor

Testing (Windows) / C++ tests (Windows) (windows-latest, lightning_qubit) (pull_request) is hanging and failing after the time limit (30 min). I will test again later.

@AmintorDusko AmintorDusko merged commit 502fecb into master Dec 8, 2023
82 checks passed
@AmintorDusko AmintorDusko deleted the clang_tidy_update branch December 8, 2023 20:47
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
ci:use-multi-gpu-runner Enable usage of Multi-GPU runner for this Pull Request
Projects
None yet
Development

Successfully merging this pull request may close these issues.

[BUG] clang-tidy error with aarch64 builds
3 participants