Landing: 02cc188d3d9f

Project / Subsystem

gcc / libgomp, amdgcn

Date

2026-04-20

Author

Andrew Stubbs

Commit

02cc188d3d9f14975c8285678f937a1ba79bedeb

Source

github

Perf win

No

Breaking

No

All attributes

project
gcc
subsystem
libgomp, amdgcn
patch_id
—
commit_hash
02cc188d3d9f14975c8285678f937a1ba79bedeb
source_type
github
headline
libgomp, amdgcn: Ensure s_memrealtime uses SGPRs
tldr
AMD GCN time function now correctly uses special function registers (SGPRs) for stability.
author
Andrew Stubbs
outcome
committed
performance_win
false
breaking_change
false
series_id
—
series_parts
[]
tags
  • • amd
  • • gpu
  • • libgomp
  • • assembly
  • • performance
discussion_id_link
—
bugzilla_pr
—
date
2026-04-20T00:00:00.000Z

The s_memrealtime intrinsic within libgomp’s AMD GCN backend was using a generic ‘r’ register constraint. This could lead to instability, especially in SIMT execution, as it might only select a compatible register by chance. This commit changes the constraint to the more specific Sg (Special General Purpose Register), ensuring that the intrinsic reliably uses SGPRs, thereby improving the stability and correctness of time-related functions on AMD GPUs.