; LLVM IR from INMOST-DEV/INMOST-FEM :: anifem++/fem (tetdofmap)

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

%"struct.Ani::DofT::LocalOrder" = type { i32, i32, i8, i8, i8, i8 }
%"struct.std::pair.4" = type <{ i32, %"struct.Ani::DofT::LocSymOrder", [2 x i8] }>
%"struct.Ani::DofT::LocSymOrder" = type { i8, i8 }
%"struct.Ani::DofT::LocGeomOrder" = type <{ i32, i8, i8, [2 x i8] }>
%"struct.Ani::DofT::TetGeomSparsity::Pos" = type { i8, i8 }
%"struct.Ani::DofT::TetGeomSparsity" = type { %"struct.std::array" }
%"struct.std::array" = type { [4 x i8] }

@.str.2 = external hidden unnamed_addr constant [40 x i8], align 1
@.str.3 = external hidden unnamed_addr constant [82 x i8], align 1
@__PRETTY_FUNCTION__._ZNK3Ani4DofT10BaseDofMap23IncrementByGeomSparsityERKNS0_15TetGeomSparsityERNS0_10LocalOrderEb = external hidden unnamed_addr constant [111 x i8], align 1

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

; 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) #1

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

; Function Attrs: mustprogress nounwind uwtable
declare dso_local void @_ZN3Ani4DofT15TetGeomSparsity3PosC2Ehh(ptr noundef nonnull align 1 dereferenceable(2), i8 noundef zeroext, i8 noundef zeroext) unnamed_addr #2 align 2

; Function Attrs: mustprogress uwtable
declare dso_local i16 @_ZNK3Ani4DofT15TetGeomSparsity7nextPosENS1_3PosE(ptr noundef nonnull align 1 dereferenceable(4), i16) #3 align 2

; Function Attrs: mustprogress nounwind uwtable
declare dso_local noundef zeroext i1 @_ZN3Ani4DofT15TetGeomSparsity3Pos7isValidEv(ptr noundef nonnull align 1 dereferenceable(2)) #2 align 2

; Function Attrs: inlinehint mustprogress uwtable
declare dso_local i64 @_ZNK3Ani4DofT10LocalOrder12getGeomOrderEv(ptr noundef nonnull align 4 dereferenceable(12)) #4 align 2

; Function Attrs: mustprogress uwtable
define dso_local void @_ZNK3Ani4DofT10BaseDofMap23IncrementByGeomSparsityERKNS0_15TetGeomSparsityERNS0_10LocalOrderEb(ptr noundef nonnull align 8 dereferenceable(8) %0, ptr noundef nonnull align 1 dereferenceable(4) %1, ptr noundef nonnull align 4 dereferenceable(12) %2, i1 noundef zeroext %3) unnamed_addr #3 align 2 {
  %5 = alloca ptr, align 8
  %6 = alloca ptr, align 8
  %7 = alloca ptr, align 8
  %8 = alloca i8, align 1
  %9 = alloca %"struct.Ani::DofT::LocalOrder", align 4
  %10 = alloca { i64, i32 }, align 4
  %11 = alloca i32, align 4
  %12 = alloca %"struct.std::pair.4", align 4
  %13 = alloca %"struct.Ani::DofT::LocGeomOrder", align 4
  %14 = alloca i32, align 4
  %15 = alloca %"struct.std::pair.4", align 4
  %16 = alloca %"struct.Ani::DofT::LocGeomOrder", align 4
  %17 = alloca %"struct.std::pair.4", align 4
  %18 = alloca %"struct.Ani::DofT::LocGeomOrder", align 4
  %19 = alloca i32, align 4
  %20 = alloca %"struct.Ani::DofT::TetGeomSparsity::Pos", align 1
  %21 = alloca %"struct.Ani::DofT::TetGeomSparsity::Pos", align 1
  %22 = alloca %"struct.std::pair.4", align 4
  %23 = alloca %"struct.Ani::DofT::LocGeomOrder", align 4
  %24 = alloca %"struct.Ani::DofT::TetGeomSparsity", align 1
  %25 = alloca i32, align 4
  store ptr %0, ptr %5, align 8, !tbaa !5
  store ptr %1, ptr %6, align 8, !tbaa !5
  store ptr %2, ptr %7, align 8, !tbaa !5
  %26 = zext i1 %3 to i8
  store i8 %26, ptr %8, align 1, !tbaa !9
  %27 = load ptr, ptr %5, align 8
  %28 = load ptr, ptr %7, align 8, !tbaa !5
  call void @llvm.memcpy.p0.p0.i64(ptr align 4 %9, ptr align 4 %28, i64 12, i1 false), !tbaa.struct !11
  call void @llvm.memcpy.p0.p0.i64(ptr align 4 %10, ptr align 4 %9, i64 12, i1 false)
  %29 = getelementptr inbounds { i64, i32 }, ptr %10, i32 0, i32 0
  %30 = load i64, ptr %29, align 4
  %31 = getelementptr inbounds { i64, i32 }, ptr %10, i32 0, i32 1
  %32 = load i32, ptr %31, align 4
  %33 = call noundef zeroext i1 @_ZNK3Ani4DofT10BaseDofMap12isValidIndexENS0_10LocalOrderEb(ptr noundef nonnull align 8 dereferenceable(8) %27, i64 %30, i32 %32, i1 noundef zeroext false)
  br i1 %33, label %34, label %35

34:                                               ; preds = %4
  br label %35

35:                                               ; preds = %34, %4
  %36 = phi i1 [ false, %4 ], [ true, %34 ]
  br i1 %36, label %37, label %38

37:                                               ; preds = %35
  br label %40

38:                                               ; preds = %35
  call void @__assert_fail(ptr noundef @.str.2, ptr noundef @.str.3, i32 noundef 196, ptr noundef @__PRETTY_FUNCTION__._ZNK3Ani4DofT10BaseDofMap23IncrementByGeomSparsityERKNS0_15TetGeomSparsityERNS0_10LocalOrderEb) #6
  unreachable

39:                                               ; No predecessors!
  br label %40

40:                                               ; preds = %39, %37
  call void @llvm.lifetime.start.p0(i64 4, ptr %11) #7
  %41 = load ptr, ptr %7, align 8, !tbaa !5
  %42 = getelementptr inbounds %"struct.Ani::DofT::LocalOrder", ptr %41, i32 0, i32 2
  %43 = load i8, ptr %42, align 4, !tbaa !15
  %44 = load ptr, ptr %27, align 8, !tbaa !17
  %45 = getelementptr inbounds ptr, ptr %44, i64 1
  %46 = load ptr, ptr %45, align 8
  %47 = call noundef i32 %46(ptr noundef nonnull align 8 dereferenceable(8) %27, i8 noundef zeroext %43)
  store i32 %47, ptr %11, align 4, !tbaa !12
  %48 = load ptr, ptr %7, align 8, !tbaa !5
  %49 = getelementptr inbounds %"struct.Ani::DofT::LocalOrder", ptr %48, i32 0, i32 1
  %50 = load i32, ptr %49, align 4, !tbaa !19
  %51 = load i32, ptr %11, align 4, !tbaa !12
  %52 = sub i32 %51, 1
  %53 = icmp ult i32 %50, %52
  br i1 %53, label %54, label %82

54:                                               ; preds = %40
  %55 = load ptr, ptr %7, align 8, !tbaa !5
  %56 = getelementptr inbounds %"struct.Ani::DofT::LocalOrder", ptr %55, i32 0, i32 1
  %57 = load i32, ptr %56, align 4, !tbaa !19
  %58 = add i32 %57, 1
  store i32 %58, ptr %56, align 4, !tbaa !19
  call void @llvm.lifetime.start.p0(i64 8, ptr %12) #7
  %59 = load ptr, ptr %7, align 8, !tbaa !5
  %60 = call i64 @_ZNK3Ani4DofT10LocalOrder12getGeomOrderEv(ptr noundef nonnull align 4 dereferenceable(12) %59)
  %61 = trunc i64 %60 to i48
  store i48 %61, ptr %13, align 4
  %62 = load i64, ptr %13, align 4
  %63 = load ptr, ptr %27, align 8, !tbaa !17
  %64 = getelementptr inbounds ptr, ptr %63, i64 10
  %65 = load ptr, ptr %64, align 8
  %66 = call i64 %65(ptr noundef nonnull align 8 dereferenceable(8) %27, i64 %62)
  %67 = trunc i64 %66 to i48
  store i48 %67, ptr %12, align 4
  %68 = getelementptr inbounds %"struct.std::pair.4", ptr %12, i32 0, i32 0
  %69 = load i32, ptr %68, align 4, !tbaa !20
  %70 = load ptr, ptr %7, align 8, !tbaa !5
  %71 = getelementptr inbounds %"struct.Ani::DofT::LocalOrder", ptr %70, i32 0, i32 0
  store i32 %69, ptr %71, align 4, !tbaa !23
  %72 = getelementptr inbounds %"struct.std::pair.4", ptr %12, i32 0, i32 1
  %73 = getelementptr inbounds %"struct.Ani::DofT::LocSymOrder", ptr %72, i32 0, i32 0
  %74 = load i8, ptr %73, align 4, !tbaa !24
  %75 = load ptr, ptr %7, align 8, !tbaa !5
  %76 = getelementptr inbounds %"struct.Ani::DofT::LocalOrder", ptr %75, i32 0, i32 4
  store i8 %74, ptr %76, align 2, !tbaa !25
  %77 = getelementptr inbounds %"struct.std::pair.4", ptr %12, i32 0, i32 1
  %78 = getelementptr inbounds %"struct.Ani::DofT::LocSymOrder", ptr %77, i32 0, i32 1
  %79 = load i8, ptr %78, align 1, !tbaa !26
  %80 = load ptr, ptr %7, align 8, !tbaa !5
  %81 = getelementptr inbounds %"struct.Ani::DofT::LocalOrder", ptr %80, i32 0, i32 5
  store i8 %79, ptr %81, align 1, !tbaa !27
  store i32 1, ptr %14, align 4
  call void @llvm.lifetime.end.p0(i64 8, ptr %12) #7
  br label %272

82:                                               ; preds = %40
  %83 = load ptr, ptr %7, align 8, !tbaa !5
  %84 = getelementptr inbounds %"struct.Ani::DofT::LocalOrder", ptr %83, i32 0, i32 2
  %85 = load i8, ptr %84, align 4, !tbaa !15
  %86 = zext i8 %85 to i32
  %87 = icmp eq i32 %86, 2
  br i1 %87, label %88, label %122

88:                                               ; preds = %82
  %89 = load ptr, ptr %27, align 8, !tbaa !17
  %90 = getelementptr inbounds ptr, ptr %89, i64 1
  %91 = load ptr, ptr %90, align 8
  %92 = call noundef i32 %91(ptr noundef nonnull align 8 dereferenceable(8) %27, i8 noundef zeroext 4)
  %93 = icmp ugt i32 %92, 0
  br i1 %93, label %94, label %122

94:                                               ; preds = %88
  %95 = load ptr, ptr %7, align 8, !tbaa !5
  %96 = getelementptr inbounds %"struct.Ani::DofT::LocalOrder", ptr %95, i32 0, i32 2
  store i8 4, ptr %96, align 4, !tbaa !15
  %97 = load ptr, ptr %7, align 8, !tbaa !5
  %98 = getelementptr inbounds %"struct.Ani::DofT::LocalOrder", ptr %97, i32 0, i32 1
  store i32 0, ptr %98, align 4, !tbaa !19
  call void @llvm.lifetime.start.p0(i64 8, ptr %15) #7
  %99 = load ptr, ptr %7, align 8, !tbaa !5
  %100 = call i64 @_ZNK3Ani4DofT10LocalOrder12getGeomOrderEv(ptr noundef nonnull align 4 dereferenceable(12) %99)
  %101 = trunc i64 %100 to i48
  store i48 %101, ptr %16, align 4
  %102 = load i64, ptr %16, align 4
  %103 = load ptr, ptr %27, align 8, !tbaa !17
  %104 = getelementptr inbounds ptr, ptr %103, i64 10
  %105 = load ptr, ptr %104, align 8
  %106 = call i64 %105(ptr noundef nonnull align 8 dereferenceable(8) %27, i64 %102)
  %107 = trunc i64 %106 to i48
  store i48 %107, ptr %15, align 4
  %108 = getelementptr inbounds %"struct.std::pair.4", ptr %15, i32 0, i32 0
  %109 = load i32, ptr %108, align 4, !tbaa !20
  %110 = load ptr, ptr %7, align 8, !tbaa !5
  %111 = getelementptr inbounds %"struct.Ani::DofT::LocalOrder", ptr %110, i32 0, i32 0
  store i32 %109, ptr %111, align 4, !tbaa !23
  %112 = getelementptr inbounds %"struct.std::pair.4", ptr %15, i32 0, i32 1
  %113 = getelementptr inbounds %"struct.Ani::DofT::LocSymOrder", ptr %112, i32 0, i32 0
  %114 = load i8, ptr %113, align 4, !tbaa !24
  %115 = load ptr, ptr %7, align 8, !tbaa !5
  %116 = getelementptr inbounds %"struct.Ani::DofT::LocalOrder", ptr %115, i32 0, i32 4
  store i8 %114, ptr %116, align 2, !tbaa !25
  %117 = getelementptr inbounds %"struct.std::pair.4", ptr %15, i32 0, i32 1
  %118 = getelementptr inbounds %"struct.Ani::DofT::LocSymOrder", ptr %117, i32 0, i32 1
  %119 = load i8, ptr %118, align 1, !tbaa !26
  %120 = load ptr, ptr %7, align 8, !tbaa !5
  %121 = getelementptr inbounds %"struct.Ani::DofT::LocalOrder", ptr %120, i32 0, i32 5
  store i8 %119, ptr %121, align 1, !tbaa !27
  store i32 1, ptr %14, align 4
  call void @llvm.lifetime.end.p0(i64 8, ptr %15) #7
  br label %272

122:                                              ; preds = %88, %82
  %123 = load ptr, ptr %7, align 8, !tbaa !5
  %124 = getelementptr inbounds %"struct.Ani::DofT::LocalOrder", ptr %123, i32 0, i32 2
  %125 = load i8, ptr %124, align 4, !tbaa !15
  %126 = zext i8 %125 to i32
  %127 = icmp eq i32 %126, 8
  br i1 %127, label %128, label %162

128:                                              ; preds = %122
  %129 = load ptr, ptr %27, align 8, !tbaa !17
  %130 = getelementptr inbounds ptr, ptr %129, i64 1
  %131 = load ptr, ptr %130, align 8
  %132 = call noundef i32 %131(ptr noundef nonnull align 8 dereferenceable(8) %27, i8 noundef zeroext 16)
  %133 = icmp ugt i32 %132, 0
  br i1 %133, label %134, label %162

134:                                              ; preds = %128
  %135 = load ptr, ptr %7, align 8, !tbaa !5
  %136 = getelementptr inbounds %"struct.Ani::DofT::LocalOrder", ptr %135, i32 0, i32 2
  store i8 16, ptr %136, align 4, !tbaa !15
  %137 = load ptr, ptr %7, align 8, !tbaa !5
  %138 = getelementptr inbounds %"struct.Ani::DofT::LocalOrder", ptr %137, i32 0, i32 1
  store i32 0, ptr %138, align 4, !tbaa !19
  call void @llvm.lifetime.start.p0(i64 8, ptr %17) #7
  %139 = load ptr, ptr %7, align 8, !tbaa !5
  %140 = call i64 @_ZNK3Ani4DofT10LocalOrder12getGeomOrderEv(ptr noundef nonnull align 4 dereferenceable(12) %139)
  %141 = trunc i64 %140 to i48
  store i48 %141, ptr %18, align 4
  %142 = load i64, ptr %18, align 4
  %143 = load ptr, ptr %27, align 8, !tbaa !17
  %144 = getelementptr inbounds ptr, ptr %143, i64 10
  %145 = load ptr, ptr %144, align 8
  %146 = call i64 %145(ptr noundef nonnull align 8 dereferenceable(8) %27, i64 %142)
  %147 = trunc i64 %146 to i48
  store i48 %147, ptr %17, align 4
  %148 = getelementptr inbounds %"struct.std::pair.4", ptr %17, i32 0, i32 0
  %149 = load i32, ptr %148, align 4, !tbaa !20
  %150 = load ptr, ptr %7, align 8, !tbaa !5
  %151 = getelementptr inbounds %"struct.Ani::DofT::LocalOrder", ptr %150, i32 0, i32 0
  store i32 %149, ptr %151, align 4, !tbaa !23
  %152 = getelementptr inbounds %"struct.std::pair.4", ptr %17, i32 0, i32 1
  %153 = getelementptr inbounds %"struct.Ani::DofT::LocSymOrder", ptr %152, i32 0, i32 0
  %154 = load i8, ptr %153, align 4, !tbaa !24
  %155 = load ptr, ptr %7, align 8, !tbaa !5
  %156 = getelementptr inbounds %"struct.Ani::DofT::LocalOrder", ptr %155, i32 0, i32 4
  store i8 %154, ptr %156, align 2, !tbaa !25
  %157 = getelementptr inbounds %"struct.std::pair.4", ptr %17, i32 0, i32 1
  %158 = getelementptr inbounds %"struct.Ani::DofT::LocSymOrder", ptr %157, i32 0, i32 1
  %159 = load i8, ptr %158, align 1, !tbaa !26
  %160 = load ptr, ptr %7, align 8, !tbaa !5
  %161 = getelementptr inbounds %"struct.Ani::DofT::LocalOrder", ptr %160, i32 0, i32 5
  store i8 %159, ptr %161, align 1, !tbaa !27
  store i32 1, ptr %14, align 4
  call void @llvm.lifetime.end.p0(i64 8, ptr %17) #7
  br label %272

162:                                              ; preds = %128, %122
  br label %163

163:                                              ; preds = %162
  call void @llvm.lifetime.start.p0(i64 4, ptr %19) #7
  %164 = load ptr, ptr %7, align 8, !tbaa !5
  %165 = getelementptr inbounds %"struct.Ani::DofT::LocalOrder", ptr %164, i32 0, i32 2
  %166 = load i8, ptr %165, align 4, !tbaa !15
  %167 = call noundef i32 @_ZN3Ani4DofT11GeomTypeDimEh(i8 noundef zeroext %166)
  store i32 %167, ptr %19, align 4, !tbaa !12
  call void @llvm.lifetime.start.p0(i64 2, ptr %20) #7
  %168 = load ptr, ptr %6, align 8, !tbaa !5
  %169 = load i32, ptr %19, align 4, !tbaa !12
  %170 = trunc i32 %169 to i8
  %171 = load ptr, ptr %7, align 8, !tbaa !5
  %172 = getelementptr inbounds %"struct.Ani::DofT::LocalOrder", ptr %171, i32 0, i32 3
  %173 = load i8, ptr %172, align 1, !tbaa !28
  call void @_ZN3Ani4DofT15TetGeomSparsity3PosC2Ehh(ptr noundef nonnull align 1 dereferenceable(2) %21, i8 noundef zeroext %170, i8 noundef zeroext %173)
  %174 = load i16, ptr %21, align 1
  %175 = call i16 @_ZNK3Ani4DofT15TetGeomSparsity7nextPosENS1_3PosE(ptr noundef nonnull align 1 dereferenceable(4) %168, i16 %174)
  store i16 %175, ptr %20, align 1
  %176 = call noundef zeroext i1 @_ZN3Ani4DofT15TetGeomSparsity3Pos7isValidEv(ptr noundef nonnull align 1 dereferenceable(2) %20)
  br i1 %176, label %182, label %177

177:                                              ; preds = %163
  %178 = load ptr, ptr %7, align 8, !tbaa !5
  %179 = load ptr, ptr %27, align 8, !tbaa !17
  %180 = getelementptr inbounds ptr, ptr %179, i64 20
  %181 = load ptr, ptr %180, align 8
  call void %181(ptr noundef nonnull align 8 dereferenceable(8) %27, ptr noundef nonnull align 4 dereferenceable(12) %178)
  store i32 1, ptr %14, align 4
  br label %271

182:                                              ; preds = %163
  %183 = load i32, ptr %19, align 4, !tbaa !12
  %184 = getelementptr inbounds %"struct.Ani::DofT::TetGeomSparsity::Pos", ptr %20, i32 0, i32 0
  %185 = load i8, ptr %184, align 1, !tbaa !29
  %186 = zext i8 %185 to i32
  %187 = icmp eq i32 %183, %186
  br i1 %187, label %188, label %249

188:                                              ; preds = %182
  %189 = getelementptr inbounds %"struct.Ani::DofT::TetGeomSparsity::Pos", ptr %20, i32 0, i32 1
  %190 = load i8, ptr %189, align 1, !tbaa !31
  %191 = load ptr, ptr %7, align 8, !tbaa !5
  %192 = getelementptr inbounds %"struct.Ani::DofT::LocalOrder", ptr %191, i32 0, i32 3
  store i8 %190, ptr %192, align 1, !tbaa !28
  %193 = load ptr, ptr %7, align 8, !tbaa !5
  %194 = getelementptr inbounds %"struct.Ani::DofT::LocalOrder", ptr %193, i32 0, i32 1
  store i32 0, ptr %194, align 4, !tbaa !19
  %195 = getelementptr inbounds %"struct.Ani::DofT::TetGeomSparsity::Pos", ptr %20, i32 0, i32 0
  %196 = load i8, ptr %195, align 1, !tbaa !29
  %197 = zext i8 %196 to i32
  %198 = icmp eq i32 %197, 1
  br i1 %198, label %199, label %209

199:                                              ; preds = %188
  %200 = load ptr, ptr %27, align 8, !tbaa !17
  %201 = getelementptr inbounds ptr, ptr %200, i64 1
  %202 = load ptr, ptr %201, align 8
  %203 = call noundef i32 %202(ptr noundef nonnull align 8 dereferenceable(8) %27, i8 noundef zeroext 2)
  %204 = icmp ugt i32 %203, 0
  br i1 %204, label %205, label %208

205:                                              ; preds = %199
  %206 = load ptr, ptr %7, align 8, !tbaa !5
  %207 = getelementptr inbounds %"struct.Ani::DofT::LocalOrder", ptr %206, i32 0, i32 2
  store i8 2, ptr %207, align 4, !tbaa !15
  br label %208

208:                                              ; preds = %205, %199
  br label %225

209:                                              ; preds = %188
  %210 = getelementptr inbounds %"struct.Ani::DofT::TetGeomSparsity::Pos", ptr %20, i32 0, i32 0
  %211 = load i8, ptr %210, align 1, !tbaa !29
  %212 = zext i8 %211 to i32
  %213 = icmp eq i32 %212, 2
  br i1 %213, label %214, label %224

214:                                              ; preds = %209
  %215 = load ptr, ptr %27, align 8, !tbaa !17
  %216 = getelementptr inbounds ptr, ptr %215, i64 1
  %217 = load ptr, ptr %216, align 8
  %218 = call noundef i32 %217(ptr noundef nonnull align 8 dereferenceable(8) %27, i8 noundef zeroext 8)
  %219 = icmp ugt i32 %218, 0
  br i1 %219, label %220, label %223

220:                                              ; preds = %214
  %221 = load ptr, ptr %7, align 8, !tbaa !5
  %222 = getelementptr inbounds %"struct.Ani::DofT::LocalOrder", ptr %221, i32 0, i32 2
  store i8 8, ptr %222, align 4, !tbaa !15
  br label %223

223:                                              ; preds = %220, %214
  br label %224

224:                                              ; preds = %223, %209
  br label %225

225:                                              ; preds = %224, %208
  call void @llvm.lifetime.start.p0(i64 8, ptr %22) #7
  %226 = load ptr, ptr %7, align 8, !tbaa !5
  %227 = call i64 @_ZNK3Ani4DofT10LocalOrder12getGeomOrderEv(ptr noundef nonnull align 4 dereferenceable(12) %226)
  %228 = trunc i64 %227 to i48
  store i48 %228, ptr %23, align 4
  %229 = load i64, ptr %23, align 4
  %230 = load ptr, ptr %27, align 8, !tbaa !17
  %231 = getelementptr inbounds ptr, ptr %230, i64 10
  %232 = load ptr, ptr %231, align 8
  %233 = call i64 %232(ptr noundef nonnull align 8 dereferenceable(8) %27, i64 %229)
  %234 = trunc i64 %233 to i48
  store i48 %234, ptr %22, align 4
  %235 = getelementptr inbounds %"struct.std::pair.4", ptr %22, i32 0, i32 0
  %236 = load i32, ptr %235, align 4, !tbaa !20
  %237 = load ptr, ptr %7, align 8, !tbaa !5
  %238 = getelementptr inbounds %"struct.Ani::DofT::LocalOrder", ptr %237, i32 0, i32 0
  store i32 %236, ptr %238, align 4, !tbaa !23
  %239 = getelementptr inbounds %"struct.std::pair.4", ptr %22, i32 0, i32 1
  %240 = getelementptr inbounds %"struct.Ani::DofT::LocSymOrder", ptr %239, i32 0, i32 0
  %241 = load i8, ptr %240, align 4, !tbaa !24
  %242 = load ptr, ptr %7, align 8, !tbaa !5
  %243 = getelementptr inbounds %"struct.Ani::DofT::LocalOrder", ptr %242, i32 0, i32 4
  store i8 %241, ptr %243, align 2, !tbaa !25
  %244 = getelementptr inbounds %"struct.std::pair.4", ptr %22, i32 0, i32 1
  %245 = getelementptr inbounds %"struct.Ani::DofT::LocSymOrder", ptr %244, i32 0, i32 1
  %246 = load i8, ptr %245, align 1, !tbaa !26
  %247 = load ptr, ptr %7, align 8, !tbaa !5
  %248 = getelementptr inbounds %"struct.Ani::DofT::LocalOrder", ptr %247, i32 0, i32 5
  store i8 %246, ptr %248, align 1, !tbaa !27
  call void @llvm.lifetime.end.p0(i64 8, ptr %22) #7
  br label %270

249:                                              ; preds = %182
  call void @llvm.lifetime.start.p0(i64 4, ptr %24) #7
  %250 = load ptr, ptr %6, align 8, !tbaa !5
  call void @llvm.memcpy.p0.p0.i64(ptr align 1 %24, ptr align 1 %250, i64 4, i1 false), !tbaa.struct !32
  call void @llvm.lifetime.start.p0(i64 4, ptr %25) #7
  store i32 0, ptr %25, align 4, !tbaa !12
  br label %251

251:                                              ; preds = %262, %249
  %252 = load i32, ptr %25, align 4, !tbaa !12
  %253 = getelementptr inbounds %"struct.Ani::DofT::TetGeomSparsity::Pos", ptr %20, i32 0, i32 0
  %254 = load i8, ptr %253, align 1, !tbaa !29
  %255 = zext i8 %254 to i32
  %256 = icmp slt i32 %252, %255
  br i1 %256, label %258, label %257

257:                                              ; preds = %251
  store i32 2, ptr %14, align 4
  call void @llvm.lifetime.end.p0(i64 4, ptr %25) #7
  br label %265

258:                                              ; preds = %251
  %259 = load i32, ptr %25, align 4, !tbaa !12
  %260 = trunc i32 %259 to i8
  %261 = call noundef nonnull align 1 dereferenceable(4) ptr @_ZN3Ani4DofT15TetGeomSparsity5unsetEh(ptr noundef nonnull align 1 dereferenceable(4) %24, i8 noundef zeroext %260)
  br label %262

262:                                              ; preds = %258
  %263 = load i32, ptr %25, align 4, !tbaa !12
  %264 = add nsw i32 %263, 1
  store i32 %264, ptr %25, align 4, !tbaa !12
  br label %251, !llvm.loop !33

265:                                              ; preds = %257
  %266 = load ptr, ptr %7, align 8, !tbaa !5
  %267 = load ptr, ptr %27, align 8, !tbaa !17
  %268 = getelementptr inbounds ptr, ptr %267, i64 19
  %269 = load ptr, ptr %268, align 8
  call void %269(ptr noundef nonnull align 8 dereferenceable(8) %27, ptr noundef nonnull align 1 dereferenceable(4) %24, ptr noundef nonnull align 4 dereferenceable(12) %266, i1 noundef zeroext false)
  call void @llvm.lifetime.end.p0(i64 4, ptr %24) #7
  br label %270

270:                                              ; preds = %265, %225
  store i32 1, ptr %14, align 4
  br label %271

271:                                              ; preds = %270, %177
  call void @llvm.lifetime.end.p0(i64 2, ptr %20) #7
  call void @llvm.lifetime.end.p0(i64 4, ptr %19) #7
  br label %272

272:                                              ; preds = %271, %134, %94, %54
  call void @llvm.lifetime.end.p0(i64 4, ptr %11) #7
  ret void
}

; Function Attrs: inlinehint mustprogress uwtable
declare dso_local noundef zeroext i1 @_ZNK3Ani4DofT10BaseDofMap12isValidIndexENS0_10LocalOrderEb(ptr noundef nonnull align 8 dereferenceable(8), i64, i32, i1 noundef zeroext) #4 align 2

; Function Attrs: noreturn nounwind
declare void @__assert_fail(ptr noundef, ptr noundef, i32 noundef, ptr noundef) #5

; Function Attrs: inlinehint mustprogress uwtable
declare dso_local noundef i32 @_ZN3Ani4DofT11GeomTypeDimEh(i8 noundef zeroext) #4

; Function Attrs: mustprogress nounwind uwtable
declare dso_local noundef nonnull align 1 dereferenceable(4) ptr @_ZN3Ani4DofT15TetGeomSparsity5unsetEh(ptr noundef nonnull align 1 dereferenceable(4), i8 noundef zeroext) #2 align 2

attributes #0 = { nocallback nofree nosync nounwind willreturn memory(argmem: readwrite) }
attributes #1 = { nocallback nofree nounwind willreturn memory(argmem: readwrite) }
attributes #2 = { 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 #3 = { 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 #4 = { inlinehint 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 #5 = { noreturn nounwind "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 #6 = { noreturn nounwind }
attributes #7 = { 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 = !{!"bool", !7, i64 0}
!11 = !{i64 0, i64 4, !12, i64 4, i64 4, !12, i64 8, i64 1, !14, i64 9, i64 1, !14, i64 10, i64 1, !14, i64 11, i64 1, !14}
!12 = !{!13, !13, i64 0}
!13 = !{!"int", !7, i64 0}
!14 = !{!7, !7, i64 0}
!15 = !{!16, !7, i64 8}
!16 = !{!"_ZTSN3Ani4DofT10LocalOrderE", !13, i64 0, !13, i64 4, !7, i64 8, !7, i64 9, !7, i64 10, !7, i64 11}
!17 = !{!18, !18, i64 0}
!18 = !{!"vtable pointer", !8, i64 0}
!19 = !{!16, !13, i64 4}
!20 = !{!21, !13, i64 0}
!21 = !{!"_ZTSSt4pairIjN3Ani4DofT11LocSymOrderEE", !13, i64 0, !22, i64 4}
!22 = !{!"_ZTSN3Ani4DofT11LocSymOrderE", !7, i64 0, !7, i64 1}
!23 = !{!16, !13, i64 0}
!24 = !{!21, !7, i64 4}
!25 = !{!16, !7, i64 10}
!26 = !{!21, !7, i64 5}
!27 = !{!16, !7, i64 11}
!28 = !{!16, !7, i64 9}
!29 = !{!30, !7, i64 0}
!30 = !{!"_ZTSN3Ani4DofT15TetGeomSparsity3PosE", !7, i64 0, !7, i64 1}
!31 = !{!30, !7, i64 1}
!32 = !{i64 0, i64 4, !14}
!33 = distinct !{!33, !34}
!34 = !{!"llvm.loop.mustprogress"}


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

%"struct.Ani::DofT::TetGeomSparsity::Pos" = type { i8, i8 }
%"struct.Ani::DofT::TetGeomSparsity" = type { %"struct.std::array" }
%"struct.std::array" = type { [4 x i8] }

@.str.2 = external hidden unnamed_addr constant [40 x i8], align 1
@.str.3 = external hidden unnamed_addr constant [82 x i8], align 1
@__PRETTY_FUNCTION__._ZNK3Ani4DofT10BaseDofMap23IncrementByGeomSparsityERKNS0_15TetGeomSparsityERNS0_10LocalOrderEb = external hidden unnamed_addr constant [111 x i8], align 1

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

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

; Function Attrs: mustprogress nounwind uwtable
declare dso_local void @_ZN3Ani4DofT15TetGeomSparsity3PosC2Ehh(ptr noundef nonnull align 1 dereferenceable(2), i8 noundef zeroext, i8 noundef zeroext) unnamed_addr #1 align 2

; Function Attrs: mustprogress uwtable
declare dso_local i16 @_ZNK3Ani4DofT15TetGeomSparsity7nextPosENS1_3PosE(ptr noundef nonnull align 1 dereferenceable(4), i16) local_unnamed_addr #2 align 2

; Function Attrs: mustprogress nounwind uwtable
declare dso_local noundef zeroext i1 @_ZN3Ani4DofT15TetGeomSparsity3Pos7isValidEv(ptr noundef nonnull align 1 dereferenceable(2)) local_unnamed_addr #1 align 2

; Function Attrs: inlinehint mustprogress uwtable
declare dso_local i64 @_ZNK3Ani4DofT10LocalOrder12getGeomOrderEv(ptr noundef nonnull align 4 dereferenceable(12)) local_unnamed_addr #3 align 2

; Function Attrs: mustprogress uwtable
define dso_local void @_ZNK3Ani4DofT10BaseDofMap23IncrementByGeomSparsityERKNS0_15TetGeomSparsityERNS0_10LocalOrderEb(ptr noundef nonnull align 8 dereferenceable(8) %0, ptr noundef nonnull align 1 dereferenceable(4) %1, ptr noundef nonnull align 4 dereferenceable(12) %2, i1 noundef zeroext %3) unnamed_addr #2 align 2 {
  %5 = alloca %"struct.Ani::DofT::TetGeomSparsity::Pos", align 2
  %6 = alloca %"struct.Ani::DofT::TetGeomSparsity::Pos", align 2
  %7 = alloca %"struct.Ani::DofT::TetGeomSparsity", align 4
  %.sroa.021.0.copyload = load i64, ptr %2, align 4
  %.sroa.222.0..sroa_idx = getelementptr inbounds i8, ptr %2, i64 8
  %.sroa.222.0.copyload = load i32, ptr %.sroa.222.0..sroa_idx, align 4
  %8 = tail call noundef zeroext i1 @_ZNK3Ani4DofT10BaseDofMap12isValidIndexENS0_10LocalOrderEb(ptr noundef nonnull align 8 dereferenceable(8) %0, i64 %.sroa.021.0.copyload, i32 %.sroa.222.0.copyload, i1 noundef zeroext false)
  br i1 %8, label %10, label %9

9:                                                ; preds = %4
  tail call void @__assert_fail(ptr noundef nonnull @.str.2, ptr noundef nonnull @.str.3, i32 noundef 196, ptr noundef nonnull @__PRETTY_FUNCTION__._ZNK3Ani4DofT10BaseDofMap23IncrementByGeomSparsityERKNS0_15TetGeomSparsityERNS0_10LocalOrderEb) #5
  unreachable

10:                                               ; preds = %4
  %11 = load i8, ptr %.sroa.222.0..sroa_idx, align 4, !tbaa !5
  %12 = load ptr, ptr %0, align 8, !tbaa !10
  %13 = getelementptr inbounds i8, ptr %12, i64 8
  %14 = load ptr, ptr %13, align 8
  %15 = tail call noundef i32 %14(ptr noundef nonnull align 8 dereferenceable(8) %0, i8 noundef zeroext %11)
  %16 = getelementptr inbounds i8, ptr %2, i64 4
  %17 = load i32, ptr %16, align 4, !tbaa !12
  %18 = add i32 %15, -1
  %19 = icmp ult i32 %17, %18
  br i1 %19, label %20, label %29

20:                                               ; preds = %10
  %21 = add nuw i32 %17, 1
  store i32 %21, ptr %16, align 4, !tbaa !12
  %22 = tail call i64 @_ZNK3Ani4DofT10LocalOrder12getGeomOrderEv(ptr noundef nonnull align 4 dereferenceable(12) %2)
  %.sroa.014.0.insert.ext = and i64 %22, 281474976710655
  %23 = load ptr, ptr %0, align 8, !tbaa !10
  %24 = getelementptr inbounds i8, ptr %23, i64 80
  %25 = load ptr, ptr %24, align 8
  %26 = tail call i64 %25(ptr noundef nonnull align 8 dereferenceable(8) %0, i64 %.sroa.014.0.insert.ext)
  %.sroa.016.0.extract.trunc = trunc i64 %26 to i32
  store i32 %.sroa.016.0.extract.trunc, ptr %2, align 4, !tbaa !13
  %.sroa.016.4.extract.shift70 = lshr i64 %26, 32
  %.sroa.016.4.extract.trunc = trunc i64 %.sroa.016.4.extract.shift70 to i8
  %27 = getelementptr inbounds i8, ptr %2, i64 10
  store i8 %.sroa.016.4.extract.trunc, ptr %27, align 2, !tbaa !14
  %.sroa.016.5.extract.shift71 = lshr i64 %26, 40
  %.sroa.016.5.extract.trunc = trunc i64 %.sroa.016.5.extract.shift71 to i8
  %28 = getelementptr inbounds i8, ptr %2, i64 11
  store i8 %.sroa.016.5.extract.trunc, ptr %28, align 1, !tbaa !15
  br label %111

29:                                               ; preds = %10
  %30 = load i8, ptr %.sroa.222.0..sroa_idx, align 4, !tbaa !5
  %31 = icmp eq i8 %30, 2
  br i1 %31, label %32, label %45

32:                                               ; preds = %29
  %33 = load ptr, ptr %0, align 8, !tbaa !10
  %34 = getelementptr inbounds i8, ptr %33, i64 8
  %35 = load ptr, ptr %34, align 8
  %36 = tail call noundef i32 %35(ptr noundef nonnull align 8 dereferenceable(8) %0, i8 noundef zeroext 4)
  %.not = icmp eq i32 %36, 0
  br i1 %.not, label %thread-pre-split, label %37

37:                                               ; preds = %32
  store i8 4, ptr %.sroa.222.0..sroa_idx, align 4, !tbaa !5
  store i32 0, ptr %16, align 4, !tbaa !12
  %38 = tail call i64 @_ZNK3Ani4DofT10LocalOrder12getGeomOrderEv(ptr noundef nonnull align 4 dereferenceable(12) %2)
  %.sroa.010.0.insert.ext = and i64 %38, 281474976710655
  %39 = load ptr, ptr %0, align 8, !tbaa !10
  %40 = getelementptr inbounds i8, ptr %39, i64 80
  %41 = load ptr, ptr %40, align 8
  %42 = tail call i64 %41(ptr noundef nonnull align 8 dereferenceable(8) %0, i64 %.sroa.010.0.insert.ext)
  %.sroa.012.0.extract.trunc = trunc i64 %42 to i32
  store i32 %.sroa.012.0.extract.trunc, ptr %2, align 4, !tbaa !13
  %.sroa.012.4.extract.shift68 = lshr i64 %42, 32
  %.sroa.012.4.extract.trunc = trunc i64 %.sroa.012.4.extract.shift68 to i8
  %43 = getelementptr inbounds i8, ptr %2, i64 10
  store i8 %.sroa.012.4.extract.trunc, ptr %43, align 2, !tbaa !14
  %.sroa.012.5.extract.shift69 = lshr i64 %42, 40
  %.sroa.012.5.extract.trunc = trunc i64 %.sroa.012.5.extract.shift69 to i8
  %44 = getelementptr inbounds i8, ptr %2, i64 11
  store i8 %.sroa.012.5.extract.trunc, ptr %44, align 1, !tbaa !15
  br label %111

thread-pre-split:                                 ; preds = %32
  %.pr = load i8, ptr %.sroa.222.0..sroa_idx, align 4, !tbaa !5
  br label %45

45:                                               ; preds = %thread-pre-split, %29
  %46 = phi i8 [ %.pr, %thread-pre-split ], [ %30, %29 ]
  %47 = icmp eq i8 %46, 8
  br i1 %47, label %48, label %61

48:                                               ; preds = %45
  %49 = load ptr, ptr %0, align 8, !tbaa !10
  %50 = getelementptr inbounds i8, ptr %49, i64 8
  %51 = load ptr, ptr %50, align 8
  %52 = tail call noundef i32 %51(ptr noundef nonnull align 8 dereferenceable(8) %0, i8 noundef zeroext 16)
  %.not61 = icmp eq i32 %52, 0
  br i1 %.not61, label %._crit_edge74, label %53

._crit_edge74:                                    ; preds = %48
  %.pre = load i8, ptr %.sroa.222.0..sroa_idx, align 4, !tbaa !5
  br label %61

53:                                               ; preds = %48
  store i8 16, ptr %.sroa.222.0..sroa_idx, align 4, !tbaa !5
  store i32 0, ptr %16, align 4, !tbaa !12
  %54 = tail call i64 @_ZNK3Ani4DofT10LocalOrder12getGeomOrderEv(ptr noundef nonnull align 4 dereferenceable(12) %2)
  %.sroa.06.0.insert.ext = and i64 %54, 281474976710655
  %55 = load ptr, ptr %0, align 8, !tbaa !10
  %56 = getelementptr inbounds i8, ptr %55, i64 80
  %57 = load ptr, ptr %56, align 8
  %58 = tail call i64 %57(ptr noundef nonnull align 8 dereferenceable(8) %0, i64 %.sroa.06.0.insert.ext)
  %.sroa.08.0.extract.trunc = trunc i64 %58 to i32
  store i32 %.sroa.08.0.extract.trunc, ptr %2, align 4, !tbaa !13
  %.sroa.08.4.extract.shift66 = lshr i64 %58, 32
  %.sroa.08.4.extract.trunc = trunc i64 %.sroa.08.4.extract.shift66 to i8
  %59 = getelementptr inbounds i8, ptr %2, i64 10
  store i8 %.sroa.08.4.extract.trunc, ptr %59, align 2, !tbaa !14
  %.sroa.08.5.extract.shift67 = lshr i64 %58, 40
  %.sroa.08.5.extract.trunc = trunc i64 %.sroa.08.5.extract.shift67 to i8
  %60 = getelementptr inbounds i8, ptr %2, i64 11
  store i8 %.sroa.08.5.extract.trunc, ptr %60, align 1, !tbaa !15
  br label %111

61:                                               ; preds = %._crit_edge74, %45
  %62 = phi i8 [ %.pre, %._crit_edge74 ], [ %46, %45 ]
  %63 = tail call noundef i32 @_ZN3Ani4DofT11GeomTypeDimEh(i8 noundef zeroext %62)
  call void @llvm.lifetime.start.p0(i64 2, ptr nonnull %5) #6
  %64 = trunc i32 %63 to i8
  %65 = getelementptr inbounds i8, ptr %2, i64 9
  %66 = load i8, ptr %65, align 1, !tbaa !16
  call void @_ZN3Ani4DofT15TetGeomSparsity3PosC2Ehh(ptr noundef nonnull align 1 dereferenceable(2) %6, i8 noundef zeroext %64, i8 noundef zeroext %66)
  %67 = load i16, ptr %6, align 2
  %68 = call i16 @_ZNK3Ani4DofT15TetGeomSparsity7nextPosENS1_3PosE(ptr noundef nonnull align 1 dereferenceable(4) %1, i16 %67)
  store i16 %68, ptr %5, align 2
  %69 = call noundef zeroext i1 @_ZN3Ani4DofT15TetGeomSparsity3Pos7isValidEv(ptr noundef nonnull align 1 dereferenceable(2) %5)
  br i1 %69, label %74, label %70

70:                                               ; preds = %61
  %71 = load ptr, ptr %0, align 8, !tbaa !10
  %72 = getelementptr inbounds i8, ptr %71, i64 160
  %73 = load ptr, ptr %72, align 8
  call void %73(ptr noundef nonnull align 8 dereferenceable(8) %0, ptr noundef nonnull align 4 dereferenceable(12) %2)
  br label %110

74:                                               ; preds = %61
  %75 = load i8, ptr %5, align 2, !tbaa !17
  %76 = zext i8 %75 to i32
  %77 = icmp eq i32 %63, %76
  br i1 %77, label %78, label %99

78:                                               ; preds = %74
  %79 = getelementptr inbounds i8, ptr %5, i64 1
  %80 = load i8, ptr %79, align 1, !tbaa !19
  store i8 %80, ptr %65, align 1, !tbaa !16
  store i32 0, ptr %16, align 4, !tbaa !12
  switch i8 %75, label %91 [
    i8 1, label %81
    i8 2, label %86
  ]

81:                                               ; preds = %78
  %82 = load ptr, ptr %0, align 8, !tbaa !10
  %83 = getelementptr inbounds i8, ptr %82, i64 8
  %84 = load ptr, ptr %83, align 8
  %85 = call noundef i32 %84(ptr noundef nonnull align 8 dereferenceable(8) %0, i8 noundef zeroext 2)
  %.not63 = icmp eq i32 %85, 0
  br i1 %.not63, label %91, label %.sink.split

86:                                               ; preds = %78
  %87 = load ptr, ptr %0, align 8, !tbaa !10
  %88 = getelementptr inbounds i8, ptr %87, i64 8
  %89 = load ptr, ptr %88, align 8
  %90 = call noundef i32 %89(ptr noundef nonnull align 8 dereferenceable(8) %0, i8 noundef zeroext 8)
  %.not62 = icmp eq i32 %90, 0
  br i1 %.not62, label %91, label %.sink.split

.sink.split:                                      ; preds = %86, %81
  %.sink = phi i8 [ 2, %81 ], [ 8, %86 ]
  store i8 %.sink, ptr %.sroa.222.0..sroa_idx, align 4, !tbaa !5
  br label %91

91:                                               ; preds = %.sink.split, %78, %86, %81
  %92 = call i64 @_ZNK3Ani4DofT10LocalOrder12getGeomOrderEv(ptr noundef nonnull align 4 dereferenceable(12) %2)
  %.sroa.0.0.insert.ext = and i64 %92, 281474976710655
  %93 = load ptr, ptr %0, align 8, !tbaa !10
  %94 = getelementptr inbounds i8, ptr %93, i64 80
  %95 = load ptr, ptr %94, align 8
  %96 = call i64 %95(ptr noundef nonnull align 8 dereferenceable(8) %0, i64 %.sroa.0.0.insert.ext)
  %.sroa.03.0.extract.trunc = trunc i64 %96 to i32
  store i32 %.sroa.03.0.extract.trunc, ptr %2, align 4, !tbaa !13
  %.sroa.03.4.extract.shift64 = lshr i64 %96, 32
  %.sroa.03.4.extract.trunc = trunc i64 %.sroa.03.4.extract.shift64 to i8
  %97 = getelementptr inbounds i8, ptr %2, i64 10
  store i8 %.sroa.03.4.extract.trunc, ptr %97, align 2, !tbaa !14
  %.sroa.03.5.extract.shift65 = lshr i64 %96, 40
  %.sroa.03.5.extract.trunc = trunc i64 %.sroa.03.5.extract.shift65 to i8
  %98 = getelementptr inbounds i8, ptr %2, i64 11
  store i8 %.sroa.03.5.extract.trunc, ptr %98, align 1, !tbaa !15
  br label %110

99:                                               ; preds = %74
  call void @llvm.lifetime.start.p0(i64 4, ptr nonnull %7) #6
  %100 = load i32, ptr %1, align 1, !tbaa !20
  store i32 %100, ptr %7, align 4, !tbaa !20
  %.not73 = icmp eq i8 %75, 0
  br i1 %.not73, label %._crit_edge, label %.lr.ph

._crit_edge:                                      ; preds = %.lr.ph, %99
  %101 = load ptr, ptr %0, align 8, !tbaa !10
  %102 = getelementptr inbounds i8, ptr %101, i64 152
  %103 = load ptr, ptr %102, align 8
  call void %103(ptr noundef nonnull align 8 dereferenceable(8) %0, ptr noundef nonnull align 1 dereferenceable(4) %7, ptr noundef nonnull align 4 dereferenceable(12) %2, i1 noundef zeroext false)
  call void @llvm.lifetime.end.p0(i64 4, ptr nonnull %7) #6
  br label %110

.lr.ph:                                           ; preds = %99, %.lr.ph
  %.072 = phi i32 [ %106, %.lr.ph ], [ 0, %99 ]
  %104 = trunc i32 %.072 to i8
  %105 = call noundef nonnull align 1 dereferenceable(4) ptr @_ZN3Ani4DofT15TetGeomSparsity5unsetEh(ptr noundef nonnull align 1 dereferenceable(4) %7, i8 noundef zeroext %104)
  %106 = add nuw nsw i32 %.072, 1
  %107 = load i8, ptr %5, align 2, !tbaa !17
  %108 = zext i8 %107 to i32
  %109 = icmp ult i32 %106, %108
  br i1 %109, label %.lr.ph, label %._crit_edge, !llvm.loop !21

110:                                              ; preds = %91, %._crit_edge, %70
  call void @llvm.lifetime.end.p0(i64 2, ptr nonnull %5) #6
  br label %111

111:                                              ; preds = %110, %53, %37, %20
  ret void
}

; Function Attrs: inlinehint mustprogress uwtable
declare dso_local noundef zeroext i1 @_ZNK3Ani4DofT10BaseDofMap12isValidIndexENS0_10LocalOrderEb(ptr noundef nonnull align 8 dereferenceable(8), i64, i32, i1 noundef zeroext) local_unnamed_addr #3 align 2

; Function Attrs: noreturn nounwind
declare void @__assert_fail(ptr noundef, ptr noundef, i32 noundef, ptr noundef) local_unnamed_addr #4

; Function Attrs: inlinehint mustprogress uwtable
declare dso_local noundef i32 @_ZN3Ani4DofT11GeomTypeDimEh(i8 noundef zeroext) local_unnamed_addr #3

; Function Attrs: mustprogress nounwind uwtable
declare dso_local noundef nonnull align 1 dereferenceable(4) ptr @_ZN3Ani4DofT15TetGeomSparsity5unsetEh(ptr noundef nonnull align 1 dereferenceable(4), i8 noundef zeroext) local_unnamed_addr #1 align 2

attributes #0 = { mustprogress nocallback nofree nosync nounwind willreturn memory(argmem: readwrite) }
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 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 = { inlinehint 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 #4 = { noreturn nounwind "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 = { noreturn nounwind }
attributes #6 = { 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, !8, i64 8}
!6 = !{!"_ZTSN3Ani4DofT10LocalOrderE", !7, i64 0, !7, i64 4, !8, i64 8, !8, i64 9, !8, i64 10, !8, i64 11}
!7 = !{!"int", !8, i64 0}
!8 = !{!"omnipotent char", !9, i64 0}
!9 = !{!"Simple C++ TBAA"}
!10 = !{!11, !11, i64 0}
!11 = !{!"vtable pointer", !9, i64 0}
!12 = !{!6, !7, i64 4}
!13 = !{!6, !7, i64 0}
!14 = !{!6, !8, i64 10}
!15 = !{!6, !8, i64 11}
!16 = !{!6, !8, i64 9}
!17 = !{!18, !8, i64 0}
!18 = !{!"_ZTSN3Ani4DofT15TetGeomSparsity3PosE", !8, i64 0, !8, i64 1}
!19 = !{!18, !8, i64 1}
!20 = !{!8, !8, i64 0}
!21 = distinct !{!21, !22}
!22 = !{!"llvm.loop.mustprogress"}


; Effective O3 passes: CorrelatedValuePropagationPass,EarlyCSEPass,GVNPass,GlobalOptPass,IPSCCPPass,InferAlignmentPass,InferFunctionAttrsPass,InstCombinePass,JumpThreadingPass,LoopRotatePass,LoopSimplifyPass,LoopUnrollPass,SROAPass,SimplifyCFGPass,TailCallElimPass