[clang] [CIR] Emit no-trapping-math and stack-protector-buffer-size function attribute (PR #234029)

Konstantinos Parasyris via cfe-commits cfe-commits at lists.llvm.org
Fri Nov 6 10:45:57 PST 2026


================
@@ -3382,6 +3385,10 @@ void CIRGenModule::setCIRFunctionAttributes(GlobalDecl globalDecl,
                          retAttrs, callingConv,
                          /*attrOnCallSite=*/false, isThunk);
 
+  // A function declared by the source gets the default function attributes,
+  // even if it was first created as a runtime function.
+  func->removeAttr(cir::CIRDialect::getRuntimeFuncAttrName());
----------------
koparasy wrote:

[c21daab](https://github.com/llvm/llvm-project/pull/234029/commits/c21daabdf9fd84e09f194a14886e3568268ba68f)

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


More information about the cfe-commits mailing list