1 ; NOTE: Assertions have been autogenerated by utils/update_llc_test_checks.py
2 ; RUN: llc < %s -mtriple=x86_64-unknown-linux-gnu -mcpu=atom | FileCheck %s
3 ; RUN: llc < %s -mtriple=x86_64-unknown-linux-gnu -mcpu=atom -filetype=obj -o /dev/null
5 define void @HUF_writeCTable_wksp() {
6 ; CHECK-LABEL: HUF_writeCTable_wksp:
7 ; CHECK: # %bb.0: # %entry
8 ; CHECK-NEXT: movl $2, %eax
9 ; CHECK-NEXT: movb $-2, %cl
10 ; CHECK-NEXT: .p2align 4
11 ; CHECK-NEXT: .LBB0_1: # %for.body
12 ; CHECK-NEXT: # =>This Inner Loop Header: Depth=1
13 ; CHECK-NEXT: leal 1(%rcx), %edx
14 ; CHECK-NEXT: movb %dl, (%rax)
15 ; CHECK-NEXT: movb %cl, (%rax)
16 ; CHECK-NEXT: leaq 2(%rax), %rax
17 ; CHECK-NEXT: addb $-2, %cl
18 ; CHECK-NEXT: jmp .LBB0_1
22 for.body: ; preds = %for.body, %entry
23 %indvars.iv8 = phi i64 [ 1, %entry ], [ %indvars.iv.next9.1, %for.body ]
24 %0 = trunc i64 %indvars.iv8 to i8
26 store i8 %conv, ptr undef, align 1
27 %indvars.iv.next9 = add nuw nsw i64 %indvars.iv8, 1
28 %1 = trunc i64 %indvars.iv.next9 to i8
29 %conv.1 = sub i8 0, %1
30 %arrayidx.1 = getelementptr inbounds i8, ptr null, i64 %indvars.iv.next9
31 store i8 %conv.1, ptr %arrayidx.1, align 1
32 %indvars.iv.next9.1 = add nuw nsw i64 %indvars.iv8, 2
33 br i1 false, label %for.end, label %for.body
35 for.end: ; preds = %for.body