Skip to content

Add the missing highway kernels - #753

Open
r-devulap wants to merge 5 commits into
mainfrom
hwy-kernels
Open

r-devulap wants to merge 5 commits into
mainfrom
hwy-kernels

Conversation

@r-devulap

Copy link
Copy Markdown
Contributor

Implemented native C++ Google Highway SIMD kernels for: min_f32, sum_f32, scale_f32, sub_f32/sub_scalar_f32, and hamming_distance in jvector_simd_kernels.cpp, eliminating Panama Java Vector API fallbacks for. These kernels vectorize horizontal reductions, in-place scaling, out-of-place subtraction, and 64-bit population count across all x86-64 (SSE4.2 to AVX-512) and AArch64 (NEON, SVE, SVE2) tiers, and are wired to NativeVectorUtilSupport.java through critical Java FFM bindings with unit tests in test_elementwise.cpp and release symbol verification in verify_native_lib.sh.

Commits Breakdown

  • 7661442: Added kernel declarations in jvector_simd_kernel_list.h and Highway SIMD implementations in jvector_simd_kernels.cpp.

  • 89bca21: Added GoogleTest suites covering boundary and tail matrix sizes (1 to 255 elements) for all new kernels in test_elementwise.cpp.

  • 368d949: Regenerated jextract Java FFM bindings with Linker.Option.critical(true) downcall handles in NativeSimdOps.java.

  • bf6288d: Added all newly exported kernel symbols to REQUIRED_SYMBOLS in verify_native_lib.sh.

  • 77adbf6: Connected Java calls in NativeVectorUtilSupport.java to invoke NativeSimdOps for both off-heap MemorySegment buffers and on-heap arrays.

@github-actions

github-actions Bot commented Oct 13, 2026 •

Copy link
Copy Markdown
Contributor

Before you submit for review:

  • Does your PR follow guidelines from CONTRIBUTIONS.md?
  • Did you summarize what this PR does clearly and concisely?
  • Did you include performance data for changes which may be performance impacting?
  • Did you include useful docs for any user-facing changes or features?
  • Did you include useful javadocs for developer oriented changes, explaining new concepts or key changes?
  • Did you rebase your branch onto the latest main for regression testing and PR submission?
  • Did you trigger regression testing via Run Bench Main and review results?
  • Did you adhere to the code formatting guidelines (TBD)
  • Did you group your changes for easy review, providing meaningful descriptions for each commit?
  • Did you ensure that all files contain the correct copyright header?
  • Did you add documentation for this feature to the release notes directory?

If you did not complete any of these, then please explain below.

@tlwillke tlwillke added the 4.0.2 Release label label Oct 13, 2026
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

4.0.2 Release label

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants