Author: John McCall
Date: 2026-08-13T18:53:47Z
New Revision: 389da87c52f1db63440f376621f5daee2fabaaf3

URL: 
https://github.com/llvm/llvm-project/commit/389da87c52f1db63440f376621f5daee2fabaaf3
DIFF: 
https://github.com/llvm/llvm-project/commit/389da87c52f1db63440f376621f5daee2fabaaf3.diff

LOG: Document that the swiftcall and swiftasynccall attributes are ABI-unstable 
(#215915)

...except on platforms where the Swift projects has declared ABI
stability.

Added: 
    

Modified: 
    clang/include/clang/Basic/AttrDocs.td

Removed: 
    


################################################################################
diff  --git a/clang/include/clang/Basic/AttrDocs.td 
b/clang/include/clang/Basic/AttrDocs.td
index 0180375cbf6b6..3052dd6c77ab1 100644
--- a/clang/include/clang/Basic/AttrDocs.td
+++ b/clang/include/clang/Basic/AttrDocs.td
@@ -6490,6 +6490,14 @@ with `__has_attribute(swiftcall)`. Query if the target 
supports the
 calling convention with `__has_extension(swiftcc)`. This implies
 support for the `swift_context`, `swift_error_result`, and
 `swift_indirect_result` attributes.
+
+Since this attribute follows the Swift calling convention, it is
+considered ABI-unstable except on targets where the Swift project
+has declared ABI stability. Users are responsible for ensuring that
+calls and definitions of functions with this attribute are compiled
+with compatible compilers. Note that 
diff erent operating systems
+on the same architecture may use 
diff erent ABIs and therefore may
+have 
diff erent standards for ABI stability.
   }];
 }
 
@@ -6538,6 +6546,14 @@ the following:
 Query for this attribute with `__has_attribute(swiftasynccall)`. Query if
 the target supports the calling convention with
 `__has_extension(swiftasynccc)`.
+
+Since this attribute follows the Swift async calling convention, it is
+considered ABI-unstable except on targets where the Swift project
+has declared ABI stability. Users are responsible for ensuring that
+calls and definitions of functions with this attribute are compiled
+with compatible compilers. Note that 
diff erent operating systems
+on the same architecture may use 
diff erent ABIs and therefore may
+have 
diff erent standards for ABI stability.
   }];
 }
 


        
_______________________________________________
cfe-commits mailing list
[email protected]
https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

Reply via email to