Hacktoberfest 2026:メンテナが10月に向けて印を付けた、オープンで初心者向けの issue。 Hacktoberfest の issue を見る

skainet-backend-native-cpu: JVM artifact ships no linux-arm64 libskainet_kernels.so → silent ~1000× reference-kernel fallback on ARM Linux

オープン
#1,356 コメント 0 件 リアクション 0 件 担当者 0 名 GitHub で見る

メンテナーはふだん 1 日以内に返信

まだ誰も着手していません。

評価

難易度
4/5
見積もり時間
3〜5日
初心者へのやさしさ
58/100
issue の種類
バグ
明瞭さ
おおむね明確
活発さ
活発
技術スタック
cmake, kotlin, linux

調査の方向性

Start with the skainet-backend-native-cpu native CMake build and the JVM artifact packaging configuration; the issue says CMake already supports aarch64 and identifies the missing native/linux-arm64/libskainet_kernels.so resource. Check how the existing Linux, macOS, and Windows libraries are built and bundled, then determine how CI can build and include the ARM Linux library. Done when the published JVM artifact contains that library and ARM Linux loads a native kernel instead of falling back to the reference decoder.

索引モデルが issue の本文から書いたものです。

説明

bug platform skill:native

Problem

The published skainet-backend-native-cpu 0.61.0 JVM artifact bundles libskainet_kernels for linux-x86_64, macos-arm64 and windows-x86_64 only. There is no native/linux-arm64/libskainet_kernels.so, although NativeLibraryLoader already resolves that path ("aarch64", "arm64" -> "arm64").

On a linux-arm64 JVM, the loader finds nothing, so KernelDispatch has no kernel for packed weights and falls back to the reference decoder:

[SKaiNET] KernelDispatch: no kernel registered for matmul (activation=Dense(bytesPerElement=4), weight=BITNET_B1_58, order=ROW_MAJOR); falling back to the decoding reference kernel (~1000x slower). Install a kernel pack (e.g. KernelPacks.install() + FfmRowMajorKernelPack.install()) before the first forward. Further fallbacks are not reported.

Repro

  • Board: Arduino Ventuno Q (QCS8275, 4× Cortex-A78C + 4× A55), Ubuntu 24.04, Temurin 21.0.12.1 (aarch64).
  • SKaiNET-transformers develop @ a92d65e: :llm-apps:skainet-cli:shadowJar.
  • unzip -l skainet-all.jar | grep native/ shows only linux-x86_64, macos-arm64 and windows-x86_64.
  • java --enable-preview --add-modules jdk.incubator.vector -jar skainet-all.jar -m ggml-model-i2_s.gguf -s 32 "The capital of France is" (BitNet b1.58 2B4T): one thread sits in ReferenceMatmulKernel → BitNetB158TensorData.dequantizeBlock, with 0 tokens after 10.5 min.

Workaround (verified)

I cross-built the library from skainet-backends/skainet-backend-native-cpu/native at tag 0.61.0 and added it to the jar:

cmake -S native -B b -DCMAKE_SYSTEM_NAME=Linux -DCMAKE_SYSTEM_PROCESSOR=aarch64 \
      -DCMAKE_C_COMPILER=aarch64-linux-gnu-gcc -DCMAKE_BUILD_TYPE=Release
cmake --build b --target skainet_kernels
mkdir -p native/linux-arm64 && cp b/libskainet_kernels.so native/linux-arm64/
jar uf skainet-all.jar native/linux-arm64/libskainet_kernels.so

With that, the same run produces correct greedy output at 1.6–1.8 tok/s instead of the reference fallback.

Ask

  • Build and bundle native/linux-arm64/libskainet_kernels.so in the JVM artifact. The CMake file already handles aarch64 cross builds (-march=armv8.2-a+fp16+dotprod, with NeoGPU pinned to armv8-a). A CI job using gcc-aarch64-linux-gnu or an arm64 runner would cover it.
  • Consider making the "no kernel registered → reference fallback" message an error on platforms where a native pack is expected, or at least naming the missing resource path.

Related: #920 (mobile/Apple/Android JNI; this issue is the plain linux-arm64 JVM case: Raspberry Pi, Qualcomm IoT boards, Graviton).

主要言語
Kotlin
スター
52
フォーク
15
平均マージ
1日 10時間
マージ済み PR(30日)
59

環境構築

はじめの一歩

  1. issue を最後まで読み、次にプロジェクトのコントリビューションガイドを読みます。
  2. 着手することを issue にコメントします — 二人が同じ作業をするのを防げます。
  3. リポジトリをフォークし、ブランチを切って変更します。
  4. issue 番号を参照したプルリクエストを送ります。

SKaiNET-developers/SKaiNET のほかの issue

SKaiNET-developers/SKaiNET の issue をすべて見る

似ている issue

Kotlin の issue をもっと見る

新しい issue をメールで受け取る

初心者向けの GitHub issue を短くまとめたダイジェスト。