define void @foo(i32* %h, i16* %y) {
entry:
  br label %outer.cond

outer.cond:                                         ; preds = %inner.end, %entry
  %yp.0 = phi i16* [ %y, %entry ], [ %yp.2, %inner.end ]
  %i.0 = phi i16 [ 0, %entry ], [ %i.1, %inner.end ]
  %cmp = icmp slt i16 %i.0, 100
  br i1 %cmp, label %outer.body, label %outer.end

outer.body:                                         ; preds = %outer.cond
  %hp.0 = getelementptr inbounds i32, i32* %h, i32 1
  %h.0 = load i32, i32* %h, align 1, !tbaa !4
  br label %inner.cond

inner.cond:                                         ; preds = %inner.body, %outer.body
  %real.0 = phi i32 [ 0, %outer.body ], [ %sub, %inner.body ]
  %j.0 = phi i16 [ 0, %outer.body ], [ %j.1, %inner.body ]
  %hp.1 = phi i32* [ %hp.0, %outer.body ], [ %hp.2, %inner.body ]
  %h.1 = phi i32 [ %h.0, %outer.body ], [ %h.2, %inner.body ]
  %cmp3 = icmp slt i16 %j.0, 100
  br i1 %cmp3, label %inner.body, label %inner.end

inner.body:                                         ; preds = %inner.cond
  %conv = trunc i32 %h.1 to i16
  %conv7 = sext i16 %conv to i32
  %add = add nsw i32 %real.0, %conv7
  %sub = sub nsw i32 %add, %h.1
  %hp.2 = getelementptr inbounds i32, i32* %hp.1, i32 1
  %h.2 = load i32, i32* %hp.1, align 1, !tbaa !4
  %j.1 = add nsw i16 %j.0, 1
  br label %inner.cond, !llvm.loop !8

inner.end:                                          ; preds = %inner.cond
  %conv27 = trunc i32 %real.0 to i16
  store i16 %conv27, i16* %yp.0, align 1, !tbaa !16
  %yp.1 = getelementptr inbounds i16, i16* %yp.0, i32 1
  store i16 0, i16* %yp.1, align 1, !tbaa !16
  %yp.2 = getelementptr inbounds i16, i16* %yp.1, i32 1
  %i.1 = add nsw i16 %i.0, 1
  br label %outer.cond, !llvm.loop !18

outer.end:                                          ; preds = %outer.cond
  ret void
}

!llvm.dbg.cu = !{}
!llvm.module.flags = !{!0, !1, !2}
!llvm.ident = !{!3}

!0 = !{i32 7, !"Dwarf Version", i32 4}
!1 = !{i32 2, !"Debug Info Version", i32 3}
!2 = !{i32 1, !"wchar_size", i32 1}
!3 = !{!"clang version 11.0.0 "}
!4 = !{!5, !5, i64 0}
!5 = !{!"int", !6, i64 0}
!6 = !{!"omnipotent char", !7, i64 0}
!7 = !{!"Simple C/C++ TBAA"}
!8 = distinct !{!8, !9, !15}
!9 = !DILocation(line: 86, column: 2, scope: !10)
!10 = distinct !DISubprogram(name: "foo", scope: !11, file: !11, line: 71, type: !12, scopeLine: 72, unit: !14)
!11 = !DIFile(filename: "foo.c", directory: "/")
!12 = !DISubroutineType(types: !13)
!13 = !{}
!14 = distinct !DICompileUnit(language: DW_LANG_C99, file: !11, producer: "clang version 11.0.0", isOptimized: true, runtimeVersion: 0, emissionKind: LineTablesOnly)
!15 = !DILocation(line: 99, column: 2, scope: !10)
!16 = !{!17, !17, i64 0}
!17 = !{!"short", !6, i64 0}
!18 = distinct !{!18, !19, !20}
!19 = !DILocation(line: 78, column: 5, scope: !10)
!20 = !DILocation(line: 103, column: 5, scope: !10)
