#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 writeInt(char *, unsigned char);
int unexportIO(unsigned char n) {
  int r;
  switch (n) {
  case (50):
    r = writeInt("/sys/class/gpio/unexport", 50);
    r += writeInt("/sys/class/gpio/unexport", 40);
    return r;
    break;
  case (51):
    r = writeInt("/sys/class/gpio/unexport", 51);
    r += writeInt("/sys/class/gpio/unexport", 41);
    return r;
    break;
  case (32):
    r = writeInt("/sys/class/gpio/unexport", 32);
    r += writeInt("/sys/class/gpio/unexport", 31);
    return r;
    break;
  case (18):
    r = writeInt("/sys/class/gpio/unexport", 18);
    r += writeInt("/sys/class/gpio/unexport", 30);
    return r;
    break;
  case (16):
    r = writeInt("/sys/class/gpio/unexport", 16);
    r += writeInt("/sys/class/gpio/unexport", 42);
    return r;
    break;
  case (25):
    r = writeInt("/sys/class/gpio/unexport", 25);
    r += writeInt("/sys/class/gpio/unexport", 43);
    return r;
    break;
  case (38):
    r = writeInt("/sys/class/gpio/unexport", 38);
    r += writeInt("/sys/class/gpio/unexport", 54);
    return r;
    break;
  case (39):
    r = writeInt("/sys/class/gpio/unexport", 39);
    r += writeInt("/sys/class/gpio/unexport", 55);
    return r;
    break;
  default:
    return writeInt("/sys/class/gpio/unexport", n);
  }
}


x86 assembly (clang, -O0):
<unexportIO>:
push   %rbp
mov    %rsp,%rbp
sub    $0x20,%rsp
mov    %dil,%al
mov    %al,-0x5(%rbp)
movzbl -0x5(%rbp),%eax
add    $0xfffffff0,%eax
mov    %eax,%ecx
mov    %rcx,-0x18(%rbp)
sub    $0x23,%eax
ja     12f8 <unexportIO+0x1e8>
mov    -0x18(%rbp),%rax
lea    0xec1(%rip),%rcx
movslq (%rcx,%rax,4),%rax
add    %rcx,%rax
jmp    *%rax
lea    0xf41(%rip),%rdi
mov    $0x32,%esi
call   1030 <writeInt@plt>
mov    %eax,-0xc(%rbp)
lea    0xf2d(%rip),%rdi
mov    $0x28,%esi
call   1030 <writeInt@plt>
add    -0xc(%rbp),%eax
mov    %eax,-0xc(%rbp)
mov    -0xc(%rbp),%eax
mov    %eax,-0x4(%rbp)
jmp    130b <unexportIO+0x1fb>
lea    0xf0b(%rip),%rdi
mov    $0x33,%esi
call   1030 <writeInt@plt>
mov    %eax,-0xc(%rbp)
lea    0xef7(%rip),%rdi
mov    $0x29,%esi
call   1030 <writeInt@plt>
add    -0xc(%rbp),%eax
mov    %eax,-0xc(%rbp)
mov    -0xc(%rbp),%eax
mov    %eax,-0x4(%rbp)
jmp    130b <unexportIO+0x1fb>
lea    0xed5(%rip),%rdi
mov    $0x20,%esi
call   1030 <writeInt@plt>
mov    %eax,-0xc(%rbp)
lea    0xec1(%rip),%rdi
mov    $0x1f,%esi
call   1030 <writeInt@plt>
add    -0xc(%rbp),%eax
mov    %eax,-0xc(%rbp)
mov    -0xc(%rbp),%eax
mov    %eax,-0x4(%rbp)
jmp    130b <unexportIO+0x1fb>
lea    0xe9f(%rip),%rdi
mov    $0x12,%esi
call   1030 <writeInt@plt>
mov    %eax,-0xc(%rbp)
lea    0xe8b(%rip),%rdi
mov    $0x1e,%esi
call   1030 <writeInt@plt>
add    -0xc(%rbp),%eax
mov    %eax,-0xc(%rbp)
mov    -0xc(%rbp),%eax
mov    %eax,-0x4(%rbp)
jmp    130b <unexportIO+0x1fb>
lea    0xe69(%rip),%rdi
mov    $0x10,%esi
call   1030 <writeInt@plt>
mov    %eax,-0xc(%rbp)
lea    0xe55(%rip),%rdi
mov    $0x2a,%esi
call   1030 <writeInt@plt>
add    -0xc(%rbp),%eax
mov    %eax,-0xc(%rbp)
mov    -0xc(%rbp),%eax
mov    %eax,-0x4(%rbp)
jmp    130b <unexportIO+0x1fb>
lea    0xe33(%rip),%rdi
mov    $0x19,%esi
call   1030 <writeInt@plt>
mov    %eax,-0xc(%rbp)
lea    0xe1f(%rip),%rdi
mov    $0x2b,%esi
call   1030 <writeInt@plt>
add    -0xc(%rbp),%eax
mov    %eax,-0xc(%rbp)
mov    -0xc(%rbp),%eax
mov    %eax,-0x4(%rbp)
jmp    130b <unexportIO+0x1fb>
lea    0xdfd(%rip),%rdi
mov    $0x26,%esi
call   1030 <writeInt@plt>
mov    %eax,-0xc(%rbp)
lea    0xde9(%rip),%rdi
mov    $0x36,%esi
call   1030 <writeInt@plt>
add    -0xc(%rbp),%eax
mov    %eax,-0xc(%rbp)
mov    -0xc(%rbp),%eax
mov    %eax,-0x4(%rbp)
jmp    130b <unexportIO+0x1fb>
lea    0xdc7(%rip),%rdi
mov    $0x27,%esi
call   1030 <writeInt@plt>
mov    %eax,-0xc(%rbp)
lea    0xdb3(%rip),%rdi
mov    $0x37,%esi
call   1030 <writeInt@plt>
add    -0xc(%rbp),%eax
mov    %eax,-0xc(%rbp)
mov    -0xc(%rbp),%eax
mov    %eax,-0x4(%rbp)
jmp    130b <unexportIO+0x1fb>
lea    0xd91(%rip),%rdi
movzbl -0x5(%rbp),%esi
call   1030 <writeInt@plt>
mov    %eax,-0x4(%rbp)
mov    -0x4(%rbp),%eax
add    $0x20,%rsp
pop    %rbp
ret

x86 assembly (clang, -O2):
<unexportIO>:
push   %rbp
push   %rbx
push   %rax
lea    -0x10(%rdi),%eax
cmp    $0x23,%al
ja     1150 <unexportIO+0x40>
movzbl %al,%eax
lea    0xedc(%rip),%rcx
movslq (%rcx,%rax,4),%rax
add    %rcx,%rax
jmp    *%rax
lea    0xf5c(%rip),%rbx
mov    %rbx,%rdi
mov    $0x10,%esi
call   1030 <writeInt@plt>
mov    %eax,%ebp
mov    %rbx,%rdi
mov    $0x2a,%esi
jmp    124a <unexportIO+0x13a>
movzbl %dil,%esi
lea    0xf35(%rip),%rdi
add    $0x8,%rsp
pop    %rbx
pop    %rbp
jmp    1030 <writeInt@plt>
lea    0xf23(%rip),%rbx
mov    %rbx,%rdi
mov    $0x12,%esi
call   1030 <writeInt@plt>
mov    %eax,%ebp
mov    %rbx,%rdi
mov    $0x1e,%esi
jmp    124a <unexportIO+0x13a>
lea    0xf00(%rip),%rbx
mov    %rbx,%rdi
mov    $0x19,%esi
call   1030 <writeInt@plt>
mov    %eax,%ebp
mov    %rbx,%rdi
mov    $0x2b,%esi
jmp    124a <unexportIO+0x13a>
lea    0xedd(%rip),%rbx
mov    %rbx,%rdi
mov    $0x20,%esi
call   1030 <writeInt@plt>
mov    %eax,%ebp
mov    %rbx,%rdi
mov    $0x1f,%esi
jmp    124a <unexportIO+0x13a>
lea    0xebd(%rip),%rbx
mov    %rbx,%rdi
mov    $0x26,%esi
call   1030 <writeInt@plt>
mov    %eax,%ebp
mov    %rbx,%rdi
mov    $0x36,%esi
jmp    124a <unexportIO+0x13a>
lea    0xe9d(%rip),%rbx
mov    %rbx,%rdi
mov    $0x27,%esi
call   1030 <writeInt@plt>
mov    %eax,%ebp
mov    %rbx,%rdi
mov    $0x37,%esi
jmp    124a <unexportIO+0x13a>
lea    0xe7d(%rip),%rbx
mov    %rbx,%rdi
mov    $0x32,%esi
call   1030 <writeInt@plt>
mov    %eax,%ebp
mov    %rbx,%rdi
mov    $0x28,%esi
jmp    124a <unexportIO+0x13a>
lea    0xe5d(%rip),%rbx
mov    %rbx,%rdi
mov    $0x33,%esi
call   1030 <writeInt@plt>
mov    %eax,%ebp
mov    %rbx,%rdi
mov    $0x29,%esi
call   1030 <writeInt@plt>
add    %ebp,%eax
add    $0x8,%rsp
pop    %rbx
pop    %rbp
ret

LLVM IR (-O0):
@.str = [25 x i8] c"/sys/class/gpio/unexport\00"
define i32 @unexportIO(i8 zeroext %0) {
%2 = alloca i32
%3 = alloca i8
%4 = alloca i32
store i8 %0, i8* %3
%5 = load i8, i8* %3
%6 = zext i8 %5 to i32
switch i32 %6, label %55 [
i32 50, label %7
i32 51, label %13
i32 32, label %19
i32 18, label %25
i32 16, label %31
i32 25, label %37
i32 38, label %43
i32 39, label %49
]
7: ; preds = %1
%8 = call i32 @writeInt(i8* getelementptr inbounds ([25 x i8], [25 x i8]* @.str, i64 0, i64 0), i8 zeroext 50)
store i32 %8, i32* %4
%9 = call i32 @writeInt(i8* getelementptr inbounds ([25 x i8], [25 x i8]* @.str, i64 0, i64 0), i8 zeroext 40)
%10 = load i32, i32* %4
%11 = add nsw i32 %10, %9
store i32 %11, i32* %4
%12 = load i32, i32* %4
store i32 %12, i32* %2
br label %58
13: ; preds = %1
%14 = call i32 @writeInt(i8* getelementptr inbounds ([25 x i8], [25 x i8]* @.str, i64 0, i64 0), i8 zeroext 51)
store i32 %14, i32* %4
%15 = call i32 @writeInt(i8* getelementptr inbounds ([25 x i8], [25 x i8]* @.str, i64 0, i64 0), i8 zeroext 41)
%16 = load i32, i32* %4
%17 = add nsw i32 %16, %15
store i32 %17, i32* %4
%18 = load i32, i32* %4
store i32 %18, i32* %2
br label %58
19: ; preds = %1
%20 = call i32 @writeInt(i8* getelementptr inbounds ([25 x i8], [25 x i8]* @.str, i64 0, i64 0), i8 zeroext 32)
store i32 %20, i32* %4
%21 = call i32 @writeInt(i8* getelementptr inbounds ([25 x i8], [25 x i8]* @.str, i64 0, i64 0), i8 zeroext 31)
%22 = load i32, i32* %4
%23 = add nsw i32 %22, %21
store i32 %23, i32* %4
%24 = load i32, i32* %4
store i32 %24, i32* %2
br label %58
25: ; preds = %1
%26 = call i32 @writeInt(i8* getelementptr inbounds ([25 x i8], [25 x i8]* @.str, i64 0, i64 0), i8 zeroext 18)
store i32 %26, i32* %4
%27 = call i32 @writeInt(i8* getelementptr inbounds ([25 x i8], [25 x i8]* @.str, i64 0, i64 0), i8 zeroext 30)
%28 = load i32, i32* %4
%29 = add nsw i32 %28, %27
store i32 %29, i32* %4
%30 = load i32, i32* %4
store i32 %30, i32* %2
br label %58
31: ; preds = %1
%32 = call i32 @writeInt(i8* getelementptr inbounds ([25 x i8], [25 x i8]* @.str, i64 0, i64 0), i8 zeroext 16)
store i32 %32, i32* %4
%33 = call i32 @writeInt(i8* getelementptr inbounds ([25 x i8], [25 x i8]* @.str, i64 0, i64 0), i8 zeroext 42)
%34 = load i32, i32* %4
%35 = add nsw i32 %34, %33
store i32 %35, i32* %4
%36 = load i32, i32* %4
store i32 %36, i32* %2
br label %58
37: ; preds = %1
%38 = call i32 @writeInt(i8* getelementptr inbounds ([25 x i8], [25 x i8]* @.str, i64 0, i64 0), i8 zeroext 25)
store i32 %38, i32* %4
%39 = call i32 @writeInt(i8* getelementptr inbounds ([25 x i8], [25 x i8]* @.str, i64 0, i64 0), i8 zeroext 43)
%40 = load i32, i32* %4
%41 = add nsw i32 %40, %39
store i32 %41, i32* %4
%42 = load i32, i32* %4
store i32 %42, i32* %2
br label %58
43: ; preds = %1
%44 = call i32 @writeInt(i8* getelementptr inbounds ([25 x i8], [25 x i8]* @.str, i64 0, i64 0), i8 zeroext 38)
store i32 %44, i32* %4
%45 = call i32 @writeInt(i8* getelementptr inbounds ([25 x i8], [25 x i8]* @.str, i64 0, i64 0), i8 zeroext 54)
%46 = load i32, i32* %4
%47 = add nsw i32 %46, %45
store i32 %47, i32* %4
%48 = load i32, i32* %4
store i32 %48, i32* %2
br label %58
49: ; preds = %1
%50 = call i32 @writeInt(i8* getelementptr inbounds ([25 x i8], [25 x i8]* @.str, i64 0, i64 0), i8 zeroext 39)
store i32 %50, i32* %4
%51 = call i32 @writeInt(i8* getelementptr inbounds ([25 x i8], [25 x i8]* @.str, i64 0, i64 0), i8 zeroext 55)
%52 = load i32, i32* %4
%53 = add nsw i32 %52, %51
store i32 %53, i32* %4
%54 = load i32, i32* %4
store i32 %54, i32* %2
br label %58
55: ; preds = %1
%56 = load i8, i8* %3
%57 = call i32 @writeInt(i8* getelementptr inbounds ([25 x i8], [25 x i8]* @.str, i64 0, i64 0), i8 zeroext %56)
store i32 %57, i32* %2
br label %58
58: ; preds = %55, %49, %43, %37, %31, %25, %19, %13, %7
%59 = load i32, i32* %2
ret i32 %59
}

LLVM IR (-O2):
@.str = [25 x i8] c"/sys/class/gpio/unexport\00"
define i32 @unexportIO(i8 zeroext %0) {
switch i8 %0, label %34 [
i8 50, label %2
i8 51, label %6
i8 32, label %10
i8 18, label %14
i8 16, label %18
i8 25, label %22
i8 38, label %26
i8 39, label %30
]
2: ; preds = %1
%3 = tail call i32 @writeInt(i8* getelementptr inbounds ([25 x i8], [25 x i8]* @.str, i64 0, i64 0), i8 zeroext 50)
%4 = tail call i32 @writeInt(i8* getelementptr inbounds ([25 x i8], [25 x i8]* @.str, i64 0, i64 0), i8 zeroext 40)
%5 = add nsw i32 %4, %3
br label %36
6: ; preds = %1
%7 = tail call i32 @writeInt(i8* getelementptr inbounds ([25 x i8], [25 x i8]* @.str, i64 0, i64 0), i8 zeroext 51)
%8 = tail call i32 @writeInt(i8* getelementptr inbounds ([25 x i8], [25 x i8]* @.str, i64 0, i64 0), i8 zeroext 41)
%9 = add nsw i32 %8, %7
br label %36
10: ; preds = %1
%11 = tail call i32 @writeInt(i8* getelementptr inbounds ([25 x i8], [25 x i8]* @.str, i64 0, i64 0), i8 zeroext 32)
%12 = tail call i32 @writeInt(i8* getelementptr inbounds ([25 x i8], [25 x i8]* @.str, i64 0, i64 0), i8 zeroext 31)
%13 = add nsw i32 %12, %11
br label %36
14: ; preds = %1
%15 = tail call i32 @writeInt(i8* getelementptr inbounds ([25 x i8], [25 x i8]* @.str, i64 0, i64 0), i8 zeroext 18)
%16 = tail call i32 @writeInt(i8* getelementptr inbounds ([25 x i8], [25 x i8]* @.str, i64 0, i64 0), i8 zeroext 30)
%17 = add nsw i32 %16, %15
br label %36
18: ; preds = %1
%19 = tail call i32 @writeInt(i8* getelementptr inbounds ([25 x i8], [25 x i8]* @.str, i64 0, i64 0), i8 zeroext 16)
%20 = tail call i32 @writeInt(i8* getelementptr inbounds ([25 x i8], [25 x i8]* @.str, i64 0, i64 0), i8 zeroext 42)
%21 = add nsw i32 %20, %19
br label %36
22: ; preds = %1
%23 = tail call i32 @writeInt(i8* getelementptr inbounds ([25 x i8], [25 x i8]* @.str, i64 0, i64 0), i8 zeroext 25)
%24 = tail call i32 @writeInt(i8* getelementptr inbounds ([25 x i8], [25 x i8]* @.str, i64 0, i64 0), i8 zeroext 43)
%25 = add nsw i32 %24, %23
br label %36
26: ; preds = %1
%27 = tail call i32 @writeInt(i8* getelementptr inbounds ([25 x i8], [25 x i8]* @.str, i64 0, i64 0), i8 zeroext 38)
%28 = tail call i32 @writeInt(i8* getelementptr inbounds ([25 x i8], [25 x i8]* @.str, i64 0, i64 0), i8 zeroext 54)
%29 = add nsw i32 %28, %27
br label %36
30: ; preds = %1
%31 = tail call i32 @writeInt(i8* getelementptr inbounds ([25 x i8], [25 x i8]* @.str, i64 0, i64 0), i8 zeroext 39)
%32 = tail call i32 @writeInt(i8* getelementptr inbounds ([25 x i8], [25 x i8]* @.str, i64 0, i64 0), i8 zeroext 55)
%33 = add nsw i32 %32, %31
br label %36
34: ; preds = %1
%35 = tail call i32 @writeInt(i8* getelementptr inbounds ([25 x i8], [25 x i8]* @.str, i64 0, i64 0), i8 zeroext %0)
br label %36
36: ; preds = %34, %30, %26, %22, %18, %14, %10, %6, %2
%37 = phi i32 [ %35, %34 ], [ %33, %30 ], [ %29, %26 ], [ %25, %22 ], [ %21, %18 ], [ %17, %14 ], [ %13, %10 ], [ %9, %6 ], [ %5, %2 ]
ret i32 %37
}