[all-commits] [llvm/llvm-project] 4516dc: Don't add optnone or noinline if the function is a...

ahatanaka via All-commits all-commits at lists.llvm.org
Fri Nov 15 15:46:36 PST 2019


  Branch: refs/heads/master
  Home:   https://github.com/llvm/llvm-project
  Commit: 4516dc1c20d1e77f20a72e90be876506805b3978
      https://github.com/llvm/llvm-project/commit/4516dc1c20d1e77f20a72e90be876506805b3978
  Author: Akira Hatanaka <ahatanaka at apple.com>
  Date:   2019-11-15 (Fri, 15 Nov 2019)

  Changed paths:
    M clang/lib/CodeGen/CodeGenModule.cpp
    M clang/test/CodeGenCXX/apple-kext.cpp

  Log Message:
  -----------
  Don't add optnone or noinline if the function is already marked as
always_inline.

The assertion in SetLLVMFunctionAttributesForDefinition used to fail
when there was attribute OptimizeNone on the AST function and attribute
always_inline on the IR function. This happens because base destructors
are annotated with always_inline when the code is compiled with
-fapple-kext (see r124757).

rdar://problem/57169694




More information about the All-commits mailing list