llvm-6502/test/DebugInfo/2010-03-19-DbgDeclare.ll
Devang Patel 608f5a6d48 call void @llvm.dbg.declare(metadata !{i32* null}, metadata !1)
is valid, but not useful, when variable  identified by !1 is optimized away by the optimizer.


git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@98986 91177308-0d34-0410-b5e6-96231b3b80d8
2010-03-19 21:06:24 +00:00

13 lines
338 B
LLVM

; RUN: llvm-as < %s | opt -verify -disable-output
define void @Foo(i32 %a, i32 %b) {
entry:
call void @llvm.dbg.declare(metadata !{i32* null}, metadata !1)
ret void
}
!0 = metadata !{i32 662302, i32 26, metadata !1, null}
!1 = metadata !{i32 4, metadata !"foo"}
declare void @llvm.dbg.declare(metadata, metadata) nounwind readnone