Skip to content

Remove the last unsafe loads and replace them with checked_transmute_copy#233

Merged
Shnatsel merged 1 commit into
linebender:mainfrom
Shnatsel:more-safe-transmute
May 26, 2026
Merged

Remove the last unsafe loads and replace them with checked_transmute_copy#233
Shnatsel merged 1 commit into
linebender:mainfrom
Shnatsel:more-safe-transmute

Conversation

@Shnatsel
Copy link
Copy Markdown
Contributor

Only affects one function.

As per #185 we don't need explicit load intrinsics, LLVM is better at selecting the right load for the job from a generic load instruction.

The generated assembly is identical before and after. This is not a performance win but a safety win.

@Shnatsel Shnatsel added this pull request to the merge queue May 26, 2026
Merged via the queue into linebender:main with commit 13dd530 May 26, 2026
22 checks passed
@Shnatsel Shnatsel deleted the more-safe-transmute branch May 26, 2026 19:44
github-merge-queue Bot pushed a commit that referenced this pull request May 27, 2026
Follow-up to #233 which did this for x86

Leaves `vld4q_*` untouched because those are deinterleaving loads that
genuinely need an intrinsic.
Shnatsel added a commit to Shnatsel/fearless_simd that referenced this pull request May 27, 2026
Merged origin/main commit 13dd530. The merge applied cleanly.
Shnatsel added a commit to Shnatsel/fearless_simd that referenced this pull request May 27, 2026
Replace AVX512 interleaved load intrinsics emitted by the branch with checked_transmute_copy, then regenerate the generated AVX512 module.
Shnatsel added a commit to Shnatsel/fearless_simd that referenced this pull request May 27, 2026
PR linebender#237 only updates NEON load construction. The AVX512 branch-specific unsafe load sites were already adapted in the PR linebender#233 follow-up, and a search found no remaining load intrinsics needing the linebender#237 pattern.
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.

2 participants