; LLVM IR from rcliftonharvey/dspfilters4juce :: DSPFilters4JUCEDemo/JuceLibraryCode/juce_cryptography.ll (ZN4juce8BlowFishC2EPKvi)

; 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.juce::BlowFish" = type { [18 x i32], [4 x %"class.juce::HeapBlock"] }
%"class.juce::HeapBlock" = type { ptr }

@_ZZN4juce8BlowFishC1EPKviE14initialPValues = external hidden constant [18 x i32], align 16
@_ZZN4juce8BlowFishC1EPKviE14initialSValues = external hidden constant [1024 x i32], align 16

; Function Attrs: mustprogress uwtable
define dso_local void @_ZN4juce8BlowFishC2EPKvi(ptr noundef nonnull align 8 dereferenceable(104) %0, ptr noundef %1, i32 noundef %2) unnamed_addr #0 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 i32, align 4
  %9 = alloca ptr, align 8
  %10 = alloca i32, align 4
  %11 = alloca i32, align 4
  %12 = alloca i32, align 4
  %13 = alloca i32, align 4
  %14 = alloca i32, align 4
  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
  %15 = load ptr, ptr %4, align 8
  %16 = getelementptr inbounds %"class.juce::BlowFish", ptr %15, i32 0, i32 1
  %17 = getelementptr inbounds [4 x %"class.juce::HeapBlock"], ptr %16, i32 0, i32 0
  %18 = getelementptr inbounds %"class.juce::HeapBlock", ptr %17, i64 4
  br label %19

19:                                               ; preds = %19, %3
  %20 = phi ptr [ %17, %3 ], [ %21, %19 ]
  call void @_ZN4juce9HeapBlockIjLb0EEC2Ev(ptr noundef nonnull align 8 dereferenceable(8) %20) #5
  %21 = getelementptr inbounds %"class.juce::HeapBlock", ptr %20, i64 1
  %22 = icmp eq ptr %21, %18
  br i1 %22, label %23, label %19

23:                                               ; preds = %19
  br label %24

24:                                               ; preds = %23
  br label %25

25:                                               ; preds = %24
  br label %26

26:                                               ; preds = %25
  br label %27

27:                                               ; preds = %26
  br label %28

28:                                               ; preds = %27
  br label %29

29:                                               ; preds = %28
  %30 = getelementptr inbounds %"class.juce::BlowFish", ptr %15, i32 0, i32 0
  %31 = getelementptr inbounds [18 x i32], ptr %30, i64 0, i64 0
  call void @llvm.memcpy.p0.p0.i64(ptr align 8 %31, ptr align 16 @_ZZN4juce8BlowFishC1EPKviE14initialPValues, i64 72, i1 false)
  call void @llvm.lifetime.start.p0(i64 4, ptr %7) #5
  call void @llvm.lifetime.start.p0(i64 4, ptr %8) #5
  store i32 0, ptr %8, align 4, !tbaa !9
  store i32 4, ptr %7, align 4, !tbaa !9
  br label %32

32:                                               ; preds = %41, %29
  %33 = load i32, ptr %7, align 4, !tbaa !9
  %34 = add nsw i32 %33, -1
  store i32 %34, ptr %7, align 4, !tbaa !9
  %35 = icmp sge i32 %34, 0
  br i1 %35, label %36, label %57

36:                                               ; preds = %32
  %37 = getelementptr inbounds %"class.juce::BlowFish", ptr %15, i32 0, i32 1
  %38 = load i32, ptr %7, align 4, !tbaa !9
  %39 = sext i32 %38 to i64
  %40 = getelementptr inbounds [4 x %"class.juce::HeapBlock"], ptr %37, i64 0, i64 %39
  invoke void @_ZN4juce9HeapBlockIjLb0EE6mallocEmm(ptr noundef nonnull align 8 dereferenceable(8) %40, i64 noundef 256, i64 noundef 4)
          to label %41 unwind label %51

41:                                               ; preds = %36
  %42 = getelementptr inbounds %"class.juce::BlowFish", ptr %15, i32 0, i32 1
  %43 = load i32, ptr %7, align 4, !tbaa !9
  %44 = sext i32 %43 to i64
  %45 = getelementptr inbounds [4 x %"class.juce::HeapBlock"], ptr %42, i64 0, i64 %44
  %46 = call noundef ptr @_ZNK4juce9HeapBlockIjLb0EEcvPvEv(ptr noundef nonnull align 8 dereferenceable(8) %45) #5
  %47 = load i32, ptr %7, align 4, !tbaa !9
  %48 = mul nsw i32 %47, 256
  %49 = sext i32 %48 to i64
  %50 = getelementptr inbounds i32, ptr @_ZZN4juce8BlowFishC1EPKviE14initialSValues, i64 %49
  call void @llvm.memcpy.p0.p0.i64(ptr align 1 %46, ptr align 4 %50, i64 1024, i1 false)
  br label %32, !llvm.loop !11

51:                                               ; preds = %36
  %52 = landingpad { ptr, i32 }
          cleanup
  %53 = extractvalue { ptr, i32 } %52, 0
  store ptr %53, ptr %9, align 8
  %54 = extractvalue { ptr, i32 } %52, 1
  store i32 %54, ptr %10, align 4
  call void @llvm.lifetime.end.p0(i64 4, ptr %8) #5
  call void @llvm.lifetime.end.p0(i64 4, ptr %7) #5
  %55 = getelementptr inbounds [4 x %"class.juce::HeapBlock"], ptr %16, i32 0, i32 0
  %56 = getelementptr inbounds %"class.juce::HeapBlock", ptr %55, i64 4
  br label %150

57:                                               ; preds = %32
  store i32 0, ptr %7, align 4, !tbaa !9
  br label %58

58:                                               ; preds = %96, %57
  %59 = load i32, ptr %7, align 4, !tbaa !9
  %60 = icmp slt i32 %59, 18
  br i1 %60, label %61, label %99

61:                                               ; preds = %58
  call void @llvm.lifetime.start.p0(i64 4, ptr %11) #5
  store i32 0, ptr %11, align 4, !tbaa !9
  call void @llvm.lifetime.start.p0(i64 4, ptr %12) #5
  store i32 0, ptr %12, align 4, !tbaa !9
  br label %62

62:                                               ; preds = %82, %61
  %63 = load i32, ptr %12, align 4, !tbaa !9
  %64 = icmp slt i32 %63, 4
  br i1 %64, label %66, label %65

65:                                               ; preds = %62
  call void @llvm.lifetime.end.p0(i64 4, ptr %12) #5
  br label %85

66:                                               ; preds = %62
  %67 = load i32, ptr %11, align 4, !tbaa !9
  %68 = shl i32 %67, 8
  %69 = load ptr, ptr %5, align 8, !tbaa !5
  %70 = load i32, ptr %8, align 4, !tbaa !9
  %71 = sext i32 %70 to i64
  %72 = getelementptr inbounds i8, ptr %69, i64 %71
  %73 = load i8, ptr %72, align 1, !tbaa !13
  %74 = zext i8 %73 to i32
  %75 = or i32 %68, %74
  store i32 %75, ptr %11, align 4, !tbaa !9
  %76 = load i32, ptr %8, align 4, !tbaa !9
  %77 = add nsw i32 %76, 1
  store i32 %77, ptr %8, align 4, !tbaa !9
  %78 = load i32, ptr %6, align 4, !tbaa !9
  %79 = icmp sge i32 %77, %78
  br i1 %79, label %80, label %81

80:                                               ; preds = %66
  store i32 0, ptr %8, align 4, !tbaa !9
  br label %81

81:                                               ; preds = %80, %66
  br label %82

82:                                               ; preds = %81
  %83 = load i32, ptr %12, align 4, !tbaa !9
  %84 = add nsw i32 %83, 1
  store i32 %84, ptr %12, align 4, !tbaa !9
  br label %62, !llvm.loop !14

85:                                               ; preds = %65
  %86 = load i32, ptr %7, align 4, !tbaa !9
  %87 = sext i32 %86 to i64
  %88 = getelementptr inbounds [18 x i32], ptr @_ZZN4juce8BlowFishC1EPKviE14initialPValues, i64 0, i64 %87
  %89 = load i32, ptr %88, align 4, !tbaa !9
  %90 = load i32, ptr %11, align 4, !tbaa !9
  %91 = xor i32 %89, %90
  %92 = getelementptr inbounds %"class.juce::BlowFish", ptr %15, i32 0, i32 0
  %93 = load i32, ptr %7, align 4, !tbaa !9
  %94 = sext i32 %93 to i64
  %95 = getelementptr inbounds [18 x i32], ptr %92, i64 0, i64 %94
  store i32 %91, ptr %95, align 4, !tbaa !9
  call void @llvm.lifetime.end.p0(i64 4, ptr %11) #5
  br label %96

96:                                               ; preds = %85
  %97 = load i32, ptr %7, align 4, !tbaa !9
  %98 = add nsw i32 %97, 1
  store i32 %98, ptr %7, align 4, !tbaa !9
  br label %58, !llvm.loop !15

99:                                               ; preds = %58
  call void @llvm.lifetime.start.p0(i64 4, ptr %13) #5
  store i32 0, ptr %13, align 4, !tbaa !9
  call void @llvm.lifetime.start.p0(i64 4, ptr %14) #5
  store i32 0, ptr %14, align 4, !tbaa !9
  store i32 0, ptr %7, align 4, !tbaa !9
  br label %100

100:                                              ; preds = %115, %99
  %101 = load i32, ptr %7, align 4, !tbaa !9
  %102 = icmp slt i32 %101, 18
  br i1 %102, label %103, label %118

103:                                              ; preds = %100
  call void @_ZNK4juce8BlowFish7encryptERjS1_(ptr noundef nonnull align 8 dereferenceable(104) %15, ptr noundef nonnull align 4 dereferenceable(4) %13, ptr noundef nonnull align 4 dereferenceable(4) %14) #5
  %104 = load i32, ptr %13, align 4, !tbaa !9
  %105 = getelementptr inbounds %"class.juce::BlowFish", ptr %15, i32 0, i32 0
  %106 = load i32, ptr %7, align 4, !tbaa !9
  %107 = sext i32 %106 to i64
  %108 = getelementptr inbounds [18 x i32], ptr %105, i64 0, i64 %107
  store i32 %104, ptr %108, align 4, !tbaa !9
  %109 = load i32, ptr %14, align 4, !tbaa !9
  %110 = getelementptr inbounds %"class.juce::BlowFish", ptr %15, i32 0, i32 0
  %111 = load i32, ptr %7, align 4, !tbaa !9
  %112 = add nsw i32 %111, 1
  %113 = sext i32 %112 to i64
  %114 = getelementptr inbounds [18 x i32], ptr %110, i64 0, i64 %113
  store i32 %109, ptr %114, align 4, !tbaa !9
  br label %115

115:                                              ; preds = %103
  %116 = load i32, ptr %7, align 4, !tbaa !9
  %117 = add nsw i32 %116, 2
  store i32 %117, ptr %7, align 4, !tbaa !9
  br label %100, !llvm.loop !16

118:                                              ; preds = %100
  store i32 0, ptr %7, align 4, !tbaa !9
  br label %119

119:                                              ; preds = %146, %118
  %120 = load i32, ptr %7, align 4, !tbaa !9
  %121 = icmp slt i32 %120, 4
  br i1 %121, label %122, label %149

122:                                              ; preds = %119
  store i32 0, ptr %8, align 4, !tbaa !9
  br label %123

123:                                              ; preds = %142, %122
  %124 = load i32, ptr %8, align 4, !tbaa !9
  %125 = icmp slt i32 %124, 256
  br i1 %125, label %126, label %145

126:                                              ; preds = %123
  call void @_ZNK4juce8BlowFish7encryptERjS1_(ptr noundef nonnull align 8 dereferenceable(104) %15, ptr noundef nonnull align 4 dereferenceable(4) %13, ptr noundef nonnull align 4 dereferenceable(4) %14) #5
  %127 = load i32, ptr %13, align 4, !tbaa !9
  %128 = getelementptr inbounds %"class.juce::BlowFish", ptr %15, i32 0, i32 1
  %129 = load i32, ptr %7, align 4, !tbaa !9
  %130 = sext i32 %129 to i64
  %131 = getelementptr inbounds [4 x %"class.juce::HeapBlock"], ptr %128, i64 0, i64 %130
  %132 = load i32, ptr %8, align 4, !tbaa !9
  %133 = call noundef nonnull align 4 dereferenceable(4) ptr @_ZNK4juce9HeapBlockIjLb0EEixIiEERjT_(ptr noundef nonnull align 8 dereferenceable(8) %131, i32 noundef %132) #5
  store i32 %127, ptr %133, align 4, !tbaa !9
  %134 = load i32, ptr %14, align 4, !tbaa !9
  %135 = getelementptr inbounds %"class.juce::BlowFish", ptr %15, i32 0, i32 1
  %136 = load i32, ptr %7, align 4, !tbaa !9
  %137 = sext i32 %136 to i64
  %138 = getelementptr inbounds [4 x %"class.juce::HeapBlock"], ptr %135, i64 0, i64 %137
  %139 = load i32, ptr %8, align 4, !tbaa !9
  %140 = add nsw i32 %139, 1
  %141 = call noundef nonnull align 4 dereferenceable(4) ptr @_ZNK4juce9HeapBlockIjLb0EEixIiEERjT_(ptr noundef nonnull align 8 dereferenceable(8) %138, i32 noundef %140) #5
  store i32 %134, ptr %141, align 4, !tbaa !9
  br label %142

142:                                              ; preds = %126
  %143 = load i32, ptr %8, align 4, !tbaa !9
  %144 = add nsw i32 %143, 2
  store i32 %144, ptr %8, align 4, !tbaa !9
  br label %123, !llvm.loop !17

145:                                              ; preds = %123
  br label %146

146:                                              ; preds = %145
  %147 = load i32, ptr %7, align 4, !tbaa !9
  %148 = add nsw i32 %147, 1
  store i32 %148, ptr %7, align 4, !tbaa !9
  br label %119, !llvm.loop !18

149:                                              ; preds = %119
  call void @llvm.lifetime.end.p0(i64 4, ptr %14) #5
  call void @llvm.lifetime.end.p0(i64 4, ptr %13) #5
  call void @llvm.lifetime.end.p0(i64 4, ptr %8) #5
  call void @llvm.lifetime.end.p0(i64 4, ptr %7) #5
  ret void

150:                                              ; preds = %150, %51
  %151 = phi ptr [ %56, %51 ], [ %152, %150 ]
  %152 = getelementptr inbounds %"class.juce::HeapBlock", ptr %151, i64 -1
  call void @_ZN4juce9HeapBlockIjLb0EED2Ev(ptr noundef nonnull align 8 dereferenceable(8) %152) #5
  %153 = icmp eq ptr %152, %55
  br i1 %153, label %154, label %150

154:                                              ; preds = %150
  br label %155

155:                                              ; preds = %154
  %156 = load ptr, ptr %9, align 8
  %157 = load i32, ptr %10, align 4
  %158 = insertvalue { ptr, i32 } poison, ptr %156, 0
  %159 = insertvalue { ptr, i32 } %158, i32 %157, 1
  resume { ptr, i32 } %159
}

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

; Function Attrs: nocallback nofree nounwind willreturn memory(argmem: readwrite)
declare void @llvm.memcpy.p0.p0.i64(ptr noalias nocapture writeonly, ptr noalias nocapture readonly, i64, i1 immarg) #2

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

; Function Attrs: mustprogress uwtable
declare dso_local void @_ZN4juce9HeapBlockIjLb0EE6mallocEmm(ptr noundef nonnull align 8 dereferenceable(8), i64 noundef, i64 noundef) #0 align 2

declare i32 @__gxx_personality_v0(...)

; Function Attrs: inlinehint mustprogress nounwind uwtable
declare dso_local noundef ptr @_ZNK4juce9HeapBlockIjLb0EEcvPvEv(ptr noundef nonnull align 8 dereferenceable(8)) #4 align 2

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

; Function Attrs: mustprogress nounwind uwtable
declare dso_local void @_ZNK4juce8BlowFish7encryptERjS1_(ptr noundef nonnull align 8 dereferenceable(104), ptr noundef nonnull align 4 dereferenceable(4), ptr noundef nonnull align 4 dereferenceable(4)) #1 align 2

; Function Attrs: inlinehint mustprogress nounwind uwtable
declare dso_local noundef nonnull align 4 dereferenceable(4) ptr @_ZNK4juce9HeapBlockIjLb0EEixIiEERjT_(ptr noundef nonnull align 8 dereferenceable(8), i32 noundef) #4 align 2

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

attributes #0 = { 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 #1 = { 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 #2 = { nocallback nofree nounwind willreturn memory(argmem: readwrite) }
attributes #3 = { nocallback nofree nosync nounwind willreturn memory(argmem: readwrite) }
attributes #4 = { inlinehint 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 #5 = { 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}
!14 = distinct !{!14, !12}
!15 = distinct !{!15, !12}
!16 = distinct !{!16, !12}
!17 = distinct !{!17, !12}
!18 = distinct !{!18, !12}


; 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"

@_ZZN4juce8BlowFishC1EPKviE14initialPValues = external hidden local_unnamed_addr constant [18 x i32], align 16
@_ZZN4juce8BlowFishC1EPKviE14initialSValues = external hidden local_unnamed_addr constant [1024 x i32], align 16

; Function Attrs: mustprogress uwtable
define dso_local void @_ZN4juce8BlowFishC2EPKvi(ptr noundef nonnull align 8 dereferenceable(104) %0, ptr nocapture noundef readonly %1, i32 noundef %2) unnamed_addr #0 align 2 personality ptr @__gxx_personality_v0 {
  %4 = alloca i32, align 4
  %5 = alloca i32, align 4
  %.ptr = getelementptr inbounds i8, ptr %0, i64 72
  tail call void @_ZN4juce9HeapBlockIjLb0EEC2Ev(ptr noundef nonnull align 8 dereferenceable(8) %.ptr) #5
  %.ptr.1 = getelementptr inbounds i8, ptr %0, i64 80
  tail call void @_ZN4juce9HeapBlockIjLb0EEC2Ev(ptr noundef nonnull align 8 dereferenceable(8) %.ptr.1) #5
  %.ptr.2 = getelementptr inbounds i8, ptr %0, i64 88
  tail call void @_ZN4juce9HeapBlockIjLb0EEC2Ev(ptr noundef nonnull align 8 dereferenceable(8) %.ptr.2) #5
  %.ptr.3 = getelementptr inbounds i8, ptr %0, i64 96
  tail call void @_ZN4juce9HeapBlockIjLb0EEC2Ev(ptr noundef nonnull align 8 dereferenceable(8) %.ptr.3) #5
  tail call void @llvm.memcpy.p0.p0.i64(ptr noundef nonnull align 8 dereferenceable(72) %0, ptr noundef nonnull align 16 dereferenceable(72) @_ZZN4juce8BlowFishC1EPKviE14initialPValues, i64 72, i1 false)
  %6 = getelementptr inbounds i8, ptr %0, i64 96
  invoke void @_ZN4juce9HeapBlockIjLb0EE6mallocEmm(ptr noundef nonnull align 8 dereferenceable(8) %6, i64 noundef 256, i64 noundef 4)
          to label %7 unwind label %16

7:                                                ; preds = %3
  %8 = tail call noundef ptr @_ZNK4juce9HeapBlockIjLb0EEcvPvEv(ptr noundef nonnull align 8 dereferenceable(8) %6) #5
  tail call void @llvm.memcpy.p0.p0.i64(ptr noundef nonnull align 1 dereferenceable(1024) %8, ptr noundef nonnull align 16 dereferenceable(1024) getelementptr inbounds (i8, ptr @_ZZN4juce8BlowFishC1EPKviE14initialSValues, i64 3072), i64 1024, i1 false)
  %9 = getelementptr inbounds i8, ptr %0, i64 88
  invoke void @_ZN4juce9HeapBlockIjLb0EE6mallocEmm(ptr noundef nonnull align 8 dereferenceable(8) %9, i64 noundef 256, i64 noundef 4)
          to label %10 unwind label %16

10:                                               ; preds = %7
  %11 = tail call noundef ptr @_ZNK4juce9HeapBlockIjLb0EEcvPvEv(ptr noundef nonnull align 8 dereferenceable(8) %9) #5
  tail call void @llvm.memcpy.p0.p0.i64(ptr noundef nonnull align 1 dereferenceable(1024) %11, ptr noundef nonnull align 16 dereferenceable(1024) getelementptr inbounds (i8, ptr @_ZZN4juce8BlowFishC1EPKviE14initialSValues, i64 2048), i64 1024, i1 false)
  %12 = getelementptr inbounds i8, ptr %0, i64 80
  invoke void @_ZN4juce9HeapBlockIjLb0EE6mallocEmm(ptr noundef nonnull align 8 dereferenceable(8) %12, i64 noundef 256, i64 noundef 4)
          to label %13 unwind label %16

13:                                               ; preds = %10
  %14 = tail call noundef ptr @_ZNK4juce9HeapBlockIjLb0EEcvPvEv(ptr noundef nonnull align 8 dereferenceable(8) %12) #5
  tail call void @llvm.memcpy.p0.p0.i64(ptr noundef nonnull align 1 dereferenceable(1024) %14, ptr noundef nonnull align 16 dereferenceable(1024) getelementptr inbounds (i8, ptr @_ZZN4juce8BlowFishC1EPKviE14initialSValues, i64 1024), i64 1024, i1 false)
  invoke void @_ZN4juce9HeapBlockIjLb0EE6mallocEmm(ptr noundef nonnull align 8 dereferenceable(8) %.ptr, i64 noundef 256, i64 noundef 4)
          to label %.preheader45.preheader unwind label %16

.preheader45.preheader:                           ; preds = %13
  %15 = tail call noundef ptr @_ZNK4juce9HeapBlockIjLb0EEcvPvEv(ptr noundef nonnull align 8 dereferenceable(8) %.ptr) #5
  tail call void @llvm.memcpy.p0.p0.i64(ptr noundef nonnull align 1 dereferenceable(1024) %15, ptr noundef nonnull align 16 dereferenceable(1024) @_ZZN4juce8BlowFishC1EPKviE14initialSValues, i64 1024, i1 false)
  br label %.preheader45

16:                                               ; preds = %13, %10, %7, %3
  %17 = landingpad { ptr, i32 }
          cleanup
  tail call void @_ZN4juce9HeapBlockIjLb0EED2Ev(ptr noundef nonnull align 8 dereferenceable(8) %.ptr.3) #5
  tail call void @_ZN4juce9HeapBlockIjLb0EED2Ev(ptr noundef nonnull align 8 dereferenceable(8) %.ptr.2) #5
  tail call void @_ZN4juce9HeapBlockIjLb0EED2Ev(ptr noundef nonnull align 8 dereferenceable(8) %.ptr.1) #5
  tail call void @_ZN4juce9HeapBlockIjLb0EED2Ev(ptr noundef nonnull align 8 dereferenceable(8) %.ptr) #5
  resume { ptr, i32 } %17

.preheader45:                                     ; preds = %.preheader45.preheader, %.preheader45
  %indvars.iv = phi i64 [ 0, %.preheader45.preheader ], [ %indvars.iv.next, %.preheader45 ]
  %.03250 = phi i32 [ 0, %.preheader45.preheader ], [ %spec.store.select.3, %.preheader45 ]
  %18 = sext i32 %.03250 to i64
  %19 = getelementptr inbounds i8, ptr %1, i64 %18
  %20 = load i8, ptr %19, align 1, !tbaa !5
  %21 = zext i8 %20 to i32
  %22 = add nsw i32 %.03250, 1
  %.not = icmp slt i32 %22, %2
  %spec.store.select = select i1 %.not, i32 %22, i32 0
  %23 = sext i32 %spec.store.select to i64
  %24 = getelementptr inbounds i8, ptr %1, i64 %23
  %25 = load i8, ptr %24, align 1, !tbaa !5
  %26 = zext i8 %25 to i32
  %27 = add nsw i32 %spec.store.select, 1
  %.not.1 = icmp slt i32 %27, %2
  %spec.store.select.1 = select i1 %.not.1, i32 %27, i32 0
  %28 = shl nuw nsw i32 %21, 16
  %29 = shl nuw nsw i32 %26, 8
  %30 = or disjoint i32 %28, %29
  %31 = sext i32 %spec.store.select.1 to i64
  %32 = getelementptr inbounds i8, ptr %1, i64 %31
  %33 = load i8, ptr %32, align 1, !tbaa !5
  %34 = zext i8 %33 to i32
  %35 = or disjoint i32 %30, %34
  %36 = add nsw i32 %spec.store.select.1, 1
  %.not.2 = icmp slt i32 %36, %2
  %spec.store.select.2 = select i1 %.not.2, i32 %36, i32 0
  %37 = shl nuw i32 %35, 8
  %38 = sext i32 %spec.store.select.2 to i64
  %39 = getelementptr inbounds i8, ptr %1, i64 %38
  %40 = load i8, ptr %39, align 1, !tbaa !5
  %41 = zext i8 %40 to i32
  %42 = or disjoint i32 %37, %41
  %43 = add nsw i32 %spec.store.select.2, 1
  %.not.3 = icmp slt i32 %43, %2
  %spec.store.select.3 = select i1 %.not.3, i32 %43, i32 0
  %44 = getelementptr inbounds [18 x i32], ptr @_ZZN4juce8BlowFishC1EPKviE14initialPValues, i64 0, i64 %indvars.iv
  %45 = load i32, ptr %44, align 4, !tbaa !8
  %46 = xor i32 %45, %42
  %47 = getelementptr inbounds [18 x i32], ptr %0, i64 0, i64 %indvars.iv
  store i32 %46, ptr %47, align 4, !tbaa !8
  %indvars.iv.next = add nuw nsw i64 %indvars.iv, 1
  %exitcond.not = icmp eq i64 %indvars.iv.next, 18
  br i1 %exitcond.not, label %.preheader.preheader, label %.preheader45, !llvm.loop !10

.preheader.preheader:                             ; preds = %.preheader45
  call void @llvm.lifetime.start.p0(i64 4, ptr nonnull %4) #5
  store i32 0, ptr %4, align 4, !tbaa !8
  call void @llvm.lifetime.start.p0(i64 4, ptr nonnull %5) #5
  store i32 0, ptr %5, align 4, !tbaa !8
  call void @_ZNK4juce8BlowFish7encryptERjS1_(ptr noundef nonnull align 8 dereferenceable(104) %0, ptr noundef nonnull align 4 dereferenceable(4) %4, ptr noundef nonnull align 4 dereferenceable(4) %5) #5
  %48 = load i32, ptr %4, align 4, !tbaa !8
  store i32 %48, ptr %0, align 8, !tbaa !8
  %49 = load i32, ptr %5, align 4, !tbaa !8
  %50 = getelementptr inbounds i8, ptr %0, i64 4
  store i32 %49, ptr %50, align 4, !tbaa !8
  call void @_ZNK4juce8BlowFish7encryptERjS1_(ptr noundef nonnull align 8 dereferenceable(104) %0, ptr noundef nonnull align 4 dereferenceable(4) %4, ptr noundef nonnull align 4 dereferenceable(4) %5) #5
  %51 = load i32, ptr %4, align 4, !tbaa !8
  %52 = getelementptr inbounds i8, ptr %0, i64 8
  store i32 %51, ptr %52, align 8, !tbaa !8
  %53 = load i32, ptr %5, align 4, !tbaa !8
  %54 = getelementptr inbounds i8, ptr %0, i64 12
  store i32 %53, ptr %54, align 4, !tbaa !8
  call void @_ZNK4juce8BlowFish7encryptERjS1_(ptr noundef nonnull align 8 dereferenceable(104) %0, ptr noundef nonnull align 4 dereferenceable(4) %4, ptr noundef nonnull align 4 dereferenceable(4) %5) #5
  %55 = load i32, ptr %4, align 4, !tbaa !8
  %56 = getelementptr inbounds i8, ptr %0, i64 16
  store i32 %55, ptr %56, align 8, !tbaa !8
  %57 = load i32, ptr %5, align 4, !tbaa !8
  %58 = getelementptr inbounds i8, ptr %0, i64 20
  store i32 %57, ptr %58, align 4, !tbaa !8
  call void @_ZNK4juce8BlowFish7encryptERjS1_(ptr noundef nonnull align 8 dereferenceable(104) %0, ptr noundef nonnull align 4 dereferenceable(4) %4, ptr noundef nonnull align 4 dereferenceable(4) %5) #5
  %59 = load i32, ptr %4, align 4, !tbaa !8
  %60 = getelementptr inbounds i8, ptr %0, i64 24
  store i32 %59, ptr %60, align 8, !tbaa !8
  %61 = load i32, ptr %5, align 4, !tbaa !8
  %62 = getelementptr inbounds i8, ptr %0, i64 28
  store i32 %61, ptr %62, align 4, !tbaa !8
  call void @_ZNK4juce8BlowFish7encryptERjS1_(ptr noundef nonnull align 8 dereferenceable(104) %0, ptr noundef nonnull align 4 dereferenceable(4) %4, ptr noundef nonnull align 4 dereferenceable(4) %5) #5
  %63 = load i32, ptr %4, align 4, !tbaa !8
  %64 = getelementptr inbounds i8, ptr %0, i64 32
  store i32 %63, ptr %64, align 8, !tbaa !8
  %65 = load i32, ptr %5, align 4, !tbaa !8
  %66 = getelementptr inbounds i8, ptr %0, i64 36
  store i32 %65, ptr %66, align 4, !tbaa !8
  call void @_ZNK4juce8BlowFish7encryptERjS1_(ptr noundef nonnull align 8 dereferenceable(104) %0, ptr noundef nonnull align 4 dereferenceable(4) %4, ptr noundef nonnull align 4 dereferenceable(4) %5) #5
  %67 = load i32, ptr %4, align 4, !tbaa !8
  %68 = getelementptr inbounds i8, ptr %0, i64 40
  store i32 %67, ptr %68, align 8, !tbaa !8
  %69 = load i32, ptr %5, align 4, !tbaa !8
  %70 = getelementptr inbounds i8, ptr %0, i64 44
  store i32 %69, ptr %70, align 4, !tbaa !8
  call void @_ZNK4juce8BlowFish7encryptERjS1_(ptr noundef nonnull align 8 dereferenceable(104) %0, ptr noundef nonnull align 4 dereferenceable(4) %4, ptr noundef nonnull align 4 dereferenceable(4) %5) #5
  %71 = load i32, ptr %4, align 4, !tbaa !8
  %72 = getelementptr inbounds i8, ptr %0, i64 48
  store i32 %71, ptr %72, align 8, !tbaa !8
  %73 = load i32, ptr %5, align 4, !tbaa !8
  %74 = getelementptr inbounds i8, ptr %0, i64 52
  store i32 %73, ptr %74, align 4, !tbaa !8
  call void @_ZNK4juce8BlowFish7encryptERjS1_(ptr noundef nonnull align 8 dereferenceable(104) %0, ptr noundef nonnull align 4 dereferenceable(4) %4, ptr noundef nonnull align 4 dereferenceable(4) %5) #5
  %75 = load i32, ptr %4, align 4, !tbaa !8
  %76 = getelementptr inbounds i8, ptr %0, i64 56
  store i32 %75, ptr %76, align 8, !tbaa !8
  %77 = load i32, ptr %5, align 4, !tbaa !8
  %78 = getelementptr inbounds i8, ptr %0, i64 60
  store i32 %77, ptr %78, align 4, !tbaa !8
  call void @_ZNK4juce8BlowFish7encryptERjS1_(ptr noundef nonnull align 8 dereferenceable(104) %0, ptr noundef nonnull align 4 dereferenceable(4) %4, ptr noundef nonnull align 4 dereferenceable(4) %5) #5
  %79 = load i32, ptr %4, align 4, !tbaa !8
  %80 = getelementptr inbounds i8, ptr %0, i64 64
  store i32 %79, ptr %80, align 8, !tbaa !8
  %81 = load i32, ptr %5, align 4, !tbaa !8
  %82 = getelementptr inbounds i8, ptr %0, i64 68
  store i32 %81, ptr %82, align 4, !tbaa !8
  br label %83

83:                                               ; preds = %.preheader.preheader, %83
  %.23453 = phi i32 [ 0, %.preheader.preheader ], [ %89, %83 ]
  call void @_ZNK4juce8BlowFish7encryptERjS1_(ptr noundef nonnull align 8 dereferenceable(104) %0, ptr noundef nonnull align 4 dereferenceable(4) %4, ptr noundef nonnull align 4 dereferenceable(4) %5) #5
  %84 = load i32, ptr %4, align 4, !tbaa !8
  %85 = call noundef nonnull align 4 dereferenceable(4) ptr @_ZNK4juce9HeapBlockIjLb0EEixIiEERjT_(ptr noundef nonnull align 8 dereferenceable(8) %.ptr, i32 noundef %.23453) #5
  store i32 %84, ptr %85, align 4, !tbaa !8
  %86 = load i32, ptr %5, align 4, !tbaa !8
  %87 = or disjoint i32 %.23453, 1
  %88 = call noundef nonnull align 4 dereferenceable(4) ptr @_ZNK4juce9HeapBlockIjLb0EEixIiEERjT_(ptr noundef nonnull align 8 dereferenceable(8) %.ptr, i32 noundef %87) #5
  store i32 %86, ptr %88, align 4, !tbaa !8
  %89 = add nuw nsw i32 %.23453, 2
  %90 = icmp ult i32 %.23453, 254
  br i1 %90, label %83, label %.preheader.1, !llvm.loop !12

.preheader.1:                                     ; preds = %83, %.preheader.1
  %.23453.1 = phi i32 [ %96, %.preheader.1 ], [ 0, %83 ]
  call void @_ZNK4juce8BlowFish7encryptERjS1_(ptr noundef nonnull align 8 dereferenceable(104) %0, ptr noundef nonnull align 4 dereferenceable(4) %4, ptr noundef nonnull align 4 dereferenceable(4) %5) #5
  %91 = load i32, ptr %4, align 4, !tbaa !8
  %92 = call noundef nonnull align 4 dereferenceable(4) ptr @_ZNK4juce9HeapBlockIjLb0EEixIiEERjT_(ptr noundef nonnull align 8 dereferenceable(8) %12, i32 noundef %.23453.1) #5
  store i32 %91, ptr %92, align 4, !tbaa !8
  %93 = load i32, ptr %5, align 4, !tbaa !8
  %94 = or disjoint i32 %.23453.1, 1
  %95 = call noundef nonnull align 4 dereferenceable(4) ptr @_ZNK4juce9HeapBlockIjLb0EEixIiEERjT_(ptr noundef nonnull align 8 dereferenceable(8) %12, i32 noundef %94) #5
  store i32 %93, ptr %95, align 4, !tbaa !8
  %96 = add nuw nsw i32 %.23453.1, 2
  %97 = icmp ult i32 %.23453.1, 254
  br i1 %97, label %.preheader.1, label %.preheader.2, !llvm.loop !12

.preheader.2:                                     ; preds = %.preheader.1, %.preheader.2
  %.23453.2 = phi i32 [ %103, %.preheader.2 ], [ 0, %.preheader.1 ]
  call void @_ZNK4juce8BlowFish7encryptERjS1_(ptr noundef nonnull align 8 dereferenceable(104) %0, ptr noundef nonnull align 4 dereferenceable(4) %4, ptr noundef nonnull align 4 dereferenceable(4) %5) #5
  %98 = load i32, ptr %4, align 4, !tbaa !8
  %99 = call noundef nonnull align 4 dereferenceable(4) ptr @_ZNK4juce9HeapBlockIjLb0EEixIiEERjT_(ptr noundef nonnull align 8 dereferenceable(8) %9, i32 noundef %.23453.2) #5
  store i32 %98, ptr %99, align 4, !tbaa !8
  %100 = load i32, ptr %5, align 4, !tbaa !8
  %101 = or disjoint i32 %.23453.2, 1
  %102 = call noundef nonnull align 4 dereferenceable(4) ptr @_ZNK4juce9HeapBlockIjLb0EEixIiEERjT_(ptr noundef nonnull align 8 dereferenceable(8) %9, i32 noundef %101) #5
  store i32 %100, ptr %102, align 4, !tbaa !8
  %103 = add nuw nsw i32 %.23453.2, 2
  %104 = icmp ult i32 %.23453.2, 254
  br i1 %104, label %.preheader.2, label %.preheader.3, !llvm.loop !12

.preheader.3:                                     ; preds = %.preheader.2, %.preheader.3
  %.23453.3 = phi i32 [ %110, %.preheader.3 ], [ 0, %.preheader.2 ]
  call void @_ZNK4juce8BlowFish7encryptERjS1_(ptr noundef nonnull align 8 dereferenceable(104) %0, ptr noundef nonnull align 4 dereferenceable(4) %4, ptr noundef nonnull align 4 dereferenceable(4) %5) #5
  %105 = load i32, ptr %4, align 4, !tbaa !8
  %106 = call noundef nonnull align 4 dereferenceable(4) ptr @_ZNK4juce9HeapBlockIjLb0EEixIiEERjT_(ptr noundef nonnull align 8 dereferenceable(8) %6, i32 noundef %.23453.3) #5
  store i32 %105, ptr %106, align 4, !tbaa !8
  %107 = load i32, ptr %5, align 4, !tbaa !8
  %108 = or disjoint i32 %.23453.3, 1
  %109 = call noundef nonnull align 4 dereferenceable(4) ptr @_ZNK4juce9HeapBlockIjLb0EEixIiEERjT_(ptr noundef nonnull align 8 dereferenceable(8) %6, i32 noundef %108) #5
  store i32 %107, ptr %109, align 4, !tbaa !8
  %110 = add nuw nsw i32 %.23453.3, 2
  %111 = icmp ult i32 %.23453.3, 254
  br i1 %111, label %.preheader.3, label %112, !llvm.loop !12

112:                                              ; preds = %.preheader.3
  call void @llvm.lifetime.end.p0(i64 4, ptr nonnull %5) #5
  call void @llvm.lifetime.end.p0(i64 4, ptr nonnull %4) #5
  ret void
}

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

; Function Attrs: mustprogress nocallback nofree nounwind willreturn memory(argmem: readwrite)
declare void @llvm.memcpy.p0.p0.i64(ptr noalias nocapture writeonly, ptr noalias nocapture readonly, i64, i1 immarg) #2

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

; Function Attrs: mustprogress uwtable
declare dso_local void @_ZN4juce9HeapBlockIjLb0EE6mallocEmm(ptr noundef nonnull align 8 dereferenceable(8), i64 noundef, i64 noundef) local_unnamed_addr #0 align 2

declare i32 @__gxx_personality_v0(...)

; Function Attrs: inlinehint mustprogress nounwind uwtable
declare dso_local noundef ptr @_ZNK4juce9HeapBlockIjLb0EEcvPvEv(ptr noundef nonnull align 8 dereferenceable(8)) local_unnamed_addr #4 align 2

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

; Function Attrs: mustprogress nounwind uwtable
declare dso_local void @_ZNK4juce8BlowFish7encryptERjS1_(ptr noundef nonnull align 8 dereferenceable(104), ptr noundef nonnull align 4 dereferenceable(4), ptr noundef nonnull align 4 dereferenceable(4)) local_unnamed_addr #1 align 2

; Function Attrs: inlinehint mustprogress nounwind uwtable
declare dso_local noundef nonnull align 4 dereferenceable(4) ptr @_ZNK4juce9HeapBlockIjLb0EEixIiEERjT_(ptr noundef nonnull align 8 dereferenceable(8), i32 noundef) local_unnamed_addr #4 align 2

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

attributes #0 = { 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 #1 = { 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 #2 = { mustprogress nocallback nofree nounwind willreturn memory(argmem: readwrite) }
attributes #3 = { mustprogress nocallback nofree nosync nounwind willreturn memory(argmem: readwrite) }
attributes #4 = { inlinehint 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 #5 = { 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 = !{!"omnipotent char", !7, i64 0}
!7 = !{!"Simple C++ TBAA"}
!8 = !{!9, !9, i64 0}
!9 = !{!"int", !6, i64 0}
!10 = distinct !{!10, !11}
!11 = !{!"llvm.loop.mustprogress"}
!12 = distinct !{!12, !11}


; Effective O3 passes: EarlyCSEPass,GVNPass,GlobalOptPass,IPSCCPPass,IndVarSimplifyPass,InferAlignmentPass,InferFunctionAttrsPass,InstCombinePass,LCSSAPass,LICMPass,LoopRotatePass,LoopSimplifyPass,LoopUnrollPass,PostOrderFunctionAttrsPass,ReassociatePass,SCCPPass,SROAPass,SimplifyCFGPass,TailCallElimPass