; LLVM IR from rweather/lightweight-crypto :: src/genavr/code.ll (ZN4Code9double_gfERK3Regj)

; Unoptimized IR (clang -disable-llvm-passes):
target datalayout = "e-m:e-p270:32:32-p271:32:32-p272:64:64-i64:64-i128:128-f80:128-n8:16:32:64-S128"
target triple = "x86_64-unknown-linux-gnu"

%class.Reg = type { %"class.std::vector" }
%"class.std::vector" = type { %"struct.std::_Vector_base" }
%"struct.std::_Vector_base" = type { %"struct.std::_Vector_base<unsigned char, std::allocator<unsigned char>>::_Vector_impl" }
%"struct.std::_Vector_base<unsigned char, std::allocator<unsigned char>>::_Vector_impl" = type { %"struct.std::_Vector_base<unsigned char, std::allocator<unsigned char>>::_Vector_impl_data" }
%"struct.std::_Vector_base<unsigned char, std::allocator<unsigned char>>::_Vector_impl_data" = type { ptr, ptr, ptr }

declare i32 @__gxx_personality_v0(...)

; Function Attrs: mustprogress nounwind uwtable
declare dso_local noundef i32 @_ZNK3Reg4sizeEv(ptr noundef nonnull align 8 dereferenceable(24)) #0 align 2

; Function Attrs: nocallback nofree nosync nounwind willreturn memory(argmem: readwrite)
declare void @llvm.lifetime.start.p0(i64 immarg, ptr nocapture) #1

; Function Attrs: nocallback nofree nosync nounwind willreturn memory(argmem: readwrite)
declare void @llvm.lifetime.end.p0(i64 immarg, ptr nocapture) #1

; Function Attrs: mustprogress nounwind uwtable
declare dso_local void @_ZN3RegD2Ev(ptr noundef nonnull align 8 dereferenceable(24)) unnamed_addr #0 align 2

; Function Attrs: mustprogress uwtable
declare dso_local void @_ZN4Code15allocateHighRegEj(ptr dead_on_unwind noalias writable sret(%class.Reg) align 8, ptr noundef nonnull align 8 dereferenceable(200), i32 noundef) #2 align 2

; Function Attrs: mustprogress uwtable
declare dso_local void @_ZN4Code10releaseRegERK3Reg(ptr noundef nonnull align 8 dereferenceable(200), ptr noundef nonnull align 8 dereferenceable(24)) #2 align 2

; Function Attrs: mustprogress uwtable
declare dso_local noundef zeroext i8 @_ZNK3Reg3regEi(ptr noundef nonnull align 8 dereferenceable(24), i32 noundef) #2 align 2

; Function Attrs: mustprogress uwtable
declare dso_local void @_ZN4Code6tworegEN4Insn4TypeEhh(ptr noundef nonnull align 8 dereferenceable(200), i32 noundef, i8 noundef zeroext, i8 noundef zeroext) #2 align 2

; Function Attrs: mustprogress uwtable
declare dso_local void @_ZN4Code6oneregEN4Insn4TypeEh(ptr noundef nonnull align 8 dereferenceable(200), i32 noundef, i8 noundef zeroext) #2 align 2

; Function Attrs: mustprogress uwtable
declare dso_local void @_ZN4Code6immregEN4Insn4TypeEhh(ptr noundef nonnull align 8 dereferenceable(200), i32 noundef, i8 noundef zeroext, i8 noundef zeroext) #2 align 2

; Function Attrs: mustprogress uwtable
declare dso_local noundef zeroext i8 @_ZN4Code7tempregEv(ptr noundef nonnull align 8 dereferenceable(200)) #2 align 2

; Function Attrs: mustprogress uwtable
declare dso_local void @_ZN4Code13zeroreg_no_ccEh(ptr noundef nonnull align 8 dereferenceable(200), i8 noundef zeroext) #2 align 2

; Function Attrs: mustprogress uwtable
define dso_local void @_ZN4Code9double_gfERK3Regj(ptr noundef nonnull align 8 dereferenceable(200) %0, ptr noundef nonnull align 8 dereferenceable(24) %1, i32 noundef %2) #2 align 2 personality ptr @__gxx_personality_v0 {
  %4 = alloca ptr, align 8
  %5 = alloca ptr, align 8
  %6 = alloca i32, align 4
  %7 = alloca i32, align 4
  %8 = alloca %class.Reg, align 8
  %9 = alloca ptr, align 8
  %10 = alloca i32, align 4
  %11 = alloca i8, align 1
  store ptr %0, ptr %4, align 8, !tbaa !5
  store ptr %1, ptr %5, align 8, !tbaa !5
  store i32 %2, ptr %6, align 4, !tbaa !9
  %12 = load ptr, ptr %4, align 8
  %13 = load ptr, ptr %5, align 8, !tbaa !5
  %14 = call noundef i32 @_ZNK3Reg4sizeEv(ptr noundef nonnull align 8 dereferenceable(24) %13)
  %15 = icmp eq i32 %14, 0
  br i1 %15, label %16, label %17

16:                                               ; preds = %3
  br label %110

17:                                               ; preds = %3
  %18 = load ptr, ptr %5, align 8, !tbaa !5
  %19 = call noundef zeroext i8 @_ZNK3Reg3regEi(ptr noundef nonnull align 8 dereferenceable(24) %18, i32 noundef 0)
  call void @_ZN4Code6oneregEN4Insn4TypeEh(ptr noundef nonnull align 8 dereferenceable(200) %12, i32 noundef 32, i8 noundef zeroext %19)
  call void @llvm.lifetime.start.p0(i64 4, ptr %7) #3
  store i32 1, ptr %7, align 4, !tbaa !9
  br label %20

20:                                               ; preds = %30, %17
  %21 = load i32, ptr %7, align 4, !tbaa !9
  %22 = load ptr, ptr %5, align 8, !tbaa !5
  %23 = call noundef i32 @_ZNK3Reg4sizeEv(ptr noundef nonnull align 8 dereferenceable(24) %22)
  %24 = icmp slt i32 %21, %23
  br i1 %24, label %26, label %25

25:                                               ; preds = %20
  call void @llvm.lifetime.end.p0(i64 4, ptr %7) #3
  br label %33

26:                                               ; preds = %20
  %27 = load ptr, ptr %5, align 8, !tbaa !5
  %28 = load i32, ptr %7, align 4, !tbaa !9
  %29 = call noundef zeroext i8 @_ZNK3Reg3regEi(ptr noundef nonnull align 8 dereferenceable(24) %27, i32 noundef %28)
  call void @_ZN4Code6oneregEN4Insn4TypeEh(ptr noundef nonnull align 8 dereferenceable(200) %12, i32 noundef 46, i8 noundef zeroext %29)
  br label %30

30:                                               ; preds = %26
  %31 = load i32, ptr %7, align 4, !tbaa !9
  %32 = add nsw i32 %31, 1
  store i32 %32, ptr %7, align 4, !tbaa !9
  br label %20, !llvm.loop !11

33:                                               ; preds = %25
  call void @llvm.lifetime.start.p0(i64 24, ptr %8) #3
  call void @_ZN4Code15allocateHighRegEj(ptr dead_on_unwind writable sret(%class.Reg) align 8 %8, ptr noundef nonnull align 8 dereferenceable(200) %12, i32 noundef 1)
  %34 = load i32, ptr %6, align 4, !tbaa !9
  %35 = icmp ult i32 %34, 256
  br i1 %35, label %41, label %36

36:                                               ; preds = %33
  %37 = load ptr, ptr %5, align 8, !tbaa !5
  %38 = invoke noundef i32 @_ZNK3Reg4sizeEv(ptr noundef nonnull align 8 dereferenceable(24) %37)
          to label %39 unwind label %61

39:                                               ; preds = %36
  %40 = icmp eq i32 %38, 1
  br i1 %40, label %41, label %65

41:                                               ; preds = %39, %33
  %42 = invoke noundef zeroext i8 @_ZNK3Reg3regEi(ptr noundef nonnull align 8 dereferenceable(24) %8, i32 noundef 0)
          to label %43 unwind label %61

43:                                               ; preds = %41
  invoke void @_ZN4Code13zeroreg_no_ccEh(ptr noundef nonnull align 8 dereferenceable(200) %12, i8 noundef zeroext %42)
          to label %44 unwind label %61

44:                                               ; preds = %43
  %45 = invoke noundef zeroext i8 @_ZNK3Reg3regEi(ptr noundef nonnull align 8 dereferenceable(24) %8, i32 noundef 0)
          to label %46 unwind label %61

46:                                               ; preds = %44
  %47 = invoke noundef zeroext i8 @_ZNK3Reg3regEi(ptr noundef nonnull align 8 dereferenceable(24) %8, i32 noundef 0)
          to label %48 unwind label %61

48:                                               ; preds = %46
  invoke void @_ZN4Code6tworegEN4Insn4TypeEhh(ptr noundef nonnull align 8 dereferenceable(200) %12, i32 noundef 48, i8 noundef zeroext %45, i8 noundef zeroext %47)
          to label %49 unwind label %61

49:                                               ; preds = %48
  %50 = invoke noundef zeroext i8 @_ZNK3Reg3regEi(ptr noundef nonnull align 8 dereferenceable(24) %8, i32 noundef 0)
          to label %51 unwind label %61

51:                                               ; preds = %49
  %52 = load i32, ptr %6, align 4, !tbaa !9
  %53 = trunc i32 %52 to i8
  invoke void @_ZN4Code6immregEN4Insn4TypeEhh(ptr noundef nonnull align 8 dereferenceable(200) %12, i32 noundef 4, i8 noundef zeroext %50, i8 noundef zeroext %53)
          to label %54 unwind label %61

54:                                               ; preds = %51
  %55 = load ptr, ptr %5, align 8, !tbaa !5
  %56 = invoke noundef zeroext i8 @_ZNK3Reg3regEi(ptr noundef nonnull align 8 dereferenceable(24) %55, i32 noundef 0)
          to label %57 unwind label %61

57:                                               ; preds = %54
  %58 = invoke noundef zeroext i8 @_ZNK3Reg3regEi(ptr noundef nonnull align 8 dereferenceable(24) %8, i32 noundef 0)
          to label %59 unwind label %61

59:                                               ; preds = %57
  invoke void @_ZN4Code6tworegEN4Insn4TypeEhh(ptr noundef nonnull align 8 dereferenceable(200) %12, i32 noundef 19, i8 noundef zeroext %56, i8 noundef zeroext %58)
          to label %60 unwind label %61

60:                                               ; preds = %59
  br label %108

61:                                               ; preds = %108, %59, %57, %54, %51, %49, %48, %46, %44, %43, %41, %36
  %62 = landingpad { ptr, i32 }
          cleanup
  %63 = extractvalue { ptr, i32 } %62, 0
  store ptr %63, ptr %9, align 8
  %64 = extractvalue { ptr, i32 } %62, 1
  store i32 %64, ptr %10, align 4
  br label %111

65:                                               ; preds = %39
  call void @llvm.lifetime.start.p0(i64 1, ptr %11) #3
  %66 = invoke noundef zeroext i8 @_ZN4Code7tempregEv(ptr noundef nonnull align 8 dereferenceable(200) %12)
          to label %67 unwind label %104

67:                                               ; preds = %65
  store i8 %66, ptr %11, align 1, !tbaa !13
  %68 = load i8, ptr %11, align 1, !tbaa !13
  invoke void @_ZN4Code13zeroreg_no_ccEh(ptr noundef nonnull align 8 dereferenceable(200) %12, i8 noundef zeroext %68)
          to label %69 unwind label %104

69:                                               ; preds = %67
  %70 = load i8, ptr %11, align 1, !tbaa !13
  %71 = load i8, ptr %11, align 1, !tbaa !13
  invoke void @_ZN4Code6tworegEN4Insn4TypeEhh(ptr noundef nonnull align 8 dereferenceable(200) %12, i32 noundef 48, i8 noundef zeroext %70, i8 noundef zeroext %71)
          to label %72 unwind label %104

72:                                               ; preds = %69
  %73 = invoke noundef zeroext i8 @_ZNK3Reg3regEi(ptr noundef nonnull align 8 dereferenceable(24) %8, i32 noundef 0)
          to label %74 unwind label %104

74:                                               ; preds = %72
  %75 = load i32, ptr %6, align 4, !tbaa !9
  %76 = trunc i32 %75 to i8
  invoke void @_ZN4Code6immregEN4Insn4TypeEhh(ptr noundef nonnull align 8 dereferenceable(200) %12, i32 noundef 26, i8 noundef zeroext %73, i8 noundef zeroext %76)
          to label %77 unwind label %104

77:                                               ; preds = %74
  %78 = invoke noundef zeroext i8 @_ZNK3Reg3regEi(ptr noundef nonnull align 8 dereferenceable(24) %8, i32 noundef 0)
          to label %79 unwind label %104

79:                                               ; preds = %77
  %80 = load i8, ptr %11, align 1, !tbaa !13
  invoke void @_ZN4Code6tworegEN4Insn4TypeEhh(ptr noundef nonnull align 8 dereferenceable(200) %12, i32 noundef 3, i8 noundef zeroext %78, i8 noundef zeroext %80)
          to label %81 unwind label %104

81:                                               ; preds = %79
  %82 = load ptr, ptr %5, align 8, !tbaa !5
  %83 = invoke noundef zeroext i8 @_ZNK3Reg3regEi(ptr noundef nonnull align 8 dereferenceable(24) %82, i32 noundef 0)
          to label %84 unwind label %104

84:                                               ; preds = %81
  %85 = invoke noundef zeroext i8 @_ZNK3Reg3regEi(ptr noundef nonnull align 8 dereferenceable(24) %8, i32 noundef 0)
          to label %86 unwind label %104

86:                                               ; preds = %84
  invoke void @_ZN4Code6tworegEN4Insn4TypeEhh(ptr noundef nonnull align 8 dereferenceable(200) %12, i32 noundef 19, i8 noundef zeroext %83, i8 noundef zeroext %85)
          to label %87 unwind label %104

87:                                               ; preds = %86
  %88 = invoke noundef zeroext i8 @_ZNK3Reg3regEi(ptr noundef nonnull align 8 dereferenceable(24) %8, i32 noundef 0)
          to label %89 unwind label %104

89:                                               ; preds = %87
  %90 = load i32, ptr %6, align 4, !tbaa !9
  %91 = lshr i32 %90, 8
  %92 = trunc i32 %91 to i8
  invoke void @_ZN4Code6immregEN4Insn4TypeEhh(ptr noundef nonnull align 8 dereferenceable(200) %12, i32 noundef 26, i8 noundef zeroext %88, i8 noundef zeroext %92)
          to label %93 unwind label %104

93:                                               ; preds = %89
  %94 = invoke noundef zeroext i8 @_ZNK3Reg3regEi(ptr noundef nonnull align 8 dereferenceable(24) %8, i32 noundef 0)
          to label %95 unwind label %104

95:                                               ; preds = %93
  %96 = load i8, ptr %11, align 1, !tbaa !13
  invoke void @_ZN4Code6tworegEN4Insn4TypeEhh(ptr noundef nonnull align 8 dereferenceable(200) %12, i32 noundef 3, i8 noundef zeroext %94, i8 noundef zeroext %96)
          to label %97 unwind label %104

97:                                               ; preds = %95
  %98 = load ptr, ptr %5, align 8, !tbaa !5
  %99 = invoke noundef zeroext i8 @_ZNK3Reg3regEi(ptr noundef nonnull align 8 dereferenceable(24) %98, i32 noundef 1)
          to label %100 unwind label %104

100:                                              ; preds = %97
  %101 = invoke noundef zeroext i8 @_ZNK3Reg3regEi(ptr noundef nonnull align 8 dereferenceable(24) %8, i32 noundef 0)
          to label %102 unwind label %104

102:                                              ; preds = %100
  invoke void @_ZN4Code6tworegEN4Insn4TypeEhh(ptr noundef nonnull align 8 dereferenceable(200) %12, i32 noundef 19, i8 noundef zeroext %99, i8 noundef zeroext %101)
          to label %103 unwind label %104

103:                                              ; preds = %102
  call void @llvm.lifetime.end.p0(i64 1, ptr %11) #3
  br label %108

104:                                              ; preds = %102, %100, %97, %95, %93, %89, %87, %86, %84, %81, %79, %77, %74, %72, %69, %67, %65
  %105 = landingpad { ptr, i32 }
          cleanup
  %106 = extractvalue { ptr, i32 } %105, 0
  store ptr %106, ptr %9, align 8
  %107 = extractvalue { ptr, i32 } %105, 1
  store i32 %107, ptr %10, align 4
  call void @llvm.lifetime.end.p0(i64 1, ptr %11) #3
  br label %111

108:                                              ; preds = %103, %60
  invoke void @_ZN4Code10releaseRegERK3Reg(ptr noundef nonnull align 8 dereferenceable(200) %12, ptr noundef nonnull align 8 dereferenceable(24) %8)
          to label %109 unwind label %61

109:                                              ; preds = %108
  call void @_ZN3RegD2Ev(ptr noundef nonnull align 8 dereferenceable(24) %8) #3
  call void @llvm.lifetime.end.p0(i64 24, ptr %8) #3
  br label %110

110:                                              ; preds = %109, %16
  ret void

111:                                              ; preds = %104, %61
  call void @_ZN3RegD2Ev(ptr noundef nonnull align 8 dereferenceable(24) %8) #3
  call void @llvm.lifetime.end.p0(i64 24, ptr %8) #3
  br label %112

112:                                              ; preds = %111
  %113 = load ptr, ptr %9, align 8
  %114 = load i32, ptr %10, align 4
  %115 = insertvalue { ptr, i32 } poison, ptr %113, 0
  %116 = insertvalue { ptr, i32 } %115, i32 %114, 1
  resume { ptr, i32 } %116
}

attributes #0 = { mustprogress nounwind uwtable "min-legal-vector-width"="0" "no-trapping-math"="true" "stack-protector-buffer-size"="8" "target-cpu"="x86-64" "target-features"="+cmov,+cx8,+fxsr,+mmx,+sse,+sse2,+x87" "tune-cpu"="generic" }
attributes #1 = { nocallback nofree nosync nounwind willreturn memory(argmem: readwrite) }
attributes #2 = { mustprogress uwtable "min-legal-vector-width"="0" "no-trapping-math"="true" "stack-protector-buffer-size"="8" "target-cpu"="x86-64" "target-features"="+cmov,+cx8,+fxsr,+mmx,+sse,+sse2,+x87" "tune-cpu"="generic" }
attributes #3 = { nounwind }

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

!0 = !{i32 1, !"wchar_size", i32 4}
!1 = !{i32 8, !"PIC Level", i32 2}
!2 = !{i32 7, !"PIE Level", i32 2}
!3 = !{i32 7, !"uwtable", i32 2}
!4 = !{!"clang version 19.1.0 (git@github.com:llvm/llvm-project.git a4bf6cd7cfb1a1421ba92bca9d017b49936c55e4)"}
!5 = !{!6, !6, i64 0}
!6 = !{!"any pointer", !7, i64 0}
!7 = !{!"omnipotent char", !8, i64 0}
!8 = !{!"Simple C++ TBAA"}
!9 = !{!10, !10, i64 0}
!10 = !{!"int", !7, i64 0}
!11 = distinct !{!11, !12}
!12 = !{!"llvm.loop.mustprogress"}
!13 = !{!7, !7, i64 0}


; Optimized IR (opt -passes='default<O3>'):
target datalayout = "e-m:e-p270:32:32-p271:32:32-p272:64:64-i64:64-i128:128-f80:128-n8:16:32:64-S128"
target triple = "x86_64-unknown-linux-gnu"

%class.Reg = type { %"class.std::vector" }
%"class.std::vector" = type { %"struct.std::_Vector_base" }
%"struct.std::_Vector_base" = type { %"struct.std::_Vector_base<unsigned char, std::allocator<unsigned char>>::_Vector_impl" }
%"struct.std::_Vector_base<unsigned char, std::allocator<unsigned char>>::_Vector_impl" = type { %"struct.std::_Vector_base<unsigned char, std::allocator<unsigned char>>::_Vector_impl_data" }
%"struct.std::_Vector_base<unsigned char, std::allocator<unsigned char>>::_Vector_impl_data" = type { ptr, ptr, ptr }

declare i32 @__gxx_personality_v0(...)

; Function Attrs: mustprogress nounwind uwtable
declare dso_local noundef i32 @_ZNK3Reg4sizeEv(ptr noundef nonnull align 8 dereferenceable(24)) local_unnamed_addr #0 align 2

; Function Attrs: mustprogress nocallback nofree nosync nounwind willreturn memory(argmem: readwrite)
declare void @llvm.lifetime.start.p0(i64 immarg, ptr nocapture) #1

; Function Attrs: mustprogress nocallback nofree nosync nounwind willreturn memory(argmem: readwrite)
declare void @llvm.lifetime.end.p0(i64 immarg, ptr nocapture) #1

; Function Attrs: mustprogress nounwind uwtable
declare dso_local void @_ZN3RegD2Ev(ptr noundef nonnull align 8 dereferenceable(24)) unnamed_addr #0 align 2

; Function Attrs: mustprogress uwtable
declare dso_local void @_ZN4Code15allocateHighRegEj(ptr dead_on_unwind noalias writable sret(%class.Reg) align 8, ptr noundef nonnull align 8 dereferenceable(200), i32 noundef) local_unnamed_addr #2 align 2

; Function Attrs: mustprogress uwtable
declare dso_local void @_ZN4Code10releaseRegERK3Reg(ptr noundef nonnull align 8 dereferenceable(200), ptr noundef nonnull align 8 dereferenceable(24)) local_unnamed_addr #2 align 2

; Function Attrs: mustprogress uwtable
declare dso_local noundef zeroext i8 @_ZNK3Reg3regEi(ptr noundef nonnull align 8 dereferenceable(24), i32 noundef) local_unnamed_addr #2 align 2

; Function Attrs: mustprogress uwtable
declare dso_local void @_ZN4Code6tworegEN4Insn4TypeEhh(ptr noundef nonnull align 8 dereferenceable(200), i32 noundef, i8 noundef zeroext, i8 noundef zeroext) local_unnamed_addr #2 align 2

; Function Attrs: mustprogress uwtable
declare dso_local void @_ZN4Code6oneregEN4Insn4TypeEh(ptr noundef nonnull align 8 dereferenceable(200), i32 noundef, i8 noundef zeroext) local_unnamed_addr #2 align 2

; Function Attrs: mustprogress uwtable
declare dso_local void @_ZN4Code6immregEN4Insn4TypeEhh(ptr noundef nonnull align 8 dereferenceable(200), i32 noundef, i8 noundef zeroext, i8 noundef zeroext) local_unnamed_addr #2 align 2

; Function Attrs: mustprogress uwtable
declare dso_local noundef zeroext i8 @_ZN4Code7tempregEv(ptr noundef nonnull align 8 dereferenceable(200)) local_unnamed_addr #2 align 2

; Function Attrs: mustprogress uwtable
declare dso_local void @_ZN4Code13zeroreg_no_ccEh(ptr noundef nonnull align 8 dereferenceable(200), i8 noundef zeroext) local_unnamed_addr #2 align 2

; Function Attrs: mustprogress uwtable
define dso_local void @_ZN4Code9double_gfERK3Regj(ptr noundef nonnull align 8 dereferenceable(200) %0, ptr noundef nonnull align 8 dereferenceable(24) %1, i32 noundef %2) local_unnamed_addr #2 align 2 personality ptr @__gxx_personality_v0 {
  %4 = alloca %class.Reg, align 8
  %5 = tail call noundef i32 @_ZNK3Reg4sizeEv(ptr noundef nonnull align 8 dereferenceable(24) %1)
  %6 = icmp eq i32 %5, 0
  br i1 %6, label %71, label %7

7:                                                ; preds = %3
  %8 = tail call noundef zeroext i8 @_ZNK3Reg3regEi(ptr noundef nonnull align 8 dereferenceable(24) %1, i32 noundef 0)
  tail call void @_ZN4Code6oneregEN4Insn4TypeEh(ptr noundef nonnull align 8 dereferenceable(200) %0, i32 noundef 32, i8 noundef zeroext %8)
  %9 = tail call noundef i32 @_ZNK3Reg4sizeEv(ptr noundef nonnull align 8 dereferenceable(24) %1)
  %10 = icmp sgt i32 %9, 1
  br i1 %10, label %.lr.ph, label %._crit_edge

._crit_edge:                                      ; preds = %.lr.ph, %7
  call void @llvm.lifetime.start.p0(i64 24, ptr nonnull %4) #3
  call void @_ZN4Code15allocateHighRegEj(ptr dead_on_unwind nonnull writable sret(%class.Reg) align 8 %4, ptr noundef nonnull align 8 dereferenceable(200) %0, i32 noundef 1)
  %11 = icmp ult i32 %2, 256
  br i1 %11, label %19, label %16

.lr.ph:                                           ; preds = %7, %.lr.ph
  %.026 = phi i32 [ %13, %.lr.ph ], [ 1, %7 ]
  %12 = tail call noundef zeroext i8 @_ZNK3Reg3regEi(ptr noundef nonnull align 8 dereferenceable(24) %1, i32 noundef %.026)
  tail call void @_ZN4Code6oneregEN4Insn4TypeEh(ptr noundef nonnull align 8 dereferenceable(200) %0, i32 noundef 46, i8 noundef zeroext %12)
  %13 = add nuw nsw i32 %.026, 1
  %14 = tail call noundef i32 @_ZNK3Reg4sizeEv(ptr noundef nonnull align 8 dereferenceable(24) %1)
  %15 = icmp slt i32 %13, %14
  br i1 %15, label %.lr.ph, label %._crit_edge, !llvm.loop !5

16:                                               ; preds = %._crit_edge
  %17 = call noundef i32 @_ZNK3Reg4sizeEv(ptr noundef nonnull align 8 dereferenceable(24) %1)
  %18 = icmp eq i32 %17, 1
  br i1 %18, label %19, label %38

19:                                               ; preds = %16, %._crit_edge
  %20 = invoke noundef zeroext i8 @_ZNK3Reg3regEi(ptr noundef nonnull align 8 dereferenceable(24) %4, i32 noundef 0)
          to label %21 unwind label %36

21:                                               ; preds = %19
  invoke void @_ZN4Code13zeroreg_no_ccEh(ptr noundef nonnull align 8 dereferenceable(200) %0, i8 noundef zeroext %20)
          to label %22 unwind label %36

22:                                               ; preds = %21
  %23 = invoke noundef zeroext i8 @_ZNK3Reg3regEi(ptr noundef nonnull align 8 dereferenceable(24) %4, i32 noundef 0)
          to label %24 unwind label %36

24:                                               ; preds = %22
  %25 = invoke noundef zeroext i8 @_ZNK3Reg3regEi(ptr noundef nonnull align 8 dereferenceable(24) %4, i32 noundef 0)
          to label %26 unwind label %36

26:                                               ; preds = %24
  invoke void @_ZN4Code6tworegEN4Insn4TypeEhh(ptr noundef nonnull align 8 dereferenceable(200) %0, i32 noundef 48, i8 noundef zeroext %23, i8 noundef zeroext %25)
          to label %27 unwind label %36

27:                                               ; preds = %26
  %28 = invoke noundef zeroext i8 @_ZNK3Reg3regEi(ptr noundef nonnull align 8 dereferenceable(24) %4, i32 noundef 0)
          to label %29 unwind label %36

29:                                               ; preds = %27
  %30 = trunc i32 %2 to i8
  invoke void @_ZN4Code6immregEN4Insn4TypeEhh(ptr noundef nonnull align 8 dereferenceable(200) %0, i32 noundef 4, i8 noundef zeroext %28, i8 noundef zeroext %30)
          to label %31 unwind label %36

31:                                               ; preds = %29
  %32 = invoke noundef zeroext i8 @_ZNK3Reg3regEi(ptr noundef nonnull align 8 dereferenceable(24) %1, i32 noundef 0)
          to label %33 unwind label %36

33:                                               ; preds = %31
  %34 = invoke noundef zeroext i8 @_ZNK3Reg3regEi(ptr noundef nonnull align 8 dereferenceable(24) %4, i32 noundef 0)
          to label %35 unwind label %36

35:                                               ; preds = %33
  invoke void @_ZN4Code6tworegEN4Insn4TypeEhh(ptr noundef nonnull align 8 dereferenceable(200) %0, i32 noundef 19, i8 noundef zeroext %32, i8 noundef zeroext %34)
          to label %69 unwind label %36

36:                                               ; preds = %69, %35, %33, %31, %29, %27, %26, %24, %22, %21, %19
  %37 = landingpad { ptr, i32 }
          cleanup
  br label %72

38:                                               ; preds = %16
  %39 = invoke noundef zeroext i8 @_ZN4Code7tempregEv(ptr noundef nonnull align 8 dereferenceable(200) %0)
          to label %40 unwind label %67

40:                                               ; preds = %38
  invoke void @_ZN4Code13zeroreg_no_ccEh(ptr noundef nonnull align 8 dereferenceable(200) %0, i8 noundef zeroext %39)
          to label %41 unwind label %67

41:                                               ; preds = %40
  invoke void @_ZN4Code6tworegEN4Insn4TypeEhh(ptr noundef nonnull align 8 dereferenceable(200) %0, i32 noundef 48, i8 noundef zeroext %39, i8 noundef zeroext %39)
          to label %42 unwind label %67

42:                                               ; preds = %41
  %43 = invoke noundef zeroext i8 @_ZNK3Reg3regEi(ptr noundef nonnull align 8 dereferenceable(24) %4, i32 noundef 0)
          to label %44 unwind label %67

44:                                               ; preds = %42
  %45 = trunc i32 %2 to i8
  invoke void @_ZN4Code6immregEN4Insn4TypeEhh(ptr noundef nonnull align 8 dereferenceable(200) %0, i32 noundef 26, i8 noundef zeroext %43, i8 noundef zeroext %45)
          to label %46 unwind label %67

46:                                               ; preds = %44
  %47 = invoke noundef zeroext i8 @_ZNK3Reg3regEi(ptr noundef nonnull align 8 dereferenceable(24) %4, i32 noundef 0)
          to label %48 unwind label %67

48:                                               ; preds = %46
  invoke void @_ZN4Code6tworegEN4Insn4TypeEhh(ptr noundef nonnull align 8 dereferenceable(200) %0, i32 noundef 3, i8 noundef zeroext %47, i8 noundef zeroext %39)
          to label %49 unwind label %67

49:                                               ; preds = %48
  %50 = invoke noundef zeroext i8 @_ZNK3Reg3regEi(ptr noundef nonnull align 8 dereferenceable(24) %1, i32 noundef 0)
          to label %51 unwind label %67

51:                                               ; preds = %49
  %52 = invoke noundef zeroext i8 @_ZNK3Reg3regEi(ptr noundef nonnull align 8 dereferenceable(24) %4, i32 noundef 0)
          to label %53 unwind label %67

53:                                               ; preds = %51
  invoke void @_ZN4Code6tworegEN4Insn4TypeEhh(ptr noundef nonnull align 8 dereferenceable(200) %0, i32 noundef 19, i8 noundef zeroext %50, i8 noundef zeroext %52)
          to label %54 unwind label %67

54:                                               ; preds = %53
  %55 = invoke noundef zeroext i8 @_ZNK3Reg3regEi(ptr noundef nonnull align 8 dereferenceable(24) %4, i32 noundef 0)
          to label %56 unwind label %67

56:                                               ; preds = %54
  %57 = lshr i32 %2, 8
  %58 = trunc i32 %57 to i8
  invoke void @_ZN4Code6immregEN4Insn4TypeEhh(ptr noundef nonnull align 8 dereferenceable(200) %0, i32 noundef 26, i8 noundef zeroext %55, i8 noundef zeroext %58)
          to label %59 unwind label %67

59:                                               ; preds = %56
  %60 = invoke noundef zeroext i8 @_ZNK3Reg3regEi(ptr noundef nonnull align 8 dereferenceable(24) %4, i32 noundef 0)
          to label %61 unwind label %67

61:                                               ; preds = %59
  invoke void @_ZN4Code6tworegEN4Insn4TypeEhh(ptr noundef nonnull align 8 dereferenceable(200) %0, i32 noundef 3, i8 noundef zeroext %60, i8 noundef zeroext %39)
          to label %62 unwind label %67

62:                                               ; preds = %61
  %63 = invoke noundef zeroext i8 @_ZNK3Reg3regEi(ptr noundef nonnull align 8 dereferenceable(24) %1, i32 noundef 1)
          to label %64 unwind label %67

64:                                               ; preds = %62
  %65 = invoke noundef zeroext i8 @_ZNK3Reg3regEi(ptr noundef nonnull align 8 dereferenceable(24) %4, i32 noundef 0)
          to label %66 unwind label %67

66:                                               ; preds = %64
  invoke void @_ZN4Code6tworegEN4Insn4TypeEhh(ptr noundef nonnull align 8 dereferenceable(200) %0, i32 noundef 19, i8 noundef zeroext %63, i8 noundef zeroext %65)
          to label %69 unwind label %67

67:                                               ; preds = %66, %64, %62, %61, %59, %56, %54, %53, %51, %49, %48, %46, %44, %42, %41, %40, %38
  %68 = landingpad { ptr, i32 }
          cleanup
  br label %72

69:                                               ; preds = %66, %35
  invoke void @_ZN4Code10releaseRegERK3Reg(ptr noundef nonnull align 8 dereferenceable(200) %0, ptr noundef nonnull align 8 dereferenceable(24) %4)
          to label %70 unwind label %36

70:                                               ; preds = %69
  call void @_ZN3RegD2Ev(ptr noundef nonnull align 8 dereferenceable(24) %4) #3
  call void @llvm.lifetime.end.p0(i64 24, ptr nonnull %4) #3
  br label %71

71:                                               ; preds = %3, %70
  ret void

72:                                               ; preds = %67, %36
  %.pn = phi { ptr, i32 } [ %37, %36 ], [ %68, %67 ]
  call void @_ZN3RegD2Ev(ptr noundef nonnull align 8 dereferenceable(24) %4) #3
  call void @llvm.lifetime.end.p0(i64 24, ptr nonnull %4) #3
  resume { ptr, i32 } %.pn
}

attributes #0 = { mustprogress nounwind uwtable "min-legal-vector-width"="0" "no-trapping-math"="true" "stack-protector-buffer-size"="8" "target-cpu"="x86-64" "target-features"="+cmov,+cx8,+fxsr,+mmx,+sse,+sse2,+x87" "tune-cpu"="generic" }
attributes #1 = { mustprogress nocallback nofree nosync nounwind willreturn memory(argmem: readwrite) }
attributes #2 = { mustprogress uwtable "min-legal-vector-width"="0" "no-trapping-math"="true" "stack-protector-buffer-size"="8" "target-cpu"="x86-64" "target-features"="+cmov,+cx8,+fxsr,+mmx,+sse,+sse2,+x87" "tune-cpu"="generic" }
attributes #3 = { nounwind }

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

!0 = !{i32 1, !"wchar_size", i32 4}
!1 = !{i32 8, !"PIC Level", i32 2}
!2 = !{i32 7, !"PIE Level", i32 2}
!3 = !{i32 7, !"uwtable", i32 2}
!4 = !{!"clang version 19.1.0 (git@github.com:llvm/llvm-project.git a4bf6cd7cfb1a1421ba92bca9d017b49936c55e4)"}
!5 = distinct !{!5, !6}
!6 = !{!"llvm.loop.mustprogress"}


; Effective O3 passes: GlobalOptPass,InferFunctionAttrsPass,InstCombinePass,JumpThreadingPass,LoopRotatePass,LoopSimplifyPass,LoopUnrollPass,SROAPass,SimplifyCFGPass,TailCallElimPass