Skip to content

transpile: Support __atomic_thread_fence/__atomic_signal_fence builtins#1862

Open
thedataking wants to merge 1 commit into
perl/overflow-builtin-typesfrom
perl/atomic-fence-builtins
Open

transpile: Support __atomic_thread_fence/__atomic_signal_fence builtins#1862
thedataking wants to merge 1 commit into
perl/overflow-builtin-typesfrom
perl/atomic-fence-builtins

Conversation

@thedataking

Copy link
Copy Markdown
Contributor

Needed to land #1861.

@thedataking thedataking requested a review from ahomescu June 18, 2026 03:25
Comment thread c2rust-transpile/src/translator/builtins.rs Outdated
Comment thread tests/unit/builtins/src/atomics.c
@thedataking thedataking changed the base branch from master to perl/overflow-builtin-types June 18, 2026 08:45
@thedataking thedataking force-pushed the perl/atomic-fence-builtins branch from 1a597b2 to 1a8ba84 Compare June 18, 2026 08:49
…iltins

Map them to the `atomic_fence`/`atomic_singlethreadfence` intrinsics using the
call's memory order. The order must be a constant (a non-constant one fails
translation); a relaxed fence is emitted as a no-op since Rust has no relaxed
fence intrinsic.
@thedataking thedataking force-pushed the perl/atomic-fence-builtins branch from 1a8ba84 to 806f076 Compare June 18, 2026 09:12
@thedataking thedataking added the enhancement New feature or request label Jun 18, 2026
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

enhancement New feature or request

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants