Skip to content

Fix segmentation fault and bump TBLIS_jll version#20

Open
liuzhaochen wants to merge 5 commits into
QuantumKitHub:mainfrom
liuzhaochen:main
Open

Fix segmentation fault and bump TBLIS_jll version#20
liuzhaochen wants to merge 5 commits into
QuantumKitHub:mainfrom
liuzhaochen:main

Conversation

@liuzhaochen

Copy link
Copy Markdown

This PR introduces a wrapper that keeps the metadata and parent array alive for the lifetime of a foreign array view.

Without this wrapper, tblis_tensor_mult may trigger a segmentation fault due to dangling pointers.

This PR also bumps the TBLIS_jll version.

liuzhaochen and others added 5 commits May 30, 2026 18:06
Fix mising "$" symbol
- Using newest version of TBLIS_jll
Root cause: tblis_tensor constructor created local dims/strides vectors,
passed their data pointers to the C struct's len/stride fields, then let
them go out of scope. TBLIS dereferenced freed memory on subsequent calls.

Fix: introduce TblisTensor{T} wrapper that holds the C struct, dims/strides
vectors, and parent array reference, keeping all pointed-to memory alive.

Co-Authored-By: Claude Opus 4.7 <noreply@anthropic.com>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant