Skip to content

[SYCL] Update sycl complex implementation #8068

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

Conversation

jle-quel
Copy link
Contributor

@jle-quel jle-quel commented Jan 20, 2023

This PR updates the complex implementation.

From the POV of the complex's user, the interface does not change.

The modification made to the implementation are:

  • the operators are now declared as hidden friends
  • encapsulation of helper functions of the implementation (only expose what needs to be)
  • using metaprogramming to specialize the complex when the trait is_genfloat is true, which removes the duplication of the operators
  • using metaprogramming to specialize different math operations when the trait is_genfloat is true, which removes some boilerplate code
  • add the missing inline attribute to different functions
  • remove unnecessary const and ref keywords on value_type
  • add missing std::enable_if on free functions

llvm-test-suite: intel/llvm-test-suite#1533

@jle-quel jle-quel requested a review from a team as a code owner January 20, 2023 14:40
@jle-quel jle-quel temporarily deployed to aws January 20, 2023 15:04 — with GitHub Actions Inactive
@jle-quel
Copy link
Contributor Author

/verify with intel/llvm-test-suite#1533

@jle-quel jle-quel temporarily deployed to aws January 20, 2023 15:36 — with GitHub Actions Inactive
@jle-quel jle-quel temporarily deployed to aws January 24, 2023 14:48 — with GitHub Actions Inactive
@jle-quel
Copy link
Contributor Author

/verify with intel/llvm-test-suite#1533

@jle-quel jle-quel temporarily deployed to aws January 24, 2023 17:28 — with GitHub Actions Inactive
@jle-quel jle-quel temporarily deployed to aws January 31, 2023 15:09 — with GitHub Actions Inactive
@jle-quel jle-quel temporarily deployed to aws January 31, 2023 15:45 — with GitHub Actions Inactive
@jle-quel
Copy link
Contributor Author

/verify with intel/llvm-test-suite#1533

@jle-quel
Copy link
Contributor Author

jle-quel commented Mar 2, 2023

I wanted to check in on the status of this PR. It has passed all tests, and I believe it is ready to be merged. Is there any blocker preventing this from being reviewed or merged?

@intel/llvm-reviewers-runtime @sergey-semenov

Copy link
Contributor

@steffenlarsen steffenlarsen left a comment

Choose a reason for hiding this comment

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

LGTM!

@jle-quel jle-quel temporarily deployed to aws March 8, 2023 17:35 — with GitHub Actions Inactive
@jle-quel jle-quel temporarily deployed to aws March 8, 2023 19:31 — with GitHub Actions Inactive
@bader
Copy link
Contributor

bader commented Mar 9, 2023

@jle-quel, please, resolve merge conflicts.

@jle-quel jle-quel temporarily deployed to aws March 9, 2023 11:39 — with GitHub Actions Inactive
@jle-quel jle-quel temporarily deployed to aws March 9, 2023 12:30 — with GitHub Actions Inactive
@steffenlarsen steffenlarsen merged commit e88d550 into intel:sycl Mar 10, 2023
@jle-quel jle-quel deleted the jle-quel/update-sycl-complex-implementation branch March 13, 2023 08:43
steffenlarsen pushed a commit to intel/llvm-test-suite that referenced this pull request Mar 13, 2023
This PR updates the tests for the experimental sycl complex implementation.

It tests the new unary operators `+` and `-`, the new functions `real` and `imag` and the variant of `conj`, `proj`, `arg`, `norm`, when the function is called with decimals as arguments.

An overload of `test_valid_types` which takes a template template parameter that takes two typename parameters has been introduced to support the new `deci_test_cases`.

Finally, the `test_cases` structure has been renamed to `cplx_test_cases` to be coherent with the new `deci_test_cases`.

Depends on: intel/llvm#8068
aelovikov-intel pushed a commit to aelovikov-intel/llvm that referenced this pull request Mar 27, 2023
This PR updates the tests for the experimental sycl complex implementation.

It tests the new unary operators `+` and `-`, the new functions `real` and `imag` and the variant of `conj`, `proj`, `arg`, `norm`, when the function is called with decimals as arguments.

An overload of `test_valid_types` which takes a template template parameter that takes two typename parameters has been introduced to support the new `deci_test_cases`.

Finally, the `test_cases` structure has been renamed to `cplx_test_cases` to be coherent with the new `deci_test_cases`.

Depends on: intel#8068
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants