[clang] [llvm] [AArch64] Implement the atomic store with hint intrinsic (PR #198316)

via cfe-commits cfe-commits at lists.llvm.org
Thu Sep 10 05:51:10 PDT 2026


================
@@ -157,6 +157,13 @@ static bool mayPrefetch(const MCInst &Inst) {
   }
 }
 
+// Memory hints 48 (stshh keep) & 49 (stshh strm) should be emitted
+// immediately before a store instruction.
+static bool isMemHint(const MCInst &Inst) {
----------------
Lukacma wrote:

I am sorry, but it looks like the LFI issue was a false positive. Even though the example code miscompiles, the user shouldn't be using builtin directly, but should rather use __arm_atomic_store_with_hint as documented in the acle. That however requires arm_acle header, which is not supported with LFI, that's why I think we don't have to worry about it. What do you think ? 

For this reason also I think we should switch the tests to use __arm_atomic_store_with_hint intsead of builtin.

https://github.com/llvm/llvm-project/pull/198316


More information about the cfe-commits mailing list