On Wed, 22 Nov 2023 09:05:31 GMT, Andrew Haley <a...@openjdk.org> wrote:
>>> Have you considered the possibility of copying the sleef source to the >>> OpenJDK repository and thereby it becomes part of the build process? I >>> don't know how straightforward that is technically and IANAL but I think >>> it's worth exploring. >>> >> >> Hi @PaulSandoz ! Thanks for the suggestion! Copying the sleef source sounds >> good. However, I actually have no idea about how to handle the third-party >> licence in OpenJDK project. Do you have any idea about this area? Some >> suggestions/guidence from the JDK team will be much helpful. Thanks! > >> > Have you considered the possibility of copying the sleef source to the >> > OpenJDK repository and thereby it becomes part of the build process? I >> > don't know how straightforward that is technically and IANAL but I think >> > it's worth exploring. >> >> Hi @PaulSandoz ! Thanks for the suggestion! Copying the sleef source sounds >> good. However, I actually have no idea about how to handle the third-party >> licence in OpenJDK project. Do you have any idea about this area? Some >> suggestions/guidence from the JDK team will be much helpful. Thanks! > > From a legal pespective, we can do this. SLEEF is distributed under Boost > Software License Version 1.0., which is a GPL-compatible free software > licence. The only issue is whether we want to do so. It would certainly be > convenient. Hi @theRealAph , @magicus , The latest commit renamed `vmath` in configure to `sleef`, and the Arm SVE cflags is removed to `flags-cflags.m4` now. I was thinking about separating the NEON and SVE functions in `libvmath.so` to two source files, and add the SVE cflags just for SVE functions as needed. But it seems I have to write the make commands manually, which I think is not good? But I can have a try if it's necessary. Since the sve flags is just used for building `libvmath.so` now, moving it to `flags-cflags.m4` seems not so right? @magicus , may I have your comments on this part? Thanks in advance! > Don't touch the make system.Instead, try to open the library at runtime with > os::dll_open(), after (or inside) VM_Version::initialize(). > > If you're not running on an SVE system, none of the SVE routines will be > called, so it doesn't matter, right? Yes, the SVE routines are called only on the SVE system. So I think it doesn't matter. I tested with the image built on non-sve machine and ran the Vector API tests on SVE machine, and it works well. It also works well on the contrary situation. Best Regards, Xiaohong ------------- PR Comment: https://git.openjdk.org/jdk/pull/16234#issuecomment-1833278899