#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 */
typedef int /*<<< orphan*/ testTwo;
typedef int /*<<< orphan*/ testOne;

/* Variables and functions */
int /*<<< orphan*/ printf(char *, int);
int main(int argc, char *argv[]) {
  int testOne[] = {1, 2, 3, 4, 5, 15};
  char testTwo[] = "Hello";
  printf("This is the size of an integer: %ld\n", sizeof(int));
  printf("This is the size of testOne[]: %ld\n", sizeof(testOne));
  printf("This is the number of ints in testOne: %ld\n\n",
         sizeof(testOne) / sizeof(int));
  printf("This is the size of a character: %ld\n", sizeof(char));
  printf("This is the size of testTwo[]: %ld\n", sizeof(testTwo));
  printf("This is the number of characters in testTwo: %ld\n",
         sizeof(testTwo) / sizeof(char));
  return 0;
}


x86 assembly (clang, -O0):
<main>:
push   %rbp
mov    %rsp,%rbp
sub    $0x40,%rsp
movl   $0x0,-0x4(%rbp)
mov    %edi,-0x8(%rbp)
mov    %rsi,-0x10(%rbp)
mov    0xed3(%rip),%rax
mov    %rax,-0x30(%rbp)
mov    0xed0(%rip),%rax
mov    %rax,-0x28(%rbp)
mov    0xecd(%rip),%rax
mov    %rax,-0x20(%rbp)
mov    0xecb(%rip),%eax
mov    %eax,-0x36(%rbp)
mov    0xec5(%rip),%ax
mov    %ax,-0x32(%rbp)
lea    0xebc(%rip),%rdi
mov    $0x4,%esi
call   1030 <printf@plt>
lea    0xed0(%rip),%rdi
mov    $0x18,%esi
call   1030 <printf@plt>
lea    0xee3(%rip),%rdi
mov    $0x6,%esi
call   1030 <printf@plt>
lea    0xeff(%rip),%rdi
mov    $0x1,%esi
call   1030 <printf@plt>
lea    0xf14(%rip),%rdi
mov    $0x6,%esi
call   1030 <printf@plt>
lea    0xf27(%rip),%rdi
mov    $0x6,%esi
call   1030 <printf@plt>
xor    %eax,%eax
add    $0x40,%rsp
pop    %rbp
ret

x86 assembly (clang, -O2):
<main>:
push   %rax
lea    0xee8(%rip),%rdi
mov    $0x4,%esi
call   1030 <printf@plt>
lea    0xefc(%rip),%rdi
mov    $0x18,%esi
call   1030 <printf@plt>
lea    0xf0f(%rip),%rdi
mov    $0x6,%esi
call   1030 <printf@plt>
lea    0xf2b(%rip),%rdi
mov    $0x1,%esi
call   1030 <printf@plt>
lea    0xf40(%rip),%rdi
mov    $0x6,%esi
call   1030 <printf@plt>
lea    0xf53(%rip),%rdi
mov    $0x6,%esi
call   1030 <printf@plt>
xor    %eax,%eax
pop    %rcx
ret

LLVM IR (-O0):
@__const.main.testOne = [6 x i32] [i32 1, i32 2, i32 3, i32 4, i32 5, i32 15]
@__const.main.testTwo = [6 x i8] c"Hello\00"
@.str = [37 x i8] c"This is the size of an integer: %ld\0A\00"
@.str.1 = [36 x i8] c"This is the size of testOne[]: %ld\0A\00"
@.str.2 = [45 x i8] c"This is the number of ints in testOne: %ld\0A\0A\00"
@.str.3 = [38 x i8] c"This is the size of a character: %ld\0A\00"
@.str.4 = [36 x i8] c"This is the size of testTwo[]: %ld\0A\00"
@.str.5 = [50 x i8] c"This is the number of characters in testTwo: %ld\0A\00"
define i32 @main(i32 %0, i8** %1) {
%3 = alloca i32
%4 = alloca i32
%5 = alloca i8**
%6 = alloca [6 x i32]
%7 = alloca [6 x i8]
store i32 0, i32* %3
store i32 %0, i32* %4
store i8** %1, i8*** %5
%8 = bitcast [6 x i32]* %6 to i8*
%9 = bitcast [6 x i8]* %7 to i8*
%10 = call i32 @printf(i8* getelementptr inbounds ([37 x i8], [37 x i8]* @.str, i64 0, i64 0), i32 4)
%11 = call i32 @printf(i8* getelementptr inbounds ([36 x i8], [36 x i8]* @.str.1, i64 0, i64 0), i32 24)
%12 = call i32 @printf(i8* getelementptr inbounds ([45 x i8], [45 x i8]* @.str.2, i64 0, i64 0), i32 6)
%13 = call i32 @printf(i8* getelementptr inbounds ([38 x i8], [38 x i8]* @.str.3, i64 0, i64 0), i32 1)
%14 = call i32 @printf(i8* getelementptr inbounds ([36 x i8], [36 x i8]* @.str.4, i64 0, i64 0), i32 6)
%15 = call i32 @printf(i8* getelementptr inbounds ([50 x i8], [50 x i8]* @.str.5, i64 0, i64 0), i32 6)
ret i32 0
}

LLVM IR (-O2):
@.str = [37 x i8] c"This is the size of an integer: %ld\0A\00"
@.str.1 = [36 x i8] c"This is the size of testOne[]: %ld\0A\00"
@.str.2 = [45 x i8] c"This is the number of ints in testOne: %ld\0A\0A\00"
@.str.3 = [38 x i8] c"This is the size of a character: %ld\0A\00"
@.str.4 = [36 x i8] c"This is the size of testTwo[]: %ld\0A\00"
@.str.5 = [50 x i8] c"This is the number of characters in testTwo: %ld\0A\00"
define i32 @main(i32 %0, i8** nocapture readnone %1) {
%3 = tail call i32 @printf(i8* getelementptr inbounds ([37 x i8], [37 x i8]* @.str, i64 0, i64 0), i32 4)
%4 = tail call i32 @printf(i8* getelementptr inbounds ([36 x i8], [36 x i8]* @.str.1, i64 0, i64 0), i32 24)
%5 = tail call i32 @printf(i8* getelementptr inbounds ([45 x i8], [45 x i8]* @.str.2, i64 0, i64 0), i32 6)
%6 = tail call i32 @printf(i8* getelementptr inbounds ([38 x i8], [38 x i8]* @.str.3, i64 0, i64 0), i32 1)
%7 = tail call i32 @printf(i8* getelementptr inbounds ([36 x i8], [36 x i8]* @.str.4, i64 0, i64 0), i32 6)
%8 = tail call i32 @printf(i8* getelementptr inbounds ([50 x i8], [50 x i8]* @.str.5, i64 0, i64 0), i32 6)
ret i32 0
}