#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*/ apperr(char *);
int /*<<< orphan*/ decodeState(char);
int /*<<< orphan*/ sprintf(char *, char *, char, char, char,
                           int /*<<< orphan*/);
int /*<<< orphan*/ strcat(char *, char *);
int /*<<< orphan*/ strcpy(char *, char *);
void nonDevelopmentRunningDevelopmentStateGame(char version[]) {
  char errorMessage[200];
  char versionString[100];
  strcpy(errorMessage, "Games generated by a development state compiler");
  sprintf(versionString, "(this game is v%d.%d.%d%s)", version[0], version[1],
          version[2], decodeState(version[3]));
  strcat(errorMessage, versionString);
  strcat(errorMessage,
         "can only be run with a matching interpreter. Look for a game file "
         "generated with an alpha, beta or release state compiler.>\n");
  apperr(errorMessage);
}


x86 assembly (clang, -O0):
<nonDevelopmentRunningDevelopmentStateGame>:
push   %rbp
mov    %rsp,%rbp
sub    $0x150,%rsp
mov    %rdi,-0x8(%rbp)
lea    -0xd0(%rbp),%rdi
lea    0xe93(%rip),%rsi
call   1030 <strcpy@plt>
lea    -0x140(%rbp),%rax
mov    %rax,-0x150(%rbp)
mov    -0x8(%rbp),%rax
mov    (%rax),%al
mov    %al,-0x143(%rbp)
mov    -0x8(%rbp),%rax
mov    0x1(%rax),%al
mov    %al,-0x142(%rbp)
mov    -0x8(%rbp),%rax
mov    0x2(%rax),%al
mov    %al,-0x141(%rbp)
mov    -0x8(%rbp),%rax
movsbl 0x3(%rax),%edi
call   1050 <decodeState@plt>
mov    -0x150(%rbp),%rdi
mov    -0x143(%rbp),%dl
mov    -0x142(%rbp),%cl
mov    %eax,%r9d
mov    -0x141(%rbp),%al
lea    0xe5a(%rip),%rsi
movsbl %dl,%edx
movsbl %cl,%ecx
movsbl %al,%r8d
call   1070 <sprintf@plt>
lea    -0xd0(%rbp),%rdi
lea    -0x140(%rbp),%rsi
call   1060 <strcat@plt>
lea    -0xd0(%rbp),%rdi
lea    0xe45(%rip),%rsi
call   1060 <strcat@plt>
lea    -0xd0(%rbp),%rdi
call   1040 <apperr@plt>
add    $0x150,%rsp
pop    %rbp
ret

x86 assembly (clang, -O2):
<nonDevelopmentRunningDevelopmentStateGame>:
push   %rbp
push   %r15
push   %r14
push   %r12
push   %rbx
sub    $0x140,%rsp
mov    %rdi,%rbx
lea    0xe97(%rip),%rsi
lea    0x70(%rsp),%r14
mov    %r14,%rdi
call   1030 <strcpy@plt>
movsbl (%rbx),%ebp
movsbl 0x1(%rbx),%r15d
movsbl 0x2(%rbx),%r12d
movsbl 0x3(%rbx),%edi
call   1050 <decodeState@plt>
lea    0xe9d(%rip),%rsi
mov    %rsp,%rbx
mov    %rbx,%rdi
mov    %ebp,%edx
mov    %r15d,%ecx
mov    %r12d,%r8d
mov    %eax,%r9d
call   1070 <sprintf@plt>
mov    %r14,%rdi
mov    %rbx,%rsi
call   1060 <strcat@plt>
lea    0xe90(%rip),%rsi
mov    %r14,%rdi
call   1060 <strcat@plt>
mov    %r14,%rdi
call   1040 <apperr@plt>
add    $0x140,%rsp
pop    %rbx
pop    %r12
pop    %r14
pop    %r15
pop    %rbp
ret

LLVM IR (-O0):
@.str = [48 x i8] c"Games generated by a development state compiler\00"
@.str.1 = [27 x i8] c"(this game is v%d.%d.%d%s)\00"
@.str.2 = [125 x i8] c"can only be run with a matching interpreter. Look for a game file generated with an alpha, beta or release state compiler.>\0A\00"
define void @nonDevelopmentRunningDevelopmentStateGame(i8* %0) {
%2 = alloca i8*
%3 = alloca [200 x i8]
%4 = alloca [100 x i8]
store i8* %0, i8** %2
%5 = getelementptr inbounds [200 x i8], [200 x i8]* %3, i64 0, i64 0
%6 = call i32 @strcpy(i8* %5, i8* getelementptr inbounds ([48 x i8], [48 x i8]* @.str, i64 0, i64 0))
%7 = getelementptr inbounds [100 x i8], [100 x i8]* %4, i64 0, i64 0
%8 = load i8*, i8** %2
%9 = getelementptr inbounds i8, i8* %8, i64 0
%10 = load i8, i8* %9
%11 = load i8*, i8** %2
%12 = getelementptr inbounds i8, i8* %11, i64 1
%13 = load i8, i8* %12
%14 = load i8*, i8** %2
%15 = getelementptr inbounds i8, i8* %14, i64 2
%16 = load i8, i8* %15
%17 = load i8*, i8** %2
%18 = getelementptr inbounds i8, i8* %17, i64 3
%19 = load i8, i8* %18
%20 = call i32 @decodeState(i8 signext %19)
%21 = call i32 @sprintf(i8* %7, i8* getelementptr inbounds ([27 x i8], [27 x i8]* @.str.1, i64 0, i64 0), i8 signext %10, i8 signext %13, i8 signext %16, i32 %20)
%22 = getelementptr inbounds [200 x i8], [200 x i8]* %3, i64 0, i64 0
%23 = getelementptr inbounds [100 x i8], [100 x i8]* %4, i64 0, i64 0
%24 = call i32 @strcat(i8* %22, i8* %23)
%25 = getelementptr inbounds [200 x i8], [200 x i8]* %3, i64 0, i64 0
%26 = call i32 @strcat(i8* %25, i8* getelementptr inbounds ([125 x i8], [125 x i8]* @.str.2, i64 0, i64 0))
%27 = getelementptr inbounds [200 x i8], [200 x i8]* %3, i64 0, i64 0
%28 = call i32 @apperr(i8* %27)
ret void
}

LLVM IR (-O2):
@.str = [48 x i8] c"Games generated by a development state compiler\00"
@.str.1 = [27 x i8] c"(this game is v%d.%d.%d%s)\00"
@.str.2 = [125 x i8] c"can only be run with a matching interpreter. Look for a game file generated with an alpha, beta or release state compiler.>\0A\00"
define void @nonDevelopmentRunningDevelopmentStateGame(i8* nocapture %0) {
%2 = alloca [200 x i8]
%3 = alloca [100 x i8]
%4 = getelementptr inbounds [200 x i8], [200 x i8]* %2, i64 0, i64 0
%5 = getelementptr inbounds [100 x i8], [100 x i8]* %3, i64 0, i64 0
%6 = call i32 @strcpy(i8* %4, i8* getelementptr inbounds ([48 x i8], [48 x i8]* @.str, i64 0, i64 0))
%7 = load i8, i8* %0
%8 = getelementptr inbounds i8, i8* %0, i64 1
%9 = load i8, i8* %8
%10 = getelementptr inbounds i8, i8* %0, i64 2
%11 = load i8, i8* %10
%12 = getelementptr inbounds i8, i8* %0, i64 3
%13 = load i8, i8* %12
%14 = call i32 @decodeState(i8 signext %13)
%15 = call i32 @sprintf(i8* %5, i8* dereferenceable(1) getelementptr inbounds ([27 x i8], [27 x i8]* @.str.1, i64 0, i64 0), i8 signext %7, i8 signext %9, i8 signext %11, i32 %14)
%16 = call i32 @strcat(i8* %4, i8* %5)
%17 = call i32 @strcat(i8* %4, i8* getelementptr inbounds ([125 x i8], [125 x i8]* @.str.2, i64 0, i64 0))
%18 = call i32 @apperr(i8* %4)
ret void
}