#define NULL ((void *)0)
typedef unsigned long size_t; // Customize by platform.
typedef long intptr_t;
typedef unsigned long uintptr_t;
typedef long scalar_t__; // Either arithmetic or pointer type.
/* By default, we understand bool (as a convenience). */
typedef int bool;
#define false 0
#define true 1

/* Forward declarations */

/* Type definitions */

/* Variables and functions */
int /*<<< orphan*/ cpu_info(char *, unsigned int *, unsigned int *);
scalar_t__ strcmp(char *, char *);
int cpu_has_slowmult(void) {
  char vendor[13];
  unsigned family;
  unsigned model;
  cpu_info(vendor, &family, &model);
  if (strcmp(vendor, "GenuineIntel") == 0) {
    if (family == 6 && model == 28)
      return 1;
  }
  return 0;
}


x86 assembly (clang, -O0):
<cpu_has_slowmult>:
push   %rbp
mov    %rsp,%rbp
sub    $0x20,%rsp
lea    -0x11(%rbp),%rdi
lea    -0x18(%rbp),%rsi
lea    -0x1c(%rbp),%rdx
call   1040 <cpu_info@plt>
lea    -0x11(%rbp),%rdi
lea    0xebc(%rip),%rsi
call   1030 <strcmp@plt>
cmp    $0x0,%rax
jne    1178 <cpu_has_slowmult+0x58>
cmpl   $0x6,-0x18(%rbp)
jne    1173 <cpu_has_slowmult+0x53>
cmpl   $0x1c,-0x1c(%rbp)
jne    1173 <cpu_has_slowmult+0x53>
movl   $0x1,-0x4(%rbp)
jmp    117f <cpu_has_slowmult+0x5f>
jmp    1178 <cpu_has_slowmult+0x58>
movl   $0x0,-0x4(%rbp)
mov    -0x4(%rbp),%eax
add    $0x20,%rsp
pop    %rbp
ret

x86 assembly (clang, -O2):
<cpu_has_slowmult>:
push   %rbx
sub    $0x20,%rsp
lea    0x13(%rsp),%rbx
lea    0xc(%rsp),%rsi
lea    0x8(%rsp),%rdx
mov    %rbx,%rdi
call   1040 <cpu_info@plt>
lea    0xebd(%rip),%rsi
mov    %rbx,%rdi
call   1030 <strcmp@plt>
test   %rax,%rax
je     1158 <cpu_has_slowmult+0x38>
xor    %eax,%eax
add    $0x20,%rsp
pop    %rbx
ret
cmpl   $0x6,0xc(%rsp)
jne    1150 <cpu_has_slowmult+0x30>
mov    $0x1,%eax
cmpl   $0x1c,0x8(%rsp)
je     1152 <cpu_has_slowmult+0x32>
jmp    1150 <cpu_has_slowmult+0x30>

LLVM IR (-O0):
@.str = [13 x i8] c"GenuineIntel\00"
define i32 @cpu_has_slowmult() {
%1 = alloca i32
%2 = alloca [13 x i8]
%3 = alloca i32
%4 = alloca i32
%5 = getelementptr inbounds [13 x i8], [13 x i8]* %2, i64 0, i64 0
%6 = call i32 @cpu_info(i8* %5, i32* %3, i32* %4)
%7 = getelementptr inbounds [13 x i8], [13 x i8]* %2, i64 0, i64 0
%8 = call i64 @strcmp(i8* %7, i8* getelementptr inbounds ([13 x i8], [13 x i8]* @.str, i64 0, i64 0))
%9 = icmp eq i64 %8, 0
br i1 %9, label %10, label %18
10: ; preds = %0
%11 = load i32, i32* %3
%12 = icmp eq i32 %11, 6
br i1 %12, label %13, label %17
13: ; preds = %10
%14 = load i32, i32* %4
%15 = icmp eq i32 %14, 28
br i1 %15, label %16, label %17
16: ; preds = %13
store i32 1, i32* %1
br label %19
17: ; preds = %13, %10
br label %18
18: ; preds = %17, %0
store i32 0, i32* %1
br label %19
19: ; preds = %18, %16
%20 = load i32, i32* %1
ret i32 %20
}

LLVM IR (-O2):
@.str = [13 x i8] c"GenuineIntel\00"
define i32 @cpu_has_slowmult() {
%1 = alloca [13 x i8]
%2 = alloca i32
%3 = alloca i32
%4 = getelementptr inbounds [13 x i8], [13 x i8]* %1, i64 0, i64 0
%5 = bitcast i32* %2 to i8*
%6 = bitcast i32* %3 to i8*
%7 = call i32 @cpu_info(i8* %4, i32* %2, i32* %3)
%8 = call i64 @strcmp(i8* %4, i8* getelementptr inbounds ([13 x i8], [13 x i8]* @.str, i64 0, i64 0))
%9 = icmp eq i64 %8, 0
br i1 %9, label %10, label %16
10: ; preds = %0
%11 = load i32, i32* %2
%12 = icmp eq i32 %11, 6
%13 = load i32, i32* %3
%14 = icmp eq i32 %13, 28
%15 = select i1 %12, i1 %14, i1 false
br i1 %15, label %17, label %16
16: ; preds = %10, %0
br label %17
17: ; preds = %10, %16
%18 = phi i32 [ 0, %16 ], [ 1, %10 ]
ret i32 %18
}