1; NOTE: Assertions have been autogenerated by utils/update_analyze_test_checks.py 2; RUN: opt < %s --data-layout="p:64:64:64:64" -S -disable-output "-passes=print<scalar-evolution>" 2>&1 | FileCheck --check-prefixes=PTR64_IDX64 %s 3; RUN: opt < %s --data-layout="p:64:64:64:32" -S -disable-output "-passes=print<scalar-evolution>" 2>&1 | FileCheck --check-prefixes=PTR64_IDX32 %s 4; RUN: opt < %s --data-layout="p:16:16:16:16" -S -disable-output "-passes=print<scalar-evolution>" 2>&1 | FileCheck --check-prefixes=PTR16_IDX16 %s 5; RUN: opt < %s --data-layout="p:16:16:16:32" -S -disable-output "-passes=print<scalar-evolution>" 2>&1 | FileCheck --check-prefixes=PTR16_IDX32 %s 6 7@global = external hidden global [0 x i8] 8 9declare void @use16(i16) 10 11define hidden i32* @trunc_ptr_to_i64(i8* %arg, i32* %arg10) { 12; PTR64_IDX64-LABEL: 'trunc_ptr_to_i64' 13; PTR64_IDX64-NEXT: Classifying expressions for: @trunc_ptr_to_i64 14; PTR64_IDX64-NEXT: %tmp = phi i32 [ 0, %bb ], [ %tmp18, %bb17 ] 15; PTR64_IDX64-NEXT: --> {0,+,2}<%bb11> U: [0,-1) S: [-2147483648,2147483647) Exits: <<Unknown>> LoopDispositions: { %bb11: Computable } 16; PTR64_IDX64-NEXT: %tmp12 = getelementptr i8, i8* %arg, i64 ptrtoint ([0 x i8]* @global to i64) 17; PTR64_IDX64-NEXT: --> ((ptrtoint [0 x i8]* @global to i64) + %arg) U: full-set S: full-set Exits: ((ptrtoint [0 x i8]* @global to i64) + %arg) LoopDispositions: { %bb11: Invariant } 18; PTR64_IDX64-NEXT: %tmp13 = bitcast i8* %tmp12 to i32* 19; PTR64_IDX64-NEXT: --> ((ptrtoint [0 x i8]* @global to i64) + %arg) U: full-set S: full-set Exits: ((ptrtoint [0 x i8]* @global to i64) + %arg) LoopDispositions: { %bb11: Invariant } 20; PTR64_IDX64-NEXT: %tmp14 = load i32, i32* %tmp13, align 4 21; PTR64_IDX64-NEXT: --> %tmp14 U: full-set S: full-set Exits: <<Unknown>> LoopDispositions: { %bb11: Variant } 22; PTR64_IDX64-NEXT: %tmp18 = add i32 %tmp, 2 23; PTR64_IDX64-NEXT: --> {2,+,2}<%bb11> U: [0,-1) S: [-2147483648,2147483647) Exits: <<Unknown>> LoopDispositions: { %bb11: Computable } 24; PTR64_IDX64-NEXT: Determining loop execution counts for: @trunc_ptr_to_i64 25; PTR64_IDX64-NEXT: Loop %bb11: Unpredictable backedge-taken count. 26; PTR64_IDX64-NEXT: Loop %bb11: Unpredictable max backedge-taken count. 27; PTR64_IDX64-NEXT: Loop %bb11: Unpredictable predicated backedge-taken count. 28; 29; PTR64_IDX32-LABEL: 'trunc_ptr_to_i64' 30; PTR64_IDX32-NEXT: Classifying expressions for: @trunc_ptr_to_i64 31; PTR64_IDX32-NEXT: %tmp = phi i32 [ 0, %bb ], [ %tmp18, %bb17 ] 32; PTR64_IDX32-NEXT: --> {0,+,2}<%bb11> U: [0,-1) S: [-2147483648,2147483647) Exits: <<Unknown>> LoopDispositions: { %bb11: Computable } 33; PTR64_IDX32-NEXT: %tmp12 = getelementptr i8, i8* %arg, i64 ptrtoint ([0 x i8]* @global to i64) 34; PTR64_IDX32-NEXT: --> ((trunc i64 ptrtoint ([0 x i8]* @global to i64) to i32) + %arg) U: full-set S: full-set Exits: ((trunc i64 ptrtoint ([0 x i8]* @global to i64) to i32) + %arg) LoopDispositions: { %bb11: Invariant } 35; PTR64_IDX32-NEXT: %tmp13 = bitcast i8* %tmp12 to i32* 36; PTR64_IDX32-NEXT: --> ((trunc i64 ptrtoint ([0 x i8]* @global to i64) to i32) + %arg) U: full-set S: full-set Exits: ((trunc i64 ptrtoint ([0 x i8]* @global to i64) to i32) + %arg) LoopDispositions: { %bb11: Invariant } 37; PTR64_IDX32-NEXT: %tmp14 = load i32, i32* %tmp13, align 4 38; PTR64_IDX32-NEXT: --> %tmp14 U: full-set S: full-set Exits: <<Unknown>> LoopDispositions: { %bb11: Variant } 39; PTR64_IDX32-NEXT: %tmp18 = add i32 %tmp, 2 40; PTR64_IDX32-NEXT: --> {2,+,2}<%bb11> U: [0,-1) S: [-2147483648,2147483647) Exits: <<Unknown>> LoopDispositions: { %bb11: Computable } 41; PTR64_IDX32-NEXT: Determining loop execution counts for: @trunc_ptr_to_i64 42; PTR64_IDX32-NEXT: Loop %bb11: Unpredictable backedge-taken count. 43; PTR64_IDX32-NEXT: Loop %bb11: Unpredictable max backedge-taken count. 44; PTR64_IDX32-NEXT: Loop %bb11: Unpredictable predicated backedge-taken count. 45; 46; PTR16_IDX16-LABEL: 'trunc_ptr_to_i64' 47; PTR16_IDX16-NEXT: Classifying expressions for: @trunc_ptr_to_i64 48; PTR16_IDX16-NEXT: %tmp = phi i32 [ 0, %bb ], [ %tmp18, %bb17 ] 49; PTR16_IDX16-NEXT: --> {0,+,2}<%bb11> U: [0,-1) S: [-2147483648,2147483647) Exits: <<Unknown>> LoopDispositions: { %bb11: Computable } 50; PTR16_IDX16-NEXT: %tmp12 = getelementptr i8, i8* %arg, i64 ptrtoint ([0 x i8]* @global to i64) 51; PTR16_IDX16-NEXT: --> ((ptrtoint [0 x i8]* @global to i16) + %arg) U: full-set S: full-set Exits: ((ptrtoint [0 x i8]* @global to i16) + %arg) LoopDispositions: { %bb11: Invariant } 52; PTR16_IDX16-NEXT: %tmp13 = bitcast i8* %tmp12 to i32* 53; PTR16_IDX16-NEXT: --> ((ptrtoint [0 x i8]* @global to i16) + %arg) U: full-set S: full-set Exits: ((ptrtoint [0 x i8]* @global to i16) + %arg) LoopDispositions: { %bb11: Invariant } 54; PTR16_IDX16-NEXT: %tmp14 = load i32, i32* %tmp13, align 4 55; PTR16_IDX16-NEXT: --> %tmp14 U: full-set S: full-set Exits: <<Unknown>> LoopDispositions: { %bb11: Variant } 56; PTR16_IDX16-NEXT: %tmp18 = add i32 %tmp, 2 57; PTR16_IDX16-NEXT: --> {2,+,2}<%bb11> U: [0,-1) S: [-2147483648,2147483647) Exits: <<Unknown>> LoopDispositions: { %bb11: Computable } 58; PTR16_IDX16-NEXT: Determining loop execution counts for: @trunc_ptr_to_i64 59; PTR16_IDX16-NEXT: Loop %bb11: Unpredictable backedge-taken count. 60; PTR16_IDX16-NEXT: Loop %bb11: Unpredictable max backedge-taken count. 61; PTR16_IDX16-NEXT: Loop %bb11: Unpredictable predicated backedge-taken count. 62; 63; PTR16_IDX32-LABEL: 'trunc_ptr_to_i64' 64; PTR16_IDX32-NEXT: Classifying expressions for: @trunc_ptr_to_i64 65; PTR16_IDX32-NEXT: %tmp = phi i32 [ 0, %bb ], [ %tmp18, %bb17 ] 66; PTR16_IDX32-NEXT: --> {0,+,2}<%bb11> U: [0,-1) S: [-2147483648,2147483647) Exits: <<Unknown>> LoopDispositions: { %bb11: Computable } 67; PTR16_IDX32-NEXT: %tmp12 = getelementptr i8, i8* %arg, i64 ptrtoint ([0 x i8]* @global to i64) 68; PTR16_IDX32-NEXT: --> ((trunc i64 ptrtoint ([0 x i8]* @global to i64) to i32) + %arg) U: [0,131071) S: [0,131071) Exits: ((trunc i64 ptrtoint ([0 x i8]* @global to i64) to i32) + %arg) LoopDispositions: { %bb11: Invariant } 69; PTR16_IDX32-NEXT: %tmp13 = bitcast i8* %tmp12 to i32* 70; PTR16_IDX32-NEXT: --> ((trunc i64 ptrtoint ([0 x i8]* @global to i64) to i32) + %arg) U: [0,131071) S: [0,131071) Exits: ((trunc i64 ptrtoint ([0 x i8]* @global to i64) to i32) + %arg) LoopDispositions: { %bb11: Invariant } 71; PTR16_IDX32-NEXT: %tmp14 = load i32, i32* %tmp13, align 4 72; PTR16_IDX32-NEXT: --> %tmp14 U: full-set S: full-set Exits: <<Unknown>> LoopDispositions: { %bb11: Variant } 73; PTR16_IDX32-NEXT: %tmp18 = add i32 %tmp, 2 74; PTR16_IDX32-NEXT: --> {2,+,2}<%bb11> U: [0,-1) S: [-2147483648,2147483647) Exits: <<Unknown>> LoopDispositions: { %bb11: Computable } 75; PTR16_IDX32-NEXT: Determining loop execution counts for: @trunc_ptr_to_i64 76; PTR16_IDX32-NEXT: Loop %bb11: Unpredictable backedge-taken count. 77; PTR16_IDX32-NEXT: Loop %bb11: Unpredictable max backedge-taken count. 78; PTR16_IDX32-NEXT: Loop %bb11: Unpredictable predicated backedge-taken count. 79; 80bb: 81 br label %bb11 82 83bb11: ; preds = %bb17, %bb 84 %tmp = phi i32 [ 0, %bb ], [ %tmp18, %bb17 ] 85 %tmp12 = getelementptr i8, i8* %arg, i64 ptrtoint ([0 x i8]* @global to i64) 86 %tmp13 = bitcast i8* %tmp12 to i32* 87 %tmp14 = load i32, i32* %tmp13, align 4 88 %tmp15 = icmp eq i32 %tmp14, 6 89 br i1 %tmp15, label %bb16, label %bb17 90 91bb16: ; preds = %bb11 92 ret i32* %arg10 93 94bb17: ; preds = %bb11 95 %tmp18 = add i32 %tmp, 2 96 br label %bb11 97} 98define hidden i32* @trunc_ptr_to_i32(i8* %arg, i32* %arg10) { 99; PTR64_IDX64-LABEL: 'trunc_ptr_to_i32' 100; PTR64_IDX64-NEXT: Classifying expressions for: @trunc_ptr_to_i32 101; PTR64_IDX64-NEXT: %tmp = phi i32 [ 0, %bb ], [ %tmp18, %bb17 ] 102; PTR64_IDX64-NEXT: --> {0,+,2}<%bb11> U: [0,-1) S: [-2147483648,2147483647) Exits: <<Unknown>> LoopDispositions: { %bb11: Computable } 103; PTR64_IDX64-NEXT: %tmp12 = getelementptr i8, i8* %arg, i32 ptrtoint ([0 x i8]* @global to i32) 104; PTR64_IDX64-NEXT: --> ((sext i32 (trunc i64 (ptrtoint [0 x i8]* @global to i64) to i32) to i64) + %arg) U: full-set S: full-set Exits: ((sext i32 (trunc i64 (ptrtoint [0 x i8]* @global to i64) to i32) to i64) + %arg) LoopDispositions: { %bb11: Invariant } 105; PTR64_IDX64-NEXT: %tmp13 = bitcast i8* %tmp12 to i32* 106; PTR64_IDX64-NEXT: --> ((sext i32 (trunc i64 (ptrtoint [0 x i8]* @global to i64) to i32) to i64) + %arg) U: full-set S: full-set Exits: ((sext i32 (trunc i64 (ptrtoint [0 x i8]* @global to i64) to i32) to i64) + %arg) LoopDispositions: { %bb11: Invariant } 107; PTR64_IDX64-NEXT: %tmp14 = load i32, i32* %tmp13, align 4 108; PTR64_IDX64-NEXT: --> %tmp14 U: full-set S: full-set Exits: <<Unknown>> LoopDispositions: { %bb11: Variant } 109; PTR64_IDX64-NEXT: %tmp18 = add i32 %tmp, 2 110; PTR64_IDX64-NEXT: --> {2,+,2}<%bb11> U: [0,-1) S: [-2147483648,2147483647) Exits: <<Unknown>> LoopDispositions: { %bb11: Computable } 111; PTR64_IDX64-NEXT: Determining loop execution counts for: @trunc_ptr_to_i32 112; PTR64_IDX64-NEXT: Loop %bb11: Unpredictable backedge-taken count. 113; PTR64_IDX64-NEXT: Loop %bb11: Unpredictable max backedge-taken count. 114; PTR64_IDX64-NEXT: Loop %bb11: Unpredictable predicated backedge-taken count. 115; 116; PTR64_IDX32-LABEL: 'trunc_ptr_to_i32' 117; PTR64_IDX32-NEXT: Classifying expressions for: @trunc_ptr_to_i32 118; PTR64_IDX32-NEXT: %tmp = phi i32 [ 0, %bb ], [ %tmp18, %bb17 ] 119; PTR64_IDX32-NEXT: --> {0,+,2}<%bb11> U: [0,-1) S: [-2147483648,2147483647) Exits: <<Unknown>> LoopDispositions: { %bb11: Computable } 120; PTR64_IDX32-NEXT: %tmp12 = getelementptr i8, i8* %arg, i32 ptrtoint ([0 x i8]* @global to i32) 121; PTR64_IDX32-NEXT: --> (ptrtoint ([0 x i8]* @global to i32) + %arg) U: full-set S: full-set Exits: (ptrtoint ([0 x i8]* @global to i32) + %arg) LoopDispositions: { %bb11: Invariant } 122; PTR64_IDX32-NEXT: %tmp13 = bitcast i8* %tmp12 to i32* 123; PTR64_IDX32-NEXT: --> (ptrtoint ([0 x i8]* @global to i32) + %arg) U: full-set S: full-set Exits: (ptrtoint ([0 x i8]* @global to i32) + %arg) LoopDispositions: { %bb11: Invariant } 124; PTR64_IDX32-NEXT: %tmp14 = load i32, i32* %tmp13, align 4 125; PTR64_IDX32-NEXT: --> %tmp14 U: full-set S: full-set Exits: <<Unknown>> LoopDispositions: { %bb11: Variant } 126; PTR64_IDX32-NEXT: %tmp18 = add i32 %tmp, 2 127; PTR64_IDX32-NEXT: --> {2,+,2}<%bb11> U: [0,-1) S: [-2147483648,2147483647) Exits: <<Unknown>> LoopDispositions: { %bb11: Computable } 128; PTR64_IDX32-NEXT: Determining loop execution counts for: @trunc_ptr_to_i32 129; PTR64_IDX32-NEXT: Loop %bb11: Unpredictable backedge-taken count. 130; PTR64_IDX32-NEXT: Loop %bb11: Unpredictable max backedge-taken count. 131; PTR64_IDX32-NEXT: Loop %bb11: Unpredictable predicated backedge-taken count. 132; 133; PTR16_IDX16-LABEL: 'trunc_ptr_to_i32' 134; PTR16_IDX16-NEXT: Classifying expressions for: @trunc_ptr_to_i32 135; PTR16_IDX16-NEXT: %tmp = phi i32 [ 0, %bb ], [ %tmp18, %bb17 ] 136; PTR16_IDX16-NEXT: --> {0,+,2}<%bb11> U: [0,-1) S: [-2147483648,2147483647) Exits: <<Unknown>> LoopDispositions: { %bb11: Computable } 137; PTR16_IDX16-NEXT: %tmp12 = getelementptr i8, i8* %arg, i32 ptrtoint ([0 x i8]* @global to i32) 138; PTR16_IDX16-NEXT: --> ((ptrtoint [0 x i8]* @global to i16) + %arg) U: full-set S: full-set Exits: ((ptrtoint [0 x i8]* @global to i16) + %arg) LoopDispositions: { %bb11: Invariant } 139; PTR16_IDX16-NEXT: %tmp13 = bitcast i8* %tmp12 to i32* 140; PTR16_IDX16-NEXT: --> ((ptrtoint [0 x i8]* @global to i16) + %arg) U: full-set S: full-set Exits: ((ptrtoint [0 x i8]* @global to i16) + %arg) LoopDispositions: { %bb11: Invariant } 141; PTR16_IDX16-NEXT: %tmp14 = load i32, i32* %tmp13, align 4 142; PTR16_IDX16-NEXT: --> %tmp14 U: full-set S: full-set Exits: <<Unknown>> LoopDispositions: { %bb11: Variant } 143; PTR16_IDX16-NEXT: %tmp18 = add i32 %tmp, 2 144; PTR16_IDX16-NEXT: --> {2,+,2}<%bb11> U: [0,-1) S: [-2147483648,2147483647) Exits: <<Unknown>> LoopDispositions: { %bb11: Computable } 145; PTR16_IDX16-NEXT: Determining loop execution counts for: @trunc_ptr_to_i32 146; PTR16_IDX16-NEXT: Loop %bb11: Unpredictable backedge-taken count. 147; PTR16_IDX16-NEXT: Loop %bb11: Unpredictable max backedge-taken count. 148; PTR16_IDX16-NEXT: Loop %bb11: Unpredictable predicated backedge-taken count. 149; 150; PTR16_IDX32-LABEL: 'trunc_ptr_to_i32' 151; PTR16_IDX32-NEXT: Classifying expressions for: @trunc_ptr_to_i32 152; PTR16_IDX32-NEXT: %tmp = phi i32 [ 0, %bb ], [ %tmp18, %bb17 ] 153; PTR16_IDX32-NEXT: --> {0,+,2}<%bb11> U: [0,-1) S: [-2147483648,2147483647) Exits: <<Unknown>> LoopDispositions: { %bb11: Computable } 154; PTR16_IDX32-NEXT: %tmp12 = getelementptr i8, i8* %arg, i32 ptrtoint ([0 x i8]* @global to i32) 155; PTR16_IDX32-NEXT: --> (ptrtoint ([0 x i8]* @global to i32) + %arg) U: [0,131071) S: [0,131071) Exits: (ptrtoint ([0 x i8]* @global to i32) + %arg) LoopDispositions: { %bb11: Invariant } 156; PTR16_IDX32-NEXT: %tmp13 = bitcast i8* %tmp12 to i32* 157; PTR16_IDX32-NEXT: --> (ptrtoint ([0 x i8]* @global to i32) + %arg) U: [0,131071) S: [0,131071) Exits: (ptrtoint ([0 x i8]* @global to i32) + %arg) LoopDispositions: { %bb11: Invariant } 158; PTR16_IDX32-NEXT: %tmp14 = load i32, i32* %tmp13, align 4 159; PTR16_IDX32-NEXT: --> %tmp14 U: full-set S: full-set Exits: <<Unknown>> LoopDispositions: { %bb11: Variant } 160; PTR16_IDX32-NEXT: %tmp18 = add i32 %tmp, 2 161; PTR16_IDX32-NEXT: --> {2,+,2}<%bb11> U: [0,-1) S: [-2147483648,2147483647) Exits: <<Unknown>> LoopDispositions: { %bb11: Computable } 162; PTR16_IDX32-NEXT: Determining loop execution counts for: @trunc_ptr_to_i32 163; PTR16_IDX32-NEXT: Loop %bb11: Unpredictable backedge-taken count. 164; PTR16_IDX32-NEXT: Loop %bb11: Unpredictable max backedge-taken count. 165; PTR16_IDX32-NEXT: Loop %bb11: Unpredictable predicated backedge-taken count. 166; 167bb: 168 br label %bb11 169 170bb11: ; preds = %bb17, %bb 171 %tmp = phi i32 [ 0, %bb ], [ %tmp18, %bb17 ] 172 %tmp12 = getelementptr i8, i8* %arg, i32 ptrtoint ([0 x i8]* @global to i32) 173 %tmp13 = bitcast i8* %tmp12 to i32* 174 %tmp14 = load i32, i32* %tmp13, align 4 175 %tmp15 = icmp eq i32 %tmp14, 6 176 br i1 %tmp15, label %bb16, label %bb17 177 178bb16: ; preds = %bb11 179 ret i32* %arg10 180 181bb17: ; preds = %bb11 182 %tmp18 = add i32 %tmp, 2 183 br label %bb11 184} 185define hidden i32* @trunc_ptr_to_i128(i8* %arg, i32* %arg10) { 186; PTR64_IDX64-LABEL: 'trunc_ptr_to_i128' 187; PTR64_IDX64-NEXT: Classifying expressions for: @trunc_ptr_to_i128 188; PTR64_IDX64-NEXT: %tmp = phi i32 [ 0, %bb ], [ %tmp18, %bb17 ] 189; PTR64_IDX64-NEXT: --> {0,+,2}<%bb11> U: [0,-1) S: [-2147483648,2147483647) Exits: <<Unknown>> LoopDispositions: { %bb11: Computable } 190; PTR64_IDX64-NEXT: %tmp12 = getelementptr i8, i8* %arg, i128 ptrtoint ([0 x i8]* @global to i128) 191; PTR64_IDX64-NEXT: --> ((ptrtoint [0 x i8]* @global to i64) + %arg) U: full-set S: full-set Exits: ((ptrtoint [0 x i8]* @global to i64) + %arg) LoopDispositions: { %bb11: Invariant } 192; PTR64_IDX64-NEXT: %tmp13 = bitcast i8* %tmp12 to i32* 193; PTR64_IDX64-NEXT: --> ((ptrtoint [0 x i8]* @global to i64) + %arg) U: full-set S: full-set Exits: ((ptrtoint [0 x i8]* @global to i64) + %arg) LoopDispositions: { %bb11: Invariant } 194; PTR64_IDX64-NEXT: %tmp14 = load i32, i32* %tmp13, align 4 195; PTR64_IDX64-NEXT: --> %tmp14 U: full-set S: full-set Exits: <<Unknown>> LoopDispositions: { %bb11: Variant } 196; PTR64_IDX64-NEXT: %tmp18 = add i32 %tmp, 2 197; PTR64_IDX64-NEXT: --> {2,+,2}<%bb11> U: [0,-1) S: [-2147483648,2147483647) Exits: <<Unknown>> LoopDispositions: { %bb11: Computable } 198; PTR64_IDX64-NEXT: Determining loop execution counts for: @trunc_ptr_to_i128 199; PTR64_IDX64-NEXT: Loop %bb11: Unpredictable backedge-taken count. 200; PTR64_IDX64-NEXT: Loop %bb11: Unpredictable max backedge-taken count. 201; PTR64_IDX64-NEXT: Loop %bb11: Unpredictable predicated backedge-taken count. 202; 203; PTR64_IDX32-LABEL: 'trunc_ptr_to_i128' 204; PTR64_IDX32-NEXT: Classifying expressions for: @trunc_ptr_to_i128 205; PTR64_IDX32-NEXT: %tmp = phi i32 [ 0, %bb ], [ %tmp18, %bb17 ] 206; PTR64_IDX32-NEXT: --> {0,+,2}<%bb11> U: [0,-1) S: [-2147483648,2147483647) Exits: <<Unknown>> LoopDispositions: { %bb11: Computable } 207; PTR64_IDX32-NEXT: %tmp12 = getelementptr i8, i8* %arg, i128 ptrtoint ([0 x i8]* @global to i128) 208; PTR64_IDX32-NEXT: --> ((trunc i128 ptrtoint ([0 x i8]* @global to i128) to i32) + %arg) U: full-set S: full-set Exits: ((trunc i128 ptrtoint ([0 x i8]* @global to i128) to i32) + %arg) LoopDispositions: { %bb11: Invariant } 209; PTR64_IDX32-NEXT: %tmp13 = bitcast i8* %tmp12 to i32* 210; PTR64_IDX32-NEXT: --> ((trunc i128 ptrtoint ([0 x i8]* @global to i128) to i32) + %arg) U: full-set S: full-set Exits: ((trunc i128 ptrtoint ([0 x i8]* @global to i128) to i32) + %arg) LoopDispositions: { %bb11: Invariant } 211; PTR64_IDX32-NEXT: %tmp14 = load i32, i32* %tmp13, align 4 212; PTR64_IDX32-NEXT: --> %tmp14 U: full-set S: full-set Exits: <<Unknown>> LoopDispositions: { %bb11: Variant } 213; PTR64_IDX32-NEXT: %tmp18 = add i32 %tmp, 2 214; PTR64_IDX32-NEXT: --> {2,+,2}<%bb11> U: [0,-1) S: [-2147483648,2147483647) Exits: <<Unknown>> LoopDispositions: { %bb11: Computable } 215; PTR64_IDX32-NEXT: Determining loop execution counts for: @trunc_ptr_to_i128 216; PTR64_IDX32-NEXT: Loop %bb11: Unpredictable backedge-taken count. 217; PTR64_IDX32-NEXT: Loop %bb11: Unpredictable max backedge-taken count. 218; PTR64_IDX32-NEXT: Loop %bb11: Unpredictable predicated backedge-taken count. 219; 220; PTR16_IDX16-LABEL: 'trunc_ptr_to_i128' 221; PTR16_IDX16-NEXT: Classifying expressions for: @trunc_ptr_to_i128 222; PTR16_IDX16-NEXT: %tmp = phi i32 [ 0, %bb ], [ %tmp18, %bb17 ] 223; PTR16_IDX16-NEXT: --> {0,+,2}<%bb11> U: [0,-1) S: [-2147483648,2147483647) Exits: <<Unknown>> LoopDispositions: { %bb11: Computable } 224; PTR16_IDX16-NEXT: %tmp12 = getelementptr i8, i8* %arg, i128 ptrtoint ([0 x i8]* @global to i128) 225; PTR16_IDX16-NEXT: --> ((ptrtoint [0 x i8]* @global to i16) + %arg) U: full-set S: full-set Exits: ((ptrtoint [0 x i8]* @global to i16) + %arg) LoopDispositions: { %bb11: Invariant } 226; PTR16_IDX16-NEXT: %tmp13 = bitcast i8* %tmp12 to i32* 227; PTR16_IDX16-NEXT: --> ((ptrtoint [0 x i8]* @global to i16) + %arg) U: full-set S: full-set Exits: ((ptrtoint [0 x i8]* @global to i16) + %arg) LoopDispositions: { %bb11: Invariant } 228; PTR16_IDX16-NEXT: %tmp14 = load i32, i32* %tmp13, align 4 229; PTR16_IDX16-NEXT: --> %tmp14 U: full-set S: full-set Exits: <<Unknown>> LoopDispositions: { %bb11: Variant } 230; PTR16_IDX16-NEXT: %tmp18 = add i32 %tmp, 2 231; PTR16_IDX16-NEXT: --> {2,+,2}<%bb11> U: [0,-1) S: [-2147483648,2147483647) Exits: <<Unknown>> LoopDispositions: { %bb11: Computable } 232; PTR16_IDX16-NEXT: Determining loop execution counts for: @trunc_ptr_to_i128 233; PTR16_IDX16-NEXT: Loop %bb11: Unpredictable backedge-taken count. 234; PTR16_IDX16-NEXT: Loop %bb11: Unpredictable max backedge-taken count. 235; PTR16_IDX16-NEXT: Loop %bb11: Unpredictable predicated backedge-taken count. 236; 237; PTR16_IDX32-LABEL: 'trunc_ptr_to_i128' 238; PTR16_IDX32-NEXT: Classifying expressions for: @trunc_ptr_to_i128 239; PTR16_IDX32-NEXT: %tmp = phi i32 [ 0, %bb ], [ %tmp18, %bb17 ] 240; PTR16_IDX32-NEXT: --> {0,+,2}<%bb11> U: [0,-1) S: [-2147483648,2147483647) Exits: <<Unknown>> LoopDispositions: { %bb11: Computable } 241; PTR16_IDX32-NEXT: %tmp12 = getelementptr i8, i8* %arg, i128 ptrtoint ([0 x i8]* @global to i128) 242; PTR16_IDX32-NEXT: --> ((trunc i128 ptrtoint ([0 x i8]* @global to i128) to i32) + %arg) U: [0,131071) S: [0,131071) Exits: ((trunc i128 ptrtoint ([0 x i8]* @global to i128) to i32) + %arg) LoopDispositions: { %bb11: Invariant } 243; PTR16_IDX32-NEXT: %tmp13 = bitcast i8* %tmp12 to i32* 244; PTR16_IDX32-NEXT: --> ((trunc i128 ptrtoint ([0 x i8]* @global to i128) to i32) + %arg) U: [0,131071) S: [0,131071) Exits: ((trunc i128 ptrtoint ([0 x i8]* @global to i128) to i32) + %arg) LoopDispositions: { %bb11: Invariant } 245; PTR16_IDX32-NEXT: %tmp14 = load i32, i32* %tmp13, align 4 246; PTR16_IDX32-NEXT: --> %tmp14 U: full-set S: full-set Exits: <<Unknown>> LoopDispositions: { %bb11: Variant } 247; PTR16_IDX32-NEXT: %tmp18 = add i32 %tmp, 2 248; PTR16_IDX32-NEXT: --> {2,+,2}<%bb11> U: [0,-1) S: [-2147483648,2147483647) Exits: <<Unknown>> LoopDispositions: { %bb11: Computable } 249; PTR16_IDX32-NEXT: Determining loop execution counts for: @trunc_ptr_to_i128 250; PTR16_IDX32-NEXT: Loop %bb11: Unpredictable backedge-taken count. 251; PTR16_IDX32-NEXT: Loop %bb11: Unpredictable max backedge-taken count. 252; PTR16_IDX32-NEXT: Loop %bb11: Unpredictable predicated backedge-taken count. 253; 254bb: 255 br label %bb11 256 257bb11: ; preds = %bb17, %bb 258 %tmp = phi i32 [ 0, %bb ], [ %tmp18, %bb17 ] 259 %tmp12 = getelementptr i8, i8* %arg, i128 ptrtoint ([0 x i8]* @global to i128) 260 %tmp13 = bitcast i8* %tmp12 to i32* 261 %tmp14 = load i32, i32* %tmp13, align 4 262 %tmp15 = icmp eq i32 %tmp14, 6 263 br i1 %tmp15, label %bb16, label %bb17 264 265bb16: ; preds = %bb11 266 ret i32* %arg10 267 268bb17: ; preds = %bb11 269 %tmp18 = add i32 %tmp, 2 270 br label %bb11 271} 272 273define void @zext_ptr_to_i32(i32 %arg, i32 %arg6) { 274; PTR64_IDX64-LABEL: 'zext_ptr_to_i32' 275; PTR64_IDX64-NEXT: Classifying expressions for: @zext_ptr_to_i32 276; PTR64_IDX64-NEXT: %tmp = sub i32 %arg, ptrtoint ([0 x i8]* @global to i32) 277; PTR64_IDX64-NEXT: --> ((-1 * (trunc i64 (ptrtoint [0 x i8]* @global to i64) to i32)) + %arg) U: full-set S: full-set Exits: ((-1 * (trunc i64 (ptrtoint [0 x i8]* @global to i64) to i32)) + %arg) LoopDispositions: { %bb7: Invariant } 278; PTR64_IDX64-NEXT: %tmp9 = select i1 %tmp8, i16 0, i16 1 279; PTR64_IDX64-NEXT: --> %tmp9 U: [0,2) S: [0,2) Exits: <<Unknown>> LoopDispositions: { %bb7: Variant } 280; PTR64_IDX64-NEXT: Determining loop execution counts for: @zext_ptr_to_i32 281; PTR64_IDX64-NEXT: Loop %bb7: Unpredictable backedge-taken count. 282; PTR64_IDX64-NEXT: Loop %bb7: Unpredictable max backedge-taken count. 283; PTR64_IDX64-NEXT: Loop %bb7: Unpredictable predicated backedge-taken count. 284; 285; PTR64_IDX32-LABEL: 'zext_ptr_to_i32' 286; PTR64_IDX32-NEXT: Classifying expressions for: @zext_ptr_to_i32 287; PTR64_IDX32-NEXT: %tmp = sub i32 %arg, ptrtoint ([0 x i8]* @global to i32) 288; PTR64_IDX32-NEXT: --> ((-1 * ptrtoint ([0 x i8]* @global to i32)) + %arg) U: full-set S: full-set Exits: ((-1 * ptrtoint ([0 x i8]* @global to i32)) + %arg) LoopDispositions: { %bb7: Invariant } 289; PTR64_IDX32-NEXT: %tmp9 = select i1 %tmp8, i16 0, i16 1 290; PTR64_IDX32-NEXT: --> %tmp9 U: [0,2) S: [0,2) Exits: <<Unknown>> LoopDispositions: { %bb7: Variant } 291; PTR64_IDX32-NEXT: Determining loop execution counts for: @zext_ptr_to_i32 292; PTR64_IDX32-NEXT: Loop %bb7: Unpredictable backedge-taken count. 293; PTR64_IDX32-NEXT: Loop %bb7: Unpredictable max backedge-taken count. 294; PTR64_IDX32-NEXT: Loop %bb7: Unpredictable predicated backedge-taken count. 295; 296; PTR16_IDX16-LABEL: 'zext_ptr_to_i32' 297; PTR16_IDX16-NEXT: Classifying expressions for: @zext_ptr_to_i32 298; PTR16_IDX16-NEXT: %tmp = sub i32 %arg, ptrtoint ([0 x i8]* @global to i32) 299; PTR16_IDX16-NEXT: --> ((-1 * (zext i16 (ptrtoint [0 x i8]* @global to i16) to i32))<nsw> + %arg) U: full-set S: full-set Exits: ((-1 * (zext i16 (ptrtoint [0 x i8]* @global to i16) to i32))<nsw> + %arg) LoopDispositions: { %bb7: Invariant } 300; PTR16_IDX16-NEXT: %tmp9 = select i1 %tmp8, i16 0, i16 1 301; PTR16_IDX16-NEXT: --> %tmp9 U: [0,2) S: [0,2) Exits: <<Unknown>> LoopDispositions: { %bb7: Variant } 302; PTR16_IDX16-NEXT: Determining loop execution counts for: @zext_ptr_to_i32 303; PTR16_IDX16-NEXT: Loop %bb7: Unpredictable backedge-taken count. 304; PTR16_IDX16-NEXT: Loop %bb7: Unpredictable max backedge-taken count. 305; PTR16_IDX16-NEXT: Loop %bb7: Unpredictable predicated backedge-taken count. 306; 307; PTR16_IDX32-LABEL: 'zext_ptr_to_i32' 308; PTR16_IDX32-NEXT: Classifying expressions for: @zext_ptr_to_i32 309; PTR16_IDX32-NEXT: %tmp = sub i32 %arg, ptrtoint ([0 x i8]* @global to i32) 310; PTR16_IDX32-NEXT: --> ((-1 * ptrtoint ([0 x i8]* @global to i32))<nsw> + %arg) U: full-set S: full-set Exits: ((-1 * ptrtoint ([0 x i8]* @global to i32))<nsw> + %arg) LoopDispositions: { %bb7: Invariant } 311; PTR16_IDX32-NEXT: %tmp9 = select i1 %tmp8, i16 0, i16 1 312; PTR16_IDX32-NEXT: --> %tmp9 U: [0,2) S: [0,2) Exits: <<Unknown>> LoopDispositions: { %bb7: Variant } 313; PTR16_IDX32-NEXT: Determining loop execution counts for: @zext_ptr_to_i32 314; PTR16_IDX32-NEXT: Loop %bb7: Unpredictable backedge-taken count. 315; PTR16_IDX32-NEXT: Loop %bb7: Unpredictable max backedge-taken count. 316; PTR16_IDX32-NEXT: Loop %bb7: Unpredictable predicated backedge-taken count. 317; 318bb: 319 br label %bb7 320 321bb7: ; preds = %bb7, %bb 322 %tmp = sub i32 %arg, ptrtoint ([0 x i8]* @global to i32) 323 %tmp8 = icmp eq i32 %tmp, %arg6 324 %tmp9 = select i1 %tmp8, i16 0, i16 1 325 call void @use16(i16 %tmp9) 326 br i1 %tmp8, label %bb7, label %bb10 327 328bb10: ; preds = %bb7 329 ret void 330} 331 332define void @sext_to_i32(i32 %arg, i32 %arg6) { 333; PTR64_IDX64-LABEL: 'sext_to_i32' 334; PTR64_IDX64-NEXT: Classifying expressions for: @sext_to_i32 335; PTR64_IDX64-NEXT: %tmp = sub i32 %arg, sext (i16 ptrtoint ([0 x i8]* @global to i16) to i32) 336; PTR64_IDX64-NEXT: --> ((-1 * (sext i16 (trunc i64 (ptrtoint [0 x i8]* @global to i64) to i16) to i32))<nsw> + %arg) U: full-set S: full-set Exits: ((-1 * (sext i16 (trunc i64 (ptrtoint [0 x i8]* @global to i64) to i16) to i32))<nsw> + %arg) LoopDispositions: { %bb7: Invariant } 337; PTR64_IDX64-NEXT: %tmp9 = select i1 %tmp8, i16 0, i16 1 338; PTR64_IDX64-NEXT: --> %tmp9 U: [0,2) S: [0,2) Exits: <<Unknown>> LoopDispositions: { %bb7: Variant } 339; PTR64_IDX64-NEXT: Determining loop execution counts for: @sext_to_i32 340; PTR64_IDX64-NEXT: Loop %bb7: Unpredictable backedge-taken count. 341; PTR64_IDX64-NEXT: Loop %bb7: Unpredictable max backedge-taken count. 342; PTR64_IDX64-NEXT: Loop %bb7: Unpredictable predicated backedge-taken count. 343; 344; PTR64_IDX32-LABEL: 'sext_to_i32' 345; PTR64_IDX32-NEXT: Classifying expressions for: @sext_to_i32 346; PTR64_IDX32-NEXT: %tmp = sub i32 %arg, sext (i16 ptrtoint ([0 x i8]* @global to i16) to i32) 347; PTR64_IDX32-NEXT: --> ((-1 * (sext i16 ptrtoint ([0 x i8]* @global to i16) to i32))<nsw> + %arg) U: full-set S: full-set Exits: ((-1 * (sext i16 ptrtoint ([0 x i8]* @global to i16) to i32))<nsw> + %arg) LoopDispositions: { %bb7: Invariant } 348; PTR64_IDX32-NEXT: %tmp9 = select i1 %tmp8, i16 0, i16 1 349; PTR64_IDX32-NEXT: --> %tmp9 U: [0,2) S: [0,2) Exits: <<Unknown>> LoopDispositions: { %bb7: Variant } 350; PTR64_IDX32-NEXT: Determining loop execution counts for: @sext_to_i32 351; PTR64_IDX32-NEXT: Loop %bb7: Unpredictable backedge-taken count. 352; PTR64_IDX32-NEXT: Loop %bb7: Unpredictable max backedge-taken count. 353; PTR64_IDX32-NEXT: Loop %bb7: Unpredictable predicated backedge-taken count. 354; 355; PTR16_IDX16-LABEL: 'sext_to_i32' 356; PTR16_IDX16-NEXT: Classifying expressions for: @sext_to_i32 357; PTR16_IDX16-NEXT: %tmp = sub i32 %arg, sext (i16 ptrtoint ([0 x i8]* @global to i16) to i32) 358; PTR16_IDX16-NEXT: --> ((-1 * (sext i16 (ptrtoint [0 x i8]* @global to i16) to i32))<nsw> + %arg) U: full-set S: full-set Exits: ((-1 * (sext i16 (ptrtoint [0 x i8]* @global to i16) to i32))<nsw> + %arg) LoopDispositions: { %bb7: Invariant } 359; PTR16_IDX16-NEXT: %tmp9 = select i1 %tmp8, i16 0, i16 1 360; PTR16_IDX16-NEXT: --> %tmp9 U: [0,2) S: [0,2) Exits: <<Unknown>> LoopDispositions: { %bb7: Variant } 361; PTR16_IDX16-NEXT: Determining loop execution counts for: @sext_to_i32 362; PTR16_IDX16-NEXT: Loop %bb7: Unpredictable backedge-taken count. 363; PTR16_IDX16-NEXT: Loop %bb7: Unpredictable max backedge-taken count. 364; PTR16_IDX16-NEXT: Loop %bb7: Unpredictable predicated backedge-taken count. 365; 366; PTR16_IDX32-LABEL: 'sext_to_i32' 367; PTR16_IDX32-NEXT: Classifying expressions for: @sext_to_i32 368; PTR16_IDX32-NEXT: %tmp = sub i32 %arg, sext (i16 ptrtoint ([0 x i8]* @global to i16) to i32) 369; PTR16_IDX32-NEXT: --> ((-1 * (sext i16 ptrtoint ([0 x i8]* @global to i16) to i32))<nsw> + %arg) U: full-set S: full-set Exits: ((-1 * (sext i16 ptrtoint ([0 x i8]* @global to i16) to i32))<nsw> + %arg) LoopDispositions: { %bb7: Invariant } 370; PTR16_IDX32-NEXT: %tmp9 = select i1 %tmp8, i16 0, i16 1 371; PTR16_IDX32-NEXT: --> %tmp9 U: [0,2) S: [0,2) Exits: <<Unknown>> LoopDispositions: { %bb7: Variant } 372; PTR16_IDX32-NEXT: Determining loop execution counts for: @sext_to_i32 373; PTR16_IDX32-NEXT: Loop %bb7: Unpredictable backedge-taken count. 374; PTR16_IDX32-NEXT: Loop %bb7: Unpredictable max backedge-taken count. 375; PTR16_IDX32-NEXT: Loop %bb7: Unpredictable predicated backedge-taken count. 376; 377bb: 378 br label %bb7 379 380bb7: ; preds = %bb7, %bb 381 %tmp = sub i32 %arg, sext (i16 ptrtoint ([0 x i8]* @global to i16) to i32) 382 %tmp8 = icmp eq i32 %tmp, %arg6 383 %tmp9 = select i1 %tmp8, i16 0, i16 1 384 call void @use16(i16 %tmp9) 385 br i1 %tmp8, label %bb7, label %bb10 386 387bb10: ; preds = %bb7 388 ret void 389} 390 391define i64 @sext_like_noop(i32 %n) { 392; PTR64_IDX64-LABEL: 'sext_like_noop' 393; PTR64_IDX64-NEXT: Classifying expressions for: @sext_like_noop 394; PTR64_IDX64-NEXT: %ii = sext i32 %i to i64 395; PTR64_IDX64-NEXT: --> (sext i32 {1,+,1}<nuw><%for.body> to i64) U: [-2147483648,2147483648) S: [-2147483648,2147483648) --> (sext i32 (-1 + (trunc i64 (ptrtoint i64 (i32)* @sext_like_noop to i64) to i32)) to i64) U: [-2147483648,2147483648) S: [-2147483648,2147483648) 396; PTR64_IDX64-NEXT: %div = sdiv i64 55555, %ii 397; PTR64_IDX64-NEXT: --> %div U: full-set S: full-set 398; PTR64_IDX64-NEXT: %i = phi i32 [ %inc, %for.body ], [ 1, %entry ] 399; PTR64_IDX64-NEXT: --> {1,+,1}<nuw><%for.body> U: [1,0) S: [1,0) Exits: (-1 + (trunc i64 (ptrtoint i64 (i32)* @sext_like_noop to i64) to i32)) LoopDispositions: { %for.body: Computable } 400; PTR64_IDX64-NEXT: %inc = add nuw i32 %i, 1 401; PTR64_IDX64-NEXT: --> {2,+,1}<nuw><%for.body> U: [2,0) S: [2,0) Exits: (trunc i64 (ptrtoint i64 (i32)* @sext_like_noop to i64) to i32) LoopDispositions: { %for.body: Computable } 402; PTR64_IDX64-NEXT: Determining loop execution counts for: @sext_like_noop 403; PTR64_IDX64-NEXT: Loop %for.body: backedge-taken count is (-2 + (trunc i64 (ptrtoint i64 (i32)* @sext_like_noop to i64) to i32)) 404; PTR64_IDX64-NEXT: Loop %for.body: max backedge-taken count is -1 405; PTR64_IDX64-NEXT: Loop %for.body: Predicated backedge-taken count is (-2 + (trunc i64 (ptrtoint i64 (i32)* @sext_like_noop to i64) to i32)) 406; PTR64_IDX64-NEXT: Predicates: 407; PTR64_IDX64: Loop %for.body: Trip multiple is 1 408; 409; PTR64_IDX32-LABEL: 'sext_like_noop' 410; PTR64_IDX32-NEXT: Classifying expressions for: @sext_like_noop 411; PTR64_IDX32-NEXT: %ii = sext i32 %i to i64 412; PTR64_IDX32-NEXT: --> (sext i32 {1,+,1}<nuw><%for.body> to i64) U: [-2147483648,2147483648) S: [-2147483648,2147483648) --> (sext i32 (-1 + ptrtoint (i64 (i32)* @sext_like_noop to i32)) to i64) U: [-2147483648,2147483648) S: [-2147483648,2147483648) 413; PTR64_IDX32-NEXT: %div = sdiv i64 55555, %ii 414; PTR64_IDX32-NEXT: --> %div U: full-set S: full-set 415; PTR64_IDX32-NEXT: %i = phi i32 [ %inc, %for.body ], [ 1, %entry ] 416; PTR64_IDX32-NEXT: --> {1,+,1}<nuw><%for.body> U: [1,0) S: [1,0) Exits: (-1 + ptrtoint (i64 (i32)* @sext_like_noop to i32)) LoopDispositions: { %for.body: Computable } 417; PTR64_IDX32-NEXT: %inc = add nuw i32 %i, 1 418; PTR64_IDX32-NEXT: --> {2,+,1}<nuw><%for.body> U: [2,0) S: [2,0) Exits: ptrtoint (i64 (i32)* @sext_like_noop to i32) LoopDispositions: { %for.body: Computable } 419; PTR64_IDX32-NEXT: Determining loop execution counts for: @sext_like_noop 420; PTR64_IDX32-NEXT: Loop %for.body: backedge-taken count is (-2 + ptrtoint (i64 (i32)* @sext_like_noop to i32)) 421; PTR64_IDX32-NEXT: Loop %for.body: max backedge-taken count is -1 422; PTR64_IDX32-NEXT: Loop %for.body: Predicated backedge-taken count is (-2 + ptrtoint (i64 (i32)* @sext_like_noop to i32)) 423; PTR64_IDX32-NEXT: Predicates: 424; PTR64_IDX32: Loop %for.body: Trip multiple is 1 425; 426; PTR16_IDX16-LABEL: 'sext_like_noop' 427; PTR16_IDX16-NEXT: Classifying expressions for: @sext_like_noop 428; PTR16_IDX16-NEXT: %ii = sext i32 %i to i64 429; PTR16_IDX16-NEXT: --> (sext i32 {1,+,1}<nuw><%for.body> to i64) U: [-2147483648,2147483648) S: [-2147483648,2147483648) --> (-1 + (zext i16 (ptrtoint i64 (i32)* @sext_like_noop to i16) to i64))<nsw> U: [-1,65535) S: [-1,65535) 430; PTR16_IDX16-NEXT: %div = sdiv i64 55555, %ii 431; PTR16_IDX16-NEXT: --> %div U: full-set S: full-set 432; PTR16_IDX16-NEXT: %i = phi i32 [ %inc, %for.body ], [ 1, %entry ] 433; PTR16_IDX16-NEXT: --> {1,+,1}<nuw><%for.body> U: [1,0) S: [1,0) Exits: (-1 + (zext i16 (ptrtoint i64 (i32)* @sext_like_noop to i16) to i32))<nsw> LoopDispositions: { %for.body: Computable } 434; PTR16_IDX16-NEXT: %inc = add nuw i32 %i, 1 435; PTR16_IDX16-NEXT: --> {2,+,1}<nuw><%for.body> U: [2,0) S: [2,0) Exits: (zext i16 (ptrtoint i64 (i32)* @sext_like_noop to i16) to i32) LoopDispositions: { %for.body: Computable } 436; PTR16_IDX16-NEXT: Determining loop execution counts for: @sext_like_noop 437; PTR16_IDX16-NEXT: Loop %for.body: backedge-taken count is (-2 + (zext i16 (ptrtoint i64 (i32)* @sext_like_noop to i16) to i32))<nsw> 438; PTR16_IDX16-NEXT: Loop %for.body: max backedge-taken count is -1 439; PTR16_IDX16-NEXT: Loop %for.body: Predicated backedge-taken count is (-2 + (zext i16 (ptrtoint i64 (i32)* @sext_like_noop to i16) to i32))<nsw> 440; PTR16_IDX16-NEXT: Predicates: 441; PTR16_IDX16: Loop %for.body: Trip multiple is 1 442; 443; PTR16_IDX32-LABEL: 'sext_like_noop' 444; PTR16_IDX32-NEXT: Classifying expressions for: @sext_like_noop 445; PTR16_IDX32-NEXT: %ii = sext i32 %i to i64 446; PTR16_IDX32-NEXT: --> (sext i32 {1,+,1}<nuw><%for.body> to i64) U: [-2147483648,2147483648) S: [-2147483648,2147483648) --> (-1 + (zext i32 ptrtoint (i64 (i32)* @sext_like_noop to i32) to i64))<nsw> U: [-1,65535) S: [-1,65535) 447; PTR16_IDX32-NEXT: %div = sdiv i64 55555, %ii 448; PTR16_IDX32-NEXT: --> %div U: full-set S: full-set 449; PTR16_IDX32-NEXT: %i = phi i32 [ %inc, %for.body ], [ 1, %entry ] 450; PTR16_IDX32-NEXT: --> {1,+,1}<nuw><%for.body> U: [1,0) S: [1,0) Exits: (-1 + ptrtoint (i64 (i32)* @sext_like_noop to i32))<nsw> LoopDispositions: { %for.body: Computable } 451; PTR16_IDX32-NEXT: %inc = add nuw i32 %i, 1 452; PTR16_IDX32-NEXT: --> {2,+,1}<nuw><%for.body> U: [2,0) S: [2,0) Exits: ptrtoint (i64 (i32)* @sext_like_noop to i32) LoopDispositions: { %for.body: Computable } 453; PTR16_IDX32-NEXT: Determining loop execution counts for: @sext_like_noop 454; PTR16_IDX32-NEXT: Loop %for.body: backedge-taken count is (-2 + ptrtoint (i64 (i32)* @sext_like_noop to i32))<nsw> 455; PTR16_IDX32-NEXT: Loop %for.body: max backedge-taken count is -1 456; PTR16_IDX32-NEXT: Loop %for.body: Predicated backedge-taken count is (-2 + ptrtoint (i64 (i32)* @sext_like_noop to i32))<nsw> 457; PTR16_IDX32-NEXT: Predicates: 458; PTR16_IDX32: Loop %for.body: Trip multiple is 1 459; 460entry: 461 %cmp6 = icmp sgt i32 %n, 1 462 br label %for.body 463 464for.cond.cleanup: 465 %ii = sext i32 %i to i64 466 %div = sdiv i64 55555, %ii 467 ret i64 %div 468 469for.body: 470 %i = phi i32 [ %inc, %for.body ], [ 1, %entry ] 471 %inc = add nuw i32 %i, 1 472 %exitcond = icmp eq i32 %inc, ptrtoint (i64 (i32)* @sext_like_noop to i32) 473 br i1 %exitcond, label %for.cond.cleanup, label %for.body 474} 475declare void @f(i64) 476