brintos

brintos / llvm-project-archived public Read only

0
0
Text · 4.0 KiB · f56044b Raw
113 lines · plain
1; NOTE: Assertions have been autogenerated by utils/update_llc_test_checks.py2; RUN: llc < %s -mtriple=i386-unknown-linux-gnu | FileCheck %s --check-prefix=I3863;4; Make sure we don't zero out %eax when both %ah and %al are used.5;6; PR1766: https://github.com/ClangBuiltLinux/linux/issues/17667 8%struct.maple_subtree_state = type { ptr }9 10@mas_data_end_type = dso_local local_unnamed_addr global i32 0, align 411@ma_meta_end_mn_0_0_0_0_0_0 = dso_local local_unnamed_addr global i8 0, align 112@mt_pivots_0 = dso_local local_unnamed_addr global i8 0, align 113@mas_data_end___trans_tmp_2 = dso_local local_unnamed_addr global ptr null, align 414@mt_slots_0 = dso_local local_unnamed_addr global i8 0, align 115 16define dso_local zeroext i1 @test1(ptr nocapture noundef readonly %0) local_unnamed_addr "zero-call-used-regs"="used-gpr" nounwind {17; I386-LABEL: test1:18; I386:       # %bb.0:19; I386-NEXT:    pushl %ebx20; I386-NEXT:    subl $24, %esp21; I386-NEXT:    movl {{[0-9]+}}(%esp), %eax22; I386-NEXT:    movl (%eax), %eax23; I386-NEXT:    movzbl (%eax), %ebx24; I386-NEXT:    calll bar25; I386-NEXT:    testb %al, %al26; I386-NEXT:    # implicit-def: $al27; I386-NEXT:    # kill: killed $al28; I386-NEXT:    je .LBB0_629; I386-NEXT:  # %bb.1:30; I386-NEXT:    cmpl $0, mas_data_end_type31; I386-NEXT:    je .LBB0_332; I386-NEXT:  # %bb.2:33; I386-NEXT:    movzbl ma_meta_end_mn_0_0_0_0_0_0, %eax34; I386-NEXT:    movb %al, {{[-0-9]+}}(%e{{[sb]}}p) # 1-byte Spill35; I386-NEXT:    jmp .LBB0_636; I386-NEXT:  .LBB0_3:37; I386-NEXT:    movb mt_pivots_0, %ah38; I386-NEXT:    movb %ah, %al39; I386-NEXT:    decb %al40; I386-NEXT:    movl mas_data_end___trans_tmp_2, %ecx41; I386-NEXT:    movsbl %al, %edx42; I386-NEXT:    cmpl $0, (%ecx,%edx,4)43; I386-NEXT:    je .LBB0_544; I386-NEXT:  # %bb.4:45; I386-NEXT:    movb %al, %ah46; I386-NEXT:  .LBB0_5:47; I386-NEXT:    movb %ah, {{[-0-9]+}}(%e{{[sb]}}p) # 1-byte Spill48; I386-NEXT:  .LBB0_6:49; I386-NEXT:    movb mt_slots_0, %bh50; I386-NEXT:    leal {{[0-9]+}}(%esp), %eax51; I386-NEXT:    movl %eax, (%esp)52; I386-NEXT:    calll baz53; I386-NEXT:    subl $4, %esp54; I386-NEXT:    cmpb %bh, %bl55; I386-NEXT:    jae .LBB0_856; I386-NEXT:  # %bb.7:57; I386-NEXT:    movsbl {{[-0-9]+}}(%e{{[sb]}}p), %eax # 1-byte Folded Reload58; I386-NEXT:    movl %eax, (%esp)59; I386-NEXT:    calll gaz60; I386-NEXT:  .LBB0_8:61; I386-NEXT:    movb $1, %al62; I386-NEXT:    addl $24, %esp63; I386-NEXT:    popl %ebx64; I386-NEXT:    xorl %ecx, %ecx65; I386-NEXT:    xorl %edx, %edx66; I386-NEXT:    retl67  %2 = alloca %struct.maple_subtree_state, align 468  %3 = load ptr, ptr %0, align 469  %4 = load i8, ptr %3, align 170  %5 = tail call zeroext i1 @bar()71  br i1 %5, label %6, label %2072 736:                                                ; preds = %174  %7 = load i32, ptr @mas_data_end_type, align 475  %8 = icmp eq i32 %7, 076  br i1 %8, label %11, label %977 789:                                                ; preds = %679  %10 = load i8, ptr @ma_meta_end_mn_0_0_0_0_0_0, align 180  br label %2081 8211:                                               ; preds = %683  %12 = load i8, ptr @mt_pivots_0, align 184  %13 = add i8 %12, -185  %14 = load ptr, ptr @mas_data_end___trans_tmp_2, align 486  %15 = sext i8 %13 to i3287  %16 = getelementptr inbounds [1 x i32], ptr %14, i32 0, i32 %1588  %17 = load i32, ptr %16, align 489  %18 = icmp eq i32 %17, 090  %19 = select i1 %18, i8 %12, i8 %1391  br label %2092 9320:                                               ; preds = %11, %9, %194  %21 = phi i8 [ undef, %1 ], [ %10, %9 ], [ %19, %11 ]95  %22 = load i8, ptr @mt_slots_0, align 196  call void @baz(ptr nonnull sret(%struct.maple_subtree_state) align 4 %2)97  %23 = icmp ult i8 %4, %2298  br i1 %23, label %24, label %2599 10024:                                               ; preds = %20101  call void @gaz(i8 noundef signext %21)102  br label %25103 10425:                                               ; preds = %20, %24105  ret i1 true106}107 108declare dso_local zeroext i1 @bar(...) local_unnamed_addr109 110declare dso_local void @baz(ptr sret(%struct.maple_subtree_state) align 4, ...) local_unnamed_addr111 112declare dso_local void @gaz(i8 noundef signext) local_unnamed_addr113