#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 */
scalar_t__ strcmp(char *, char *);
char *getStringClouds(char *code) {
  if (strcmp(code, "FEW") == 0)
    code = "Few clouds at";
  else if (strcmp(code, "SCT") == 0)
    code = "Scattered clouds at";
  else if (strcmp(code, "BKN") == 0)
    code = "Broken clouds at";
  else if (strcmp(code, "OVC") == 0)
    code = "Overcast clouds at";
  else if (strcmp(code, "CLR") == 0 || strcmp(code, "SKC") == 0)
    code = "Clear skies";
  else
    code = "";
  return code;
}


x86 assembly (clang, -O0):
<getStringClouds>:
push   %rbp
mov    %rsp,%rbp
sub    $0x10,%rsp
mov    %rdi,-0x8(%rbp)
mov    -0x8(%rbp),%rdi
lea    0xed9(%rip),%rsi
call   1030 <strcmp@plt>
cmp    $0x0,%rax
jne    1146 <getStringClouds+0x36>
lea    0xec7(%rip),%rax
mov    %rax,-0x8(%rbp)
jmp    1227 <getStringClouds+0x117>
mov    -0x8(%rbp),%rdi
lea    0xec1(%rip),%rsi
call   1030 <strcmp@plt>
cmp    $0x0,%rax
jne    1170 <getStringClouds+0x60>
lea    0xeaf(%rip),%rax
mov    %rax,-0x8(%rbp)
jmp    1222 <getStringClouds+0x112>
mov    -0x8(%rbp),%rdi
lea    0xeaf(%rip),%rsi
call   1030 <strcmp@plt>
cmp    $0x0,%rax
jne    119a <getStringClouds+0x8a>
lea    0xe9d(%rip),%rax
mov    %rax,-0x8(%rbp)
jmp    121d <getStringClouds+0x10d>
mov    -0x8(%rbp),%rdi
lea    0xe9a(%rip),%rsi
call   1030 <strcmp@plt>
cmp    $0x0,%rax
jne    11c4 <getStringClouds+0xb4>
lea    0xe88(%rip),%rax
mov    %rax,-0x8(%rbp)
jmp    1218 <getStringClouds+0x108>
mov    -0x8(%rbp),%rdi
lea    0xe87(%rip),%rsi
call   1030 <strcmp@plt>
cmp    $0x0,%rax
je     11f8 <getStringClouds+0xe8>
mov    -0x8(%rbp),%rdi
lea    0xe71(%rip),%rsi
call   1030 <strcmp@plt>
cmp    $0x0,%rax
jne    1208 <getStringClouds+0xf8>
lea    0xe5f(%rip),%rax
mov    %rax,-0x8(%rbp)
jmp    1213 <getStringClouds+0x103>
lea    0xe4e(%rip),%rax
mov    %rax,-0x8(%rbp)
jmp    1218 <getStringClouds+0x108>
jmp    121d <getStringClouds+0x10d>
jmp    1222 <getStringClouds+0x112>
jmp    1227 <getStringClouds+0x117>
mov    -0x8(%rbp),%rax
add    $0x10,%rsp
pop    %rbp
ret

x86 assembly (clang, -O2):
<getStringClouds>:
push   %rbx
mov    %rdi,%rbx
lea    0xee5(%rip),%rsi
call   1030 <strcmp@plt>
test   %rax,%rax
je     119b <getStringClouds+0x8b>
lea    0xee6(%rip),%rsi
mov    %rbx,%rdi
call   1030 <strcmp@plt>
test   %rax,%rax
je     11a4 <getStringClouds+0x94>
lea    0xeea(%rip),%rsi
mov    %rbx,%rdi
call   1030 <strcmp@plt>
test   %rax,%rax
je     11ad <getStringClouds+0x9d>
lea    0xeeb(%rip),%rsi
mov    %rbx,%rdi
call   1030 <strcmp@plt>
test   %rax,%rax
je     11b6 <getStringClouds+0xa6>
lea    0xeee(%rip),%rsi
mov    %rbx,%rdi
call   1030 <strcmp@plt>
test   %rax,%rax
je     11bf <getStringClouds+0xaf>
lea    0xede(%rip),%rsi
mov    %rbx,%rdi
call   1030 <strcmp@plt>
test   %rax,%rax
lea    0xed0(%rip),%rcx
lea    0xec8(%rip),%rax
cmove  %rcx,%rax
pop    %rbx
ret
lea    0xe62(%rip),%rax
pop    %rbx
ret
lea    0xe6b(%rip),%rax
pop    %rbx
ret
lea    0xe7a(%rip),%rax
pop    %rbx
ret
lea    0xe86(%rip),%rax
pop    %rbx
ret
lea    0xe98(%rip),%rax
pop    %rbx
ret

LLVM IR (-O0):
@.str = [4 x i8] c"FEW\00"
@.str.1 = [14 x i8] c"Few clouds at\00"
@.str.2 = [4 x i8] c"SCT\00"
@.str.3 = [20 x i8] c"Scattered clouds at\00"
@.str.4 = [4 x i8] c"BKN\00"
@.str.5 = [17 x i8] c"Broken clouds at\00"
@.str.6 = [4 x i8] c"OVC\00"
@.str.7 = [19 x i8] c"Overcast clouds at\00"
@.str.8 = [4 x i8] c"CLR\00"
@.str.9 = [4 x i8] c"SKC\00"
@.str.10 = [12 x i8] c"Clear skies\00"
@.str.11 = [1 x i8] zeroinitializer
define i8* @getStringClouds(i8* %0) {
%2 = alloca i8*
store i8* %0, i8** %2
%3 = load i8*, i8** %2
%4 = call i64 @strcmp(i8* %3, i8* getelementptr inbounds ([4 x i8], [4 x i8]* @.str, i64 0, i64 0))
%5 = icmp eq i64 %4, 0
br i1 %5, label %6, label %7
6: ; preds = %1
store i8* getelementptr inbounds ([14 x i8], [14 x i8]* @.str.1, i64 0, i64 0), i8** %2
br label %36
7: ; preds = %1
%8 = load i8*, i8** %2
%9 = call i64 @strcmp(i8* %8, i8* getelementptr inbounds ([4 x i8], [4 x i8]* @.str.2, i64 0, i64 0))
%10 = icmp eq i64 %9, 0
br i1 %10, label %11, label %12
11: ; preds = %7
store i8* getelementptr inbounds ([20 x i8], [20 x i8]* @.str.3, i64 0, i64 0), i8** %2
br label %35
12: ; preds = %7
%13 = load i8*, i8** %2
%14 = call i64 @strcmp(i8* %13, i8* getelementptr inbounds ([4 x i8], [4 x i8]* @.str.4, i64 0, i64 0))
%15 = icmp eq i64 %14, 0
br i1 %15, label %16, label %17
16: ; preds = %12
store i8* getelementptr inbounds ([17 x i8], [17 x i8]* @.str.5, i64 0, i64 0), i8** %2
br label %34
17: ; preds = %12
%18 = load i8*, i8** %2
%19 = call i64 @strcmp(i8* %18, i8* getelementptr inbounds ([4 x i8], [4 x i8]* @.str.6, i64 0, i64 0))
%20 = icmp eq i64 %19, 0
br i1 %20, label %21, label %22
21: ; preds = %17
store i8* getelementptr inbounds ([19 x i8], [19 x i8]* @.str.7, i64 0, i64 0), i8** %2
br label %33
22: ; preds = %17
%23 = load i8*, i8** %2
%24 = call i64 @strcmp(i8* %23, i8* getelementptr inbounds ([4 x i8], [4 x i8]* @.str.8, i64 0, i64 0))
%25 = icmp eq i64 %24, 0
br i1 %25, label %30, label %26
26: ; preds = %22
%27 = load i8*, i8** %2
%28 = call i64 @strcmp(i8* %27, i8* getelementptr inbounds ([4 x i8], [4 x i8]* @.str.9, i64 0, i64 0))
%29 = icmp eq i64 %28, 0
br i1 %29, label %30, label %31
30: ; preds = %26, %22
store i8* getelementptr inbounds ([12 x i8], [12 x i8]* @.str.10, i64 0, i64 0), i8** %2
br label %32
31: ; preds = %26
store i8* getelementptr inbounds ([1 x i8], [1 x i8]* @.str.11, i64 0, i64 0), i8** %2
br label %32
32: ; preds = %31, %30
br label %33
33: ; preds = %32, %21
br label %34
34: ; preds = %33, %16
br label %35
35: ; preds = %34, %11
br label %36
36: ; preds = %35, %6
%37 = load i8*, i8** %2
ret i8* %37
}

LLVM IR (-O2):
@.str = [4 x i8] c"FEW\00"
@.str.1 = [14 x i8] c"Few clouds at\00"
@.str.2 = [4 x i8] c"SCT\00"
@.str.3 = [20 x i8] c"Scattered clouds at\00"
@.str.4 = [4 x i8] c"BKN\00"
@.str.5 = [17 x i8] c"Broken clouds at\00"
@.str.6 = [4 x i8] c"OVC\00"
@.str.7 = [19 x i8] c"Overcast clouds at\00"
@.str.8 = [4 x i8] c"CLR\00"
@.str.9 = [4 x i8] c"SKC\00"
@.str.10 = [12 x i8] c"Clear skies\00"
@.str.11 = [1 x i8] zeroinitializer
define i8* @getStringClouds(i8* %0) {
%2 = tail call i64 @strcmp(i8* %0, i8* getelementptr inbounds ([4 x i8], [4 x i8]* @.str, i64 0, i64 0))
%3 = icmp eq i64 %2, 0
br i1 %3, label %20, label %4
4: ; preds = %1
%5 = tail call i64 @strcmp(i8* %0, i8* getelementptr inbounds ([4 x i8], [4 x i8]* @.str.2, i64 0, i64 0))
%6 = icmp eq i64 %5, 0
br i1 %6, label %20, label %7
7: ; preds = %4
%8 = tail call i64 @strcmp(i8* %0, i8* getelementptr inbounds ([4 x i8], [4 x i8]* @.str.4, i64 0, i64 0))
%9 = icmp eq i64 %8, 0
br i1 %9, label %20, label %10
10: ; preds = %7
%11 = tail call i64 @strcmp(i8* %0, i8* getelementptr inbounds ([4 x i8], [4 x i8]* @.str.6, i64 0, i64 0))
%12 = icmp eq i64 %11, 0
br i1 %12, label %20, label %13
13: ; preds = %10
%14 = tail call i64 @strcmp(i8* %0, i8* getelementptr inbounds ([4 x i8], [4 x i8]* @.str.8, i64 0, i64 0))
%15 = icmp eq i64 %14, 0
br i1 %15, label %20, label %16
16: ; preds = %13
%17 = tail call i64 @strcmp(i8* %0, i8* getelementptr inbounds ([4 x i8], [4 x i8]* @.str.9, i64 0, i64 0))
%18 = icmp eq i64 %17, 0
%19 = select i1 %18, i8* getelementptr inbounds ([12 x i8], [12 x i8]* @.str.10, i64 0, i64 0), i8* getelementptr inbounds ([1 x i8], [1 x i8]* @.str.11, i64 0, i64 0)
br label %20
20: ; preds = %16, %13, %10, %7, %4, %1
%21 = phi i8* [ getelementptr inbounds ([14 x i8], [14 x i8]* @.str.1, i64 0, i64 0), %1 ], [ getelementptr inbounds ([20 x i8], [20 x i8]* @.str.3, i64 0, i64 0), %4 ], [ getelementptr inbounds ([17 x i8], [17 x i8]* @.str.5, i64 0, i64 0), %7 ], [ getelementptr inbounds ([19 x i8], [19 x i8]* @.str.7, i64 0, i64 0), %10 ], [ getelementptr inbounds ([12 x i8], [12 x i8]* @.str.10, i64 0, i64 0), %13 ], [ %19, %16 ]
ret i8* %21
}