#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 */
struct tm {
  int tm_mon;
  int tm_mday;
  int tm_hour;
  int tm_min;
};
struct stat {
  int st_mode;
  int /*<<< orphan*/ st_mtime;
  int /*<<< orphan*/ st_size;
  int /*<<< orphan*/ st_gid;
  int /*<<< orphan*/ st_uid;
  int /*<<< orphan*/ st_nlink;
};

/* Variables and functions */
#define S_IFBLK 134
#define S_IFCHR 133
#define S_IFDIR 132
#define S_IFIFO 131
#define S_IFLNK 130
int S_IFMT;
#define S_IFREG 129
#define S_IFSOCK 128
int S_IRGRP;
int S_IROTH;
int S_IRUSR;
int S_ISGID;
int S_ISUID;
int S_ISVTX;
int S_IWGRP;
int S_IWOTH;
int S_IWUSR;
int S_IXGRP;
int S_IXOTH;
int S_IXUSR;
char *get_Groupname(int /*<<< orphan*/);
char *get_Username(int /*<<< orphan*/);
struct tm *localtime(int /*<<< orphan*/ *);
int /*<<< orphan*/ printf(char *, ...);
int /*<<< orphan*/ stat(char *, struct stat *);
void print_Stat(char *name) {
  struct stat sb;
  char *owner, *group;
  struct tm *t;
  stat(name, &sb);
  switch (sb.st_mode & S_IFMT) {
  case S_IFREG:
    printf("-");
    break;
  case S_IFDIR:
    printf("d");
    break;
  case S_IFLNK:
    printf("l");
    break;
  case S_IFIFO:
    printf("p");
    break;
  case S_IFSOCK:
    printf("s");
    break;
  case S_IFBLK:
    printf("b");
    break;
  case S_IFCHR:
    printf("c");
    break;
  default:
    printf("?");
    break;
  }
  printf((sb.st_mode & S_IRUSR) ? "r" : "-");
  printf((sb.st_mode & S_IWUSR) ? "w" : "-");
  printf((sb.st_mode & S_ISUID) ? "s" : (sb.st_mode & S_IXUSR) ? "x" : "-");
  printf((sb.st_mode & S_IRGRP) ? "r" : "-");
  printf((sb.st_mode & S_IWGRP) ? "w" : "-");
  printf((sb.st_mode & S_ISGID) ? "s" : (sb.st_mode & S_IXGRP) ? "x" : "-");
  printf((sb.st_mode & S_IROTH) ? "r" : "-");
  printf((sb.st_mode & S_IWOTH) ? "w" : "-");
  printf((sb.st_mode & S_IXOTH) ? "x" : "-");
  printf((sb.st_mode & S_ISVTX) ? "t" : "");
  printf(" %ld", sb.st_nlink);
  owner = get_Username(sb.st_uid);
  printf(" %s", owner);
  group = get_Groupname(sb.st_gid);
  printf(" %s", group);
  printf(" %7ld", sb.st_size);
  t = localtime(&sb.st_mtime);
  switch (t->tm_mon) {
  case 0:
    printf(" Jen");
    break;
  case 1:
    printf(" Feb");
    break;
  case 2:
    printf(" Mar");
    break;
  case 3:
    printf(" Apr");
    break;
  case 4:
    printf(" May");
    break;
  case 5:
    printf(" Jun");
    break;
  case 6:
    printf(" Jul");
    break;
  case 7:
    printf(" Aug");
    break;
  case 8:
    printf(" Sep");
    break;
  case 9:
    printf(" Oct");
    break;
  case 10:
    printf(" Nov");
    break;
  case 11:
    printf(" Dec");
    break;
  }
  printf(" %2d %02d:%02d ", t->tm_mday, t->tm_hour, t->tm_min);
}


x86 assembly (clang, -O0):
<print_Stat>:
push   %rbp
mov    %rsp,%rbp
sub    $0x70,%rsp
mov    %rdi,-0x8(%rbp)
mov    -0x8(%rbp),%rdi
lea    -0x20(%rbp),%rsi
call   1050 <stat@plt>
mov    -0x20(%rbp),%eax
mov    0x2e35(%rip),%rcx
mov    (%rcx),%ecx
and    %ecx,%eax
add    $0xffffff80,%eax
mov    %eax,%ecx
mov    %rcx,-0x40(%rbp)
sub    $0x6,%eax
ja     1222 <print_Stat+0xd2>
mov    -0x40(%rbp),%rax
lea    0xe6c(%rip),%rcx
movslq (%rcx,%rax,4),%rax
add    %rcx,%rax
jmp    *%rax
lea    0xea8(%rip),%rdi
mov    $0x0,%al
call   1040 <printf@plt>
jmp    1230 <print_Stat+0xe0>
lea    0xea0(%rip),%rdi
mov    $0x0,%al
call   1040 <printf@plt>
jmp    1230 <print_Stat+0xe0>
lea    0xeba(%rip),%rdi
mov    $0x0,%al
call   1040 <printf@plt>
jmp    1230 <print_Stat+0xe0>
lea    0xeb1(%rip),%rdi
mov    $0x0,%al
call   1040 <printf@plt>
jmp    1230 <print_Stat+0xe0>
lea    0xe6b(%rip),%rdi
mov    $0x0,%al
call   1040 <printf@plt>
jmp    1230 <print_Stat+0xe0>
lea    0xe68(%rip),%rdi
mov    $0x0,%al
call   1040 <printf@plt>
jmp    1230 <print_Stat+0xe0>
lea    0xe87(%rip),%rdi
mov    $0x0,%al
call   1040 <printf@plt>
jmp    1230 <print_Stat+0xe0>
lea    0xe25(%rip),%rdi
mov    $0x0,%al
call   1040 <printf@plt>
mov    -0x20(%rbp),%ecx
mov    0x2d4e(%rip),%rax
and    (%rax),%ecx
lea    0xe09(%rip),%rdi
lea    0xe26(%rip),%rax
cmp    $0x0,%ecx
cmovne %rax,%rdi
mov    $0x0,%al
call   1040 <printf@plt>
mov    -0x20(%rbp),%ecx
mov    0x2d5e(%rip),%rax
and    (%rax),%ecx
lea    0xde1(%rip),%rdi
lea    0xdde(%rip),%rax
cmp    $0x0,%ecx
cmovne %rax,%rdi
mov    $0x0,%al
call   1040 <printf@plt>
mov    -0x20(%rbp),%eax
mov    0x2d46(%rip),%rcx
and    (%rcx),%eax
cmp    $0x0,%eax
je     12a5 <print_Stat+0x155>
lea    0xdbf(%rip),%rax
mov    %rax,-0x48(%rbp)
jmp    12ca <print_Stat+0x17a>
mov    -0x20(%rbp),%edx
mov    0x2d29(%rip),%rax
and    (%rax),%edx
lea    0xd94(%rip),%rax
lea    0xd93(%rip),%rcx
cmp    $0x0,%edx
cmovne %rcx,%rax
mov    %rax,-0x48(%rbp)
mov    -0x48(%rbp),%rdi
mov    $0x0,%al
call   1040 <printf@plt>
mov    -0x20(%rbp),%ecx
mov    0x2cb9(%rip),%rax
and    (%rax),%ecx
lea    0xd64(%rip),%rdi
lea    0xd81(%rip),%rax
cmp    $0x0,%ecx
cmovne %rax,%rdi
mov    $0x0,%al
call   1040 <printf@plt>
mov    -0x20(%rbp),%ecx
mov    0x2cc1(%rip),%rax
and    (%rax),%ecx
lea    0xd3c(%rip),%rdi
lea    0xd39(%rip),%rax
cmp    $0x0,%ecx
cmovne %rax,%rdi
mov    $0x0,%al
call   1040 <printf@plt>
mov    -0x20(%rbp),%eax
mov    0x2c71(%rip),%rcx
and    (%rcx),%eax
cmp    $0x0,%eax
je     134a <print_Stat+0x1fa>
lea    0xd1a(%rip),%rax
mov    %rax,-0x50(%rbp)
jmp    136f <print_Stat+0x21f>
mov    -0x20(%rbp),%edx
mov    0x2c64(%rip),%rax
and    (%rax),%edx
lea    0xcef(%rip),%rax
lea    0xcee(%rip),%rcx
cmp    $0x0,%edx
cmovne %rcx,%rax
mov    %rax,-0x50(%rbp)
mov    -0x50(%rbp),%rdi
xor    %eax,%eax
mov    %al,-0x59(%rbp)
call   1040 <printf@plt>
mov    -0x59(%rbp),%al
mov    -0x20(%rbp),%ecx
mov    0x2c06(%rip),%rdx
mov    (%rdx),%edx
and    %edx,%ecx
test   %ecx,%ecx
lea    0xcd9(%rip),%rcx
lea    0xcae(%rip),%rdi
mov    %rdi,-0x70(%rbp)
cmovne %rcx,%rdi
call   1040 <printf@plt>
mov    -0x70(%rbp),%rdi
mov    -0x59(%rbp),%al
mov    -0x20(%rbp),%ecx
mov    0x2bbc(%rip),%rdx
mov    (%rdx),%edx
and    %edx,%ecx
test   %ecx,%ecx
lea    0xc87(%rip),%rcx
cmovne %rcx,%rdi
call   1040 <printf@plt>
mov    -0x70(%rbp),%rdi
mov    -0x59(%rbp),%al
mov    -0x20(%rbp),%ecx
mov    0x2bfd(%rip),%rdx
mov    (%rdx),%edx
and    %edx,%ecx
test   %ecx,%ecx
lea    0xc62(%rip),%rcx
cmovne %rcx,%rdi
call   1040 <printf@plt>
mov    -0x59(%rbp),%al
mov    -0x20(%rbp),%ecx
mov    0x2be2(%rip),%rdx
mov    (%rdx),%edx
and    %edx,%ecx
test   %ecx,%ecx
lea    0xc80(%rip),%rcx
lea    0xc94(%rip),%rdi
cmovne %rcx,%rdi
call   1040 <printf@plt>
mov    -0x59(%rbp),%al
mov    -0xc(%rbp),%esi
lea    0xc24(%rip),%rdi
call   1040 <printf@plt>
mov    -0x10(%rbp),%edi
call   1060 <get_Username@plt>
mov    %rax,%rcx
mov    -0x59(%rbp),%al
mov    %rcx,-0x28(%rbp)
mov    -0x28(%rbp),%rsi
lea    0xc07(%rip),%rdi
mov    %rdi,-0x68(%rbp)
call   1040 <printf@plt>
mov    -0x14(%rbp),%edi
call   1070 <get_Groupname@plt>
mov    -0x68(%rbp),%rdi
mov    %rax,%rcx
mov    -0x59(%rbp),%al
mov    %rcx,-0x30(%rbp)
mov    -0x30(%rbp),%rsi
call   1040 <printf@plt>
mov    -0x59(%rbp),%al
mov    -0x18(%rbp),%esi
lea    0xbd6(%rip),%rdi
call   1040 <printf@plt>
lea    -0x1c(%rbp),%rdi
call   1030 <localtime@plt>
mov    %rax,-0x38(%rbp)
mov    -0x38(%rbp),%rax
mov    (%rax),%eax
mov    %rax,-0x58(%rbp)
sub    $0xb,%rax
ja     15a0 <print_Stat+0x450>
mov    -0x58(%rbp),%rax
lea    0xb64(%rip),%rcx
movslq (%rcx,%rax,4),%rax
add    %rcx,%rax
jmp    *%rax
lea    0xb9b(%rip),%rdi
mov    $0x0,%al
call   1040 <printf@plt>
jmp    15a0 <print_Stat+0x450>
lea    0xb8d(%rip),%rdi
mov    $0x0,%al
call   1040 <printf@plt>
jmp    15a0 <print_Stat+0x450>
lea    0xb7f(%rip),%rdi
mov    $0x0,%al
call   1040 <printf@plt>
jmp    15a0 <print_Stat+0x450>
lea    0xb71(%rip),%rdi
mov    $0x0,%al
call   1040 <printf@plt>
jmp    15a0 <print_Stat+0x450>
lea    0xb63(%rip),%rdi
mov    $0x0,%al
call   1040 <printf@plt>
jmp    15a0 <print_Stat+0x450>
lea    0xb55(%rip),%rdi
mov    $0x0,%al
call   1040 <printf@plt>
jmp    15a0 <print_Stat+0x450>
lea    0xb47(%rip),%rdi
mov    $0x0,%al
call   1040 <printf@plt>
jmp    15a0 <print_Stat+0x450>
lea    0xb39(%rip),%rdi
mov    $0x0,%al
call   1040 <printf@plt>
jmp    15a0 <print_Stat+0x450>
lea    0xb2b(%rip),%rdi
mov    $0x0,%al
call   1040 <printf@plt>
jmp    15a0 <print_Stat+0x450>
lea    0xb1d(%rip),%rdi
mov    $0x0,%al
call   1040 <printf@plt>
jmp    15a0 <print_Stat+0x450>
lea    0xb0f(%rip),%rdi
mov    $0x0,%al
call   1040 <printf@plt>
jmp    15a0 <print_Stat+0x450>
lea    0xb01(%rip),%rdi
mov    $0x0,%al
call   1040 <printf@plt>
mov    -0x38(%rbp),%rax
mov    0x4(%rax),%esi
mov    -0x38(%rbp),%rax
mov    0x8(%rax),%edx
mov    -0x38(%rbp),%rax
mov    0xc(%rax),%ecx
lea    0xae3(%rip),%rdi
mov    $0x0,%al
call   1040 <printf@plt>
add    $0x70,%rsp
pop    %rbp
ret

x86 assembly (clang, -O2):
<print_Stat>:
push   %rbp
push   %r15
push   %r14
push   %r13
push   %r12
push   %rbx
sub    $0x18,%rsp
mov    %rsp,%rsi
call   1060 <stat@plt>
mov    (%rsp),%ebp
mov    0x2e28(%rip),%rax
mov    (%rax),%eax
and    %ebp,%eax
add    $0xffffff80,%eax
mov    $0x3f,%edi
cmp    $0x6,%eax
ja     119d <print_Stat+0x3d>
cltq
lea    0xeca(%rip),%rcx
mov    (%rcx,%rax,4),%edi
call   1030 <putchar@plt>
mov    0x2ddf(%rip),%rax
mov    (%rax),%eax
and    %ebp,%eax
lea    0xe4c(%rip),%r12
lea    0xe67(%rip),%r14
mov    %r14,%rdi
cmove  %r12,%rdi
xor    %eax,%eax
call   1050 <printf@plt>
mov    0x2df0(%rip),%rax
mov    (%rax),%eax
and    %ebp,%eax
lea    0xe27(%rip),%r15
mov    %r15,%rdi
cmove  %r12,%rdi
xor    %eax,%eax
call   1050 <printf@plt>
mov    0x2de0(%rip),%rax
mov    (%rax),%eax
and    %ebp,%eax
mov    0x2ddd(%rip),%rcx
mov    (%rcx),%ecx
and    %ebp,%ecx
lea    0xdfe(%rip),%rbx
mov    %rbx,%rdi
cmove  %r12,%rdi
test   %eax,%eax
lea    0xdf7(%rip),%r13
cmovne %r13,%rdi
xor    %eax,%eax
call   1050 <printf@plt>
mov    0x2d70(%rip),%rax
mov    (%rax),%eax
and    %ebp,%eax
mov    %r14,%rdi
cmove  %r12,%rdi
xor    %eax,%eax
call   1050 <printf@plt>
mov    0x2d87(%rip),%rax
mov    (%rax),%eax
and    %ebp,%eax
mov    %r15,%rdi
cmove  %r12,%rdi
xor    %eax,%eax
call   1050 <printf@plt>
mov    0x2d46(%rip),%rax
mov    (%rax),%eax
and    %ebp,%eax
mov    0x2d53(%rip),%rcx
mov    (%rcx),%ecx
and    %ebp,%ecx
mov    %rbx,%rdi
cmove  %r12,%rdi
test   %eax,%eax
cmovne %r13,%rdi
xor    %eax,%eax
call   1050 <printf@plt>
mov    0x2d0c(%rip),%rax
mov    (%rax),%eax
and    %ebp,%eax
cmove  %r12,%r14
mov    %r14,%rdi
xor    %eax,%eax
call   1050 <printf@plt>
mov    0x2cdb(%rip),%rax
mov    (%rax),%eax
and    %ebp,%eax
cmove  %r12,%r15
mov    %r15,%rdi
xor    %eax,%eax
call   1050 <printf@plt>
mov    0x2d2a(%rip),%rax
mov    (%rax),%eax
and    %ebp,%eax
cmove  %r12,%rbx
mov    %rbx,%rdi
xor    %eax,%eax
call   1050 <printf@plt>
mov    0x2d19(%rip),%rax
and    (%rax),%ebp
lea    0xd88(%rip),%rax
lea    0xd66(%rip),%rdi
cmove  %rax,%rdi
xor    %eax,%eax
call   1050 <printf@plt>
mov    0x14(%rsp),%esi
lea    0xd11(%rip),%rdi
xor    %eax,%eax
call   1050 <printf@plt>
mov    0x10(%rsp),%edi
call   1070 <get_Username@plt>
lea    0xcff(%rip),%rbx
mov    %rbx,%rdi
mov    %rax,%rsi
xor    %eax,%eax
call   1050 <printf@plt>
mov    0xc(%rsp),%edi
call   1080 <get_Groupname@plt>
mov    %rbx,%rdi
mov    %rax,%rsi
xor    %eax,%eax
call   1050 <printf@plt>
mov    0x8(%rsp),%esi
lea    0xcd5(%rip),%rdi
xor    %eax,%eax
call   1050 <printf@plt>
lea    0x4(%rsp),%rdi
call   1040 <localtime@plt>
mov    %rax,%rbx
movslq (%rax),%rax
cmp    $0xb,%rax
ja     136c <print_Stat+0x20c>
lea    0xd22(%rip),%rcx
movslq (%rcx,%rax,4),%rdi
add    %rcx,%rdi
xor    %eax,%eax
call   1050 <printf@plt>
mov    0x4(%rbx),%esi
mov    0x8(%rbx),%edx
mov    0xc(%rbx),%ecx
lea    0xcd5(%rip),%rdi
xor    %eax,%eax
call   1050 <printf@plt>
add    $0x18,%rsp
pop    %rbx
pop    %r12
pop    %r13
pop    %r14
pop    %r15
pop    %rbp
ret

LLVM IR (-O0):
%struct.stat = type { i32, i32, i32, i32, i32, i32 }
%struct.tm = type { i32, i32, i32, i32 }
@S_IFMT = global i32 0
@.str = [2 x i8] c"-\00"
@.str.1 = [2 x i8] c"d\00"
@.str.2 = [2 x i8] c"l\00"
@.str.3 = [2 x i8] c"p\00"
@.str.4 = [2 x i8] c"s\00"
@.str.5 = [2 x i8] c"b\00"
@.str.6 = [2 x i8] c"c\00"
@.str.7 = [2 x i8] c"?\00"
@S_IRUSR = global i32 0
@.str.8 = [2 x i8] c"r\00"
@S_IWUSR = global i32 0
@.str.9 = [2 x i8] c"w\00"
@S_ISUID = global i32 0
@S_IXUSR = global i32 0
@.str.10 = [2 x i8] c"x\00"
@S_IRGRP = global i32 0
@S_IWGRP = global i32 0
@S_ISGID = global i32 0
@S_IXGRP = global i32 0
@S_IROTH = global i32 0
@S_IWOTH = global i32 0
@S_IXOTH = global i32 0
@S_ISVTX = global i32 0
@.str.11 = [2 x i8] c"t\00"
@.str.12 = [1 x i8] zeroinitializer
@.str.13 = [5 x i8] c" %ld\00"
@.str.14 = [4 x i8] c" %s\00"
@.str.15 = [6 x i8] c" %7ld\00"
@.str.16 = [5 x i8] c" Jen\00"
@.str.17 = [5 x i8] c" Feb\00"
@.str.18 = [5 x i8] c" Mar\00"
@.str.19 = [5 x i8] c" Apr\00"
@.str.20 = [5 x i8] c" May\00"
@.str.21 = [5 x i8] c" Jun\00"
@.str.22 = [5 x i8] c" Jul\00"
@.str.23 = [5 x i8] c" Aug\00"
@.str.24 = [5 x i8] c" Sep\00"
@.str.25 = [5 x i8] c" Oct\00"
@.str.26 = [5 x i8] c" Nov\00"
@.str.27 = [5 x i8] c" Dec\00"
@.str.28 = [16 x i8] c" %2d %02d:%02d \00"
define void @print_Stat(i8* %0) {
%2 = alloca i8*
%3 = alloca %struct.stat
%4 = alloca i8*
%5 = alloca i8*
%6 = alloca %struct.tm*
store i8* %0, i8** %2
%7 = load i8*, i8** %2
%8 = call i32 @stat(i8* %7, %struct.stat* %3)
%9 = getelementptr inbounds %struct.stat, %struct.stat* %3, i32 0, i32 0
%10 = load i32, i32* %9
%11 = load i32, i32* @S_IFMT
%12 = and i32 %10, %11
switch i32 %12, label %27 [
i32 129, label %13
i32 132, label %15
i32 130, label %17
i32 131, label %19
i32 128, label %21
i32 134, label %23
i32 133, label %25
]
13: ; preds = %1
%14 = call i32 (i8*, ...) @printf(i8* getelementptr inbounds ([2 x i8], [2 x i8]* @.str, i64 0, i64 0))
br label %29
15: ; preds = %1
%16 = call i32 (i8*, ...) @printf(i8* getelementptr inbounds ([2 x i8], [2 x i8]* @.str.1, i64 0, i64 0))
br label %29
17: ; preds = %1
%18 = call i32 (i8*, ...) @printf(i8* getelementptr inbounds ([2 x i8], [2 x i8]* @.str.2, i64 0, i64 0))
br label %29
19: ; preds = %1
%20 = call i32 (i8*, ...) @printf(i8* getelementptr inbounds ([2 x i8], [2 x i8]* @.str.3, i64 0, i64 0))
br label %29
21: ; preds = %1
%22 = call i32 (i8*, ...) @printf(i8* getelementptr inbounds ([2 x i8], [2 x i8]* @.str.4, i64 0, i64 0))
br label %29
23: ; preds = %1
%24 = call i32 (i8*, ...) @printf(i8* getelementptr inbounds ([2 x i8], [2 x i8]* @.str.5, i64 0, i64 0))
br label %29
25: ; preds = %1
%26 = call i32 (i8*, ...) @printf(i8* getelementptr inbounds ([2 x i8], [2 x i8]* @.str.6, i64 0, i64 0))
br label %29
27: ; preds = %1
%28 = call i32 (i8*, ...) @printf(i8* getelementptr inbounds ([2 x i8], [2 x i8]* @.str.7, i64 0, i64 0))
br label %29
29: ; preds = %27, %25, %23, %21, %19, %17, %15, %13
%30 = getelementptr inbounds %struct.stat, %struct.stat* %3, i32 0, i32 0
%31 = load i32, i32* %30
%32 = load i32, i32* @S_IRUSR
%33 = and i32 %31, %32
%34 = icmp ne i32 %33, 0
%35 = zext i1 %34 to i64
%36 = select i1 %34, i8* getelementptr inbounds ([2 x i8], [2 x i8]* @.str.8, i64 0, i64 0), i8* getelementptr inbounds ([2 x i8], [2 x i8]* @.str, i64 0, i64 0)
%37 = call i32 (i8*, ...) @printf(i8* %36)
%38 = getelementptr inbounds %struct.stat, %struct.stat* %3, i32 0, i32 0
%39 = load i32, i32* %38
%40 = load i32, i32* @S_IWUSR
%41 = and i32 %39, %40
%42 = icmp ne i32 %41, 0
%43 = zext i1 %42 to i64
%44 = select i1 %42, i8* getelementptr inbounds ([2 x i8], [2 x i8]* @.str.9, i64 0, i64 0), i8* getelementptr inbounds ([2 x i8], [2 x i8]* @.str, i64 0, i64 0)
%45 = call i32 (i8*, ...) @printf(i8* %44)
%46 = getelementptr inbounds %struct.stat, %struct.stat* %3, i32 0, i32 0
%47 = load i32, i32* %46
%48 = load i32, i32* @S_ISUID
%49 = and i32 %47, %48
%50 = icmp ne i32 %49, 0
br i1 %50, label %51, label %52
51: ; preds = %29
br label %60
52: ; preds = %29
%53 = getelementptr inbounds %struct.stat, %struct.stat* %3, i32 0, i32 0
%54 = load i32, i32* %53
%55 = load i32, i32* @S_IXUSR
%56 = and i32 %54, %55
%57 = icmp ne i32 %56, 0
%58 = zext i1 %57 to i64
%59 = select i1 %57, i8* getelementptr inbounds ([2 x i8], [2 x i8]* @.str.10, i64 0, i64 0), i8* getelementptr inbounds ([2 x i8], [2 x i8]* @.str, i64 0, i64 0)
br label %60
60: ; preds = %52, %51
%61 = phi i8* [ getelementptr inbounds ([2 x i8], [2 x i8]* @.str.4, i64 0, i64 0), %51 ], [ %59, %52 ]
%62 = call i32 (i8*, ...) @printf(i8* %61)
%63 = getelementptr inbounds %struct.stat, %struct.stat* %3, i32 0, i32 0
%64 = load i32, i32* %63
%65 = load i32, i32* @S_IRGRP
%66 = and i32 %64, %65
%67 = icmp ne i32 %66, 0
%68 = zext i1 %67 to i64
%69 = select i1 %67, i8* getelementptr inbounds ([2 x i8], [2 x i8]* @.str.8, i64 0, i64 0), i8* getelementptr inbounds ([2 x i8], [2 x i8]* @.str, i64 0, i64 0)
%70 = call i32 (i8*, ...) @printf(i8* %69)
%71 = getelementptr inbounds %struct.stat, %struct.stat* %3, i32 0, i32 0
%72 = load i32, i32* %71
%73 = load i32, i32* @S_IWGRP
%74 = and i32 %72, %73
%75 = icmp ne i32 %74, 0
%76 = zext i1 %75 to i64
%77 = select i1 %75, i8* getelementptr inbounds ([2 x i8], [2 x i8]* @.str.9, i64 0, i64 0), i8* getelementptr inbounds ([2 x i8], [2 x i8]* @.str, i64 0, i64 0)
%78 = call i32 (i8*, ...) @printf(i8* %77)
%79 = getelementptr inbounds %struct.stat, %struct.stat* %3, i32 0, i32 0
%80 = load i32, i32* %79
%81 = load i32, i32* @S_ISGID
%82 = and i32 %80, %81
%83 = icmp ne i32 %82, 0
br i1 %83, label %84, label %85
84: ; preds = %60
br label %93
85: ; preds = %60
%86 = getelementptr inbounds %struct.stat, %struct.stat* %3, i32 0, i32 0
%87 = load i32, i32* %86
%88 = load i32, i32* @S_IXGRP
%89 = and i32 %87, %88
%90 = icmp ne i32 %89, 0
%91 = zext i1 %90 to i64
%92 = select i1 %90, i8* getelementptr inbounds ([2 x i8], [2 x i8]* @.str.10, i64 0, i64 0), i8* getelementptr inbounds ([2 x i8], [2 x i8]* @.str, i64 0, i64 0)
br label %93
93: ; preds = %85, %84
%94 = phi i8* [ getelementptr inbounds ([2 x i8], [2 x i8]* @.str.4, i64 0, i64 0), %84 ], [ %92, %85 ]
%95 = call i32 (i8*, ...) @printf(i8* %94)
%96 = getelementptr inbounds %struct.stat, %struct.stat* %3, i32 0, i32 0
%97 = load i32, i32* %96
%98 = load i32, i32* @S_IROTH
%99 = and i32 %97, %98
%100 = icmp ne i32 %99, 0
%101 = zext i1 %100 to i64
%102 = select i1 %100, i8* getelementptr inbounds ([2 x i8], [2 x i8]* @.str.8, i64 0, i64 0), i8* getelementptr inbounds ([2 x i8], [2 x i8]* @.str, i64 0, i64 0)
%103 = call i32 (i8*, ...) @printf(i8* %102)
%104 = getelementptr inbounds %struct.stat, %struct.stat* %3, i32 0, i32 0
%105 = load i32, i32* %104
%106 = load i32, i32* @S_IWOTH
%107 = and i32 %105, %106
%108 = icmp ne i32 %107, 0
%109 = zext i1 %108 to i64
%110 = select i1 %108, i8* getelementptr inbounds ([2 x i8], [2 x i8]* @.str.9, i64 0, i64 0), i8* getelementptr inbounds ([2 x i8], [2 x i8]* @.str, i64 0, i64 0)
%111 = call i32 (i8*, ...) @printf(i8* %110)
%112 = getelementptr inbounds %struct.stat, %struct.stat* %3, i32 0, i32 0
%113 = load i32, i32* %112
%114 = load i32, i32* @S_IXOTH
%115 = and i32 %113, %114
%116 = icmp ne i32 %115, 0
%117 = zext i1 %116 to i64
%118 = select i1 %116, i8* getelementptr inbounds ([2 x i8], [2 x i8]* @.str.10, i64 0, i64 0), i8* getelementptr inbounds ([2 x i8], [2 x i8]* @.str, i64 0, i64 0)
%119 = call i32 (i8*, ...) @printf(i8* %118)
%120 = getelementptr inbounds %struct.stat, %struct.stat* %3, i32 0, i32 0
%121 = load i32, i32* %120
%122 = load i32, i32* @S_ISVTX
%123 = and i32 %121, %122
%124 = icmp ne i32 %123, 0
%125 = zext i1 %124 to i64
%126 = select i1 %124, i8* getelementptr inbounds ([2 x i8], [2 x i8]* @.str.11, i64 0, i64 0), i8* getelementptr inbounds ([1 x i8], [1 x i8]* @.str.12, i64 0, i64 0)
%127 = call i32 (i8*, ...) @printf(i8* %126)
%128 = getelementptr inbounds %struct.stat, %struct.stat* %3, i32 0, i32 5
%129 = load i32, i32* %128
%130 = call i32 (i8*, ...) @printf(i8* getelementptr inbounds ([5 x i8], [5 x i8]* @.str.13, i64 0, i64 0), i32 %129)
%131 = getelementptr inbounds %struct.stat, %struct.stat* %3, i32 0, i32 4
%132 = load i32, i32* %131
%133 = call i8* @get_Username(i32 %132)
store i8* %133, i8** %4
%134 = load i8*, i8** %4
%135 = call i32 (i8*, ...) @printf(i8* getelementptr inbounds ([4 x i8], [4 x i8]* @.str.14, i64 0, i64 0), i8* %134)
%136 = getelementptr inbounds %struct.stat, %struct.stat* %3, i32 0, i32 3
%137 = load i32, i32* %136
%138 = call i8* @get_Groupname(i32 %137)
store i8* %138, i8** %5
%139 = load i8*, i8** %5
%140 = call i32 (i8*, ...) @printf(i8* getelementptr inbounds ([4 x i8], [4 x i8]* @.str.14, i64 0, i64 0), i8* %139)
%141 = getelementptr inbounds %struct.stat, %struct.stat* %3, i32 0, i32 2
%142 = load i32, i32* %141
%143 = call i32 (i8*, ...) @printf(i8* getelementptr inbounds ([6 x i8], [6 x i8]* @.str.15, i64 0, i64 0), i32 %142)
%144 = getelementptr inbounds %struct.stat, %struct.stat* %3, i32 0, i32 1
%145 = call %struct.tm* @localtime(i32* %144)
store %struct.tm* %145, %struct.tm** %6
%146 = load %struct.tm*, %struct.tm** %6
%147 = getelementptr inbounds %struct.tm, %struct.tm* %146, i32 0, i32 0
%148 = load i32, i32* %147
switch i32 %148, label %173 [
i32 0, label %149
i32 1, label %151
i32 2, label %153
i32 3, label %155
i32 4, label %157
i32 5, label %159
i32 6, label %161
i32 7, label %163
i32 8, label %165
i32 9, label %167
i32 10, label %169
i32 11, label %171
]
149: ; preds = %93
%150 = call i32 (i8*, ...) @printf(i8* getelementptr inbounds ([5 x i8], [5 x i8]* @.str.16, i64 0, i64 0))
br label %173
151: ; preds = %93
%152 = call i32 (i8*, ...) @printf(i8* getelementptr inbounds ([5 x i8], [5 x i8]* @.str.17, i64 0, i64 0))
br label %173
153: ; preds = %93
%154 = call i32 (i8*, ...) @printf(i8* getelementptr inbounds ([5 x i8], [5 x i8]* @.str.18, i64 0, i64 0))
br label %173
155: ; preds = %93
%156 = call i32 (i8*, ...) @printf(i8* getelementptr inbounds ([5 x i8], [5 x i8]* @.str.19, i64 0, i64 0))
br label %173
157: ; preds = %93
%158 = call i32 (i8*, ...) @printf(i8* getelementptr inbounds ([5 x i8], [5 x i8]* @.str.20, i64 0, i64 0))
br label %173
159: ; preds = %93
%160 = call i32 (i8*, ...) @printf(i8* getelementptr inbounds ([5 x i8], [5 x i8]* @.str.21, i64 0, i64 0))
br label %173
161: ; preds = %93
%162 = call i32 (i8*, ...) @printf(i8* getelementptr inbounds ([5 x i8], [5 x i8]* @.str.22, i64 0, i64 0))
br label %173
163: ; preds = %93
%164 = call i32 (i8*, ...) @printf(i8* getelementptr inbounds ([5 x i8], [5 x i8]* @.str.23, i64 0, i64 0))
br label %173
165: ; preds = %93
%166 = call i32 (i8*, ...) @printf(i8* getelementptr inbounds ([5 x i8], [5 x i8]* @.str.24, i64 0, i64 0))
br label %173
167: ; preds = %93
%168 = call i32 (i8*, ...) @printf(i8* getelementptr inbounds ([5 x i8], [5 x i8]* @.str.25, i64 0, i64 0))
br label %173
169: ; preds = %93
%170 = call i32 (i8*, ...) @printf(i8* getelementptr inbounds ([5 x i8], [5 x i8]* @.str.26, i64 0, i64 0))
br label %173
171: ; preds = %93
%172 = call i32 (i8*, ...) @printf(i8* getelementptr inbounds ([5 x i8], [5 x i8]* @.str.27, i64 0, i64 0))
br label %173
173: ; preds = %93, %171, %169, %167, %165, %163, %161, %159, %157, %155, %153, %151, %149
%174 = load %struct.tm*, %struct.tm** %6
%175 = getelementptr inbounds %struct.tm, %struct.tm* %174, i32 0, i32 1
%176 = load i32, i32* %175
%177 = load %struct.tm*, %struct.tm** %6
%178 = getelementptr inbounds %struct.tm, %struct.tm* %177, i32 0, i32 2
%179 = load i32, i32* %178
%180 = load %struct.tm*, %struct.tm** %6
%181 = getelementptr inbounds %struct.tm, %struct.tm* %180, i32 0, i32 3
%182 = load i32, i32* %181
%183 = call i32 (i8*, ...) @printf(i8* getelementptr inbounds ([16 x i8], [16 x i8]* @.str.28, i64 0, i64 0), i32 %176, i32 %179, i32 %182)
ret void
}

LLVM IR (-O2):
%struct.stat = type { i32, i32, i32, i32, i32, i32 }
%struct.tm = type { i32, i32, i32, i32 }
@S_IFMT = global i32 0
@.str = [2 x i8] c"-\00"
@.str.4 = [2 x i8] c"s\00"
@S_IRUSR = global i32 0
@.str.8 = [2 x i8] c"r\00"
@S_IWUSR = global i32 0
@.str.9 = [2 x i8] c"w\00"
@S_ISUID = global i32 0
@S_IXUSR = global i32 0
@.str.10 = [2 x i8] c"x\00"
@S_IRGRP = global i32 0
@S_IWGRP = global i32 0
@S_ISGID = global i32 0
@S_IXGRP = global i32 0
@S_IROTH = global i32 0
@S_IWOTH = global i32 0
@S_IXOTH = global i32 0
@S_ISVTX = global i32 0
@.str.11 = [2 x i8] c"t\00"
@.str.12 = [1 x i8] zeroinitializer
@.str.13 = [5 x i8] c" %ld\00"
@.str.14 = [4 x i8] c" %s\00"
@.str.15 = [6 x i8] c" %7ld\00"
@.str.16 = [5 x i8] c" Jen\00"
@.str.17 = [5 x i8] c" Feb\00"
@.str.18 = [5 x i8] c" Mar\00"
@.str.19 = [5 x i8] c" Apr\00"
@.str.20 = [5 x i8] c" May\00"
@.str.21 = [5 x i8] c" Jun\00"
@.str.22 = [5 x i8] c" Jul\00"
@.str.23 = [5 x i8] c" Aug\00"
@.str.24 = [5 x i8] c" Sep\00"
@.str.25 = [5 x i8] c" Oct\00"
@.str.26 = [5 x i8] c" Nov\00"
@.str.27 = [5 x i8] c" Dec\00"
@.str.28 = [16 x i8] c" %2d %02d:%02d \00"
@switch.table.print_Stat = [7 x i32] [i32 115, i32 45, i32 108, i32 112, i32 100, i32 99, i32 98]
@reltable.print_Stat = [12 x i32] [i32 trunc (i64 sub (i64 ptrtoint ([5 x i8]* @.str.16 to i64), i64 ptrtoint ([12 x i32]* @reltable.print_Stat to i64)) to i32), i32 trunc (i64 sub (i64 ptrtoint ([5 x i8]* @.str.17 to i64), i64 ptrtoint ([12 x i32]* @reltable.print_Stat to i64)) to i32), i32 trunc (i64 sub (i64 ptrtoint ([5 x i8]* @.str.18 to i64), i64 ptrtoint ([12 x i32]* @reltable.print_Stat to i64)) to i32), i32 trunc (i64 sub (i64 ptrtoint ([5 x i8]* @.str.19 to i64), i64 ptrtoint ([12 x i32]* @reltable.print_Stat to i64)) to i32), i32 trunc (i64 sub (i64 ptrtoint ([5 x i8]* @.str.20 to i64), i64 ptrtoint ([12 x i32]* @reltable.print_Stat to i64)) to i32), i32 trunc (i64 sub (i64 ptrtoint ([5 x i8]* @.str.21 to i64), i64 ptrtoint ([12 x i32]* @reltable.print_Stat to i64)) to i32), i32 trunc (i64 sub (i64 ptrtoint ([5 x i8]* @.str.22 to i64), i64 ptrtoint ([12 x i32]* @reltable.print_Stat to i64)) to i32), i32 trunc (i64 sub (i64 ptrtoint ([5 x i8]* @.str.23 to i64), i64 ptrtoint ([12 x i32]* @reltable.print_Stat to i64)) to i32), i32 trunc (i64 sub (i64 ptrtoint ([5 x i8]* @.str.24 to i64), i64 ptrtoint ([12 x i32]* @reltable.print_Stat to i64)) to i32), i32 trunc (i64 sub (i64 ptrtoint ([5 x i8]* @.str.25 to i64), i64 ptrtoint ([12 x i32]* @reltable.print_Stat to i64)) to i32), i32 trunc (i64 sub (i64 ptrtoint ([5 x i8]* @.str.26 to i64), i64 ptrtoint ([12 x i32]* @reltable.print_Stat to i64)) to i32), i32 trunc (i64 sub (i64 ptrtoint ([5 x i8]* @.str.27 to i64), i64 ptrtoint ([12 x i32]* @reltable.print_Stat to i64)) to i32)]
define void @print_Stat(i8* nocapture %0) {
%2 = alloca %struct.stat
%3 = bitcast %struct.stat* %2 to i8*
%4 = call i32 @stat(i8* %0, %struct.stat* %2)
%5 = getelementptr inbounds %struct.stat, %struct.stat* %2, i64 0, i32 0
%6 = load i32, i32* %5
%7 = load i32, i32* @S_IFMT
%8 = and i32 %7, %6
%9 = add i32 %8, -128
%10 = icmp ult i32 %9, 7
br i1 %10, label %11, label %15
11: ; preds = %1
%12 = sext i32 %9 to i64
%13 = getelementptr inbounds [7 x i32], [7 x i32]* @switch.table.print_Stat, i64 0, i64 %12
%14 = load i32, i32* %13
br label %15
15: ; preds = %1, %11
%16 = phi i32 [ %14, %11 ], [ 63, %1 ]
%17 = tail call i32 @putchar(i32 %16)
%18 = load i32, i32* @S_IRUSR
%19 = and i32 %18, %6
%20 = icmp eq i32 %19, 0
%21 = select i1 %20, i8* getelementptr inbounds ([2 x i8], [2 x i8]* @.str, i64 0, i64 0), i8* getelementptr inbounds ([2 x i8], [2 x i8]* @.str.8, i64 0, i64 0)
%22 = tail call i32 (i8*, ...) @printf(i8* dereferenceable(1) %21)
%23 = load i32, i32* @S_IWUSR
%24 = and i32 %23, %6
%25 = icmp eq i32 %24, 0
%26 = select i1 %25, i8* getelementptr inbounds ([2 x i8], [2 x i8]* @.str, i64 0, i64 0), i8* getelementptr inbounds ([2 x i8], [2 x i8]* @.str.9, i64 0, i64 0)
%27 = tail call i32 (i8*, ...) @printf(i8* dereferenceable(1) %26)
%28 = load i32, i32* @S_ISUID
%29 = and i32 %28, %6
%30 = icmp eq i32 %29, 0
%31 = load i32, i32* @S_IXUSR
%32 = and i32 %31, %6
%33 = icmp eq i32 %32, 0
%34 = select i1 %33, i8* getelementptr inbounds ([2 x i8], [2 x i8]* @.str, i64 0, i64 0), i8* getelementptr inbounds ([2 x i8], [2 x i8]* @.str.10, i64 0, i64 0)
%35 = select i1 %30, i8* %34, i8* getelementptr inbounds ([2 x i8], [2 x i8]* @.str.4, i64 0, i64 0)
%36 = tail call i32 (i8*, ...) @printf(i8* dereferenceable(1) %35)
%37 = load i32, i32* @S_IRGRP
%38 = and i32 %37, %6
%39 = icmp eq i32 %38, 0
%40 = select i1 %39, i8* getelementptr inbounds ([2 x i8], [2 x i8]* @.str, i64 0, i64 0), i8* getelementptr inbounds ([2 x i8], [2 x i8]* @.str.8, i64 0, i64 0)
%41 = tail call i32 (i8*, ...) @printf(i8* dereferenceable(1) %40)
%42 = load i32, i32* @S_IWGRP
%43 = and i32 %42, %6
%44 = icmp eq i32 %43, 0
%45 = select i1 %44, i8* getelementptr inbounds ([2 x i8], [2 x i8]* @.str, i64 0, i64 0), i8* getelementptr inbounds ([2 x i8], [2 x i8]* @.str.9, i64 0, i64 0)
%46 = tail call i32 (i8*, ...) @printf(i8* dereferenceable(1) %45)
%47 = load i32, i32* @S_ISGID
%48 = and i32 %47, %6
%49 = icmp eq i32 %48, 0
%50 = load i32, i32* @S_IXGRP
%51 = and i32 %50, %6
%52 = icmp eq i32 %51, 0
%53 = select i1 %52, i8* getelementptr inbounds ([2 x i8], [2 x i8]* @.str, i64 0, i64 0), i8* getelementptr inbounds ([2 x i8], [2 x i8]* @.str.10, i64 0, i64 0)
%54 = select i1 %49, i8* %53, i8* getelementptr inbounds ([2 x i8], [2 x i8]* @.str.4, i64 0, i64 0)
%55 = tail call i32 (i8*, ...) @printf(i8* dereferenceable(1) %54)
%56 = load i32, i32* @S_IROTH
%57 = and i32 %56, %6
%58 = icmp eq i32 %57, 0
%59 = select i1 %58, i8* getelementptr inbounds ([2 x i8], [2 x i8]* @.str, i64 0, i64 0), i8* getelementptr inbounds ([2 x i8], [2 x i8]* @.str.8, i64 0, i64 0)
%60 = tail call i32 (i8*, ...) @printf(i8* dereferenceable(1) %59)
%61 = load i32, i32* @S_IWOTH
%62 = and i32 %61, %6
%63 = icmp eq i32 %62, 0
%64 = select i1 %63, i8* getelementptr inbounds ([2 x i8], [2 x i8]* @.str, i64 0, i64 0), i8* getelementptr inbounds ([2 x i8], [2 x i8]* @.str.9, i64 0, i64 0)
%65 = tail call i32 (i8*, ...) @printf(i8* dereferenceable(1) %64)
%66 = load i32, i32* @S_IXOTH
%67 = and i32 %66, %6
%68 = icmp eq i32 %67, 0
%69 = select i1 %68, i8* getelementptr inbounds ([2 x i8], [2 x i8]* @.str, i64 0, i64 0), i8* getelementptr inbounds ([2 x i8], [2 x i8]* @.str.10, i64 0, i64 0)
%70 = tail call i32 (i8*, ...) @printf(i8* dereferenceable(1) %69)
%71 = load i32, i32* @S_ISVTX
%72 = and i32 %71, %6
%73 = icmp eq i32 %72, 0
%74 = select i1 %73, i8* getelementptr inbounds ([1 x i8], [1 x i8]* @.str.12, i64 0, i64 0), i8* getelementptr inbounds ([2 x i8], [2 x i8]* @.str.11, i64 0, i64 0)
%75 = tail call i32 (i8*, ...) @printf(i8* dereferenceable(1) %74)
%76 = getelementptr inbounds %struct.stat, %struct.stat* %2, i64 0, i32 5
%77 = load i32, i32* %76
%78 = tail call i32 (i8*, ...) @printf(i8* dereferenceable(1) getelementptr inbounds ([5 x i8], [5 x i8]* @.str.13, i64 0, i64 0), i32 %77)
%79 = getelementptr inbounds %struct.stat, %struct.stat* %2, i64 0, i32 4
%80 = load i32, i32* %79
%81 = tail call i8* @get_Username(i32 %80)
%82 = tail call i32 (i8*, ...) @printf(i8* dereferenceable(1) getelementptr inbounds ([4 x i8], [4 x i8]* @.str.14, i64 0, i64 0), i8* %81)
%83 = getelementptr inbounds %struct.stat, %struct.stat* %2, i64 0, i32 3
%84 = load i32, i32* %83
%85 = tail call i8* @get_Groupname(i32 %84)
%86 = tail call i32 (i8*, ...) @printf(i8* dereferenceable(1) getelementptr inbounds ([4 x i8], [4 x i8]* @.str.14, i64 0, i64 0), i8* %85)
%87 = getelementptr inbounds %struct.stat, %struct.stat* %2, i64 0, i32 2
%88 = load i32, i32* %87
%89 = tail call i32 (i8*, ...) @printf(i8* dereferenceable(1) getelementptr inbounds ([6 x i8], [6 x i8]* @.str.15, i64 0, i64 0), i32 %88)
%90 = getelementptr inbounds %struct.stat, %struct.stat* %2, i64 0, i32 1
%91 = call %struct.tm* @localtime(i32* %90)
%92 = getelementptr inbounds %struct.tm, %struct.tm* %91, i64 0, i32 0
%93 = load i32, i32* %92
%94 = icmp ult i32 %93, 12
br i1 %94, label %95, label %100
95: ; preds = %15
%96 = sext i32 %93 to i64
%97 = shl i64 %96, 2
%98 = call i8* @llvm.load.relative.i64(i8* bitcast ([12 x i32]* @reltable.print_Stat to i8*), i64 %97)
%99 = call i32 (i8*, ...) @printf(i8* dereferenceable(1) %98)
br label %100
100: ; preds = %15, %95
%101 = getelementptr inbounds %struct.tm, %struct.tm* %91, i64 0, i32 1
%102 = load i32, i32* %101
%103 = getelementptr inbounds %struct.tm, %struct.tm* %91, i64 0, i32 2
%104 = load i32, i32* %103
%105 = getelementptr inbounds %struct.tm, %struct.tm* %91, i64 0, i32 3
%106 = load i32, i32* %105
%107 = call i32 (i8*, ...) @printf(i8* dereferenceable(1) getelementptr inbounds ([16 x i8], [16 x i8]* @.str.28, i64 0, i64 0), i32 %102, i32 %104, i32 %106)
ret void
}