blob: a09ba72439fcf7ea848c90695e271bd8cb38c10c [file] [log] [blame]
Chris Lattnerc1c45952010-04-28 22:34:35 +00001; RUN: opt -S -globalopt < %s | FileCheck %s
Chris Lattnerf3f325b2010-04-28 20:16:12 +00002
3; PR6112 - When globalopt does RAUW(@G, %G), the metadata reference should drop
4; to null.
5@G = internal global i8** null
6
7define i32 @main(i32 %argc, i8** %argv) {
8; CHECK: @main
9; CHECK: %G = alloca
10 store i8** %argv, i8*** @G
11 ret i32 0
12}
13
14!named = !{!0}
15
16; CHECK: !0 = metadata !{null}
17!0 = metadata !{i8*** @G}
18
19