#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*/ LC_ALL;
int createAbc(int, char **);
int /*<<< orphan*/ free(char **);
char **malloc(int);
int /*<<< orphan*/ setlocale(int /*<<< orphan*/, char *);
int runAbcToBigSvg(char *abcFile, char *svgFile) {
  setlocale(LC_ALL, "C");
  char *first = "abcm2ps";
  char *second = "-g";
  char *third = "-s";
  char *fourth = "2";
  char *fifth = "-w";
  char *sixth = "15.28in";
  char *seventh = "-O";
  char **argc = malloc(sizeof(char *) * 9);
  argc[0] = first;
  argc[1] = second;
  argc[2] = third;
  argc[3] = fourth;
  argc[4] = fifth;
  argc[5] = sixth;
  argc[6] = seventh;
  argc[7] = svgFile;
  argc[8] = abcFile;
  int answer = createAbc(9, argc);
  free(argc);
  return answer;
}


x86 assembly (clang, -O0):
<runAbcToBigSvg>:
push   %rbp
mov    %rsp,%rbp
sub    $0x60,%rsp
mov    %rdi,-0x8(%rbp)
mov    %rsi,-0x10(%rbp)
mov    0x2e89(%rip),%rax
mov    (%rax),%edi
lea    0xea0(%rip),%rsi
call   1060 <setlocale@plt>
lea    0xe96(%rip),%rax
mov    %rax,-0x18(%rbp)
lea    0xe93(%rip),%rax
mov    %rax,-0x20(%rbp)
lea    0xe8b(%rip),%rax
mov    %rax,-0x28(%rbp)
lea    0xe83(%rip),%rax
mov    %rax,-0x30(%rbp)
lea    0xe7a(%rip),%rax
mov    %rax,-0x38(%rbp)
lea    0xe72(%rip),%rax
mov    %rax,-0x40(%rbp)
lea    0xe6f(%rip),%rax
mov    %rax,-0x48(%rbp)
mov    $0x48,%edi
call   1050 <malloc@plt>
mov    %rax,-0x50(%rbp)
mov    -0x18(%rbp),%rcx
mov    -0x50(%rbp),%rax
mov    %rcx,(%rax)
mov    -0x20(%rbp),%rcx
mov    -0x50(%rbp),%rax
mov    %rcx,0x8(%rax)
mov    -0x28(%rbp),%rcx
mov    -0x50(%rbp),%rax
mov    %rcx,0x10(%rax)
mov    -0x30(%rbp),%rcx
mov    -0x50(%rbp),%rax
mov    %rcx,0x18(%rax)
mov    -0x38(%rbp),%rcx
mov    -0x50(%rbp),%rax
mov    %rcx,0x20(%rax)
mov    -0x40(%rbp),%rcx
mov    -0x50(%rbp),%rax
mov    %rcx,0x28(%rax)
mov    -0x48(%rbp),%rcx
mov    -0x50(%rbp),%rax
mov    %rcx,0x30(%rax)
mov    -0x10(%rbp),%rcx
mov    -0x50(%rbp),%rax
mov    %rcx,0x38(%rax)
mov    -0x8(%rbp),%rcx
mov    -0x50(%rbp),%rax
mov    %rcx,0x40(%rax)
mov    -0x50(%rbp),%rsi
mov    $0x9,%edi
call   1040 <createAbc@plt>
mov    %eax,-0x54(%rbp)
mov    -0x50(%rbp),%rdi
call   1030 <free@plt>
mov    -0x54(%rbp),%eax
add    $0x60,%rsp
pop    %rbp
ret

x86 assembly (clang, -O2):
<runAbcToBigSvg>:
push   %rbp
push   %r15
push   %r14
push   %rbx
push   %rax
mov    %rsi,%r15
mov    %rdi,%r14
mov    0x2e8c(%rip),%rax
mov    (%rax),%edi
lea    0xea3(%rip),%rsi
call   1060 <setlocale@plt>
mov    $0x48,%edi
call   1050 <malloc@plt>
mov    %rax,%rbx
lea    0xe8c(%rip),%rax
mov    %rax,(%rbx)
lea    0xe8a(%rip),%rax
mov    %rax,0x8(%rbx)
lea    0xe82(%rip),%rax
mov    %rax,0x10(%rbx)
lea    0xe7a(%rip),%rax
mov    %rax,0x18(%rbx)
lea    0xe71(%rip),%rax
mov    %rax,0x20(%rbx)
lea    0xe69(%rip),%rax
mov    %rax,0x28(%rbx)
lea    0xe66(%rip),%rax
mov    %rax,0x30(%rbx)
mov    %r15,0x38(%rbx)
mov    %r14,0x40(%rbx)
mov    $0x9,%edi
mov    %rbx,%rsi
call   1040 <createAbc@plt>
mov    %eax,%ebp
mov    %rbx,%rdi
call   1030 <free@plt>
mov    %ebp,%eax
add    $0x8,%rsp
pop    %rbx
pop    %r14
pop    %r15
pop    %rbp
ret

LLVM IR (-O0):
@LC_ALL = global i32 0
@.str = [2 x i8] c"C\00"
@.str.1 = [8 x i8] c"abcm2ps\00"
@.str.2 = [3 x i8] c"-g\00"
@.str.3 = [3 x i8] c"-s\00"
@.str.4 = [2 x i8] c"2\00"
@.str.5 = [3 x i8] c"-w\00"
@.str.6 = [8 x i8] c"15.28in\00"
@.str.7 = [3 x i8] c"-O\00"
define i32 @runAbcToBigSvg(i8* %0, i8* %1) {
%3 = alloca i8*
%4 = alloca i8*
%5 = alloca i8*
%6 = alloca i8*
%7 = alloca i8*
%8 = alloca i8*
%9 = alloca i8*
%10 = alloca i8*
%11 = alloca i8*
%12 = alloca i8**
%13 = alloca i32
store i8* %0, i8** %3
store i8* %1, i8** %4
%14 = load i32, i32* @LC_ALL
%15 = call i32 @setlocale(i32 %14, i8* getelementptr inbounds ([2 x i8], [2 x i8]* @.str, i64 0, i64 0))
store i8* getelementptr inbounds ([8 x i8], [8 x i8]* @.str.1, i64 0, i64 0), i8** %5
store i8* getelementptr inbounds ([3 x i8], [3 x i8]* @.str.2, i64 0, i64 0), i8** %6
store i8* getelementptr inbounds ([3 x i8], [3 x i8]* @.str.3, i64 0, i64 0), i8** %7
store i8* getelementptr inbounds ([2 x i8], [2 x i8]* @.str.4, i64 0, i64 0), i8** %8
store i8* getelementptr inbounds ([3 x i8], [3 x i8]* @.str.5, i64 0, i64 0), i8** %9
store i8* getelementptr inbounds ([8 x i8], [8 x i8]* @.str.6, i64 0, i64 0), i8** %10
store i8* getelementptr inbounds ([3 x i8], [3 x i8]* @.str.7, i64 0, i64 0), i8** %11
%16 = call i8** @malloc(i32 72)
store i8** %16, i8*** %12
%17 = load i8*, i8** %5
%18 = load i8**, i8*** %12
%19 = getelementptr inbounds i8*, i8** %18, i64 0
store i8* %17, i8** %19
%20 = load i8*, i8** %6
%21 = load i8**, i8*** %12
%22 = getelementptr inbounds i8*, i8** %21, i64 1
store i8* %20, i8** %22
%23 = load i8*, i8** %7
%24 = load i8**, i8*** %12
%25 = getelementptr inbounds i8*, i8** %24, i64 2
store i8* %23, i8** %25
%26 = load i8*, i8** %8
%27 = load i8**, i8*** %12
%28 = getelementptr inbounds i8*, i8** %27, i64 3
store i8* %26, i8** %28
%29 = load i8*, i8** %9
%30 = load i8**, i8*** %12
%31 = getelementptr inbounds i8*, i8** %30, i64 4
store i8* %29, i8** %31
%32 = load i8*, i8** %10
%33 = load i8**, i8*** %12
%34 = getelementptr inbounds i8*, i8** %33, i64 5
store i8* %32, i8** %34
%35 = load i8*, i8** %11
%36 = load i8**, i8*** %12
%37 = getelementptr inbounds i8*, i8** %36, i64 6
store i8* %35, i8** %37
%38 = load i8*, i8** %4
%39 = load i8**, i8*** %12
%40 = getelementptr inbounds i8*, i8** %39, i64 7
store i8* %38, i8** %40
%41 = load i8*, i8** %3
%42 = load i8**, i8*** %12
%43 = getelementptr inbounds i8*, i8** %42, i64 8
store i8* %41, i8** %43
%44 = load i8**, i8*** %12
%45 = call i32 @createAbc(i32 9, i8** %44)
store i32 %45, i32* %13
%46 = load i8**, i8*** %12
%47 = call i32 @free(i8** %46)
%48 = load i32, i32* %13
ret i32 %48
}

LLVM IR (-O2):
@LC_ALL = global i32 0
@.str = [2 x i8] c"C\00"
@.str.1 = [8 x i8] c"abcm2ps\00"
@.str.2 = [3 x i8] c"-g\00"
@.str.3 = [3 x i8] c"-s\00"
@.str.4 = [2 x i8] c"2\00"
@.str.5 = [3 x i8] c"-w\00"
@.str.6 = [8 x i8] c"15.28in\00"
@.str.7 = [3 x i8] c"-O\00"
define i32 @runAbcToBigSvg(i8* %0, i8* %1) {
%3 = load i32, i32* @LC_ALL
%4 = tail call i32 @setlocale(i32 %3, i8* getelementptr inbounds ([2 x i8], [2 x i8]* @.str, i64 0, i64 0))
%5 = tail call i8** @malloc(i32 72)
store i8* getelementptr inbounds ([8 x i8], [8 x i8]* @.str.1, i64 0, i64 0), i8** %5
%6 = getelementptr inbounds i8*, i8** %5, i64 1
store i8* getelementptr inbounds ([3 x i8], [3 x i8]* @.str.2, i64 0, i64 0), i8** %6
%7 = getelementptr inbounds i8*, i8** %5, i64 2
store i8* getelementptr inbounds ([3 x i8], [3 x i8]* @.str.3, i64 0, i64 0), i8** %7
%8 = getelementptr inbounds i8*, i8** %5, i64 3
store i8* getelementptr inbounds ([2 x i8], [2 x i8]* @.str.4, i64 0, i64 0), i8** %8
%9 = getelementptr inbounds i8*, i8** %5, i64 4
store i8* getelementptr inbounds ([3 x i8], [3 x i8]* @.str.5, i64 0, i64 0), i8** %9
%10 = getelementptr inbounds i8*, i8** %5, i64 5
store i8* getelementptr inbounds ([8 x i8], [8 x i8]* @.str.6, i64 0, i64 0), i8** %10
%11 = getelementptr inbounds i8*, i8** %5, i64 6
store i8* getelementptr inbounds ([3 x i8], [3 x i8]* @.str.7, i64 0, i64 0), i8** %11
%12 = getelementptr inbounds i8*, i8** %5, i64 7
store i8* %1, i8** %12
%13 = getelementptr inbounds i8*, i8** %5, i64 8
store i8* %0, i8** %13
%14 = tail call i32 @createAbc(i32 9, i8** %5)
%15 = tail call i32 @free(i8** %5)
ret i32 %14
}