2 source_filename = "test.c"
3 target datalayout = "e-m:e-p270:32:32-p271:32:32-p272:64:64-i64:64-f80:128-n8:16:32:64-S128"
4 target triple = "x86_64-unknown-linux-gnu"
6 ; RUN: opt -module-summary %s -o %t.bc
7 ; RUN: llvm-lto2 run -save-temps %t.bc -o %t.out \
8 ; RUN: -r=%t.bc,foo,plx \
11 ; Check that we don't internalize `bar` during promotion,
12 ; because foo and bar are members of the same comdat
13 ; RUN: llvm-dis %t.out.1.1.promote.bc -o - | FileCheck %s
15 ; Thin LTO internalization shouldn't internalize `bar` as well
16 ; RUN: llvm-dis %t.out.1.2.internalize.bc -o - | FileCheck %s
18 ; CHECK: define linkonce_odr dso_local i32 @bar() comdat($foo)
22 ; Function Attrs: noinline nounwind optnone uwtable
23 define linkonce_odr dso_local i32 @bar() comdat($foo) {
28 ; Function Attrs: noinline nounwind optnone uwtable
29 define linkonce_odr dso_local i32 @foo() comdat {
31 %call = call i32 @bar()
32 %add = add nsw i32 42, %call