#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*/ gets(char *);
int /*<<< orphan*/ printf(char *, int);
int toupper(char);
int main() {
  char str[80];
  int i, n = 0, len;
  gets(str);
  i = 0;
  while (str[i] != '\0') {
    switch (toupper(str[i])) {
    case 'A':
    case 'E':
    case 'I':
    case 'O':
    case 'U':
      n++;
    }
    i++;
  }
  printf("%d", n);
  return 0;
}


x86 assembly (clang, -O0):
<main>:
push   %rbp
mov    %rsp,%rbp
sub    $0x70,%rsp
movl   $0x0,-0x4(%rbp)
movl   $0x0,-0x68(%rbp)
lea    -0x60(%rbp),%rdi
call   1050 <gets@plt>
movl   $0x0,-0x64(%rbp)
movslq -0x64(%rbp),%rax
movsbl -0x60(%rbp,%rax,1),%eax
cmp    $0x0,%eax
je     11e4 <main+0xb4>
movslq -0x64(%rbp),%rax
movsbl -0x60(%rbp,%rax,1),%edi
call   1030 <toupper@plt>
mov    %eax,%ecx
mov    %ecx,-0x70(%rbp)
sub    $0x41,%eax
je     11cd <main+0x9d>
jmp    1189 <main+0x59>
mov    -0x70(%rbp),%eax
sub    $0x45,%eax
je     11cd <main+0x9d>
jmp    119a <main+0x6a>
mov    -0x70(%rbp),%eax
sub    $0x49,%eax
je     11cd <main+0x9d>
jmp    11ab <main+0x7b>
mov    -0x70(%rbp),%eax
sub    $0x4f,%eax
je     11cd <main+0x9d>
jmp    11bc <main+0x8c>
mov    -0x70(%rbp),%eax
sub    $0x55,%eax
jne    11d6 <main+0xa6>
jmp    11cd <main+0x9d>
mov    -0x68(%rbp),%eax
add    $0x1,%eax
mov    %eax,-0x68(%rbp)
mov    -0x64(%rbp),%eax
add    $0x1,%eax
mov    %eax,-0x64(%rbp)
jmp    1156 <main+0x26>
mov    -0x68(%rbp),%esi
lea    0xe12(%rip),%rdi
call   1040 <printf@plt>
xor    %eax,%eax
add    $0x70,%rsp
pop    %rbp
ret

x86 assembly (clang, -O2):
<main>:
push   %rbp
push   %r14
push   %rbx
sub    $0x50,%rsp
mov    %rsp,%rdi
call   1050 <gets@plt>
mov    (%rsp),%al
test   %al,%al
je     1188 <main+0x58>
lea    0x1(%rsp),%rbx
xor    %ebp,%ebp
mov    $0x495,%r14d
jmp    116b <main+0x3b>
cs nopw 0x0(%rax,%rax,1)
movzbl (%rbx),%eax
add    $0x1,%rbx
test   %al,%al
je     118a <main+0x5a>
movsbl %al,%edi
call   1030 <toupper@plt>
add    $0xffffffbf,%eax
ror    %eax
cmp    $0xa,%eax
ja     1160 <main+0x30>
bt     %eax,%r14d
jae    1160 <main+0x30>
add    $0x1,%ebp
jmp    1160 <main+0x30>
xor    %ebp,%ebp
lea    0xe6f(%rip),%rdi
mov    %ebp,%esi
call   1040 <printf@plt>
xor    %eax,%eax
add    $0x50,%rsp
pop    %rbx
pop    %r14
pop    %rbp
ret

LLVM IR (-O0):
@.str = [3 x i8] c"%d\00"
define i32 @main() {
%1 = alloca i32
%2 = alloca [80 x i8]
%3 = alloca i32
%4 = alloca i32
%5 = alloca i32
store i32 0, i32* %1
store i32 0, i32* %4
%6 = getelementptr inbounds [80 x i8], [80 x i8]* %2, i64 0, i64 0
%7 = call i32 @gets(i8* %6)
store i32 0, i32* %3
br label %8
8: ; preds = %24, %0
%9 = load i32, i32* %3
%10 = sext i32 %9 to i64
%11 = getelementptr inbounds [80 x i8], [80 x i8]* %2, i64 0, i64 %10
%12 = load i8, i8* %11
%13 = sext i8 %12 to i32
%14 = icmp ne i32 %13, 0
br i1 %14, label %15, label %27
15: ; preds = %8
%16 = load i32, i32* %3
%17 = sext i32 %16 to i64
%18 = getelementptr inbounds [80 x i8], [80 x i8]* %2, i64 0, i64 %17
%19 = load i8, i8* %18
%20 = call i32 @toupper(i8 signext %19)
switch i32 %20, label %24 [
i32 65, label %21
i32 69, label %21
i32 73, label %21
i32 79, label %21
i32 85, label %21
]
21: ; preds = %15, %15, %15, %15, %15
%22 = load i32, i32* %4
%23 = add nsw i32 %22, 1
store i32 %23, i32* %4
br label %24
24: ; preds = %21, %15
%25 = load i32, i32* %3
%26 = add nsw i32 %25, 1
store i32 %26, i32* %3
br label %8
27: ; preds = %8
%28 = load i32, i32* %4
%29 = call i32 @printf(i8* getelementptr inbounds ([3 x i8], [3 x i8]* @.str, i64 0, i64 0), i32 %28)
ret i32 0
}

LLVM IR (-O2):
@.str = [3 x i8] c"%d\00"
define i32 @main() {
%1 = alloca [80 x i8]
%2 = getelementptr inbounds [80 x i8], [80 x i8]* %1, i64 0, i64 0
%3 = call i32 @gets(i8* %2)
%4 = load i8, i8* %2
%5 = icmp eq i8 %4, 0
br i1 %5, label %21, label %6
6: ; preds = %0, %15
%7 = phi i64 [ %17, %15 ], [ 0, %0 ]
%8 = phi i8 [ %19, %15 ], [ %4, %0 ]
%9 = phi i32 [ %16, %15 ], [ 0, %0 ]
%10 = call i32 @toupper(i8 signext %8)
%11 = add i32 %10, -65
%12 = call i32 @llvm.fshl.i32(i32 %11, i32 %11, i32 31)
switch i32 %12, label %15 [
i32 0, label %13
i32 2, label %13
i32 4, label %13
i32 7, label %13
i32 10, label %13
]
13: ; preds = %6, %6, %6, %6, %6
%14 = add nsw i32 %9, 1
br label %15
15: ; preds = %13, %6
%16 = phi i32 [ %9, %6 ], [ %14, %13 ]
%17 = add nuw i64 %7, 1
%18 = getelementptr inbounds [80 x i8], [80 x i8]* %1, i64 0, i64 %17
%19 = load i8, i8* %18
%20 = icmp eq i8 %19, 0
br i1 %20, label %21, label %6
21: ; preds = %15, %0
%22 = phi i32 [ 0, %0 ], [ %16, %15 ]
%23 = call i32 @printf(i8* getelementptr inbounds ([3 x i8], [3 x i8]* @.str, i64 0, i64 0), i32 %22)
ret i32 0
}