Closed luhenry closed 11 months ago
This PR depends on https://github.com/shibatch/sleef/pull/476
cc @blapie
Hi! Could you please put a link to passing GHA workflow? Is there a chance this can be tested with a clang/llvm toolchain as well? SLEEF did not tend to merge features if not supported in both?
What is the rationale for adding the prefix ?
The intrinsics' name changed upstream. It's purely to follow with the spec and not a design preference.
Could you please put a link to passing GHA workflow?
https://github.com/rivosinc/sleef/actions/runs/6754458819
Is there a chance this can be tested with a clang/llvm toolchain as well? SLEEF did not tend to merge features if not supported in both?
It currently only works with clang as gcc doesn't have support for the RISC-V RVV intrinsics just yet.
It currently only works with clang as gcc doesn't have support for the RISC-V RVV intrinsics just yet.
Got you. I understand that it might take some time to be supported in gcc. It would be a shame not to make this available though.
@ericlove @GlassOfWhiskey Would you be able to review the extra changes on top of yours? @luhenry Do you know someone else the community that could review? There is only a few changes in essence (https://github.com/shibatch/sleef/pull/477/commits/19efad8e19259dda7aaca7882523534912bb23ec) so I'll check and merge by next week, assuming the CI is in.
@blapie I've rebased the PR on top of the initial CI.
Hi all, I'll review this today or tomorrow. Sry for the late reply.
As a first comment, since the RISC-V vector intrinsics standard has not reached a stable version yet, it could be useful to document which version of the intrinsics are we using right now.
I’ll also look into adding gcc + llvm compilation as both of them support the intrinsics. It’ll also improve testing on other platforms.
I've added the gcc and llvm builds, but I'm getting quite a few failures. I've explicitly disabled the configurations that don't work (no regression compared to master
), but worth looking into some follow up PRs.
@blapie @GlassOfWhiskey let me know what you think
@blapie this looks good to me. Thanks to @luhenry for updating to the new intrinsics format!
I've enabled the LLVM builds for s390x and ppc64el. The issue was with cross-compilation of the builtin headers.
I've added the gcc and llvm builds, but I'm getting quite a few failures. I've explicitly disabled the configurations that don't work (no regression compared to
master
), but worth looking into some follow up PRs.@blapie @GlassOfWhiskey let me know what you think
I see that riscv
builds with gcc
are commented in the .github/workflow
pipeline. Did they fail to compile for some reason?
I see that riscv builds with gcc are commented in the .github/workflow pipeline. Did they fail to compile for some reason?
Yes, the gcc I'm getting from riscv-gnu-toolchain isn't recent enough, it needs to be GCC trunk and it's only GCC 13.2 at the moment. Once there is a new GCC release, we should be able to bump that version at .github/workflows/build_and_test.yml#L145 and be able to test with GCC.
Per the documentation of the RISC-V V intrinsics, LLVM-17 should have the final version of the intrinsics, so building and testing with that is the best we have today. See https://github.com/riscv-non-isa/rvv-intrinsic-doc/blob/main/README.md:
Clang 17 and GCC trunk supports the v0.12 version, no more incompatibility will be introduced.
@luhenry it makes sense to me. For me the PR is ready to be merged. Maybe as a last bit, you could put in the README.md
that SLEEF now supports RISC-V V 1.0
with intrinsics >=0.12
, just to make compatibility explicit.
Sorry Isee that README is quite minimal and doesn't say anything about compatibility. We can put this in the CHANGELOG.md
before next release
aarch64, ppc64el, and s390x fail with GCC 12 with the following error:
tanf denormal/nonnumber test : arg = -0, test = 0, correct = -0
The error isn't there when compiling with GCC 11, so downgrading to that and I'll let you explore why that is.
Thank you! We also observed this. Created #483 to track this.
@blapie it should have everything now. Let me know what you think, thanks!
@blapie it should have everything now. Let me know what you think, thanks!
Will have one last pass today, but it looks good to me!
@blapie all tests are passing (including tester3) with the latest changes.
@blapie should be fixed.
LGTM - Will merge now!
Done. Thanks for a brilliant collab! I hope we can add support for the rest of the features soon.
Yes, I already have some ideas on what I want to improve for RISC-V. Thanks again!
It integrates the following changes: