#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*/ printf(char *, char *);
int /*<<< orphan*/ sprintf(char *, char *, char *);
int main() {
  char sql[500];
  sprintf(sql,
          "CREATE TABLE IF NOT EXISTS `%s`("
          "`id` INTEGER PRIMARY KEY AUTOINCREMENT NOT NULL,"
          "`username` vchar(64),"
          "`serialnum`  vchar(36),"
          "`pubkey` vchar(280));",
          "T_Admin");
  ;
  printf("%s\n", sql);
  sprintf(sql,
          "CREATE TABLE IF NOT EXISTS `%s`("
          "`id` integer primary key,"
          "`username` vchar(64),"
          "`macaddress`   vchar(18),"
          "`ipaddress` INTEGER );",
          "T_Member");
  ;
  printf("%s\n", sql);
}


x86 assembly (clang, -O0):
<main>:
push   %rbp
mov    %rsp,%rbp
sub    $0x200,%rsp
lea    -0x200(%rbp),%rdi
lea    0xec7(%rip),%rsi
lea    0xf52(%rip),%rdx
call   1040 <sprintf@plt>
lea    -0x200(%rbp),%rsi
lea    0xf47(%rip),%rdi
call   1030 <printf@plt>
lea    -0x200(%rbp),%rdi
lea    0xf38(%rip),%rsi
lea    0xfaf(%rip),%rdx
call   1040 <sprintf@plt>
lea    -0x200(%rbp),%rsi
lea    0xf1a(%rip),%rdi
call   1030 <printf@plt>
xor    %eax,%eax
add    $0x200,%rsp
pop    %rbp
ret

x86 assembly (clang, -O2):
<main>:
push   %r14
push   %rbx
sub    $0x1f8,%rsp
lea    0xecf(%rip),%rsi
lea    0xf5a(%rip),%rdx
mov    %rsp,%rbx
mov    %rbx,%rdi
call   1040 <sprintf@plt>
lea    0xf50(%rip),%r14
mov    %r14,%rdi
mov    %rbx,%rsi
call   1030 <printf@plt>
lea    0xf42(%rip),%rsi
lea    0xfb9(%rip),%rdx
mov    %rbx,%rdi
call   1040 <sprintf@plt>
mov    %r14,%rdi
mov    %rbx,%rsi
call   1030 <printf@plt>
xor    %eax,%eax
add    $0x1f8,%rsp
pop    %rbx
pop    %r14
ret

LLVM IR (-O0):
@.str = [146 x i8] c"CREATE TABLE IF NOT EXISTS `%s`(`id` INTEGER PRIMARY KEY AUTOINCREMENT NOT NULL,`username` vchar(64),`serialnum` vchar(36),`pubkey` vchar(280));\00"
@.str.1 = [8 x i8] c"T_Admin\00"
@.str.2 = [4 x i8] c"%s\0A\00"
@.str.3 = [126 x i8] c"CREATE TABLE IF NOT EXISTS `%s`(`id` integer primary key,`username` vchar(64),`macaddress` vchar(18),`ipaddress` INTEGER );\00"
@.str.4 = [9 x i8] c"T_Member\00"
define i32 @main() {
%1 = alloca [500 x i8]
%2 = getelementptr inbounds [500 x i8], [500 x i8]* %1, i64 0, i64 0
%3 = call i32 @sprintf(i8* %2, i8* getelementptr inbounds ([146 x i8], [146 x i8]* @.str, i64 0, i64 0), i8* getelementptr inbounds ([8 x i8], [8 x i8]* @.str.1, i64 0, i64 0))
%4 = getelementptr inbounds [500 x i8], [500 x i8]* %1, i64 0, i64 0
%5 = call i32 @printf(i8* getelementptr inbounds ([4 x i8], [4 x i8]* @.str.2, i64 0, i64 0), i8* %4)
%6 = getelementptr inbounds [500 x i8], [500 x i8]* %1, i64 0, i64 0
%7 = call i32 @sprintf(i8* %6, i8* getelementptr inbounds ([126 x i8], [126 x i8]* @.str.3, i64 0, i64 0), i8* getelementptr inbounds ([9 x i8], [9 x i8]* @.str.4, i64 0, i64 0))
%8 = getelementptr inbounds [500 x i8], [500 x i8]* %1, i64 0, i64 0
%9 = call i32 @printf(i8* getelementptr inbounds ([4 x i8], [4 x i8]* @.str.2, i64 0, i64 0), i8* %8)
ret i32 0
}

LLVM IR (-O2):
@.str = [146 x i8] c"CREATE TABLE IF NOT EXISTS `%s`(`id` INTEGER PRIMARY KEY AUTOINCREMENT NOT NULL,`username` vchar(64),`serialnum` vchar(36),`pubkey` vchar(280));\00"
@.str.1 = [8 x i8] c"T_Admin\00"
@.str.2 = [4 x i8] c"%s\0A\00"
@.str.3 = [126 x i8] c"CREATE TABLE IF NOT EXISTS `%s`(`id` integer primary key,`username` vchar(64),`macaddress` vchar(18),`ipaddress` INTEGER );\00"
@.str.4 = [9 x i8] c"T_Member\00"
define i32 @main() {
%1 = alloca [500 x i8]
%2 = getelementptr inbounds [500 x i8], [500 x i8]* %1, i64 0, i64 0
%3 = call i32 @sprintf(i8* %2, i8* dereferenceable(1) getelementptr inbounds ([146 x i8], [146 x i8]* @.str, i64 0, i64 0), i8* getelementptr inbounds ([8 x i8], [8 x i8]* @.str.1, i64 0, i64 0))
%4 = call i32 @printf(i8* getelementptr inbounds ([4 x i8], [4 x i8]* @.str.2, i64 0, i64 0), i8* %2)
%5 = call i32 @sprintf(i8* %2, i8* dereferenceable(1) getelementptr inbounds ([126 x i8], [126 x i8]* @.str.3, i64 0, i64 0), i8* getelementptr inbounds ([9 x i8], [9 x i8]* @.str.4, i64 0, i64 0))
%6 = call i32 @printf(i8* getelementptr inbounds ([4 x i8], [4 x i8]* @.str.2, i64 0, i64 0), i8* %2)
ret i32 0
}