Open
Conversation
Codecov Report✅ All modified and coverable lines are covered by tests. Additional details and impacted files@@ Coverage Diff @@
## master #6606 +/- ##
==========================================
- Coverage 93.41% 93.22% -0.19%
==========================================
Files 868 784 -84
Lines 275540 261017 -14523
==========================================
- Hits 257391 243346 -14045
+ Misses 18149 17671 -478 ☔ View full report in Codecov by Sentry. 🚀 New features to boost your workflow:
|
Member
Contributor
There was a problem hiding this comment.
Pull request overview
This PR adds LoongArch-optimized implementations for several activation/math layers (SELU, GELU, ELU, Erf) and extends the LoongArch LSX/LASX math helper headers with new vector routines needed by those layers.
Changes:
- Add LoongArch layer implementations for SELU, GELU, ELU, and Erf with LSX/LASX vectorized fast paths plus scalar fallbacks.
- Extend
lsx_mathfun.hwitherf_psandelu_ps, and extendlasx_mathfun.hwithelu_psfor LASX. - Enable packing support in the new LoongArch layer constructors when LSX is available.
Reviewed changes
Copilot reviewed 10 out of 10 changed files in this pull request and generated 3 comments.
Show a summary per file
| File | Description |
|---|---|
| src/layer/loongarch/selu_loongarch.h | Declares SELU_loongarch layer specialization. |
| src/layer/loongarch/selu_loongarch.cpp | Implements LSX-vectorized SELU forward. |
| src/layer/loongarch/gelu_loongarch.h | Declares GELU_loongarch layer specialization. |
| src/layer/loongarch/gelu_loongarch.cpp | Implements LSX-vectorized GELU (fast and non-fast) forward. |
| src/layer/loongarch/erf_loongarch.h | Declares Erf_loongarch layer specialization. |
| src/layer/loongarch/erf_loongarch.cpp | Implements LSX-vectorized erf forward. |
| src/layer/loongarch/elu_loongarch.h | Declares ELU_loongarch layer specialization. |
| src/layer/loongarch/elu_loongarch.cpp | Implements LASX/LSX-vectorized ELU forward. |
| src/layer/loongarch/lsx_mathfun.h | Adds erf_ps and elu_ps LSX vector helpers. |
| src/layer/loongarch/lasx_mathfun.h | Adds elu_ps LASX vector helper. |
💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
No description provided.