• Home
  • Line#
  • Scopes#
  • Navigate#
  • Raw
  • Download
1; RUN: opt < %s -internalize -S | FileCheck %s
2; Internalized symbols should have default visibility.
3
4; CHECK: @global = global i32 0
5@global = global i32 0
6@llvm.used = appending global [1 x i32*] [i32* @global]
7
8; CHECK: @hidden.variable = internal global i32 0
9@hidden.variable = hidden global i32 0
10; CHECK: @protected.variable = internal global i32 0
11@protected.variable = protected global i32 0
12
13; CHECK: @hidden.alias = internal alias  i32,  i32* @global
14@hidden.alias = hidden alias i32, i32* @global
15; CHECK: @protected.alias = internal alias i32, i32* @global
16@protected.alias = protected alias i32, i32* @global
17
18; CHECK: define internal void @hidden.function() {
19define hidden void @hidden.function() {
20  ret void
21}
22; CHECK: define internal void @protected.function() {
23define protected void @protected.function() {
24  ret void
25}
26