#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 DefaultFontSize();
int /*<<< orphan*/ setLength(char *, int);
void setThree(char *s, int ten, int eleven, int twelve) {
  int n = DefaultFontSize();
  if (n == 20)
    setLength(s, ten * 20);
  else if (n == 22)
    setLength(s, eleven * 20);
  else
    setLength(s, twelve * 20);
}


x86 assembly (clang, -O0):
<setThree>:
push   %rbp
mov    %rsp,%rbp
sub    $0x20,%rsp
mov    %rdi,-0x8(%rbp)
mov    %esi,-0xc(%rbp)
mov    %edx,-0x10(%rbp)
mov    %ecx,-0x14(%rbp)
mov    $0x0,%al
call   1040 <DefaultFontSize@plt>
mov    %eax,-0x18(%rbp)
cmpl   $0x14,-0x18(%rbp)
jne    115b <setThree+0x3b>
mov    -0x8(%rbp),%rdi
imul   $0x14,-0xc(%rbp),%esi
call   1030 <setLength@plt>
jmp    1189 <setThree+0x69>
cmpl   $0x16,-0x18(%rbp)
jne    1177 <setThree+0x57>
mov    -0x8(%rbp),%rdi
imul   $0x14,-0x10(%rbp),%esi
call   1030 <setLength@plt>
jmp    1184 <setThree+0x64>
mov    -0x8(%rbp),%rdi
imul   $0x14,-0x14(%rbp),%esi
call   1030 <setLength@plt>
jmp    1189 <setThree+0x69>
add    $0x20,%rsp
pop    %rbp
ret

x86 assembly (clang, -O2):
<setThree>:
push   %rbp
push   %r15
push   %r14
push   %rbx
push   %rax
mov    %ecx,%r15d
mov    %edx,%ebp
mov    %esi,%ebx
mov    %rdi,%r14
xor    %eax,%eax
call   1040 <DefaultFontSize@plt>
cmp    $0x14,%eax
je     1147 <setThree+0x27>
mov    %ebp,%ebx
cmp    $0x16,%eax
je     1147 <setThree+0x27>
mov    %r15d,%ebx
shl    $0x2,%ebx
lea    (%rbx,%rbx,4),%esi
mov    %r14,%rdi
add    $0x8,%rsp
pop    %rbx
pop    %r14
pop    %r15
pop    %rbp
jmp    1030 <setLength@plt>

LLVM IR (-O0):
define void @setThree(i8* %0, i32 %1, i32 %2, i32 %3) {
%5 = alloca i8*
%6 = alloca i32
%7 = alloca i32
%8 = alloca i32
%9 = alloca i32
store i8* %0, i8** %5
store i32 %1, i32* %6
store i32 %2, i32* %7
store i32 %3, i32* %8
%10 = call i32 (...) @DefaultFontSize()
store i32 %10, i32* %9
%11 = load i32, i32* %9
%12 = icmp eq i32 %11, 20
br i1 %12, label %13, label %18
13: ; preds = %4
%14 = load i8*, i8** %5
%15 = load i32, i32* %6
%16 = mul nsw i32 %15, 20
%17 = call i32 @setLength(i8* %14, i32 %16)
br label %32
18: ; preds = %4
%19 = load i32, i32* %9
%20 = icmp eq i32 %19, 22
br i1 %20, label %21, label %26
21: ; preds = %18
%22 = load i8*, i8** %5
%23 = load i32, i32* %7
%24 = mul nsw i32 %23, 20
%25 = call i32 @setLength(i8* %22, i32 %24)
br label %31
26: ; preds = %18
%27 = load i8*, i8** %5
%28 = load i32, i32* %8
%29 = mul nsw i32 %28, 20
%30 = call i32 @setLength(i8* %27, i32 %29)
br label %31
31: ; preds = %26, %21
br label %32
32: ; preds = %31, %13
ret void
}

LLVM IR (-O2):
define void @setThree(i8* %0, i32 %1, i32 %2, i32 %3) {
%5 = tail call i32 (...) @DefaultFontSize()
switch i32 %5, label %7 [
i32 20, label %8
i32 22, label %6
]
6: ; preds = %4
br label %8
7: ; preds = %4
br label %8
8: ; preds = %4, %6, %7
%9 = phi i32 [ %2, %6 ], [ %3, %7 ], [ %1, %4 ]
%10 = mul nsw i32 %9, 20
%11 = tail call i32 @setLength(i8* %0, i32 %10)
ret void
}