reference, declarationdefinition
definition → references, declarations, derived classes, virtual overrides
reference to multiple definitions → definitions
unreferenced
    1
    2
    3
    4
    5
    6
    7
    8
    9
   10
   11
   12
   13
   14
   15
   16
   17
   18
   19
   20
   21
   22
   23
   24
   25
   26
   27
   28
   29
   30
   31
   32
   33
   34
   35
   36
   37
   38
   39
   40
   41
   42
   43
   44
   45
   46
   47
   48
   49
   50
   51
   52
   53
   54
   55
   56
   57
   58
   59
   60
   61
; Check the linkage types in both the per-module and combined summaries.
; RUN: opt -module-summary %s -o %t.o
; RUN: llvm-bcanalyzer -dump %t.o | FileCheck %s
; RUN: llvm-lto -thinlto -o %t2 %t.o
; RUN: llvm-bcanalyzer -dump %t2.thinlto.bc | FileCheck %s --check-prefix=COMBINED

define private void @private()
; CHECK: <PERMODULE {{.*}} op1=72
; COMBINED-DAG: <COMBINED {{.*}} op2=72
{
  ret void
}

define internal void @internal()
; CHECK: <PERMODULE {{.*}} op1=7
; COMBINED-DAG: <COMBINED {{.*}} op2=7
{
  ret void
}

define available_externally void @available_externally()
; CHECK: <PERMODULE {{.*}} op1=1
; COMBINED-DAG: <COMBINED {{.*}} op2=1
{
  ret void
}

define linkonce void @linkonce()
; CHECK: <PERMODULE {{.*}} op1=2
; COMBINED-DAG: <COMBINED {{.*}} op2=2
{
  ret void
}

define weak void @weak()
; CHECK: <PERMODULE {{.*}} op1=4
; COMBINED-DAG: <COMBINED {{.*}} op2=4
{
  ret void
}

define linkonce_odr void @linkonce_odr()
; CHECK: <PERMODULE {{.*}} op1=3
; COMBINED-DAG: <COMBINED {{.*}} op2=3
{
  ret void
}

define weak_odr void @weak_odr()
; CHECK: <PERMODULE {{.*}} op1=5
; COMBINED-DAG: <COMBINED {{.*}} op2=5
{
  ret void
}

define external void @external()
; CHECK: <PERMODULE {{.*}} op1=0
; COMBINED-DAG: <COMBINED {{.*}} op2=0
{
  ret void
}