Skip to content

transpile: Support __atomic_thread_fence/__atomic_signal_fence builtins#1862

Merged
thedataking merged 1 commit into
masterfrom
perl/atomic-fence-builtins
Jul 1, 2026
Merged

transpile: Support __atomic_thread_fence/__atomic_signal_fence builtins#1862
thedataking merged 1 commit into
masterfrom
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 2 times, most recently from 1a8ba84 to 806f076 Compare June 18, 2026 09:12
@thedataking thedataking added the enhancement New feature or request label Jun 18, 2026
@thedataking thedataking force-pushed the perl/atomic-fence-builtins branch from 806f076 to d3fef4f Compare June 24, 2026 04:28
@thedataking thedataking force-pushed the perl/overflow-builtin-types branch from 7fc752f to b8781e0 Compare June 24, 2026 04:29
@thedataking thedataking changed the base branch from perl/overflow-builtin-types to master July 1, 2026 03:13
@thedataking thedataking closed this Jul 1, 2026
@thedataking thedataking reopened this Jul 1, 2026

@fw-immunant fw-immunant left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

A couple inline comments, no blocking concerns.

Comment thread c2rust-transpile/src/translator/builtins.rs Outdated
Comment thread c2rust-transpile/src/translator/builtins.rs Outdated
…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 d3fef4f to f8f00b1 Compare July 1, 2026 08:41
@thedataking thedataking merged commit cf72d63 into master Jul 1, 2026
11 checks passed
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.

3 participants