comparison polly/test/ScopInfo/invariant_load_complex_condition.ll @ 252:1f2b6ac9f198 llvm-original

LLVM16-1
author Shinji KONO <kono@ie.u-ryukyu.ac.jp>
date Fri, 18 Aug 2023 09:04:13 +0900
parents c4bab56944e8
children
comparison
equal deleted inserted replaced
237:c80f45b162ad 252:1f2b6ac9f198
1 ; RUN: opt %loadPolly -polly-stmt-granularity=bb -S -polly-print-scops -disable-output \ 1 ; RUN: opt %loadPolly -polly-stmt-granularity=bb -S -polly-print-scops -disable-output \
2 ; RUN: -polly-invariant-load-hoisting=true < %s | FileCheck %s 2 ; RUN: -polly-invariant-load-hoisting=true < %s | FileCheck %s
3 3
4 target datalayout = "e-m:e-i64:64-f80:128-n8:16:32:64-S128" 4 target datalayout = "e-m:e-i64:64-f80:128-n8:16:32:64-S128"
5 5
6 %struct.IP = type { i32****, i32***, %struct.P, %struct.S, %struct.m } 6 %struct.IP = type { ptr, ptr, %struct.P, %struct.S, %struct.m }
7 %struct.P = type { i32 } 7 %struct.P = type { i32 }
8 %struct.S = type { i32 } 8 %struct.S = type { i32 }
9 %struct.D = type { i32 } 9 %struct.D = type { i32 }
10 %struct.B = type { i32 } 10 %struct.B = type { i32 }
11 %struct.E = type { i32 } 11 %struct.E = type { i32 }
30 ; CHECK-NEXT: [block_y, block_x] -> { Stmt_entry_split[] -> MemRef4[o0] : (-3 <= block_y < 0 and block_x <= -4 and -8 + block_x - 4o0 <= 8*floor((-1 + block_x)/8) <= -5 + block_x - 4o0) or (-3 <= block_y < 0 and block_x >= 0 and -3 + block_x - 4o0 <= 8*floor((block_x)/8) <= block_x - 4o0) or (block_y <= -4 and block_x <= -4 and -16 + block_x - 4o0 - 8*floor((-1 + block_x)/8) + 8*floor((-1 + block_y)/4) <= 16*floor((-1 + block_y)/8) <= -13 + block_x - 4o0 - 8*floor((-1 + block_x)/8) + 8*floor((-1 + block_y)/4)) or (block_y <= -4 and block_x >= 0 and -11 + block_x - 4o0 - 8*floor((block_x)/8) + 8*floor((-1 + block_y)/4) <= 16*floor((-1 + block_y)/8) <= -8 + block_x - 4o0 - 8*floor((block_x)/8) + 8*floor((-1 + block_y)/4)) or (block_y >= 0 and block_x <= -4 and -8 + block_x - 4o0 - 8*floor((-1 + block_x)/8) + 8*floor((block_y)/4) <= 16*floor((block_y)/8) <= -5 + block_x - 4o0 - 8*floor((-1 + block_x)/8) + 8*floor((block_y)/4)) or (block_y >= 0 and block_x >= 0 and -3 + block_x - 4o0 - 8*floor((block_x)/8) + 8*floor((block_y)/4) <= 16*floor((block_y)/8) <= block_x - 4o0 - 8*floor((block_x)/8) + 8*floor((block_y)/4)) or (4*floor((block_y)/8) = -o0 + 2*floor((block_y)/4) and block_y >= 0 and -3 <= block_x < 0 and 4*floor((block_y)/4) >= -7 + block_y + 2o0 and 4*floor((block_y)/4) <= block_y + 2o0) or (4*floor((-1 + block_y)/8) = -2 - o0 + 2*floor((-1 + block_y)/4) and block_y <= -4 and -3 <= block_x < 0 and 4*floor((-1 + block_y)/4) >= -4 + block_y + 2o0 and 4*floor((-1 + block_y)/4) <= 3 + block_y + 2o0); Stmt_entry_split[] -> MemRef4[0] : -3 <= block_y < 0 and -3 <= block_x < 0 }; 30 ; CHECK-NEXT: [block_y, block_x] -> { Stmt_entry_split[] -> MemRef4[o0] : (-3 <= block_y < 0 and block_x <= -4 and -8 + block_x - 4o0 <= 8*floor((-1 + block_x)/8) <= -5 + block_x - 4o0) or (-3 <= block_y < 0 and block_x >= 0 and -3 + block_x - 4o0 <= 8*floor((block_x)/8) <= block_x - 4o0) or (block_y <= -4 and block_x <= -4 and -16 + block_x - 4o0 - 8*floor((-1 + block_x)/8) + 8*floor((-1 + block_y)/4) <= 16*floor((-1 + block_y)/8) <= -13 + block_x - 4o0 - 8*floor((-1 + block_x)/8) + 8*floor((-1 + block_y)/4)) or (block_y <= -4 and block_x >= 0 and -11 + block_x - 4o0 - 8*floor((block_x)/8) + 8*floor((-1 + block_y)/4) <= 16*floor((-1 + block_y)/8) <= -8 + block_x - 4o0 - 8*floor((block_x)/8) + 8*floor((-1 + block_y)/4)) or (block_y >= 0 and block_x <= -4 and -8 + block_x - 4o0 - 8*floor((-1 + block_x)/8) + 8*floor((block_y)/4) <= 16*floor((block_y)/8) <= -5 + block_x - 4o0 - 8*floor((-1 + block_x)/8) + 8*floor((block_y)/4)) or (block_y >= 0 and block_x >= 0 and -3 + block_x - 4o0 - 8*floor((block_x)/8) + 8*floor((block_y)/4) <= 16*floor((block_y)/8) <= block_x - 4o0 - 8*floor((block_x)/8) + 8*floor((block_y)/4)) or (4*floor((block_y)/8) = -o0 + 2*floor((block_y)/4) and block_y >= 0 and -3 <= block_x < 0 and 4*floor((block_y)/4) >= -7 + block_y + 2o0 and 4*floor((block_y)/4) <= block_y + 2o0) or (4*floor((-1 + block_y)/8) = -2 - o0 + 2*floor((-1 + block_y)/4) and block_y <= -4 and -3 <= block_x < 0 and 4*floor((-1 + block_y)/4) >= -4 + block_y + 2o0 and 4*floor((-1 + block_y)/4) <= 3 + block_y + 2o0); Stmt_entry_split[] -> MemRef4[0] : -3 <= block_y < 0 and -3 <= block_x < 0 };
31 ; CHECK-NEXT: MustWriteAccess := [Reduction Type: NONE] [Scalar: 1] 31 ; CHECK-NEXT: MustWriteAccess := [Reduction Type: NONE] [Scalar: 1]
32 ; CHECK-NEXT: [block_y, block_x] -> { Stmt_entry_split[] -> MemRef0[] }; 32 ; CHECK-NEXT: [block_y, block_x] -> { Stmt_entry_split[] -> MemRef0[] };
33 ; CHECK-NEXT: } 33 ; CHECK-NEXT: }
34 34
35 @img = external global %struct.IP*, align 8 35 @img = external global ptr, align 8
36 36
37 ; Function Attrs: nounwind uwtable 37 ; Function Attrs: nounwind uwtable
38 define void @dct_luma(i32 %block_x, i32 %block_y) #0 { 38 define void @dct_luma(i32 %block_x, i32 %block_y) #0 {
39 entry: 39 entry:
40 br label %entry.split 40 br label %entry.split
45 %rem = srem i32 %div1, 2 45 %rem = srem i32 %div1, 2
46 %mul4 = shl nsw i32 %rem, 1 46 %mul4 = shl nsw i32 %rem, 1
47 %rem5 = srem i32 %div, 2 47 %rem5 = srem i32 %div, 2
48 %add6 = add nsw i32 %mul4, %rem5 48 %add6 = add nsw i32 %mul4, %rem5
49 %idxprom = sext i32 %add6 to i64 49 %idxprom = sext i32 %add6 to i64
50 %0 = load %struct.IP*, %struct.IP** @img, align 8 50 %0 = load ptr, ptr @img, align 8
51 %cofAC = getelementptr inbounds %struct.IP, %struct.IP* %0, i32 0, i32 0 51 %1 = load ptr, ptr %0, align 8
52 %1 = load i32****, i32***** %cofAC, align 8 52 %2 = load ptr, ptr %1, align 8
53 %arrayidx = getelementptr inbounds i32***, i32**** %1, i64 0 53 %arrayidx8 = getelementptr inbounds ptr, ptr %2, i64 %idxprom
54 %2 = load i32***, i32**** %arrayidx, align 8 54 %3 = load ptr, ptr %arrayidx8, align 8
55 %arrayidx8 = getelementptr inbounds i32**, i32*** %2, i64 %idxprom 55 %mb_data = getelementptr inbounds %struct.IP, ptr %0, i64 0, i32 4
56 %3 = load i32**, i32*** %arrayidx8, align 8 56 %4 = load %struct.m, ptr %mb_data, align 8
57 %mb_data = getelementptr inbounds %struct.IP, %struct.IP* %0, i64 0, i32 4
58 %4 = load %struct.m, %struct.m* %mb_data, align 8
59 br i1 false, label %land.rhs, label %land.end 57 br i1 false, label %land.rhs, label %land.end
60 58
61 land.rhs: ; preds = %entry.split 59 land.rhs: ; preds = %entry.split
62 br label %land.end 60 br label %land.end
63 61