1 ; NOTE: Assertions have been autogenerated by utils/update_llc_test_checks.py
2 ; RUN: llc < %s -mtriple=i686-unknown-linux-gnu | FileCheck %s --check-prefixes=X86
4 define { i64, i8 } @mulodi_test(i64 %l, i64 %r) unnamed_addr #0 {
5 ; X86-LABEL: mulodi_test:
6 ; X86: # %bb.0: # %start
8 ; X86-NEXT: .cfi_def_cfa_offset 8
10 ; X86-NEXT: .cfi_def_cfa_offset 12
11 ; X86-NEXT: pushl %edi
12 ; X86-NEXT: .cfi_def_cfa_offset 16
13 ; X86-NEXT: pushl %esi
14 ; X86-NEXT: .cfi_def_cfa_offset 20
15 ; X86-NEXT: .cfi_offset %esi, -20
16 ; X86-NEXT: .cfi_offset %edi, -16
17 ; X86-NEXT: .cfi_offset %ebx, -12
18 ; X86-NEXT: .cfi_offset %ebp, -8
19 ; X86-NEXT: movl {{[0-9]+}}(%esp), %ebp
20 ; X86-NEXT: movl {{[0-9]+}}(%esp), %eax
21 ; X86-NEXT: movl {{[0-9]+}}(%esp), %esi
22 ; X86-NEXT: testl %esi, %esi
24 ; X86-NEXT: testl %eax, %eax
26 ; X86-NEXT: andb %dl, %cl
27 ; X86-NEXT: mull {{[0-9]+}}(%esp)
28 ; X86-NEXT: movl %eax, %edi
30 ; X86-NEXT: movl %esi, %eax
33 ; X86-NEXT: orb %bl, %ch
34 ; X86-NEXT: orb %cl, %ch
35 ; X86-NEXT: leal (%edi,%eax), %esi
36 ; X86-NEXT: movl %ebp, %eax
37 ; X86-NEXT: mull {{[0-9]+}}(%esp)
38 ; X86-NEXT: addl %esi, %edx
40 ; X86-NEXT: orb %ch, %cl
42 ; X86-NEXT: .cfi_def_cfa_offset 16
44 ; X86-NEXT: .cfi_def_cfa_offset 12
46 ; X86-NEXT: .cfi_def_cfa_offset 8
48 ; X86-NEXT: .cfi_def_cfa_offset 4
51 %0 = tail call { i64, i1 } @llvm.umul.with.overflow.i64(i64 %l, i64 %r) #2
52 %1 = extractvalue { i64, i1 } %0, 0
53 %2 = extractvalue { i64, i1 } %0, 1
55 %4 = insertvalue { i64, i8 } undef, i64 %1, 0
56 %5 = insertvalue { i64, i8 } %4, i8 %3, 1
60 ; Function Attrs: nounwind readnone speculatable
61 declare { i64, i1 } @llvm.umul.with.overflow.i64(i64, i64) #1
63 attributes #0 = { nounwind readnone uwtable }
64 attributes #1 = { nounwind readnone speculatable }
65 attributes #2 = { nounwind }