Skip to content

QS8 / QU8 PReLU microkernels #7738

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

Open
wants to merge 3 commits into
base: master
Choose a base branch
from

Conversation

swamipreksha
Copy link

  • Implementations for various ISAs:
    • x86 AVX2
    • Scalar ISA
  • Unit tests

Copy link

google-cla bot commented Jan 30, 2025

Thanks for your pull request! It looks like this may be your first contribution to a Google open source project. Before we can look at your pull request, you'll need to sign a Contributor License Agreement (CLA).

View this failed invocation of the CLA check for more information.

For the most up to date status, view the checks section at the bottom of the pull request.

@dsharlet
Copy link
Collaborator

Thanks for the PR. Unfortunately, it looks like this is implementing the old prelu kernels. We now support prelu as a binary operator, and removed the old prelu operator: #6962, #7034

Can you please add binary operator implementation of the kernels you would like to have instead?

Copy link
Collaborator

@dsharlet dsharlet 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 the PR, this is great work.

Just a few remaining minor nits.

@swamipreksha swamipreksha force-pushed the qs8_qu8_vprelu branch 3 times, most recently from aa81513 to fee5c12 Compare February 6, 2025 07:57
@swamipreksha
Copy link
Author

@dsharlet please let us know if any other change is required for approval of the PR.

@dsharlet
Copy link
Collaborator

dsharlet commented Mar 6, 2025

I still think this is a good change, but it is failing tests, can you take a look?

@swamipreksha
Copy link
Author

I still think this is a good change, but it is failing tests, can you take a look?

Thank you for the feedback. I'm looking into the test failures and working on a fix.

@swamipreksha
Copy link
Author

@dsharlet We have tried fixing the failing testcases. Kindly review.

@swamipreksha
Copy link
Author

@dsharlet can we re-run the jobs since most of the jobs got cancelled as they exceeded the maximum execution time while awaiting a runner for 24h0m0s.

@swamipreksha
Copy link
Author

@dsharlet Kindly review and approve for merge.

1 similar comment
@swamipreksha
Copy link
Author

@dsharlet Kindly review and approve for merge.

@swamipreksha swamipreksha force-pushed the qs8_qu8_vprelu branch 2 times, most recently from a10ffd0 to 524c036 Compare April 10, 2025 05:31
@dsharlet
Copy link
Collaborator

The change I requested looks good. However, there is now a merge conflict with CMakeLists.txt (sorry about that). The tests part of CMakeLists.txt moved to tests/CMakeLists.txt

@swamipreksha
Copy link
Author

The change I requested looks good. However, there is now a merge conflict with CMakeLists.txt (sorry about that). The tests part of CMakeLists.txt moved to tests/CMakeLists.txt

Thanks for the update. We have resolved the conflicts and pushed again. Kindly check.

@swamipreksha
Copy link
Author

@dsharlet we have resolved the failing check with the latest push. Could you kindly retrigger the tests?

@dsharlet
Copy link
Collaborator

When you push fixes, can you please not force-push? It makes it hard to see what you changed.

@dsharlet
Copy link
Collaborator

This is failing some tests due to:

src/qu8-vprelu/gen/qu8-vprelu-scalar-u2.c:56:17: error: unused variable 'output_zero_point' [-Werror,-Wunused-variable]
   56 |   const int32_t output_zero_point = params->scalar.output_zero_point;
      |                 ^~~~~~~~~~~~~~~~~
1 error generated.

@swamipreksha swamipreksha force-pushed the qs8_qu8_vprelu branch 2 times, most recently from daef981 to c49c84e Compare April 15, 2025 09:07
swamipreksha and others added 3 commits April 15, 2025 09:11
- Implementations for various ISAs:
  - x86 AVX2
  - Scalar ISA
- Unit tests

Signed-Off-by: Ravi Kumar Soni <[email protected]>
Signed-off-by: Swami, Preksha <[email protected]>
Remove trailing space
Removed unused variables and regenerated scalar files.

Signed-off-by: Swami, Preksha <[email protected]>
@swamipreksha
Copy link
Author

swamipreksha commented Apr 15, 2025

This is failing some tests due to:

src/qu8-vprelu/gen/qu8-vprelu-scalar-u2.c:56:17: error: unused variable 'output_zero_point' [-Werror,-Wunused-variable]
   56 |   const int32_t output_zero_point = params->scalar.output_zero_point;
      |                 ^~~~~~~~~~~~~~~~~
1 error generated.

@dsharlet we have added a new commit addressing this issue. Kindly check.

copybara-service bot pushed a commit that referenced this pull request Apr 15, 2025
--
5f6a0a6 by Swami, Preksha <[email protected]>:

QS8 / QU8 PReLU microkernels

- Implementations for various ISAs:
  - x86 AVX2
  - Scalar ISA
- Unit tests

Signed-Off-by: Ravi Kumar Soni <[email protected]>
Signed-off-by: Swami, Preksha <[email protected]>

--
cbfa3ad by Dillon <[email protected]>:

Update scalar_microkernels.bzl

Remove trailing space

--
c49c84e by Swami, Preksha <[email protected]>:

Update qs8-vprelu/scalar.c.in

Removed unused variables and regenerated scalar files.

Signed-off-by: Swami, Preksha <[email protected]>
FUTURE_COPYBARA_INTEGRATE_REVIEW=#7738 from swamipreksha:qs8_qu8_vprelu c49c84e
PiperOrigin-RevId: 747503284
@swamipreksha
Copy link
Author

Hi @dsharlet, for this PR, copybara-service pushed a commit last week with commit id: e33d847 as mentioned above which passed all the testcases (#8267) but it is now showing as closed with unmerged commits. The failures that we see in this PR were observed much before the copybara-service pushed that commit. Please let us know how to proceed further to get this PR merged.

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.

2 participants