Skip to content

RISC-V: "Illegal instruction" crash on SpacemiT-K3 #64538

Description

@sxa

Version

v26.5.0 (but any v26 and above is affected)

Platform

Linux firefly 6.18.3 #2 SMP PREEMPT_DYNAMIC Wed May 13 16:58:11 CST 2026 riscv64 GNU/Linux

Subsystem

V8

What steps will reproduce the bug?

run npm or any node-gyp on a SpacemiT-K3 board. Also fails in the build-addons step with make run-ci as that executes node-gyp. Other boards such as the SpacemiT-K1 do not show the crash (Both should have vector instructions available)

How often does it reproduce? Is there a required condition?

100% of the time

What is the expected behavior? Why is that the expected behavior?

There should be no crash when running npm

What do you see instead?

Illegal Instruction

Additional information

Based on the fact that sxa@1ecdd38 fixes it seems likely that this was introduced as part of the vector instructions introduced in v8/v8@de361fd - I haven't yet tracked it down to any specific operation in that function. At the moment I've also only determined that it fixes the initial crash and hopefully that doesn' uncover more issues.

FYI @luhenry @luyahan @nodejs/platform-riscv64

Split out from nodejs/build#4099 (comment)

Metadata

Metadata

Assignees

No one assigned

    Labels

    riscv64Issues and PRs related to the riscv64 architecture.v8 engineIssues and PRs related to the V8 dependency.

    Type

    No type

    Fields

    No fields configured for issues without a type.

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions