#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*/ printf(char *);
int /*<<< orphan*/ scanf(char *, char *);
scalar_t__ strcmp(char *, char *);
int main() {
  char sigla[3];
  printf("Entre com a sigla do seu estado:");
  scanf("%s", sigla);
  if (strcmp(sigla, "RJ") == 0 || strcmp(sigla, "rj") == 0)
    printf("\nCarioca!");
  else if (strcmp(sigla, "SP") == 0 || strcmp(sigla, "sp") == 0)
    printf("\nPaulista");
  else if (strcmp(sigla, "MG") == 0 || strcmp(sigla, "mg") == 0)
    printf("\nMineiro!");
  else
    printf("\nOutros Estados!");
}


x86 assembly (clang, -O0):
<main>:
push   %rbp
mov    %rsp,%rbp
sub    $0x10,%rsp
movl   $0x0,-0x4(%rbp)
lea    0xeba(%rip),%rdi
call   1030 <printf@plt>
lea    -0x7(%rbp),%rsi
lea    0xecb(%rip),%rdi
call   1050 <scanf@plt>
lea    -0x7(%rbp),%rdi
lea    0xebe(%rip),%rsi
call   1040 <strcmp@plt>
cmp    $0x0,%rax
je     118f <main+0x5f>
lea    -0x7(%rbp),%rdi
lea    0xea7(%rip),%rsi
call   1040 <strcmp@plt>
cmp    $0x0,%rax
jne    11a0 <main+0x70>
lea    0xe94(%rip),%rdi
call   1030 <printf@plt>
jmp    1240 <main+0x110>
lea    -0x7(%rbp),%rdi
lea    0xe89(%rip),%rsi
call   1040 <strcmp@plt>
cmp    $0x0,%rax
je     11d4 <main+0xa4>
lea    -0x7(%rbp),%rdi
lea    0xe72(%rip),%rsi
call   1040 <strcmp@plt>
cmp    $0x0,%rax
jne    11e5 <main+0xb5>
lea    0xe5f(%rip),%rdi
call   1030 <printf@plt>
jmp    123b <main+0x10b>
lea    -0x7(%rbp),%rdi
lea    0xe54(%rip),%rsi
call   1040 <strcmp@plt>
cmp    $0x0,%rax
je     1219 <main+0xe9>
lea    -0x7(%rbp),%rdi
lea    0xe3d(%rip),%rsi
call   1040 <strcmp@plt>
cmp    $0x0,%rax
jne    122a <main+0xfa>
lea    0xe2a(%rip),%rdi
call   1030 <printf@plt>
jmp    1236 <main+0x106>
lea    0xe23(%rip),%rdi
call   1030 <printf@plt>
jmp    123b <main+0x10b>
jmp    1240 <main+0x110>
mov    -0x4(%rbp),%eax
add    $0x10,%rsp
pop    %rbp
ret

x86 assembly (clang, -O2):
<main>:
push   %rbx
sub    $0x10,%rsp
lea    0xec4(%rip),%rdi
call   1030 <printf@plt>
lea    0xed9(%rip),%rdi
lea    0xd(%rsp),%rbx
mov    %rbx,%rsi
call   1050 <scanf@plt>
lea    0xec8(%rip),%rsi
mov    %rbx,%rdi
call   1040 <strcmp@plt>
lea    0xebf(%rip),%rbx
test   %rax,%rax
je     1202 <main+0xd2>
lea    0xeac(%rip),%rsi
lea    0xd(%rsp),%rdi
call   1040 <strcmp@plt>
test   %rax,%rax
je     1202 <main+0xd2>
lea    0xea3(%rip),%rsi
lea    0xd(%rsp),%rdi
call   1040 <strcmp@plt>
lea    0xe98(%rip),%rbx
test   %rax,%rax
je     1202 <main+0xd2>
lea    0xe89(%rip),%rsi
lea    0xd(%rsp),%rdi
call   1040 <strcmp@plt>
test   %rax,%rax
je     1202 <main+0xd2>
lea    0xe80(%rip),%rsi
lea    0xd(%rsp),%rdi
call   1040 <strcmp@plt>
test   %rax,%rax
je     11fb <main+0xcb>
lea    0xe6d(%rip),%rsi
lea    0xd(%rsp),%rdi
call   1040 <strcmp@plt>
test   %rax,%rax
lea    0xe5c(%rip),%rax
lea    0xe5f(%rip),%rbx
cmove  %rax,%rbx
jmp    1202 <main+0xd2>
lea    0xe48(%rip),%rbx
mov    %rbx,%rdi
call   1030 <printf@plt>
xor    %eax,%eax
add    $0x10,%rsp
pop    %rbx
ret

LLVM IR (-O0):
@.str = [33 x i8] c"Entre com a sigla do seu estado:\00"
@.str.1 = [3 x i8] c"%s\00"
@.str.2 = [3 x i8] c"RJ\00"
@.str.3 = [3 x i8] c"rj\00"
@.str.4 = [10 x i8] c"\0ACarioca!\00"
@.str.5 = [3 x i8] c"SP\00"
@.str.6 = [3 x i8] c"sp\00"
@.str.7 = [10 x i8] c"\0APaulista\00"
@.str.8 = [3 x i8] c"MG\00"
@.str.9 = [3 x i8] c"mg\00"
@.str.10 = [10 x i8] c"\0AMineiro!\00"
@.str.11 = [17 x i8] c"\0AOutros Estados!\00"
define i32 @main() {
%1 = alloca i32
%2 = alloca [3 x i8]
store i32 0, i32* %1
%3 = call i32 @printf(i8* getelementptr inbounds ([33 x i8], [33 x i8]* @.str, i64 0, i64 0))
%4 = getelementptr inbounds [3 x i8], [3 x i8]* %2, i64 0, i64 0
%5 = call i32 @scanf(i8* getelementptr inbounds ([3 x i8], [3 x i8]* @.str.1, i64 0, i64 0), i8* %4)
%6 = getelementptr inbounds [3 x i8], [3 x i8]* %2, i64 0, i64 0
%7 = call i64 @strcmp(i8* %6, i8* getelementptr inbounds ([3 x i8], [3 x i8]* @.str.2, i64 0, i64 0))
%8 = icmp eq i64 %7, 0
br i1 %8, label %13, label %9
9: ; preds = %0
%10 = getelementptr inbounds [3 x i8], [3 x i8]* %2, i64 0, i64 0
%11 = call i64 @strcmp(i8* %10, i8* getelementptr inbounds ([3 x i8], [3 x i8]* @.str.3, i64 0, i64 0))
%12 = icmp eq i64 %11, 0
br i1 %12, label %13, label %15
13: ; preds = %9, %0
%14 = call i32 @printf(i8* getelementptr inbounds ([10 x i8], [10 x i8]* @.str.4, i64 0, i64 0))
br label %39
15: ; preds = %9
%16 = getelementptr inbounds [3 x i8], [3 x i8]* %2, i64 0, i64 0
%17 = call i64 @strcmp(i8* %16, i8* getelementptr inbounds ([3 x i8], [3 x i8]* @.str.5, i64 0, i64 0))
%18 = icmp eq i64 %17, 0
br i1 %18, label %23, label %19
19: ; preds = %15
%20 = getelementptr inbounds [3 x i8], [3 x i8]* %2, i64 0, i64 0
%21 = call i64 @strcmp(i8* %20, i8* getelementptr inbounds ([3 x i8], [3 x i8]* @.str.6, i64 0, i64 0))
%22 = icmp eq i64 %21, 0
br i1 %22, label %23, label %25
23: ; preds = %19, %15
%24 = call i32 @printf(i8* getelementptr inbounds ([10 x i8], [10 x i8]* @.str.7, i64 0, i64 0))
br label %38
25: ; preds = %19
%26 = getelementptr inbounds [3 x i8], [3 x i8]* %2, i64 0, i64 0
%27 = call i64 @strcmp(i8* %26, i8* getelementptr inbounds ([3 x i8], [3 x i8]* @.str.8, i64 0, i64 0))
%28 = icmp eq i64 %27, 0
br i1 %28, label %33, label %29
29: ; preds = %25
%30 = getelementptr inbounds [3 x i8], [3 x i8]* %2, i64 0, i64 0
%31 = call i64 @strcmp(i8* %30, i8* getelementptr inbounds ([3 x i8], [3 x i8]* @.str.9, i64 0, i64 0))
%32 = icmp eq i64 %31, 0
br i1 %32, label %33, label %35
33: ; preds = %29, %25
%34 = call i32 @printf(i8* getelementptr inbounds ([10 x i8], [10 x i8]* @.str.10, i64 0, i64 0))
br label %37
35: ; preds = %29
%36 = call i32 @printf(i8* getelementptr inbounds ([17 x i8], [17 x i8]* @.str.11, i64 0, i64 0))
br label %37
37: ; preds = %35, %33
br label %38
38: ; preds = %37, %23
br label %39
39: ; preds = %38, %13
%40 = load i32, i32* %1
ret i32 %40
}

LLVM IR (-O2):
@.str = [33 x i8] c"Entre com a sigla do seu estado:\00"
@.str.1 = [3 x i8] c"%s\00"
@.str.2 = [3 x i8] c"RJ\00"
@.str.3 = [3 x i8] c"rj\00"
@.str.4 = [10 x i8] c"\0ACarioca!\00"
@.str.5 = [3 x i8] c"SP\00"
@.str.6 = [3 x i8] c"sp\00"
@.str.7 = [10 x i8] c"\0APaulista\00"
@.str.8 = [3 x i8] c"MG\00"
@.str.9 = [3 x i8] c"mg\00"
@.str.10 = [10 x i8] c"\0AMineiro!\00"
@.str.11 = [17 x i8] c"\0AOutros Estados!\00"
define i32 @main() {
%1 = alloca [3 x i8]
%2 = getelementptr inbounds [3 x i8], [3 x i8]* %1, i64 0, i64 0
%3 = tail call i32 @printf(i8* dereferenceable(1) getelementptr inbounds ([33 x i8], [33 x i8]* @.str, i64 0, i64 0))
%4 = call i32 @scanf(i8* getelementptr inbounds ([3 x i8], [3 x i8]* @.str.1, i64 0, i64 0), i8* %2)
%5 = call i64 @strcmp(i8* %2, i8* getelementptr inbounds ([3 x i8], [3 x i8]* @.str.2, i64 0, i64 0))
%6 = icmp eq i64 %5, 0
br i1 %6, label %23, label %7
7: ; preds = %0
%8 = call i64 @strcmp(i8* %2, i8* getelementptr inbounds ([3 x i8], [3 x i8]* @.str.3, i64 0, i64 0))
%9 = icmp eq i64 %8, 0
br i1 %9, label %23, label %10
10: ; preds = %7
%11 = call i64 @strcmp(i8* %2, i8* getelementptr inbounds ([3 x i8], [3 x i8]* @.str.5, i64 0, i64 0))
%12 = icmp eq i64 %11, 0
br i1 %12, label %23, label %13
13: ; preds = %10
%14 = call i64 @strcmp(i8* %2, i8* getelementptr inbounds ([3 x i8], [3 x i8]* @.str.6, i64 0, i64 0))
%15 = icmp eq i64 %14, 0
br i1 %15, label %23, label %16
16: ; preds = %13
%17 = call i64 @strcmp(i8* %2, i8* getelementptr inbounds ([3 x i8], [3 x i8]* @.str.8, i64 0, i64 0))
%18 = icmp eq i64 %17, 0
br i1 %18, label %23, label %19
19: ; preds = %16
%20 = call i64 @strcmp(i8* %2, i8* getelementptr inbounds ([3 x i8], [3 x i8]* @.str.9, i64 0, i64 0))
%21 = icmp eq i64 %20, 0
%22 = select i1 %21, i8* getelementptr inbounds ([10 x i8], [10 x i8]* @.str.10, i64 0, i64 0), i8* getelementptr inbounds ([17 x i8], [17 x i8]* @.str.11, i64 0, i64 0)
br label %23
23: ; preds = %19, %16, %10, %13, %0, %7
%24 = phi i8* [ getelementptr inbounds ([10 x i8], [10 x i8]* @.str.4, i64 0, i64 0), %7 ], [ getelementptr inbounds ([10 x i8], [10 x i8]* @.str.4, i64 0, i64 0), %0 ], [ getelementptr inbounds ([10 x i8], [10 x i8]* @.str.7, i64 0, i64 0), %13 ], [ getelementptr inbounds ([10 x i8], [10 x i8]* @.str.7, i64 0, i64 0), %10 ], [ getelementptr inbounds ([10 x i8], [10 x i8]* @.str.10, i64 0, i64 0), %16 ], [ %22, %19 ]
%25 = call i32 @printf(i8* dereferenceable(1) %24)
ret i32 0
}