#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*/ Inst_Printf(char *, char *, ...);
int Call_C_Arg_String(int offset, int str_no) {
  switch (offset) {
  case 0:
    Inst_Printf("la", "$4,%s%d", ".LC", str_no);
    break;
  case 1:
    Inst_Printf("la", "$5,%s%d", ".LC", str_no);
    break;
  case 2:
    Inst_Printf("la", "$6,%s%d", ".LC", str_no);
    break;
  case 3:
    Inst_Printf("la", "$7,%s%d", ".LC", str_no);
    break;
  case 4:
    Inst_Printf("la", "$8,%s%d", ".LC", str_no);
    break;
  case 5:
    Inst_Printf("la", "$9,%s%d", ".LC", str_no);
    break;
  case 6:
    Inst_Printf("la", "$10,%s%d", ".LC", str_no);
    break;
  case 7:
    Inst_Printf("la", "$11,%s%d", ".LC", str_no);
    break;
  default:
    Inst_Printf("la", "$24,%s%d", ".LC", str_no);
    Inst_Printf("sw", "$24,%d($sp)", (offset - 8) * 8 + 4);
  }
  return 1;
}


x86 assembly (clang, -O0):
<Call_C_Arg_String>:
push   %rbp
mov    %rsp,%rbp
sub    $0x10,%rsp
mov    %edi,-0x4(%rbp)
mov    %esi,-0x8(%rbp)
mov    -0x4(%rbp),%eax
mov    %rax,-0x10(%rbp)
sub    $0x7,%rax
ja     1263 <Call_C_Arg_String+0x153>
mov    -0x10(%rbp),%rax
lea    0xec6(%rip),%rcx
movslq (%rcx,%rax,4),%rax
add    %rcx,%rax
jmp    *%rax
mov    -0x8(%rbp),%ecx
lea    0xed3(%rip),%rdi
lea    0xecf(%rip),%rsi
lea    0xed0(%rip),%rdx
mov    $0x0,%al
call   1030 <Inst_Printf@plt>
jmp    12a3 <Call_C_Arg_String+0x193>
mov    -0x8(%rbp),%ecx
lea    0xeaf(%rip),%rdi
lea    0xeb7(%rip),%rsi
lea    0xeac(%rip),%rdx
mov    $0x0,%al
call   1030 <Inst_Printf@plt>
jmp    12a3 <Call_C_Arg_String+0x193>
mov    -0x8(%rbp),%ecx
lea    0xe8b(%rip),%rdi
lea    0xe9b(%rip),%rsi
lea    0xe88(%rip),%rdx
mov    $0x0,%al
call   1030 <Inst_Printf@plt>
jmp    12a3 <Call_C_Arg_String+0x193>
mov    -0x8(%rbp),%ecx
lea    0xe67(%rip),%rdi
lea    0xe7f(%rip),%rsi
lea    0xe64(%rip),%rdx
mov    $0x0,%al
call   1030 <Inst_Printf@plt>
jmp    12a3 <Call_C_Arg_String+0x193>
mov    -0x8(%rbp),%ecx
lea    0xe43(%rip),%rdi
lea    0xe63(%rip),%rsi
lea    0xe40(%rip),%rdx
mov    $0x0,%al
call   1030 <Inst_Printf@plt>
jmp    12a3 <Call_C_Arg_String+0x193>
mov    -0x8(%rbp),%ecx
lea    0xe1f(%rip),%rdi
lea    0xe47(%rip),%rsi
lea    0xe1c(%rip),%rdx
mov    $0x0,%al
call   1030 <Inst_Printf@plt>
jmp    12a3 <Call_C_Arg_String+0x193>
mov    -0x8(%rbp),%ecx
lea    0xdfb(%rip),%rdi
lea    0xe2b(%rip),%rsi
lea    0xdf8(%rip),%rdx
mov    $0x0,%al
call   1030 <Inst_Printf@plt>
jmp    12a3 <Call_C_Arg_String+0x193>
mov    -0x8(%rbp),%ecx
lea    0xdd7(%rip),%rdi
lea    0xe10(%rip),%rsi
lea    0xdd4(%rip),%rdx
mov    $0x0,%al
call   1030 <Inst_Printf@plt>
jmp    12a3 <Call_C_Arg_String+0x193>
mov    -0x8(%rbp),%ecx
lea    0xdb3(%rip),%rdi
lea    0xdf5(%rip),%rsi
lea    0xdb0(%rip),%rdx
mov    $0x0,%al
call   1030 <Inst_Printf@plt>
mov    -0x4(%rbp),%edx
sub    $0x8,%edx
shl    $0x3,%edx
add    $0x4,%edx
lea    0xddd(%rip),%rdi
lea    0xdd9(%rip),%rsi
mov    $0x0,%al
call   1030 <Inst_Printf@plt>
mov    $0x1,%eax
add    $0x10,%rsp
pop    %rbp
ret

x86 assembly (clang, -O2):
<Call_C_Arg_String>:
push   %rbx
mov    %esi,%ecx
mov    %edi,%ebx
cmp    $0x7,%edi
ja     113f <Call_C_Arg_String+0x2f>
mov    %ebx,%eax
lea    0xedd(%rip),%rdx
movslq (%rdx,%rax,4),%rax
add    %rdx,%rax
jmp    *%rax
lea    0xeed(%rip),%rdi
lea    0xee9(%rip),%rsi
jmp    11e7 <Call_C_Arg_String+0xd7>
lea    0xeda(%rip),%rdi
lea    0xf1c(%rip),%rsi
lea    0xed7(%rip),%rdx
xor    %eax,%eax
call   1030 <Inst_Printf@plt>
lea    -0x3c(,%rbx,8),%edx
lea    0xf09(%rip),%rdi
lea    0xf05(%rip),%rsi
xor    %eax,%eax
call   1030 <Inst_Printf@plt>
jmp    11f5 <Call_C_Arg_String+0xe5>
lea    0xea0(%rip),%rdi
lea    0xea8(%rip),%rsi
jmp    11e7 <Call_C_Arg_String+0xd7>
lea    0xe90(%rip),%rdi
lea    0xea0(%rip),%rsi
jmp    11e7 <Call_C_Arg_String+0xd7>
lea    0xe80(%rip),%rdi
lea    0xe98(%rip),%rsi
jmp    11e7 <Call_C_Arg_String+0xd7>
lea    0xe70(%rip),%rdi
lea    0xe90(%rip),%rsi
jmp    11e7 <Call_C_Arg_String+0xd7>
lea    0xe60(%rip),%rdi
lea    0xe88(%rip),%rsi
jmp    11e7 <Call_C_Arg_String+0xd7>
lea    0xe50(%rip),%rdi
lea    0xe80(%rip),%rsi
jmp    11e7 <Call_C_Arg_String+0xd7>
lea    0xe40(%rip),%rdi
lea    0xe79(%rip),%rsi
lea    0xe3d(%rip),%rdx
xor    %eax,%eax
call   1030 <Inst_Printf@plt>
mov    $0x1,%eax
pop    %rbx
ret

LLVM IR (-O0):
@.str = [3 x i8] c"la\00"
@.str.1 = [8 x i8] c"$4,%s%d\00"
@.str.2 = [4 x i8] c".LC\00"
@.str.3 = [8 x i8] c"$5,%s%d\00"
@.str.4 = [8 x i8] c"$6,%s%d\00"
@.str.5 = [8 x i8] c"$7,%s%d\00"
@.str.6 = [8 x i8] c"$8,%s%d\00"
@.str.7 = [8 x i8] c"$9,%s%d\00"
@.str.8 = [9 x i8] c"$10,%s%d\00"
@.str.9 = [9 x i8] c"$11,%s%d\00"
@.str.10 = [9 x i8] c"$24,%s%d\00"
@.str.11 = [3 x i8] c"sw\00"
@.str.12 = [12 x i8] c"$24,%d($sp)\00"
define i32 @Call_C_Arg_String(i32 %0, i32 %1) {
%3 = alloca i32
%4 = alloca i32
store i32 %0, i32* %3
store i32 %1, i32* %4
%5 = load i32, i32* %3
switch i32 %5, label %30 [
i32 0, label %6
i32 1, label %9
i32 2, label %12
i32 3, label %15
i32 4, label %18
i32 5, label %21
i32 6, label %24
i32 7, label %27
]
6: ; preds = %2
%7 = load i32, i32* %4
%8 = call i32 (i8*, i8*, ...) @Inst_Printf(i8* getelementptr inbounds ([3 x i8], [3 x i8]* @.str, i64 0, i64 0), i8* getelementptr inbounds ([8 x i8], [8 x i8]* @.str.1, i64 0, i64 0), i8* getelementptr inbounds ([4 x i8], [4 x i8]* @.str.2, i64 0, i64 0), i32 %7)
br label %38
9: ; preds = %2
%10 = load i32, i32* %4
%11 = call i32 (i8*, i8*, ...) @Inst_Printf(i8* getelementptr inbounds ([3 x i8], [3 x i8]* @.str, i64 0, i64 0), i8* getelementptr inbounds ([8 x i8], [8 x i8]* @.str.3, i64 0, i64 0), i8* getelementptr inbounds ([4 x i8], [4 x i8]* @.str.2, i64 0, i64 0), i32 %10)
br label %38
12: ; preds = %2
%13 = load i32, i32* %4
%14 = call i32 (i8*, i8*, ...) @Inst_Printf(i8* getelementptr inbounds ([3 x i8], [3 x i8]* @.str, i64 0, i64 0), i8* getelementptr inbounds ([8 x i8], [8 x i8]* @.str.4, i64 0, i64 0), i8* getelementptr inbounds ([4 x i8], [4 x i8]* @.str.2, i64 0, i64 0), i32 %13)
br label %38
15: ; preds = %2
%16 = load i32, i32* %4
%17 = call i32 (i8*, i8*, ...) @Inst_Printf(i8* getelementptr inbounds ([3 x i8], [3 x i8]* @.str, i64 0, i64 0), i8* getelementptr inbounds ([8 x i8], [8 x i8]* @.str.5, i64 0, i64 0), i8* getelementptr inbounds ([4 x i8], [4 x i8]* @.str.2, i64 0, i64 0), i32 %16)
br label %38
18: ; preds = %2
%19 = load i32, i32* %4
%20 = call i32 (i8*, i8*, ...) @Inst_Printf(i8* getelementptr inbounds ([3 x i8], [3 x i8]* @.str, i64 0, i64 0), i8* getelementptr inbounds ([8 x i8], [8 x i8]* @.str.6, i64 0, i64 0), i8* getelementptr inbounds ([4 x i8], [4 x i8]* @.str.2, i64 0, i64 0), i32 %19)
br label %38
21: ; preds = %2
%22 = load i32, i32* %4
%23 = call i32 (i8*, i8*, ...) @Inst_Printf(i8* getelementptr inbounds ([3 x i8], [3 x i8]* @.str, i64 0, i64 0), i8* getelementptr inbounds ([8 x i8], [8 x i8]* @.str.7, i64 0, i64 0), i8* getelementptr inbounds ([4 x i8], [4 x i8]* @.str.2, i64 0, i64 0), i32 %22)
br label %38
24: ; preds = %2
%25 = load i32, i32* %4
%26 = call i32 (i8*, i8*, ...) @Inst_Printf(i8* getelementptr inbounds ([3 x i8], [3 x i8]* @.str, i64 0, i64 0), i8* getelementptr inbounds ([9 x i8], [9 x i8]* @.str.8, i64 0, i64 0), i8* getelementptr inbounds ([4 x i8], [4 x i8]* @.str.2, i64 0, i64 0), i32 %25)
br label %38
27: ; preds = %2
%28 = load i32, i32* %4
%29 = call i32 (i8*, i8*, ...) @Inst_Printf(i8* getelementptr inbounds ([3 x i8], [3 x i8]* @.str, i64 0, i64 0), i8* getelementptr inbounds ([9 x i8], [9 x i8]* @.str.9, i64 0, i64 0), i8* getelementptr inbounds ([4 x i8], [4 x i8]* @.str.2, i64 0, i64 0), i32 %28)
br label %38
30: ; preds = %2
%31 = load i32, i32* %4
%32 = call i32 (i8*, i8*, ...) @Inst_Printf(i8* getelementptr inbounds ([3 x i8], [3 x i8]* @.str, i64 0, i64 0), i8* getelementptr inbounds ([9 x i8], [9 x i8]* @.str.10, i64 0, i64 0), i8* getelementptr inbounds ([4 x i8], [4 x i8]* @.str.2, i64 0, i64 0), i32 %31)
%33 = load i32, i32* %3
%34 = sub nsw i32 %33, 8
%35 = mul nsw i32 %34, 8
%36 = add nsw i32 %35, 4
%37 = call i32 (i8*, i8*, ...) @Inst_Printf(i8* getelementptr inbounds ([3 x i8], [3 x i8]* @.str.11, i64 0, i64 0), i8* getelementptr inbounds ([12 x i8], [12 x i8]* @.str.12, i64 0, i64 0), i32 %36)
br label %38
38: ; preds = %30, %27, %24, %21, %18, %15, %12, %9, %6
ret i32 1
}

LLVM IR (-O2):
@.str = [3 x i8] c"la\00"
@.str.1 = [8 x i8] c"$4,%s%d\00"
@.str.2 = [4 x i8] c".LC\00"
@.str.3 = [8 x i8] c"$5,%s%d\00"
@.str.4 = [8 x i8] c"$6,%s%d\00"
@.str.5 = [8 x i8] c"$7,%s%d\00"
@.str.6 = [8 x i8] c"$8,%s%d\00"
@.str.7 = [8 x i8] c"$9,%s%d\00"
@.str.8 = [9 x i8] c"$10,%s%d\00"
@.str.9 = [9 x i8] c"$11,%s%d\00"
@.str.10 = [9 x i8] c"$24,%s%d\00"
@.str.11 = [3 x i8] c"sw\00"
@.str.12 = [12 x i8] c"$24,%d($sp)\00"
define i32 @Call_C_Arg_String(i32 %0, i32 %1) {
switch i32 %0, label %19 [
i32 0, label %3
i32 1, label %5
i32 2, label %7
i32 3, label %9
i32 4, label %11
i32 5, label %13
i32 6, label %15
i32 7, label %17
]
3: ; preds = %2
%4 = tail call i32 (i8*, i8*, ...) @Inst_Printf(i8* getelementptr inbounds ([3 x i8], [3 x i8]* @.str, i64 0, i64 0), i8* getelementptr inbounds ([8 x i8], [8 x i8]* @.str.1, i64 0, i64 0), i8* getelementptr inbounds ([4 x i8], [4 x i8]* @.str.2, i64 0, i64 0), i32 %1)
br label %24
5: ; preds = %2
%6 = tail call i32 (i8*, i8*, ...) @Inst_Printf(i8* getelementptr inbounds ([3 x i8], [3 x i8]* @.str, i64 0, i64 0), i8* getelementptr inbounds ([8 x i8], [8 x i8]* @.str.3, i64 0, i64 0), i8* getelementptr inbounds ([4 x i8], [4 x i8]* @.str.2, i64 0, i64 0), i32 %1)
br label %24
7: ; preds = %2
%8 = tail call i32 (i8*, i8*, ...) @Inst_Printf(i8* getelementptr inbounds ([3 x i8], [3 x i8]* @.str, i64 0, i64 0), i8* getelementptr inbounds ([8 x i8], [8 x i8]* @.str.4, i64 0, i64 0), i8* getelementptr inbounds ([4 x i8], [4 x i8]* @.str.2, i64 0, i64 0), i32 %1)
br label %24
9: ; preds = %2
%10 = tail call i32 (i8*, i8*, ...) @Inst_Printf(i8* getelementptr inbounds ([3 x i8], [3 x i8]* @.str, i64 0, i64 0), i8* getelementptr inbounds ([8 x i8], [8 x i8]* @.str.5, i64 0, i64 0), i8* getelementptr inbounds ([4 x i8], [4 x i8]* @.str.2, i64 0, i64 0), i32 %1)
br label %24
11: ; preds = %2
%12 = tail call i32 (i8*, i8*, ...) @Inst_Printf(i8* getelementptr inbounds ([3 x i8], [3 x i8]* @.str, i64 0, i64 0), i8* getelementptr inbounds ([8 x i8], [8 x i8]* @.str.6, i64 0, i64 0), i8* getelementptr inbounds ([4 x i8], [4 x i8]* @.str.2, i64 0, i64 0), i32 %1)
br label %24
13: ; preds = %2
%14 = tail call i32 (i8*, i8*, ...) @Inst_Printf(i8* getelementptr inbounds ([3 x i8], [3 x i8]* @.str, i64 0, i64 0), i8* getelementptr inbounds ([8 x i8], [8 x i8]* @.str.7, i64 0, i64 0), i8* getelementptr inbounds ([4 x i8], [4 x i8]* @.str.2, i64 0, i64 0), i32 %1)
br label %24
15: ; preds = %2
%16 = tail call i32 (i8*, i8*, ...) @Inst_Printf(i8* getelementptr inbounds ([3 x i8], [3 x i8]* @.str, i64 0, i64 0), i8* getelementptr inbounds ([9 x i8], [9 x i8]* @.str.8, i64 0, i64 0), i8* getelementptr inbounds ([4 x i8], [4 x i8]* @.str.2, i64 0, i64 0), i32 %1)
br label %24
17: ; preds = %2
%18 = tail call i32 (i8*, i8*, ...) @Inst_Printf(i8* getelementptr inbounds ([3 x i8], [3 x i8]* @.str, i64 0, i64 0), i8* getelementptr inbounds ([9 x i8], [9 x i8]* @.str.9, i64 0, i64 0), i8* getelementptr inbounds ([4 x i8], [4 x i8]* @.str.2, i64 0, i64 0), i32 %1)
br label %24
19: ; preds = %2
%20 = tail call i32 (i8*, i8*, ...) @Inst_Printf(i8* getelementptr inbounds ([3 x i8], [3 x i8]* @.str, i64 0, i64 0), i8* getelementptr inbounds ([9 x i8], [9 x i8]* @.str.10, i64 0, i64 0), i8* getelementptr inbounds ([4 x i8], [4 x i8]* @.str.2, i64 0, i64 0), i32 %1)
%21 = shl i32 %0, 3
%22 = add i32 %21, -60
%23 = tail call i32 (i8*, i8*, ...) @Inst_Printf(i8* getelementptr inbounds ([3 x i8], [3 x i8]* @.str.11, i64 0, i64 0), i8* getelementptr inbounds ([12 x i8], [12 x i8]* @.str.12, i64 0, i64 0), i32 %22)
br label %24
24: ; preds = %19, %17, %15, %13, %11, %9, %7, %5, %3
ret i32 1
}