#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 scalar_t__ uid_t;
struct stat {
  scalar_t__ st_uid;
  int /*<<< orphan*/ st_mode;
};
typedef int /*<<< orphan*/ mode_t;

/* Variables and functions */
int /*<<< orphan*/ DisplayUsage(char *);
int /*<<< orphan*/ S_IRGRP;
int /*<<< orphan*/ S_IROTH;
int /*<<< orphan*/ S_IRUSR;
int /*<<< orphan*/ S_IWGRP;
int /*<<< orphan*/ S_IWOTH;
int /*<<< orphan*/ S_IWUSR;
int /*<<< orphan*/ S_IXGRP;
int /*<<< orphan*/ S_IXOTH;
int /*<<< orphan*/ S_IXUSR;
int /*<<< orphan*/ abort();
int chmod(char *, int /*<<< orphan*/);
int /*<<< orphan*/ fprintf(int /*<<< orphan*/, char *, ...);
int getopt(int, char **, char *);
scalar_t__ getuid();
int /*<<< orphan*/ isprint(unsigned char);
char *optarg;
scalar_t__ opterr;
int optind;
unsigned char optopt;
int /*<<< orphan*/ perror(char *);
int /*<<< orphan*/ printf(char *);
scalar_t__ stat(char *, struct stat *);
int /*<<< orphan*/ stderr;
int strlen(char *);
int main(int argc, char **argv) {
  int c;
  int i;
  int index;
  int fileCount = 0;
  char isFileError = 0;
  uid_t myUid = getuid();
  struct stat fileStat;
  mode_t addPermissions = 0;
  mode_t removePermissions = 0;
  opterr = 0;
  while ((c = getopt(argc, argv, "u:g:o:U:G:O:")) != -1) {
    switch (c) {
    case 'u':
      for (i = 0; i < strlen(optarg); i++) {
        if (optarg[i] == 'r')
          addPermissions |= S_IRUSR;
        else if (optarg[i] == 'w')
          addPermissions |= S_IWUSR;
        else if (optarg[i] == 'x')
          addPermissions |= S_IXUSR;
      }
      break;
    case 'g':
      for (i = 0; i < strlen(optarg); i++) {
        if (optarg[i] == 'r')
          addPermissions |= S_IRGRP;
        else if (optarg[i] == 'w')
          addPermissions |= S_IWGRP;
        else if (optarg[i] == 'x')
          addPermissions |= S_IXGRP;
      }
      break;
    case 'o':
      for (i = 0; i < strlen(optarg); i++) {
        if (optarg[i] == 'r')
          addPermissions |= S_IROTH;
        else if (optarg[i] == 'w')
          addPermissions |= S_IWOTH;
        else if (optarg[i] == 'x')
          addPermissions |= S_IXOTH;
      }
      break;
    case 'U':
      for (i = 0; i < strlen(optarg); i++) {
        if (optarg[i] == 'r')
          removePermissions |= S_IRUSR;
        else if (optarg[i] == 'w')
          removePermissions |= S_IWUSR;
        else if (optarg[i] == 'x')
          removePermissions |= S_IXUSR;
      }
      break;
    case 'G':
      for (i = 0; i < strlen(optarg); i++) {
        if (optarg[i] == 'r')
          removePermissions |= S_IRGRP;
        else if (optarg[i] == 'w')
          removePermissions |= S_IWGRP;
        else if (optarg[i] == 'x')
          removePermissions |= S_IXGRP;
      }
      break;
    case 'O':
      for (i = 0; i < strlen(optarg); i++) {
        if (optarg[i] == 'r')
          removePermissions |= S_IROTH;
        else if (optarg[i] == 'w')
          removePermissions |= S_IWOTH;
        else if (optarg[i] == 'x')
          removePermissions |= S_IXOTH;
      }
      break;
    case '?':
      if (optopt == 'u' || optopt == 'g' || optopt == 'o' || optopt == 'U' ||
          optopt == 'G' || optopt == 'O')
        fprintf(stderr, "\n\t***Option -%c requires an argument***\n", optopt);
      else if (isprint(optopt))
        fprintf(stderr, "\n\t***Unknown option `-%c'***\n", optopt);
      else
        fprintf(stderr, "\n\t***Unknown option character `\\x%x'***\n", optopt);
      DisplayUsage(argv[0]);
      printf("Exit status: 1\n");
      return 1;
    default:
      abort();
    }
  }
  if (argc == 1)
    DisplayUsage(argv[0]);
  else {
    for (index = optind; index < argc; index++) {
      ++fileCount;
      if (stat(argv[index], &fileStat) < 0) {
        perror("Stat()");
        isFileError = 1;
      } else if (fileStat.st_uid != myUid && myUid != 0) {
        fprintf(stderr, "UID ERROR: You do not own this file\n");
        isFileError = 1;
      }
      fileStat.st_mode |= addPermissions;
      fileStat.st_mode &= ~removePermissions;
      if (chmod(argv[index], fileStat.st_mode) == -1) {
        perror(argv[index]);
        isFileError = 1;
      }
    }
  }
  if (fileCount == 0) {
    printf("No file specified\nExit Status: 2\n");
    return 2;
  }
  if (isFileError) {
    printf("Exit status: 2\n");
    return 2;
  } else {
    printf("Exit status: 0\n");
    return 0;
  }
}


x86 assembly (clang, -O0):
<main>:
push   %rbp
mov    %rsp,%rbp
sub    $0x70,%rsp
movl   $0x0,-0x4(%rbp)
mov    %edi,-0x8(%rbp)
mov    %rsi,-0x10(%rbp)
movl   $0x0,-0x20(%rbp)
movb   $0x0,-0x21(%rbp)
mov    $0x0,%al
call   1050 <getuid@plt>
mov    %rax,-0x30(%rbp)
movl   $0x0,-0x44(%rbp)
movl   $0x0,-0x48(%rbp)
mov    0x2d8f(%rip),%rax
movq   $0x0,(%rax)
mov    -0x8(%rbp),%edi
mov    -0x10(%rbp),%rsi
lea    0xed6(%rip),%rdx
call   10c0 <getopt@plt>
mov    %eax,-0x14(%rbp)
cmp    $0xffffffff,%eax
je     185e <main+0x6ae>
mov    -0x14(%rbp),%eax
add    $0xffffffc1,%eax
mov    %eax,%ecx
mov    %rcx,-0x50(%rbp)
sub    $0x36,%eax
ja     1852 <main+0x6a2>
mov    -0x50(%rbp),%rax
lea    0xdc9(%rip),%rcx
movslq (%rcx,%rax,4),%rax
add    %rcx,%rax
jmp    *%rax
movl   $0x0,-0x18(%rbp)
mov    -0x18(%rbp),%eax
mov    %eax,-0x54(%rbp)
mov    0x2da4(%rip),%rax
mov    (%rax),%rdi
call   1040 <strlen@plt>
mov    %eax,%ecx
mov    -0x54(%rbp),%eax
cmp    %ecx,%eax
jge    130e <main+0x15e>
mov    0x2d88(%rip),%rax
mov    (%rax),%rax
movslq -0x18(%rbp),%rcx
movsbl (%rax,%rcx,1),%eax
cmp    $0x72,%eax
jne    1298 <main+0xe8>
mov    0x2cfd(%rip),%rax
mov    (%rax),%eax
or     -0x44(%rbp),%eax
mov    %eax,-0x44(%rbp)
jmp    12fb <main+0x14b>
mov    0x2d59(%rip),%rax
mov    (%rax),%rax
movslq -0x18(%rbp),%rcx
movsbl (%rax,%rcx,1),%eax
cmp    $0x77,%eax
jne    12c7 <main+0x117>
mov    0x2d06(%rip),%rax
mov    (%rax),%eax
or     -0x44(%rbp),%eax
mov    %eax,-0x44(%rbp)
jmp    12f6 <main+0x146>
mov    0x2d2a(%rip),%rax
mov    (%rax),%rax
movslq -0x18(%rbp),%rcx
movsbl (%rax,%rcx,1),%eax
cmp    $0x78,%eax
jne    12f1 <main+0x141>
mov    0x2cef(%rip),%rax
mov    (%rax),%eax
or     -0x44(%rbp),%eax
mov    %eax,-0x44(%rbp)
jmp    12f6 <main+0x146>
jmp    12fb <main+0x14b>
jmp    1300 <main+0x150>
mov    -0x18(%rbp),%eax
add    $0x1,%eax
mov    %eax,-0x18(%rbp)
jmp    1247 <main+0x97>
jmp    1859 <main+0x6a9>
movl   $0x0,-0x18(%rbp)
mov    -0x18(%rbp),%eax
mov    %eax,-0x58(%rbp)
mov    0x2cd1(%rip),%rax
mov    (%rax),%rdi
call   1040 <strlen@plt>
mov    %eax,%ecx
mov    -0x58(%rbp),%eax
cmp    %ecx,%eax
jge    13e1 <main+0x231>
mov    0x2cb5(%rip),%rax
mov    (%rax),%rax
movslq -0x18(%rbp),%rcx
movsbl (%rax,%rcx,1),%eax
cmp    $0x72,%eax
jne    136b <main+0x1bb>
mov    0x2c3a(%rip),%rax
mov    (%rax),%eax
or     -0x44(%rbp),%eax
mov    %eax,-0x44(%rbp)
jmp    13ce <main+0x21e>
mov    0x2c86(%rip),%rax
mov    (%rax),%rax
movslq -0x18(%rbp),%rcx
movsbl (%rax,%rcx,1),%eax
cmp    $0x77,%eax
jne    139a <main+0x1ea>
mov    0x2c43(%rip),%rax
mov    (%rax),%eax
or     -0x44(%rbp),%eax
mov    %eax,-0x44(%rbp)
jmp    13c9 <main+0x219>
mov    0x2c57(%rip),%rax
mov    (%rax),%rax
movslq -0x18(%rbp),%rcx
movsbl (%rax,%rcx,1),%eax
cmp    $0x78,%eax
jne    13c4 <main+0x214>
mov    0x2bf4(%rip),%rax
mov    (%rax),%eax
or     -0x44(%rbp),%eax
mov    %eax,-0x44(%rbp)
jmp    13c9 <main+0x219>
jmp    13ce <main+0x21e>
jmp    13d3 <main+0x223>
mov    -0x18(%rbp),%eax
add    $0x1,%eax
mov    %eax,-0x18(%rbp)
jmp    131a <main+0x16a>
jmp    1859 <main+0x6a9>
movl   $0x0,-0x18(%rbp)
mov    -0x18(%rbp),%eax
mov    %eax,-0x5c(%rbp)
mov    0x2bfe(%rip),%rax
mov    (%rax),%rdi
call   1040 <strlen@plt>
mov    %eax,%ecx
mov    -0x5c(%rbp),%eax
cmp    %ecx,%eax
jge    14b4 <main+0x304>
mov    0x2be2(%rip),%rax
mov    (%rax),%rax
movslq -0x18(%rbp),%rcx
movsbl (%rax,%rcx,1),%eax
cmp    $0x72,%eax
jne    143e <main+0x28e>
mov    0x2b5f(%rip),%rax
mov    (%rax),%eax
or     -0x44(%rbp),%eax
mov    %eax,-0x44(%rbp)
jmp    14a1 <main+0x2f1>
mov    0x2bb3(%rip),%rax
mov    (%rax),%rax
movslq -0x18(%rbp),%rcx
movsbl (%rax,%rcx,1),%eax
cmp    $0x77,%eax
jne    146d <main+0x2bd>
mov    0x2b10(%rip),%rax
mov    (%rax),%eax
or     -0x44(%rbp),%eax
mov    %eax,-0x44(%rbp)
jmp    149c <main+0x2ec>
mov    0x2b84(%rip),%rax
mov    (%rax),%rax
movslq -0x18(%rbp),%rcx
movsbl (%rax,%rcx,1),%eax
cmp    $0x78,%eax
jne    1497 <main+0x2e7>
mov    0x2b51(%rip),%rax
mov    (%rax),%eax
or     -0x44(%rbp),%eax
mov    %eax,-0x44(%rbp)
jmp    149c <main+0x2ec>
jmp    14a1 <main+0x2f1>
jmp    14a6 <main+0x2f6>
mov    -0x18(%rbp),%eax
add    $0x1,%eax
mov    %eax,-0x18(%rbp)
jmp    13ed <main+0x23d>
jmp    1859 <main+0x6a9>
movl   $0x0,-0x18(%rbp)
mov    -0x18(%rbp),%eax
mov    %eax,-0x60(%rbp)
mov    0x2b2b(%rip),%rax
mov    (%rax),%rdi
call   1040 <strlen@plt>
mov    %eax,%ecx
mov    -0x60(%rbp),%eax
cmp    %ecx,%eax
jge    1587 <main+0x3d7>
mov    0x2b0f(%rip),%rax
mov    (%rax),%rax
movslq -0x18(%rbp),%rcx
movsbl (%rax,%rcx,1),%eax
cmp    $0x72,%eax
jne    1511 <main+0x361>
mov    0x2a84(%rip),%rax
mov    (%rax),%eax
or     -0x48(%rbp),%eax
mov    %eax,-0x48(%rbp)
jmp    1574 <main+0x3c4>
mov    0x2ae0(%rip),%rax
mov    (%rax),%rax
movslq -0x18(%rbp),%rcx
movsbl (%rax,%rcx,1),%eax
cmp    $0x77,%eax
jne    1540 <main+0x390>
mov    0x2a8d(%rip),%rax
mov    (%rax),%eax
or     -0x48(%rbp),%eax
mov    %eax,-0x48(%rbp)
jmp    156f <main+0x3bf>
mov    0x2ab1(%rip),%rax
mov    (%rax),%rax
movslq -0x18(%rbp),%rcx
movsbl (%rax,%rcx,1),%eax
cmp    $0x78,%eax
jne    156a <main+0x3ba>
mov    0x2a76(%rip),%rax
mov    (%rax),%eax
or     -0x48(%rbp),%eax
mov    %eax,-0x48(%rbp)
jmp    156f <main+0x3bf>
jmp    1574 <main+0x3c4>
jmp    1579 <main+0x3c9>
mov    -0x18(%rbp),%eax
add    $0x1,%eax
mov    %eax,-0x18(%rbp)
jmp    14c0 <main+0x310>
jmp    1859 <main+0x6a9>
movl   $0x0,-0x18(%rbp)
mov    -0x18(%rbp),%eax
mov    %eax,-0x64(%rbp)
mov    0x2a58(%rip),%rax
mov    (%rax),%rdi
call   1040 <strlen@plt>
mov    %eax,%ecx
mov    -0x64(%rbp),%eax
cmp    %ecx,%eax
jge    165a <main+0x4aa>
mov    0x2a3c(%rip),%rax
mov    (%rax),%rax
movslq -0x18(%rbp),%rcx
movsbl (%rax,%rcx,1),%eax
cmp    $0x72,%eax
jne    15e4 <main+0x434>
mov    0x29c1(%rip),%rax
mov    (%rax),%eax
or     -0x48(%rbp),%eax
mov    %eax,-0x48(%rbp)
jmp    1647 <main+0x497>
mov    0x2a0d(%rip),%rax
mov    (%rax),%rax
movslq -0x18(%rbp),%rcx
movsbl (%rax,%rcx,1),%eax
cmp    $0x77,%eax
jne    1613 <main+0x463>
mov    0x29ca(%rip),%rax
mov    (%rax),%eax
or     -0x48(%rbp),%eax
mov    %eax,-0x48(%rbp)
jmp    1642 <main+0x492>
mov    0x29de(%rip),%rax
mov    (%rax),%rax
movslq -0x18(%rbp),%rcx
movsbl (%rax,%rcx,1),%eax
cmp    $0x78,%eax
jne    163d <main+0x48d>
mov    0x297b(%rip),%rax
mov    (%rax),%eax
or     -0x48(%rbp),%eax
mov    %eax,-0x48(%rbp)
jmp    1642 <main+0x492>
jmp    1647 <main+0x497>
jmp    164c <main+0x49c>
mov    -0x18(%rbp),%eax
add    $0x1,%eax
mov    %eax,-0x18(%rbp)
jmp    1593 <main+0x3e3>
jmp    1859 <main+0x6a9>
movl   $0x0,-0x18(%rbp)
mov    -0x18(%rbp),%eax
mov    %eax,-0x68(%rbp)
mov    0x2985(%rip),%rax
mov    (%rax),%rdi
call   1040 <strlen@plt>
mov    %eax,%ecx
mov    -0x68(%rbp),%eax
cmp    %ecx,%eax
jge    172d <main+0x57d>
mov    0x2969(%rip),%rax
mov    (%rax),%rax
movslq -0x18(%rbp),%rcx
movsbl (%rax,%rcx,1),%eax
cmp    $0x72,%eax
jne    16b7 <main+0x507>
mov    0x28e6(%rip),%rax
mov    (%rax),%eax
or     -0x48(%rbp),%eax
mov    %eax,-0x48(%rbp)
jmp    171a <main+0x56a>
mov    0x293a(%rip),%rax
mov    (%rax),%rax
movslq -0x18(%rbp),%rcx
movsbl (%rax,%rcx,1),%eax
cmp    $0x77,%eax
jne    16e6 <main+0x536>
mov    0x2897(%rip),%rax
mov    (%rax),%eax
or     -0x48(%rbp),%eax
mov    %eax,-0x48(%rbp)
jmp    1715 <main+0x565>
mov    0x290b(%rip),%rax
mov    (%rax),%rax
movslq -0x18(%rbp),%rcx
movsbl (%rax,%rcx,1),%eax
cmp    $0x78,%eax
jne    1710 <main+0x560>
mov    0x28d8(%rip),%rax
mov    (%rax),%eax
or     -0x48(%rbp),%eax
mov    %eax,-0x48(%rbp)
jmp    1715 <main+0x565>
jmp    171a <main+0x56a>
jmp    171f <main+0x56f>
mov    -0x18(%rbp),%eax
add    $0x1,%eax
mov    %eax,-0x18(%rbp)
jmp    1666 <main+0x4b6>
jmp    1859 <main+0x6a9>
mov    0x288f(%rip),%rax
movzbl (%rax),%eax
cmp    $0x75,%eax
je     17a4 <main+0x5f4>
mov    0x287c(%rip),%rax
movzbl (%rax),%eax
cmp    $0x67,%eax
je     17a4 <main+0x5f4>
mov    0x2869(%rip),%rax
movzbl (%rax),%eax
cmp    $0x6f,%eax
je     17a4 <main+0x5f4>
mov    0x2856(%rip),%rax
movzbl (%rax),%eax
cmp    $0x55,%eax
je     17a4 <main+0x5f4>
mov    0x2843(%rip),%rax
movzbl (%rax),%eax
cmp    $0x47,%eax
je     17a4 <main+0x5f4>
mov    0x2830(%rip),%rax
movzbl (%rax),%eax
cmp    $0x4f,%eax
jne    17ca <main+0x61a>
mov    0x27f5(%rip),%rax
mov    (%rax),%edi
mov    0x2814(%rip),%rax
movzbl (%rax),%edx
lea    0x92b(%rip),%rsi
mov    $0x0,%al
call   1070 <fprintf@plt>
jmp    182e <main+0x67e>
mov    0x27f7(%rip),%rax
movzbl (%rax),%edi
call   1090 <isprint@plt>
cmp    $0x0,%eax
je     1808 <main+0x658>
mov    0x27b7(%rip),%rax
mov    (%rax),%edi
mov    0x27d6(%rip),%rax
movzbl (%rax),%edx
lea    0x916(%rip),%rsi
mov    $0x0,%al
call   1070 <fprintf@plt>
jmp    1829 <main+0x679>
mov    0x2791(%rip),%rax
mov    (%rax),%edi
mov    0x27b0(%rip),%rax
movzbl (%rax),%edx
lea    0x90e(%rip),%rsi
mov    $0x0,%al
call   1070 <fprintf@plt>
jmp    182e <main+0x67e>
mov    -0x10(%rbp),%rax
mov    (%rax),%rdi
call   10d0 <DisplayUsage@plt>
lea    0x918(%rip),%rdi
call   1060 <printf@plt>
movl   $0x1,-0x4(%rbp)
jmp    19bd <main+0x80d>
mov    $0x0,%al
call   1030 <abort@plt>
jmp    11f8 <main+0x48>
cmpl   $0x1,-0x8(%rbp)
jne    1879 <main+0x6c9>
mov    -0x10(%rbp),%rax
mov    (%rax),%rdi
call   10d0 <DisplayUsage@plt>
jmp    1966 <main+0x7b6>
mov    0x2738(%rip),%rax
mov    (%rax),%eax
mov    %eax,-0x1c(%rbp)
mov    -0x1c(%rbp),%eax
cmp    -0x8(%rbp),%eax
jge    1961 <main+0x7b1>
mov    -0x20(%rbp),%eax
add    $0x1,%eax
mov    %eax,-0x20(%rbp)
mov    -0x10(%rbp),%rax
movslq -0x1c(%rbp),%rcx
mov    (%rax,%rcx,8),%rdi
lea    -0x40(%rbp),%rsi
call   1080 <stat@plt>
cmp    $0x0,%rax
jge    18ce <main+0x71e>
lea    0x8a9(%rip),%rdi
call   10b0 <perror@plt>
movb   $0x1,-0x21(%rbp)
jmp    1907 <main+0x757>
mov    -0x40(%rbp),%rax
cmp    -0x30(%rbp),%rax
je     1902 <main+0x752>
cmpq   $0x0,-0x30(%rbp)
je     1902 <main+0x752>
mov    0x26b2(%rip),%rax
mov    (%rax),%edi
lea    0x879(%rip),%rsi
mov    $0x0,%al
call   1070 <fprintf@plt>
movb   $0x1,-0x21(%rbp)
jmp    1907 <main+0x757>
mov    -0x44(%rbp),%eax
or     -0x38(%rbp),%eax
mov    %eax,-0x38(%rbp)
mov    -0x48(%rbp),%eax
xor    $0xffffffff,%eax
and    -0x38(%rbp),%eax
mov    %eax,-0x38(%rbp)
mov    -0x10(%rbp),%rax
movslq -0x1c(%rbp),%rcx
mov    (%rax,%rcx,8),%rdi
mov    -0x38(%rbp),%esi
call   10a0 <chmod@plt>
cmp    $0xffffffff,%eax
jne    194e <main+0x79e>
mov    -0x10(%rbp),%rax
movslq -0x1c(%rbp),%rcx
mov    (%rax,%rcx,8),%rdi
call   10b0 <perror@plt>
movb   $0x1,-0x21(%rbp)
jmp    1953 <main+0x7a3>
mov    -0x1c(%rbp),%eax
add    $0x1,%eax
mov    %eax,-0x1c(%rbp)
jmp    1885 <main+0x6d5>
jmp    1966 <main+0x7b6>
cmpl   $0x0,-0x20(%rbp)
jne    1988 <main+0x7d8>
lea    0x81e(%rip),%rdi
call   1060 <printf@plt>
movl   $0x2,-0x4(%rbp)
jmp    19bd <main+0x80d>
cmpb   $0x0,-0x21(%rbp)
je     19aa <main+0x7fa>
lea    0x81e(%rip),%rdi
call   1060 <printf@plt>
movl   $0x2,-0x4(%rbp)
jmp    19bd <main+0x80d>
lea    0x816(%rip),%rdi
call   1060 <printf@plt>
movl   $0x0,-0x4(%rbp)
mov    -0x4(%rbp),%eax
add    $0x70,%rsp
pop    %rbp
ret

x86 assembly (clang, -O2):
<main>:
push   %rbp
push   %r15
push   %r14
push   %r13
push   %r12
push   %rbx
sub    $0x28,%rsp
mov    %rsi,0x8(%rsp)
mov    %edi,%ebx
xor    %ebp,%ebp
xor    %eax,%eax
call   1060 <getuid@plt>
mov    %rax,0x10(%rsp)
mov    0x2da6(%rip),%rax
movq   $0x0,(%rax)
lea    0xe18(%rip),%r14
mov    0x2e09(%rip),%r15
mov    0x2d92(%rip),%r13
xor    %r12d,%r12d
mov    %ebx,0x4(%rsp)
jmp    1210 <main+0x60>
mov    0x4(%rsp),%ebx
cs nopw 0x0(%rax,%rax,1)
nopl   (%rax)
mov    %ebx,%edi
mov    0x8(%rsp),%rsi
lea    0xebe(%rip),%rdx
call   10c0 <getopt@plt>
lea    -0x3f(%rax),%ecx
cmp    $0x36,%ecx
ja     14a6 <main+0x2f6>
movslq (%r14,%rcx,4),%rax
add    %r14,%rax
jmp    *%rax
mov    (%r15),%rdi
call   1050 <strlen@plt>
test   %eax,%eax
jle    1210 <main+0x60>
xor    %ebx,%ebx
jmp    126e <main+0xbe>
nopl   0x0(%rax,%rax,1)
mov    0x2d59(%rip),%rax
or     (%rax),%r12d
add    $0x1,%rbx
call   1050 <strlen@plt>
cltq
cmp    %rax,%rbx
jge    1479 <main+0x2c9>
mov    (%r15),%rdi
movzbl (%rdi,%rbx,1),%eax
cmp    $0x78,%al
je     1250 <main+0xa0>
cmp    $0x77,%al
je     1290 <main+0xe0>
cmp    $0x72,%al
jne    125a <main+0xaa>
mov    0x2d10(%rip),%rax
jmp    1257 <main+0xa7>
nopw   0x0(%rax,%rax,1)
mov    0x2d39(%rip),%rax
jmp    1257 <main+0xa7>
mov    (%r15),%rdi
call   1050 <strlen@plt>
test   %eax,%eax
jle    1210 <main+0x60>
xor    %ebx,%ebx
jmp    12ce <main+0x11e>
nopl   (%rax)
mov    0x2d29(%rip),%rax
or     (%rax),%r12d
add    $0x1,%rbx
call   1050 <strlen@plt>
cltq
cmp    %rax,%rbx
jge    11ff <main+0x4f>
mov    (%r15),%rdi
movzbl (%rdi,%rbx,1),%eax
cmp    $0x78,%al
je     12b0 <main+0x100>
cmp    $0x77,%al
je     12f0 <main+0x140>
cmp    $0x72,%al
jne    12ba <main+0x10a>
mov    0x2ca8(%rip),%rax
jmp    12b7 <main+0x107>
nopw   0x0(%rax,%rax,1)
mov    0x2c79(%rip),%rax
jmp    12b7 <main+0x107>
mov    (%r15),%rdi
call   1050 <strlen@plt>
test   %eax,%eax
jle    1210 <main+0x60>
xor    %ebx,%ebx
jmp    132e <main+0x17e>
nopl   (%rax)
mov    0x2cc1(%rip),%rax
or     (%rax),%r12d
add    $0x1,%rbx
call   1050 <strlen@plt>
cltq
cmp    %rax,%rbx
jge    1482 <main+0x2d2>
mov    (%r15),%rdi
movzbl (%rdi,%rbx,1),%eax
cmp    $0x78,%al
je     1310 <main+0x160>
cmp    $0x77,%al
je     1350 <main+0x1a0>
cmp    $0x72,%al
jne    131a <main+0x16a>
or     0x0(%r13),%r12d
jmp    131a <main+0x16a>
nopw   0x0(%rax,%rax,1)
mov    0x2c69(%rip),%rax
jmp    1317 <main+0x167>
mov    (%r15),%rdi
call   1050 <strlen@plt>
test   %eax,%eax
jle    1210 <main+0x60>
xor    %ebx,%ebx
jmp    138d <main+0x1dd>
nopl   (%rax)
mov    0x2c39(%rip),%rax
or     (%rax),%ebp
add    $0x1,%rbx
call   1050 <strlen@plt>
cltq
cmp    %rax,%rbx
jge    148b <main+0x2db>
mov    (%r15),%rdi
movzbl (%rdi,%rbx,1),%eax
cmp    $0x78,%al
je     1370 <main+0x1c0>
cmp    $0x77,%al
je     13b0 <main+0x200>
cmp    $0x72,%al
jne    1379 <main+0x1c9>
mov    0x2bf1(%rip),%rax
jmp    1377 <main+0x1c7>
nopl   0x0(%rax)
mov    0x2c19(%rip),%rax
jmp    1377 <main+0x1c7>
mov    (%r15),%rdi
call   1050 <strlen@plt>
test   %eax,%eax
jle    1210 <main+0x60>
xor    %ebx,%ebx
jmp    13ed <main+0x23d>
nopl   (%rax)
mov    0x2c09(%rip),%rax
or     (%rax),%ebp
add    $0x1,%rbx
call   1050 <strlen@plt>
cltq
cmp    %rax,%rbx
jge    1494 <main+0x2e4>
mov    (%r15),%rdi
movzbl (%rdi,%rbx,1),%eax
cmp    $0x78,%al
je     13d0 <main+0x220>
cmp    $0x77,%al
je     1410 <main+0x260>
cmp    $0x72,%al
jne    13d9 <main+0x229>
mov    0x2b89(%rip),%rax
jmp    13d7 <main+0x227>
nopl   0x0(%rax)
mov    0x2b59(%rip),%rax
jmp    13d7 <main+0x227>
mov    (%r15),%rdi
call   1050 <strlen@plt>
test   %eax,%eax
jle    1210 <main+0x60>
xor    %ebx,%ebx
jmp    1449 <main+0x299>
nopl   (%rax)
mov    0x2ba1(%rip),%rax
or     (%rax),%ebp
add    $0x1,%rbx
call   1050 <strlen@plt>
cltq
cmp    %rax,%rbx
jge    149d <main+0x2ed>
mov    (%r15),%rdi
movzbl (%rdi,%rbx,1),%eax
cmp    $0x78,%al
je     1430 <main+0x280>
cmp    $0x77,%al
je     1470 <main+0x2c0>
cmp    $0x72,%al
jne    1439 <main+0x289>
or     0x0(%r13),%ebp
jmp    1439 <main+0x289>
cs nopw 0x0(%rax,%rax,1)
nopl   0x0(%rax)
mov    0x2b49(%rip),%rax
jmp    1437 <main+0x287>
mov    0x4(%rsp),%ebx
jmp    1210 <main+0x60>
mov    0x4(%rsp),%ebx
jmp    1210 <main+0x60>
mov    0x4(%rsp),%ebx
jmp    1210 <main+0x60>
mov    0x4(%rsp),%ebx
jmp    1210 <main+0x60>
mov    0x4(%rsp),%ebx
jmp    1210 <main+0x60>
cmp    $0xffffffff,%eax
jne    165a <main+0x4aa>
cmp    $0x1,%ebx
jne    152c <main+0x37c>
mov    0x8(%rsp),%rax
mov    (%rax),%rdi
call   10d0 <DisplayUsage@plt>
jmp    15fb <main+0x44b>
mov    0x2afb(%rip),%rbx
movzbl (%rbx),%edx
lea    -0x47(%rdx),%eax
cmp    $0x2e,%al
ja     161b <main+0x46b>
movzbl %al,%eax
movabs $0x410100004101,%rcx
bt     %rax,%rcx
jae    161b <main+0x46b>
mov    0x2aa7(%rip),%rax
mov    (%rax),%edi
lea    0xbe7(%rip),%rsi
xor    %eax,%eax
call   1070 <fprintf@plt>
mov    0x8(%rsp),%rax
mov    (%rax),%rdi
call   10d0 <DisplayUsage@plt>
lea    0xca7(%rip),%rdi
call   1040 <puts@plt>
mov    $0x1,%eax
jmp    160c <main+0x45c>
mov    0x2a85(%rip),%rax
movslq (%rax),%rdx
cmp    %ebx,%edx
jge    15fb <main+0x44b>
not    %r12d
mov    %ebx,%eax
mov    0x8(%rsp),%rcx
lea    (%rcx,%rdx,8),%rbx
mov    %eax,%r14d
mov    %rdx,0x8(%rsp)
sub    %edx,%r14d
xor    %r15d,%r15d
xor    %r13d,%r13d
jmp    1597 <main+0x3e7>
lea    0xbf3(%rip),%rdi
call   10b0 <perror@plt>
nopl   0x0(%rax,%rax,1)
mov    $0x1,%r13b
mov    0x20(%rsp),%esi
or     %ebp,%esi
and    %r12d,%esi
mov    %esi,0x20(%rsp)
mov    (%rbx,%r15,8),%rdi
call   10a0 <chmod@plt>
cmp    $0xffffffff,%eax
je     15d4 <main+0x424>
add    $0x1,%r15
cmp    %r15d,%r14d
je     15e2 <main+0x432>
mov    (%rbx,%r15,8),%rdi
lea    0x18(%rsp),%rsi
call   1080 <stat@plt>
test   %rax,%rax
js     155f <main+0x3af>
mov    0x10(%rsp),%rax
test   %rax,%rax
je     1573 <main+0x3c3>
cmp    %rax,0x18(%rsp)
je     1573 <main+0x3c3>
mov    0x29de(%rip),%rax
mov    (%rax),%edi
lea    0xb95(%rip),%rsi
xor    %eax,%eax
call   1070 <fprintf@plt>
jmp    1570 <main+0x3c0>
mov    (%rbx,%r15,8),%rdi
call   10b0 <perror@plt>
mov    $0x1,%r13b
jmp    158e <main+0x3de>
mov    0x8(%rsp),%rax
cmp    0x4(%rsp),%eax
jge    15fb <main+0x44b>
test   %r13b,%r13b
je     164a <main+0x49a>
lea    0xb9b(%rip),%rdi
jmp    1602 <main+0x452>
lea    0xba1(%rip),%rdi
call   1040 <puts@plt>
mov    $0x2,%eax
add    $0x28,%rsp
pop    %rbx
pop    %r12
pop    %r13
pop    %r14
pop    %r15
pop    %rbp
ret
mov    %edx,%edi
call   1090 <isprint@plt>
mov    0x2977(%rip),%rcx
mov    (%rcx),%edi
movzbl (%rbx),%edx
test   %eax,%eax
je     163e <main+0x48e>
lea    0xad9(%rip),%rsi
jmp    1502 <main+0x352>
lea    0xaeb(%rip),%rsi
jmp    1502 <main+0x352>
lea    0xb34(%rip),%rdi
call   1040 <puts@plt>
xor    %eax,%eax
jmp    160c <main+0x45c>
xor    %eax,%eax
call   1030 <abort@plt>

LLVM IR (-O0):
%struct.stat = type { i64, i32 }
@opterr = global i64 0
@.str = [13 x i8] c"u:g:o:U:G:O:\00"
@optarg = global i8* null
@S_IRUSR = global i32 0
@S_IWUSR = global i32 0
@S_IXUSR = global i32 0
@S_IRGRP = global i32 0
@S_IWGRP = global i32 0
@S_IXGRP = global i32 0
@S_IROTH = global i32 0
@S_IWOTH = global i32 0
@S_IXOTH = global i32 0
@optopt = global i8 0
@stderr = global i32 0
@.str.1 = [41 x i8] c"\0A\09***Option -%c requires an argument***\0A\00"
@.str.2 = [30 x i8] c"\0A\09***Unknown option `-%c'***\0A\00"
@.str.3 = [41 x i8] c"\0A\09***Unknown option character `\\x%x'***\0A\00"
@.str.4 = [16 x i8] c"Exit status: 1\0A\00"
@optind = global i32 0
@.str.5 = [7 x i8] c"Stat()\00"
@.str.6 = [37 x i8] c"UID ERROR: You do not own this file\0A\00"
@.str.7 = [34 x i8] c"No file specified\0AExit Status: 2\0A\00"
@.str.8 = [16 x i8] c"Exit status: 2\0A\00"
@.str.9 = [16 x i8] c"Exit status: 0\0A\00"
define i32 @main(i32 %0, i8** %1) {
%3 = alloca i32
%4 = alloca i32
%5 = alloca i8**
%6 = alloca i32
%7 = alloca i32
%8 = alloca i32
%9 = alloca i32
%10 = alloca i8
%11 = alloca i64
%12 = alloca %struct.stat
%13 = alloca i32
%14 = alloca i32
store i32 0, i32* %3
store i32 %0, i32* %4
store i8** %1, i8*** %5
store i32 0, i32* %9
store i8 0, i8* %10
%15 = call i64 (...) @getuid()
store i64 %15, i64* %11
store i32 0, i32* %13
store i32 0, i32* %14
store i64 0, i64* @opterr
br label %16
16: ; preds = %369, %2
%17 = load i32, i32* %4
%18 = load i8**, i8*** %5
%19 = call i32 @getopt(i32 %17, i8** %18, i8* getelementptr inbounds ([13 x i8], [13 x i8]* @.str, i64 0, i64 0))
store i32 %19, i32* %6
%20 = icmp ne i32 %19, -1
br i1 %20, label %21, label %370
21: ; preds = %16
%22 = load i32, i32* %6
switch i32 %22, label %367 [
i32 117, label %23
i32 103, label %72
i32 111, label %121
i32 85, label %170
i32 71, label %219
i32 79, label %268
i32 63, label %317
]
23: ; preds = %21
store i32 0, i32* %7
br label %24
24: ; preds = %68, %23
%25 = load i32, i32* %7
%26 = load i8*, i8** @optarg
%27 = call i32 @strlen(i8* %26)
%28 = icmp slt i32 %25, %27
br i1 %28, label %29, label %71
29: ; preds = %24
%30 = load i8*, i8** @optarg
%31 = load i32, i32* %7
%32 = sext i32 %31 to i64
%33 = getelementptr inbounds i8, i8* %30, i64 %32
%34 = load i8, i8* %33
%35 = sext i8 %34 to i32
%36 = icmp eq i32 %35, 114
br i1 %36, label %37, label %41
37: ; preds = %29
%38 = load i32, i32* @S_IRUSR
%39 = load i32, i32* %13
%40 = or i32 %39, %38
store i32 %40, i32* %13
br label %67
41: ; preds = %29
%42 = load i8*, i8** @optarg
%43 = load i32, i32* %7
%44 = sext i32 %43 to i64
%45 = getelementptr inbounds i8, i8* %42, i64 %44
%46 = load i8, i8* %45
%47 = sext i8 %46 to i32
%48 = icmp eq i32 %47, 119
br i1 %48, label %49, label %53
49: ; preds = %41
%50 = load i32, i32* @S_IWUSR
%51 = load i32, i32* %13
%52 = or i32 %51, %50
store i32 %52, i32* %13
br label %66
53: ; preds = %41
%54 = load i8*, i8** @optarg
%55 = load i32, i32* %7
%56 = sext i32 %55 to i64
%57 = getelementptr inbounds i8, i8* %54, i64 %56
%58 = load i8, i8* %57
%59 = sext i8 %58 to i32
%60 = icmp eq i32 %59, 120
br i1 %60, label %61, label %65
61: ; preds = %53
%62 = load i32, i32* @S_IXUSR
%63 = load i32, i32* %13
%64 = or i32 %63, %62
store i32 %64, i32* %13
br label %65
65: ; preds = %61, %53
br label %66
66: ; preds = %65, %49
br label %67
67: ; preds = %66, %37
br label %68
68: ; preds = %67
%69 = load i32, i32* %7
%70 = add nsw i32 %69, 1
store i32 %70, i32* %7
br label %24
71: ; preds = %24
br label %369
72: ; preds = %21
store i32 0, i32* %7
br label %73
73: ; preds = %117, %72
%74 = load i32, i32* %7
%75 = load i8*, i8** @optarg
%76 = call i32 @strlen(i8* %75)
%77 = icmp slt i32 %74, %76
br i1 %77, label %78, label %120
78: ; preds = %73
%79 = load i8*, i8** @optarg
%80 = load i32, i32* %7
%81 = sext i32 %80 to i64
%82 = getelementptr inbounds i8, i8* %79, i64 %81
%83 = load i8, i8* %82
%84 = sext i8 %83 to i32
%85 = icmp eq i32 %84, 114
br i1 %85, label %86, label %90
86: ; preds = %78
%87 = load i32, i32* @S_IRGRP
%88 = load i32, i32* %13
%89 = or i32 %88, %87
store i32 %89, i32* %13
br label %116
90: ; preds = %78
%91 = load i8*, i8** @optarg
%92 = load i32, i32* %7
%93 = sext i32 %92 to i64
%94 = getelementptr inbounds i8, i8* %91, i64 %93
%95 = load i8, i8* %94
%96 = sext i8 %95 to i32
%97 = icmp eq i32 %96, 119
br i1 %97, label %98, label %102
98: ; preds = %90
%99 = load i32, i32* @S_IWGRP
%100 = load i32, i32* %13
%101 = or i32 %100, %99
store i32 %101, i32* %13
br label %115
102: ; preds = %90
%103 = load i8*, i8** @optarg
%104 = load i32, i32* %7
%105 = sext i32 %104 to i64
%106 = getelementptr inbounds i8, i8* %103, i64 %105
%107 = load i8, i8* %106
%108 = sext i8 %107 to i32
%109 = icmp eq i32 %108, 120
br i1 %109, label %110, label %114
110: ; preds = %102
%111 = load i32, i32* @S_IXGRP
%112 = load i32, i32* %13
%113 = or i32 %112, %111
store i32 %113, i32* %13
br label %114
114: ; preds = %110, %102
br label %115
115: ; preds = %114, %98
br label %116
116: ; preds = %115, %86
br label %117
117: ; preds = %116
%118 = load i32, i32* %7
%119 = add nsw i32 %118, 1
store i32 %119, i32* %7
br label %73
120: ; preds = %73
br label %369
121: ; preds = %21
store i32 0, i32* %7
br label %122
122: ; preds = %166, %121
%123 = load i32, i32* %7
%124 = load i8*, i8** @optarg
%125 = call i32 @strlen(i8* %124)
%126 = icmp slt i32 %123, %125
br i1 %126, label %127, label %169
127: ; preds = %122
%128 = load i8*, i8** @optarg
%129 = load i32, i32* %7
%130 = sext i32 %129 to i64
%131 = getelementptr inbounds i8, i8* %128, i64 %130
%132 = load i8, i8* %131
%133 = sext i8 %132 to i32
%134 = icmp eq i32 %133, 114
br i1 %134, label %135, label %139
135: ; preds = %127
%136 = load i32, i32* @S_IROTH
%137 = load i32, i32* %13
%138 = or i32 %137, %136
store i32 %138, i32* %13
br label %165
139: ; preds = %127
%140 = load i8*, i8** @optarg
%141 = load i32, i32* %7
%142 = sext i32 %141 to i64
%143 = getelementptr inbounds i8, i8* %140, i64 %142
%144 = load i8, i8* %143
%145 = sext i8 %144 to i32
%146 = icmp eq i32 %145, 119
br i1 %146, label %147, label %151
147: ; preds = %139
%148 = load i32, i32* @S_IWOTH
%149 = load i32, i32* %13
%150 = or i32 %149, %148
store i32 %150, i32* %13
br label %164
151: ; preds = %139
%152 = load i8*, i8** @optarg
%153 = load i32, i32* %7
%154 = sext i32 %153 to i64
%155 = getelementptr inbounds i8, i8* %152, i64 %154
%156 = load i8, i8* %155
%157 = sext i8 %156 to i32
%158 = icmp eq i32 %157, 120
br i1 %158, label %159, label %163
159: ; preds = %151
%160 = load i32, i32* @S_IXOTH
%161 = load i32, i32* %13
%162 = or i32 %161, %160
store i32 %162, i32* %13
br label %163
163: ; preds = %159, %151
br label %164
164: ; preds = %163, %147
br label %165
165: ; preds = %164, %135
br label %166
166: ; preds = %165
%167 = load i32, i32* %7
%168 = add nsw i32 %167, 1
store i32 %168, i32* %7
br label %122
169: ; preds = %122
br label %369
170: ; preds = %21
store i32 0, i32* %7
br label %171
171: ; preds = %215, %170
%172 = load i32, i32* %7
%173 = load i8*, i8** @optarg
%174 = call i32 @strlen(i8* %173)
%175 = icmp slt i32 %172, %174
br i1 %175, label %176, label %218
176: ; preds = %171
%177 = load i8*, i8** @optarg
%178 = load i32, i32* %7
%179 = sext i32 %178 to i64
%180 = getelementptr inbounds i8, i8* %177, i64 %179
%181 = load i8, i8* %180
%182 = sext i8 %181 to i32
%183 = icmp eq i32 %182, 114
br i1 %183, label %184, label %188
184: ; preds = %176
%185 = load i32, i32* @S_IRUSR
%186 = load i32, i32* %14
%187 = or i32 %186, %185
store i32 %187, i32* %14
br label %214
188: ; preds = %176
%189 = load i8*, i8** @optarg
%190 = load i32, i32* %7
%191 = sext i32 %190 to i64
%192 = getelementptr inbounds i8, i8* %189, i64 %191
%193 = load i8, i8* %192
%194 = sext i8 %193 to i32
%195 = icmp eq i32 %194, 119
br i1 %195, label %196, label %200
196: ; preds = %188
%197 = load i32, i32* @S_IWUSR
%198 = load i32, i32* %14
%199 = or i32 %198, %197
store i32 %199, i32* %14
br label %213
200: ; preds = %188
%201 = load i8*, i8** @optarg
%202 = load i32, i32* %7
%203 = sext i32 %202 to i64
%204 = getelementptr inbounds i8, i8* %201, i64 %203
%205 = load i8, i8* %204
%206 = sext i8 %205 to i32
%207 = icmp eq i32 %206, 120
br i1 %207, label %208, label %212
208: ; preds = %200
%209 = load i32, i32* @S_IXUSR
%210 = load i32, i32* %14
%211 = or i32 %210, %209
store i32 %211, i32* %14
br label %212
212: ; preds = %208, %200
br label %213
213: ; preds = %212, %196
br label %214
214: ; preds = %213, %184
br label %215
215: ; preds = %214
%216 = load i32, i32* %7
%217 = add nsw i32 %216, 1
store i32 %217, i32* %7
br label %171
218: ; preds = %171
br label %369
219: ; preds = %21
store i32 0, i32* %7
br label %220
220: ; preds = %264, %219
%221 = load i32, i32* %7
%222 = load i8*, i8** @optarg
%223 = call i32 @strlen(i8* %222)
%224 = icmp slt i32 %221, %223
br i1 %224, label %225, label %267
225: ; preds = %220
%226 = load i8*, i8** @optarg
%227 = load i32, i32* %7
%228 = sext i32 %227 to i64
%229 = getelementptr inbounds i8, i8* %226, i64 %228
%230 = load i8, i8* %229
%231 = sext i8 %230 to i32
%232 = icmp eq i32 %231, 114
br i1 %232, label %233, label %237
233: ; preds = %225
%234 = load i32, i32* @S_IRGRP
%235 = load i32, i32* %14
%236 = or i32 %235, %234
store i32 %236, i32* %14
br label %263
237: ; preds = %225
%238 = load i8*, i8** @optarg
%239 = load i32, i32* %7
%240 = sext i32 %239 to i64
%241 = getelementptr inbounds i8, i8* %238, i64 %240
%242 = load i8, i8* %241
%243 = sext i8 %242 to i32
%244 = icmp eq i32 %243, 119
br i1 %244, label %245, label %249
245: ; preds = %237
%246 = load i32, i32* @S_IWGRP
%247 = load i32, i32* %14
%248 = or i32 %247, %246
store i32 %248, i32* %14
br label %262
249: ; preds = %237
%250 = load i8*, i8** @optarg
%251 = load i32, i32* %7
%252 = sext i32 %251 to i64
%253 = getelementptr inbounds i8, i8* %250, i64 %252
%254 = load i8, i8* %253
%255 = sext i8 %254 to i32
%256 = icmp eq i32 %255, 120
br i1 %256, label %257, label %261
257: ; preds = %249
%258 = load i32, i32* @S_IXGRP
%259 = load i32, i32* %14
%260 = or i32 %259, %258
store i32 %260, i32* %14
br label %261
261: ; preds = %257, %249
br label %262
262: ; preds = %261, %245
br label %263
263: ; preds = %262, %233
br label %264
264: ; preds = %263
%265 = load i32, i32* %7
%266 = add nsw i32 %265, 1
store i32 %266, i32* %7
br label %220
267: ; preds = %220
br label %369
268: ; preds = %21
store i32 0, i32* %7
br label %269
269: ; preds = %313, %268
%270 = load i32, i32* %7
%271 = load i8*, i8** @optarg
%272 = call i32 @strlen(i8* %271)
%273 = icmp slt i32 %270, %272
br i1 %273, label %274, label %316
274: ; preds = %269
%275 = load i8*, i8** @optarg
%276 = load i32, i32* %7
%277 = sext i32 %276 to i64
%278 = getelementptr inbounds i8, i8* %275, i64 %277
%279 = load i8, i8* %278
%280 = sext i8 %279 to i32
%281 = icmp eq i32 %280, 114
br i1 %281, label %282, label %286
282: ; preds = %274
%283 = load i32, i32* @S_IROTH
%284 = load i32, i32* %14
%285 = or i32 %284, %283
store i32 %285, i32* %14
br label %312
286: ; preds = %274
%287 = load i8*, i8** @optarg
%288 = load i32, i32* %7
%289 = sext i32 %288 to i64
%290 = getelementptr inbounds i8, i8* %287, i64 %289
%291 = load i8, i8* %290
%292 = sext i8 %291 to i32
%293 = icmp eq i32 %292, 119
br i1 %293, label %294, label %298
294: ; preds = %286
%295 = load i32, i32* @S_IWOTH
%296 = load i32, i32* %14
%297 = or i32 %296, %295
store i32 %297, i32* %14
br label %311
298: ; preds = %286
%299 = load i8*, i8** @optarg
%300 = load i32, i32* %7
%301 = sext i32 %300 to i64
%302 = getelementptr inbounds i8, i8* %299, i64 %301
%303 = load i8, i8* %302
%304 = sext i8 %303 to i32
%305 = icmp eq i32 %304, 120
br i1 %305, label %306, label %310
306: ; preds = %298
%307 = load i32, i32* @S_IXOTH
%308 = load i32, i32* %14
%309 = or i32 %308, %307
store i32 %309, i32* %14
br label %310
310: ; preds = %306, %298
br label %311
311: ; preds = %310, %294
br label %312
312: ; preds = %311, %282
br label %313
313: ; preds = %312
%314 = load i32, i32* %7
%315 = add nsw i32 %314, 1
store i32 %315, i32* %7
br label %269
316: ; preds = %269
br label %369
317: ; preds = %21
%318 = load i8, i8* @optopt
%319 = zext i8 %318 to i32
%320 = icmp eq i32 %319, 117
br i1 %320, label %341, label %321
321: ; preds = %317
%322 = load i8, i8* @optopt
%323 = zext i8 %322 to i32
%324 = icmp eq i32 %323, 103
br i1 %324, label %341, label %325
325: ; preds = %321
%326 = load i8, i8* @optopt
%327 = zext i8 %326 to i32
%328 = icmp eq i32 %327, 111
br i1 %328, label %341, label %329
329: ; preds = %325
%330 = load i8, i8* @optopt
%331 = zext i8 %330 to i32
%332 = icmp eq i32 %331, 85
br i1 %332, label %341, label %333
333: ; preds = %329
%334 = load i8, i8* @optopt
%335 = zext i8 %334 to i32
%336 = icmp eq i32 %335, 71
br i1 %336, label %341, label %337
337: ; preds = %333
%338 = load i8, i8* @optopt
%339 = zext i8 %338 to i32
%340 = icmp eq i32 %339, 79
br i1 %340, label %341, label %346
341: ; preds = %337, %333, %329, %325, %321, %317
%342 = load i32, i32* @stderr
%343 = load i8, i8* @optopt
%344 = zext i8 %343 to i32
%345 = call i32 (i32, i8*, ...) @fprintf(i32 %342, i8* getelementptr inbounds ([41 x i8], [41 x i8]* @.str.1, i64 0, i64 0), i32 %344)
br label %361
346: ; preds = %337
%347 = load i8, i8* @optopt
%348 = call i32 @isprint(i8 zeroext %347)
%349 = icmp ne i32 %348, 0
br i1 %349, label %350, label %355
350: ; preds = %346
%351 = load i32, i32* @stderr
%352 = load i8, i8* @optopt
%353 = zext i8 %352 to i32
%354 = call i32 (i32, i8*, ...) @fprintf(i32 %351, i8* getelementptr inbounds ([30 x i8], [30 x i8]* @.str.2, i64 0, i64 0), i32 %353)
br label %360
355: ; preds = %346
%356 = load i32, i32* @stderr
%357 = load i8, i8* @optopt
%358 = zext i8 %357 to i32
%359 = call i32 (i32, i8*, ...) @fprintf(i32 %356, i8* getelementptr inbounds ([41 x i8], [41 x i8]* @.str.3, i64 0, i64 0), i32 %358)
br label %360
360: ; preds = %355, %350
br label %361
361: ; preds = %360, %341
%362 = load i8**, i8*** %5
%363 = getelementptr inbounds i8*, i8** %362, i64 0
%364 = load i8*, i8** %363
%365 = call i32 @DisplayUsage(i8* %364)
%366 = call i32 @printf(i8* getelementptr inbounds ([16 x i8], [16 x i8]* @.str.4, i64 0, i64 0))
store i32 1, i32* %3
br label %451
367: ; preds = %21
%368 = call i32 (...) @abort()
unreachable
369: ; preds = %316, %267, %218, %169, %120, %71
br label %16
370: ; preds = %16
%371 = load i32, i32* %4
%372 = icmp eq i32 %371, 1
br i1 %372, label %373, label %378
373: ; preds = %370
%374 = load i8**, i8*** %5
%375 = getelementptr inbounds i8*, i8** %374, i64 0
%376 = load i8*, i8** %375
%377 = call i32 @DisplayUsage(i8* %376)
br label %439
378: ; preds = %370
%379 = load i32, i32* @optind
store i32 %379, i32* %8
br label %380
380: ; preds = %435, %378
%381 = load i32, i32* %8
%382 = load i32, i32* %4
%383 = icmp slt i32 %381, %382
br i1 %383, label %384, label %438
384: ; preds = %380
%385 = load i32, i32* %9
%386 = add nsw i32 %385, 1
store i32 %386, i32* %9
%387 = load i8**, i8*** %5
%388 = load i32, i32* %8
%389 = sext i32 %388 to i64
%390 = getelementptr inbounds i8*, i8** %387, i64 %389
%391 = load i8*, i8** %390
%392 = call i64 @stat(i8* %391, %struct.stat* %12)
%393 = icmp slt i64 %392, 0
br i1 %393, label %394, label %396
394: ; preds = %384
%395 = call i32 @perror(i8* getelementptr inbounds ([7 x i8], [7 x i8]* @.str.5, i64 0, i64 0))
store i8 1, i8* %10
br label %408
396: ; preds = %384
%397 = getelementptr inbounds %struct.stat, %struct.stat* %12, i32 0, i32 0
%398 = load i64, i64* %397
%399 = load i64, i64* %11
%400 = icmp ne i64 %398, %399
br i1 %400, label %401, label %407
401: ; preds = %396
%402 = load i64, i64* %11
%403 = icmp ne i64 %402, 0
br i1 %403, label %404, label %407
404: ; preds = %401
%405 = load i32, i32* @stderr
%406 = call i32 (i32, i8*, ...) @fprintf(i32 %405, i8* getelementptr inbounds ([37 x i8], [37 x i8]* @.str.6, i64 0, i64 0))
store i8 1, i8* %10
br label %407
407: ; preds = %404, %401, %396
br label %408
408: ; preds = %407, %394
%409 = load i32, i32* %13
%410 = getelementptr inbounds %struct.stat, %struct.stat* %12, i32 0, i32 1
%411 = load i32, i32* %410
%412 = or i32 %411, %409
store i32 %412, i32* %410
%413 = load i32, i32* %14
%414 = xor i32 %413, -1
%415 = getelementptr inbounds %struct.stat, %struct.stat* %12, i32 0, i32 1
%416 = load i32, i32* %415
%417 = and i32 %416, %414
store i32 %417, i32* %415
%418 = load i8**, i8*** %5
%419 = load i32, i32* %8
%420 = sext i32 %419 to i64
%421 = getelementptr inbounds i8*, i8** %418, i64 %420
%422 = load i8*, i8** %421
%423 = getelementptr inbounds %struct.stat, %struct.stat* %12, i32 0, i32 1
%424 = load i32, i32* %423
%425 = call i32 @chmod(i8* %422, i32 %424)
%426 = icmp eq i32 %425, -1
br i1 %426, label %427, label %434
427: ; preds = %408
%428 = load i8**, i8*** %5
%429 = load i32, i32* %8
%430 = sext i32 %429 to i64
%431 = getelementptr inbounds i8*, i8** %428, i64 %430
%432 = load i8*, i8** %431
%433 = call i32 @perror(i8* %432)
store i8 1, i8* %10
br label %434
434: ; preds = %427, %408
br label %435
435: ; preds = %434
%436 = load i32, i32* %8
%437 = add nsw i32 %436, 1
store i32 %437, i32* %8
br label %380
438: ; preds = %380
br label %439
439: ; preds = %438, %373
%440 = load i32, i32* %9
%441 = icmp eq i32 %440, 0
br i1 %441, label %442, label %444
442: ; preds = %439
%443 = call i32 @printf(i8* getelementptr inbounds ([34 x i8], [34 x i8]* @.str.7, i64 0, i64 0))
store i32 2, i32* %3
br label %451
444: ; preds = %439
%445 = load i8, i8* %10
%446 = icmp ne i8 %445, 0
br i1 %446, label %447, label %449
447: ; preds = %444
%448 = call i32 @printf(i8* getelementptr inbounds ([16 x i8], [16 x i8]* @.str.8, i64 0, i64 0))
store i32 2, i32* %3
br label %451
449: ; preds = %444
%450 = call i32 @printf(i8* getelementptr inbounds ([16 x i8], [16 x i8]* @.str.9, i64 0, i64 0))
store i32 0, i32* %3
br label %451
451: ; preds = %449, %447, %442, %361
%452 = load i32, i32* %3
ret i32 %452
}

LLVM IR (-O2):
%struct.stat = type { i64, i32 }
@opterr = global i64 0
@.str = [13 x i8] c"u:g:o:U:G:O:\00"
@optarg = global i8* null
@S_IRUSR = global i32 0
@S_IWUSR = global i32 0
@S_IXUSR = global i32 0
@S_IRGRP = global i32 0
@S_IWGRP = global i32 0
@S_IXGRP = global i32 0
@S_IROTH = global i32 0
@S_IWOTH = global i32 0
@S_IXOTH = global i32 0
@optopt = global i8 0
@stderr = global i32 0
@.str.1 = [41 x i8] c"\0A\09***Option -%c requires an argument***\0A\00"
@.str.2 = [30 x i8] c"\0A\09***Unknown option `-%c'***\0A\00"
@.str.3 = [41 x i8] c"\0A\09***Unknown option character `\\x%x'***\0A\00"
@optind = global i32 0
@.str.5 = [7 x i8] c"Stat()\00"
@.str.6 = [37 x i8] c"UID ERROR: You do not own this file\0A\00"
@str = [15 x i8] c"Exit status: 0\00"
@str.10 = [15 x i8] c"Exit status: 2\00"
@str.11 = [33 x i8] c"No file specified\0AExit Status: 2\00"
@str.12 = [15 x i8] c"Exit status: 1\00"
define i32 @main(i32 %0, i8** %1) {
%3 = alloca %struct.stat
%4 = tail call i64 (...) @getuid()
%5 = bitcast %struct.stat* %3 to i8*
store i64 0, i64* @opterr
br label %6
6: ; preds = %14, %2
%7 = phi i32 [ 0, %2 ], [ %15, %14 ]
%8 = phi i32 [ 0, %2 ], [ %16, %14 ]
%9 = tail call i32 @getopt(i32 %0, i8** %1, i8* getelementptr inbounds ([13 x i8], [13 x i8]* @.str, i64 0, i64 0))
switch i32 %9, label %183 [
i32 -1, label %185
i32 117, label %33
i32 103, label %29
i32 111, label %25
i32 85, label %21
i32 71, label %17
i32 79, label %10
i32 63, label %163
]
10: ; preds = %6
%11 = load i8*, i8** @optarg
%12 = tail call i32 @strlen(i8* %11)
%13 = icmp sgt i32 %12, 0
br i1 %13, label %142, label %14
14: ; preds = %157, %136, %115, %94, %73, %52, %10, %17, %21, %25, %29, %33
%15 = phi i32 [ %7, %33 ], [ %7, %29 ], [ %7, %25 ], [ %7, %21 ], [ %7, %17 ], [ %7, %10 ], [ %53, %52 ], [ %74, %73 ], [ %95, %94 ], [ %7, %115 ], [ %7, %136 ], [ %7, %157 ]
%16 = phi i32 [ %8, %33 ], [ %8, %29 ], [ %8, %25 ], [ %8, %21 ], [ %8, %17 ], [ %8, %10 ], [ %8, %52 ], [ %8, %73 ], [ %8, %94 ], [ %116, %115 ], [ %137, %136 ], [ %158, %157 ]
br label %6
17: ; preds = %6
%18 = load i8*, i8** @optarg
%19 = tail call i32 @strlen(i8* %18)
%20 = icmp sgt i32 %19, 0
br i1 %20, label %121, label %14
21: ; preds = %6
%22 = load i8*, i8** @optarg
%23 = tail call i32 @strlen(i8* %22)
%24 = icmp sgt i32 %23, 0
br i1 %24, label %100, label %14
25: ; preds = %6
%26 = load i8*, i8** @optarg
%27 = tail call i32 @strlen(i8* %26)
%28 = icmp sgt i32 %27, 0
br i1 %28, label %79, label %14
29: ; preds = %6
%30 = load i8*, i8** @optarg
%31 = tail call i32 @strlen(i8* %30)
%32 = icmp sgt i32 %31, 0
br i1 %32, label %58, label %14
33: ; preds = %6
%34 = load i8*, i8** @optarg
%35 = tail call i32 @strlen(i8* %34)
%36 = icmp sgt i32 %35, 0
br i1 %36, label %37, label %14
37: ; preds = %33, %52
%38 = phi i64 [ %54, %52 ], [ 0, %33 ]
%39 = phi i32 [ %53, %52 ], [ %7, %33 ]
%40 = load i8*, i8** @optarg
%41 = getelementptr inbounds i8, i8* %40, i64 %38
%42 = load i8, i8* %41
switch i8 %42, label %52 [
i8 114, label %43
i8 119, label %46
i8 120, label %49
]
43: ; preds = %37
%44 = load i32, i32* @S_IRUSR
%45 = or i32 %44, %39
br label %52
46: ; preds = %37
%47 = load i32, i32* @S_IWUSR
%48 = or i32 %47, %39
br label %52
49: ; preds = %37
%50 = load i32, i32* @S_IXUSR
%51 = or i32 %50, %39
br label %52
52: ; preds = %37, %43, %49, %46
%53 = phi i32 [ %45, %43 ], [ %48, %46 ], [ %51, %49 ], [ %39, %37 ]
%54 = add nuw nsw i64 %38, 1
%55 = tail call i32 @strlen(i8* %40)
%56 = sext i32 %55 to i64
%57 = icmp slt i64 %54, %56
br i1 %57, label %37, label %14
58: ; preds = %29, %73
%59 = phi i64 [ %75, %73 ], [ 0, %29 ]
%60 = phi i32 [ %74, %73 ], [ %7, %29 ]
%61 = load i8*, i8** @optarg
%62 = getelementptr inbounds i8, i8* %61, i64 %59
%63 = load i8, i8* %62
switch i8 %63, label %73 [
i8 114, label %64
i8 119, label %67
i8 120, label %70
]
64: ; preds = %58
%65 = load i32, i32* @S_IRGRP
%66 = or i32 %65, %60
br label %73
67: ; preds = %58
%68 = load i32, i32* @S_IWGRP
%69 = or i32 %68, %60
br label %73
70: ; preds = %58
%71 = load i32, i32* @S_IXGRP
%72 = or i32 %71, %60
br label %73
73: ; preds = %58, %64, %70, %67
%74 = phi i32 [ %66, %64 ], [ %69, %67 ], [ %72, %70 ], [ %60, %58 ]
%75 = add nuw nsw i64 %59, 1
%76 = tail call i32 @strlen(i8* %61)
%77 = sext i32 %76 to i64
%78 = icmp slt i64 %75, %77
br i1 %78, label %58, label %14
79: ; preds = %25, %94
%80 = phi i64 [ %96, %94 ], [ 0, %25 ]
%81 = phi i32 [ %95, %94 ], [ %7, %25 ]
%82 = load i8*, i8** @optarg
%83 = getelementptr inbounds i8, i8* %82, i64 %80
%84 = load i8, i8* %83
switch i8 %84, label %94 [
i8 114, label %85
i8 119, label %88
i8 120, label %91
]
85: ; preds = %79
%86 = load i32, i32* @S_IROTH
%87 = or i32 %86, %81
br label %94
88: ; preds = %79
%89 = load i32, i32* @S_IWOTH
%90 = or i32 %89, %81
br label %94
91: ; preds = %79
%92 = load i32, i32* @S_IXOTH
%93 = or i32 %92, %81
br label %94
94: ; preds = %79, %85, %91, %88
%95 = phi i32 [ %87, %85 ], [ %90, %88 ], [ %93, %91 ], [ %81, %79 ]
%96 = add nuw nsw i64 %80, 1
%97 = tail call i32 @strlen(i8* %82)
%98 = sext i32 %97 to i64
%99 = icmp slt i64 %96, %98
br i1 %99, label %79, label %14
100: ; preds = %21, %115
%101 = phi i64 [ %117, %115 ], [ 0, %21 ]
%102 = phi i32 [ %116, %115 ], [ %8, %21 ]
%103 = load i8*, i8** @optarg
%104 = getelementptr inbounds i8, i8* %103, i64 %101
%105 = load i8, i8* %104
switch i8 %105, label %115 [
i8 114, label %106
i8 119, label %109
i8 120, label %112
]
106: ; preds = %100
%107 = load i32, i32* @S_IRUSR
%108 = or i32 %107, %102
br label %115
109: ; preds = %100
%110 = load i32, i32* @S_IWUSR
%111 = or i32 %110, %102
br label %115
112: ; preds = %100
%113 = load i32, i32* @S_IXUSR
%114 = or i32 %113, %102
br label %115
115: ; preds = %100, %106, %112, %109
%116 = phi i32 [ %108, %106 ], [ %111, %109 ], [ %114, %112 ], [ %102, %100 ]
%117 = add nuw nsw i64 %101, 1
%118 = tail call i32 @strlen(i8* %103)
%119 = sext i32 %118 to i64
%120 = icmp slt i64 %117, %119
br i1 %120, label %100, label %14
121: ; preds = %17, %136
%122 = phi i64 [ %138, %136 ], [ 0, %17 ]
%123 = phi i32 [ %137, %136 ], [ %8, %17 ]
%124 = load i8*, i8** @optarg
%125 = getelementptr inbounds i8, i8* %124, i64 %122
%126 = load i8, i8* %125
switch i8 %126, label %136 [
i8 114, label %127
i8 119, label %130
i8 120, label %133
]
127: ; preds = %121
%128 = load i32, i32* @S_IRGRP
%129 = or i32 %128, %123
br label %136
130: ; preds = %121
%131 = load i32, i32* @S_IWGRP
%132 = or i32 %131, %123
br label %136
133: ; preds = %121
%134 = load i32, i32* @S_IXGRP
%135 = or i32 %134, %123
br label %136
136: ; preds = %121, %127, %133, %130
%137 = phi i32 [ %129, %127 ], [ %132, %130 ], [ %135, %133 ], [ %123, %121 ]
%138 = add nuw nsw i64 %122, 1
%139 = tail call i32 @strlen(i8* %124)
%140 = sext i32 %139 to i64
%141 = icmp slt i64 %138, %140
br i1 %141, label %121, label %14
142: ; preds = %10, %157
%143 = phi i64 [ %159, %157 ], [ 0, %10 ]
%144 = phi i32 [ %158, %157 ], [ %8, %10 ]
%145 = load i8*, i8** @optarg
%146 = getelementptr inbounds i8, i8* %145, i64 %143
%147 = load i8, i8* %146
switch i8 %147, label %157 [
i8 114, label %148
i8 119, label %151
i8 120, label %154
]
148: ; preds = %142
%149 = load i32, i32* @S_IROTH
%150 = or i32 %149, %144
br label %157
151: ; preds = %142
%152 = load i32, i32* @S_IWOTH
%153 = or i32 %152, %144
br label %157
154: ; preds = %142
%155 = load i32, i32* @S_IXOTH
%156 = or i32 %155, %144
br label %157
157: ; preds = %142, %148, %154, %151
%158 = phi i32 [ %150, %148 ], [ %153, %151 ], [ %156, %154 ], [ %144, %142 ]
%159 = add nuw nsw i64 %143, 1
%160 = tail call i32 @strlen(i8* %145)
%161 = sext i32 %160 to i64
%162 = icmp slt i64 %159, %161
br i1 %162, label %142, label %14
163: ; preds = %6
%164 = load i8, i8* @optopt
switch i8 %164, label %169 [
i8 117, label %165
i8 111, label %165
i8 103, label %165
i8 85, label %165
i8 79, label %165
i8 71, label %165
]
165: ; preds = %163, %163, %163, %163, %163, %163
%166 = zext i8 %164 to i32
%167 = load i32, i32* @stderr
%168 = tail call i32 (i32, i8*, ...) @fprintf(i32 %167, i8* getelementptr inbounds ([41 x i8], [41 x i8]* @.str.1, i64 0, i64 0), i32 %166)
br label %179
169: ; preds = %163
%170 = tail call i32 @isprint(i8 zeroext %164)
%171 = icmp eq i32 %170, 0
%172 = load i32, i32* @stderr
%173 = load i8, i8* @optopt
%174 = zext i8 %173 to i32
br i1 %171, label %177, label %175
175: ; preds = %169
%176 = tail call i32 (i32, i8*, ...) @fprintf(i32 %172, i8* getelementptr inbounds ([30 x i8], [30 x i8]* @.str.2, i64 0, i64 0), i32 %174)
br label %179
177: ; preds = %169
%178 = tail call i32 (i32, i8*, ...) @fprintf(i32 %172, i8* getelementptr inbounds ([41 x i8], [41 x i8]* @.str.3, i64 0, i64 0), i32 %174)
br label %179
179: ; preds = %175, %177, %165
%180 = load i8*, i8** %1
%181 = tail call i32 @DisplayUsage(i8* %180)
%182 = tail call i32 @puts(i8* dereferenceable(1) getelementptr inbounds ([15 x i8], [15 x i8]* @str.12, i64 0, i64 0))
br label %240
183: ; preds = %6
%184 = tail call i32 (...) @abort()
unreachable
185: ; preds = %6
%186 = icmp eq i32 %0, 1
br i1 %186, label %187, label %190
187: ; preds = %185
%188 = load i8*, i8** %1
%189 = tail call i32 @DisplayUsage(i8* %188)
br label %232
190: ; preds = %185
%191 = load i32, i32* @optind
%192 = icmp slt i32 %191, %0
br i1 %192, label %193, label %232
193: ; preds = %190
%194 = getelementptr inbounds %struct.stat, %struct.stat* %3, i64 0, i32 0
%195 = icmp ne i64 %4, 0
%196 = getelementptr inbounds %struct.stat, %struct.stat* %3, i64 0, i32 1
%197 = xor i32 %8, -1
%198 = sext i32 %191 to i64
br label %199
199: ; preds = %193, %226
%200 = phi i64 [ %198, %193 ], [ %228, %226 ]
%201 = phi i8 [ 0, %193 ], [ %227, %226 ]
%202 = getelementptr inbounds i8*, i8** %1, i64 %200
%203 = load i8*, i8** %202
%204 = call i64 @stat(i8* %203, %struct.stat* %3)
%205 = icmp slt i64 %204, 0
br i1 %205, label %206, label %208
206: ; preds = %199
%207 = call i32 @perror(i8* getelementptr inbounds ([7 x i8], [7 x i8]* @.str.5, i64 0, i64 0))
br label %215
208: ; preds = %199
%209 = load i64, i64* %194
%210 = icmp ne i64 %209, %4
%211 = and i1 %195, %210
br i1 %211, label %212, label %215
212: ; preds = %208
%213 = load i32, i32* @stderr
%214 = call i32 (i32, i8*, ...) @fprintf(i32 %213, i8* getelementptr inbounds ([37 x i8], [37 x i8]* @.str.6, i64 0, i64 0))
br label %215
215: ; preds = %208, %212, %206
%216 = phi i8 [ 1, %206 ], [ 1, %212 ], [ %201, %208 ]
%217 = load i32, i32* %196
%218 = or i32 %217, %7
%219 = and i32 %218, %197
store i32 %219, i32* %196
%220 = load i8*, i8** %202
%221 = call i32 @chmod(i8* %220, i32 %219)
%222 = icmp eq i32 %221, -1
br i1 %222, label %223, label %226
223: ; preds = %215
%224 = load i8*, i8** %202
%225 = call i32 @perror(i8* %224)
br label %226
226: ; preds = %215, %223
%227 = phi i8 [ 1, %223 ], [ %216, %215 ]
%228 = add nsw i64 %200, 1
%229 = trunc i64 %228 to i32
%230 = icmp eq i32 %229, %0
br i1 %230, label %231, label %199
231: ; preds = %226
br i1 %192, label %234, label %232
232: ; preds = %190, %187, %231
%233 = call i32 @puts(i8* dereferenceable(1) getelementptr inbounds ([33 x i8], [33 x i8]* @str.11, i64 0, i64 0))
br label %240
234: ; preds = %231
%235 = icmp eq i8 %227, 0
br i1 %235, label %238, label %236
236: ; preds = %234
%237 = call i32 @puts(i8* dereferenceable(1) getelementptr inbounds ([15 x i8], [15 x i8]* @str.10, i64 0, i64 0))
br label %240
238: ; preds = %234
%239 = call i32 @puts(i8* dereferenceable(1) getelementptr inbounds ([15 x i8], [15 x i8]* @str, i64 0, i64 0))
br label %240
240: ; preds = %238, %236, %232, %179
%241 = phi i32 [ 1, %179 ], [ 2, %232 ], [ 2, %236 ], [ 0, %238 ]
ret i32 %241
}