Follow-up to #174899 which added the flatten function attribute to LLVM IR and implemented recursive inlining in the `AlwaysInliner` pass. This patch updates Clang to emit the LLVM flatten attribute on functions with `__attribute__((flatten))`, instead of the previous approach of marking each call site with `alwaysinline`. This completes the transition to matching GCC's flatten semantics. Changes: - Remove the callsite `alwaysinline` annotation logic from CGCall.cpp - Emit the flatten function attribute in CodeGenModule.cpp - Update clang/test/CodeGen/flatten.c to reflect the new IR output - Update clang/test/CodeGen/AArch64/sme-inline-callees-streaming-attrs.c to reflect the new behavior - Add release notes documenting the behavior change RFC: https://discourse.llvm.org/t/rfc-function-level-flatten-depth-attribute-for-depth-limited-inlining
255 KiB
255 KiB