On Tue, 29 Aug 2023 17:32:26 GMT, Srinivas Vamsi Parasa <d...@openjdk.org> wrote:
>>> The reason this PR is focused on Linux is because the AVX512 sort and >>> partitioning routines are based on Intel’s x86-simd-library >>> (https://github.com/intel/x86-simd-sort) which was originally developed >>> with GCC as the target compiler. Thus, this PR has restricted itself to >>> Linux as the code was tested using GCC/Linux platforms. Additionally, the >>> x86_64 library is compiled for AVX512 using file specific compilation >>> pragmas (`#pragma GCC target("avx512dq", "avx512f")`). This feature is >>> absent for Windows/MSVC++ compiler.” >> >> That is why I am questioning this approach to have additional separate C++ >> code library - too much dependencies on other tools. >> >> As I suggested before try to disassemble this library and use assembler code >> in VM new stubs. You can create specialized >> stubGenerator_x86_64_array_sort.cpp file for it. Then you don't need to >> depend on C++ compiler or OS. > > The shared library approach is being followed currently as an initial > implementation to demonstrate the value of AVX512 sorting. This will be > followed up in future with support for Windows as well. > If it is ok with you, the shared library approach could be pursued for now to > be later replaced with specialized assembly stubs (which are agnostic to OS > and compiler) when AVX512 sort is enabled for Windows. Please let us know. I am okay with such incremental approach. Please, file RFE to replace library with stubs in a future (it could be still separate library but with assembler code). ------------- PR Review Comment: https://git.openjdk.org/jdk/pull/14227#discussion_r1309316767