int main() {
  int a = 1;
  char b = 'a';
  char c[] = {"Reez-Patel"};
  float d = 10.2;
  double e = 100.212;
  long int f = 2332;
  long long int g = 21321;
  long double h = 312;
  printf("Size of Int = %d bytes \n", sizeof(a));
  printf("Size of char = %d bytes\n"
         "Size of char[] = %d bytes\n"
         "Size of float = %d bytes \n"
         "Size of double = %d bytes\n"
         "Size of long int = %d bytes\n"
         "Size of long long int = %d bytes\n"
         "Size of long double = %ld bytes\n",
         sizeof(b), sizeof(c), sizeof(d), sizeof(e), sizeof(f), sizeof(g),
         sizeof(h));
  return 0;
}


x86 assembly (clang, -O0):
<main>:
push   %rbp
mov    %rsp,%rbp
sub    $0x60,%rsp
movl   $0x0,-0x4(%rbp)
movl   $0x1,-0x8(%rbp)
movb   $0x61,-0x9(%rbp)
movabs $0x7461502d7a656552,%rax
50 61 74
mov    %rax,-0x18(%rbp)
movl   $0x6c6574,-0x11(%rbp)
movl   $0x41233333,-0x1c(%rbp)
movabs $0x40590d916872b021,%rax
0d 59 40
mov    %rax,-0x28(%rbp)
movq   $0x91c,-0x30(%rbp)
movq   $0x5349,-0x38(%rbp)
flds   0xe96(%rip)
fstpt  -0x50(%rbp)
lea    0xe9b(%rip),%rdi
mov    $0x4,%esi
mov    $0x0,%al
call   1030 <printf@plt>
lea    0xea1(%rip),%rdi
mov    $0x1,%esi
mov    $0xb,%edx
mov    $0x4,%ecx
mov    $0x8,%r9d
mov    %r9,%r8
movq   $0x8,(%rsp)
movq   $0x10,0x8(%rsp)
mov    $0x0,%al
call   1030 <printf@plt>
xor    %eax,%eax
add    $0x60,%rsp
pop    %rbp
ret

x86 assembly (clang, -O2):
<main>:
push   %rax
lea    0xee8(%rip),%rdi
mov    $0x4,%esi
xor    %eax,%eax
call   1030 <printf@plt>
lea    0xeee(%rip),%rdi
mov    $0x1,%esi
mov    $0xb,%edx
mov    $0x4,%ecx
mov    $0x8,%r8d
mov    $0x8,%r9d
xor    %eax,%eax
push   $0x10
push   $0x8
call   1030 <printf@plt>
add    $0x10,%rsp
xor    %eax,%eax
pop    %rcx
ret

LLVM IR (-O0):
@__const.main.c = [11 x i8] c"Reez-Patel\00"
@.str = [25 x i8] c"Size of Int = %d bytes \0A\00"
@.str.1 = [196 x i8] c"Size of char = %d bytes\0ASize of char[] = %d bytes\0ASize of float = %d bytes \0ASize of double = %d bytes\0ASize of long int = %d bytes\0ASize of long long int = %d bytes\0ASize of long double = %ld bytes\0A\00"
define i32 @main() {
%1 = alloca i32
%2 = alloca i32
%3 = alloca i8
%4 = alloca [11 x i8]
%5 = alloca float
%6 = alloca double
%7 = alloca i64
%8 = alloca i64
%9 = alloca x86_fp80
store i32 0, i32* %1
store i32 1, i32* %2
store i8 97, i8* %3
%10 = bitcast [11 x i8]* %4 to i8*
store float 0x4024666660000000, float* %5
store double 1.002120e+02, double* %6
store i64 2332, i64* %7
store i64 21321, i64* %8
store x86_fp80 0xK40079C00000000000000, x86_fp80* %9
%11 = call i32 (i8*, ...) @printf(i8* getelementptr inbounds ([25 x i8], [25 x i8]* @.str, i64 0, i64 0), i64 4)
%12 = call i32 (i8*, ...) @printf(i8* getelementptr inbounds ([196 x i8], [196 x i8]* @.str.1, i64 0, i64 0), i64 1, i64 11, i64 4, i64 8, i64 8, i64 8, i64 16)
ret i32 0
}

LLVM IR (-O2):
@.str = [25 x i8] c"Size of Int = %d bytes \0A\00"
@.str.1 = [196 x i8] c"Size of char = %d bytes\0ASize of char[] = %d bytes\0ASize of float = %d bytes \0ASize of double = %d bytes\0ASize of long int = %d bytes\0ASize of long long int = %d bytes\0ASize of long double = %ld bytes\0A\00"
define i32 @main() {
%1 = tail call i32 (i8*, ...) @printf(i8* dereferenceable(1) getelementptr inbounds ([25 x i8], [25 x i8]* @.str, i64 0, i64 0), i64 4)
%2 = tail call i32 (i8*, ...) @printf(i8* dereferenceable(1) getelementptr inbounds ([196 x i8], [196 x i8]* @.str.1, i64 0, i64 0), i64 1, i64 11, i64 4, i64 8, i64 8, i64 8, i64 16)
ret i32 0
}