1 ; NOTE: Assertions have been autogenerated by utils/update_llc_test_checks.py
2 ; RUN: llc -o - %s -mtriple=x86_64--unknown-linux-gnu | FileCheck %s
4 define void @foo(ptr %a, ptr %b, ptr noalias %c, i64 %s) {
7 ; CHECK-NEXT: movq $0, -{{[0-9]+}}(%rsp)
8 ; CHECK-NEXT: .p2align 4, 0x90
9 ; CHECK-NEXT: .LBB0_1: # %loop
10 ; CHECK-NEXT: # =>This Inner Loop Header: Depth=1
11 ; CHECK-NEXT: movq -{{[0-9]+}}(%rsp), %r9
12 ; CHECK-NEXT: cmpq %rcx, %r9
13 ; CHECK-NEXT: je .LBB0_3
14 ; CHECK-NEXT: # %bb.2: # %body
15 ; CHECK-NEXT: # in Loop: Header=BB0_1 Depth=1
16 ; CHECK-NEXT: movl $1, (%rdx,%r9,4)
17 ; CHECK-NEXT: movzbl (%rdi,%r9,4), %r8d
18 ; CHECK-NEXT: movzbl (%rsi,%r9,4), %eax
19 ; CHECK-NEXT: andl %r8d, %eax
20 ; CHECK-NEXT: andl $1, %eax
21 ; CHECK-NEXT: movl %eax, (%rdi,%r9,4)
22 ; CHECK-NEXT: incq %r9
23 ; CHECK-NEXT: movq %r9, -{{[0-9]+}}(%rsp)
24 ; CHECK-NEXT: jmp .LBB0_1
25 ; CHECK-NEXT: .LBB0_3: # %endloop
32 %ct = load i64, ptr %i
33 %comp = icmp eq i64 %ct, %s
34 br i1 %comp, label %endloop, label %body
37 %var0 = getelementptr i32, ptr %c, i64 %ct
38 store i32 1, ptr %var0
39 %var1 = getelementptr i32, ptr %c, i64 %ct
40 %var2 = load i32, ptr %var1
41 %var3 = add i32 %var2, 1
42 %var4 = getelementptr i32, ptr %a, i64 %ct
43 %var5 = load i32, ptr %var4
44 %var6 = and i32 %var3, %var5
45 %var7 = add i32 %var6, 1
46 %var8 = getelementptr i32, ptr %a, i64 %ct
47 %var9 = load i32, ptr %var8
48 %var10 = and i32 %var7, %var9
49 %var11 = getelementptr i32, ptr %c, i64 %ct
50 %var12 = load i32, ptr %var11
51 %var13 = and i32 %var10, %var12
52 %var14 = getelementptr i32, ptr %b, i64 %ct
53 %var15 = load i32, ptr %var14
54 %var16 = and i32 %var15, 63
55 %var17 = and i32 %var13, %var16
56 %var18 = getelementptr i32, ptr %a, i64 %ct
57 store i32 %var17, ptr %var18