Repository navigation
openrknn: document vendor multi-core submit from decompile - #92
Merged
Merged
Conversation
From decompiling librknnrt.so's submit path and ioctl tracing: - Vendor sends 10 ACTION ioctls during init (POWER_ON, GET_IOMMU_EN, etc.) - Vendor submit: core_mask=0 (AUTO), subcore_task all zeroed, task_number=N*3 - Kernel auto-distributes tasks across all 3 NPU cores - core_mask=0 with tripled tasks crashes kernel without vendor's context setup - Single-core tasks only cover ~512/1024 spatial positions (by design) - Tripled tasks on single core: kernel rejects (task_start+count exceeds BO) The 50% spatial coverage is a fundamental architectural feature: the RKNN compiler generates single-core tasks for half the spatial dimension, with multi-core replicas for the other half. Full coverage requires kernel-level multi-core dispatch that openrknn's OWN mode doesn't implement yet. Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
widgetii
force-pushed
the
openrknn/multicore-investigation
branch
from
April 13, 2026 10:22
021f948 to
b43ee21
Compare
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Summary
Documents findings from decompiling the vendor's submit path in librknnrt.so:
rknpu_submitwithcore_maskfrom ctx+2428,subcore_task[]all zeroedrknn_set_core_mask(sub_E1260) just stores the mask value — no kernel ioctltask_number = N*3withcore_mask=0(AUTO) for 3-core executioncore_mask=0with tripled tasks causes kernel panic without vendor's context setupDisabled the vendor-3core submit path to prevent panics.
Key decompile references
Next step
Reproduce the vendor's kernel init sequence:
0x40086414to allocate a context handle0x40106410to configure NPU corescore_mask=0and tripled task count🤖 Generated with Claude Code